Skip to content

NestedFrame.drop(columns=["nested.t"]) doesn't work #367

@hombit

Description

@hombit

Bug report

It looks like only nf.drop(labels=..., axis=1) is supported for nested columns, not nf.drop(columns=...), which is confusing:

from nested_pandas.datasets import generate_data

nf = generate_data(3, 2)
nf.drop(labels="a", axis=1)  # works
nf.drop(columns="a")  # works
nf.drop(labels="nested.t", axis=1)  # works
nf.drop(columns="nested.t")  # fails

Before submitting
Please check the following:

  • I have described the situation in which the bug arose, including what code was executed, information about my environment, and any applicable data others will need to reproduce the problem.
  • I have included available evidence of the unexpected behavior (including error messages, screenshots, and/or plots) as well as a description of what I expected instead.
  • If I have a solution in mind, I have provided an explanation and/or pseudocode and/or task list.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions