Skip to content

plot empty dataframe fails if facet_col/row is specified #3984

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Gabriel-ROBIN opened this issue Dec 15, 2022 · 0 comments · Fixed by #4038
Closed

plot empty dataframe fails if facet_col/row is specified #3984

Gabriel-ROBIN opened this issue Dec 15, 2022 · 0 comments · Fixed by #4038
Labels
bug something broken

Comments

@Gabriel-ROBIN
Copy link

In most cases plotting with an empty data_frame works nicely, I mean, it shows a figure with no traces but with the good layout.
But if we specify a facet_col or facet_row it fails.

import plotly.express as px
import pandas as pd
px.bar(
    pd.DataFrame(columns=['A', 'B', 'X']),
    x = 'A',
    y = 'X',
    facet_col = 'B'
)

I would expect the same result as if facet_col was None. As it is already the case for animation_frame

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something broken
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants