We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
dodge
FacetGrid
pointplot
This seems to be the same issue as this but in a different circumstance: #3553
If do the following:
g = sns.FacetGrid( df, col="col_field", hue="hue_field", ) g.map( sns.pointplot, 'x_field', 'y_field', estimator='mean', errorbar='sd', linestyles='none', markers='x', dodge=0.1, )
I get this error:
File ~/miniconda3/envs/my_env/lib/python3.10/site-packages/seaborn/categorical.py:1217, in _CategoricalPlotter.plot_points(self, aggregator, markers, linestyles, dodge, color, capsize, err_kws, plot_kws) 1208 agg_data = sub_data if sub_data.empty else ( 1209 sub_data 1210 .groupby(self.orient) (...) 1213 .reset_index() 1214 ) 1216 if dodge: -> 1217 hue_idx = self._hue_map.levels.index(sub_vars["hue"]) 1218 step_size = dodge / (n_hue_levels - 1) 1219 offset = -dodge / 2 + step_size * hue_idx AttributeError: 'NoneType' object has no attribute 'index'
If I set dodge=True instead of a value I do not get an error but the dodge is not applied
dodge=True
The text was updated successfully, but these errors were encountered:
Please provide a reproducible example. But I bet the issue is that you are passing the hue argument to the FacetGrid instead of inside map.
hue
map
Sorry, something went wrong.
Yes — this wouldn't work anyway, even if it gave a better error message. I think you want to use catplot here.
catplot
No branches or pull requests
This seems to be the same issue as this but in a different circumstance: #3553
If do the following:
I get this error:
If I set
dodge=True
instead of a value I do not get an error but the dodge is not appliedThe text was updated successfully, but these errors were encountered: