Skip to content

Fix to the issue #3922#3938

Open
bidyut18 wants to merge 1 commit into
mwaskom:masterfrom
bidyut18:hue_color
Open

Fix to the issue #3922#3938
bidyut18 wants to merge 1 commit into
mwaskom:masterfrom
bidyut18:hue_color

Conversation

@bidyut18

@bidyut18 bidyut18 commented May 3, 2026

Copy link
Copy Markdown

Title

Fix of hue_order which get ignored in categorical plots when hue is a pandas Categorical
I observed this issue only in pd.Categorical

Description of the bug

When a pandas Categorical column is used for hue with hue_order is provided, violinplot ignore the user’s order and draw the hue levels based on CategoricalDtype. Therefore, Order is reversed.

Solution

My solution is to manually add a check to ensure that integrity of hue_order thus fixing the bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant