Skip to content

BUG: concat on axis=0 with categorical #10177

Closed
@jreback

Description

@jreback

xref #9426, fixed in #9597
axis=1 is ok

df1 = pandas.DataFrame(numpy.random.randn(6, 3), columns=["a", "b", "c"])
df2 = pandas.DataFrame(numpy.random.randn(7, 4), columns=["g", "h", "a", "c"])
df2['h'] = pandas.Series(pandas.Categorical(["one", "one", "two", "one", "two", "two", "one"]))
df = pandas.concat((df1, df2))

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugCategoricalCategorical Data TypeReshapingConcat, Merge/Join, Stack/Unstack, Explode

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions