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

Seaborn categorical plot issue #133

Open
sjg2203 opened this issue Oct 3, 2023 · 1 comment
Open

Seaborn categorical plot issue #133

sjg2203 opened this issue Oct 3, 2023 · 1 comment

Comments

@sjg2203
Copy link

sjg2203 commented Oct 3, 2023

Hi,
I have been using this package for quite some time but came back to it more recently to find it broken when trying to plot violin plot with Seaborn
I have tried with Seaborn 0.13 and Pandas 2.1.1, which got me this error (see below), then downgraded Seaborn 0.11.2 and Pandas 1.5.3, same error, even created another conda env with just the required package (Seaborn 0.11.2 and Pandas 1.5.3) and still gets me the same error message
It seems that Seaborn has removed the use of _ViolinPlotter in categorical.py
A solution would be to update this package to actual versions of Seaborn and Pandas, which both received important updates and because it's the only stats annotator package on Python, or at least update the calling names for Seaborn plots

  File "<ipython-input-4-827f267a0f19>", line 8, in <module>
    annotator=Annotator(ax,pairs=[('C1','Mt')],plot='violinplot',data=df,x='Classification',y='X2')
  File "C:\ProgramData\miniforge\envs\statenv\lib\site-packages\statannotations\Annotator.py", line 108, in __init__
    self._plotter = self._get_plotter(engine, ax, pairs, plot, data,
  File "C:\ProgramData\miniforge\envs\statenv\lib\site-packages\statannotations\Annotator.py", line 784, in _get_plotter
    return engine_plotter(*args, **kwargs)
  File "C:\ProgramData\miniforge\envs\statenv\lib\site-packages\statannotations\_Plotter.py", line 87, in __init__
    self.plotter = self._get_plotter(plot, x, y, hue, data, order,
  File "C:\ProgramData\miniforge\envs\statenv\lib\site-packages\statannotations\_Plotter.py", line 157, in _get_plotter
    plotter = sns.categorical._ViolinPlotter(
AttributeError: module 'seaborn.categorical' has no attribute '_ViolinPlotter'

Cheers!

@moqri
Copy link

moqri commented Feb 26, 2024

same issue here:
AttributeError: module 'seaborn.categorical' has no attribute '_BoxPlotter'

any updates?

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

No branches or pull requests

2 participants