olgabot / prettyplotlib

Painlessly create beautiful matplotlib plots.
olgabot.github.io/prettyplotlib
MIT License
1.69k stars 148 forks source link

remove_chartjunk bug using the ticklabels kwarg #81

Closed aboucaud closed 10 years ago

aboucaud commented 10 years ago

When I try using the remove_chartjunk method for getting rid of axes plus BOTH ticklabels, that is

ppl.utils.remove_chartjunk(ax, ['top', 'right', 'left', 'bottom'], ticklabels=['x', 'y'])

only the x-axis ticklabels are suppressed. Same happens if I swap the axes, e.g. ticklabels=['y', 'x']. Looking at the code, the issue seems to reside in a misused elif statement.

olgabot commented 10 years ago

Thank you for your comment. Unfortunately, I no longer have the bandwidth to maintain prettyplotlib. I recommend using seaborn. Using seaborn, to get the prettyplotlib style, do:

import seaborn as sns
sns.set(style='ticks', palette='Set2')

And to remove "chartjunk", do:

sns.despine()

If you have discrete pull requests, I will accept them, but I personally will no longer fix bugs.

If you are a biological scientist looking for ways to analyze your big-ish (20+ samples) data, check out my main project, flotilla.