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

Implements a new version of symlog that is smooth around linthresh #481

Merged
merged 4 commits into from Sep 23, 2011

Conversation

mdboom
Copy link
Member

@mdboom mdboom commented Sep 19, 2011

Implements a new version of symlog that is smooth around linthresh contributed by ssyr. Also includes a cleaner implementation of the symlog ticker. Closes #396.

…ntributed by ssyr. Also includes a cleaner implementation of the symlog ticker. Closes matplotlib#396.
@mdboom
Copy link
Member Author

mdboom commented Sep 19, 2011

@efiring: Can you elaborate on where the mask is being thrown away? Plotting a masked array does appear to work.

@efiring
Copy link
Member

efiring commented Sep 19, 2011

On 09/19/2011 04:02 AM, Michael Droettboom wrote:

@efiring: Can you elaborate on where the mask is being thrown away? Plotting a masked array does appear to work.

Every use of np.asarray throws away the mask, starting with the first
line in transform(), 327.

I have not tested in actual use, so maybe this is being compensated or
taken into account somewhere else; but based on looking at the code, it
appears to be an anomaly in the SymmetricalLogTransform family.

@mdboom
Copy link
Member Author

mdboom commented Sep 20, 2011

Ok. It doesn't seem to make any practical difference, but I've removed the "asarray" calls in the transformation functions.

@WeatherGod
Copy link
Member

Those asarray() calls wouldn't change anything. I think it is the calls to asarray() for the returns that could be the issue. I don't see why we even need a call to asarray() there (except possibly for the second return, but that should still be asanyarray()

@efiring
Copy link
Member

efiring commented Sep 20, 2011

Ben, I don't see how you can say those initial asarray calls don't change anything; they are explicitly throwing away any mask at the start.

@WeatherGod
Copy link
Member

Sorry, I wasn't clear... they don't do anything useful for the code and are completely unnecessary.

@mdboom
Copy link
Member Author

mdboom commented Sep 23, 2011

I've removed all of the redundant "asarray"s. I believe this pull is ready to merge now.

efiring added a commit that referenced this pull request Sep 23, 2011
Implements a new version of symlog that is smooth around linthresh
@efiring efiring merged commit 187f403 into matplotlib:master Sep 23, 2011
@mdboom mdboom deleted the symlog_bugs branch March 3, 2015 18:44
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.

Plotting with negative x values on semilogx
3 participants