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

Minor issue // plot.show_cycles() throws AttributeError #90

Closed
Thomas-Moore-Creative opened this issue Dec 19, 2019 · 2 comments
Closed
Labels

Comments

@Thomas-Moore-Creative
Copy link

import proplot as plot
f = plot.show_cycles()

Thanks for this great package!
I'm running 0.3.1 and just working my way through your docs. I noted above from your docs throws the following error:

AttributeError: 'LinearSegmentedColormap' object has no attribute 'colors'

@lukelbd lukelbd added the bug label Dec 19, 2019
@lukelbd
Copy link
Collaborator

lukelbd commented Jan 3, 2020

No problem :). I figured this out: The current show_cycles command is fragile; it just tracks cycle names, and evidently you have overwritten a cycle by that name with a colormap.

The next version includes changes to show_cycles that will solve this issue: plot.show_cycles will be identical to plot.show_cmaps, the only difference being that plot.show_cmaps displays LinearSegmentedColormaps (continuous color gradations) while plot.show_cycles displays ListedColormaps (discrete color sets).

@lukelbd
Copy link
Collaborator

lukelbd commented Jan 7, 2020

This should be fixed by #98. It is published in the latest (0.4.0) release; use pip install --upgrade proplot to upgrade.

@lukelbd lukelbd closed this as completed Jan 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants