Skip to content

Setting category_orders leads to missing data (master branch) #4875

Closed
@LiamConnors

Description

@LiamConnors

This example from the docs, shows how to define the category orders:

import plotly.express as px
df = px.data.tips()
fig = px.bar(df, x="day", y="total_bill", color="smoker", barmode="group", facet_col="sex",
             category_orders={"day": ["Thur", "Fri", "Sat", "Sun"],
                              "smoker": ["Yes", "No"],
                              "sex": ["Male", "Female"]})
fig.show()

And renders like this:

Image

The same example run with plotly built from master branch, only shows the bars for Sunday:

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1needed for current cyclebugsomething broken

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions