Skip to content
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

feat: (Series | DataFrame).plot.bar #1152

Merged
merged 5 commits into from
Nov 21, 2024
Merged

Conversation

chelsea-lin
Copy link
Contributor

Fixes internal issue 375905303🦕

@chelsea-lin chelsea-lin requested review from a team as code owners November 14, 2024 19:45
@chelsea-lin chelsea-lin requested a review from shobsi November 14, 2024 19:45
@product-auto-label product-auto-label bot added the size: m Pull request size is medium. label Nov 14, 2024
@product-auto-label product-auto-label bot added the api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. label Nov 14, 2024
@chelsea-lin chelsea-lin force-pushed the main_chelsealin_plotbar branch from 47a02f4 to aa1ecb0 Compare November 14, 2024 19:51
Comment on lines +84 to +100
class BarPlot(SamplingPlot):
@property
def _kind(self) -> typing.Literal["bar"]:
return "bar"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does bar plot make sense as a sampling plot? It seems that bar plots are really meant for small-cardinalities and don't down-sample well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The bar plots are discrete while the area/line/scatter plots are continuous. Hence, the downsampling in the bar is not straightforward compared to others. Thanks for suggestions here. I just added a warning message to suggest users to consider pre-processing data (aggregations or select top categories).

@chelsea-lin chelsea-lin merged commit 0fae2e0 into main Nov 21, 2024
23 checks passed
@chelsea-lin chelsea-lin deleted the main_chelsealin_plotbar branch November 21, 2024 21:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants