Skip to content

Allow 3D references as argument to xl method #37

Open

Description

@ncalm

It would be incredibly useful to be able to pass 3D references into the xl method.

Suppose you have some data in B2:K11 on each of sheets 1, 2 and 3.

We might have a 3D reference:

Sheet1:Sheet3!B2:K11

The xl method currently doesn't allow this type of reference.

It would be useful to be able to create one of the following from such a reference:

  • 3D np.ndarray
  • list of dataframes (one per sheet)
  • dictionary of dataframes (one per sheet)
  • sheets concatenated into a single pd.DataFrame (with a metadata column for sheet_name added by the function)

I'm sure all of this is possible by passing a callback to excel.set_xl_array_conversion, but the issue is that the xl method doesn't recognize 3D arrays at all, so it's not possible.

Activity

  1. keyur32 commented on Oct 4, 2023

    @keyur32
    Collaborator

    Thanks for this Owen Price (@ncalm)! Yes, we currently do not support this behavior so would be interested, so don't have an ETA.

    There are some not-great workarounds, for example putting your references into data frames (or whatever object you have overridden in your conversion functions). And then combining them in a subsequent python cell.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions