-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
[ENH]: contour kwarg for negative_linestyle #23028
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
Comments
Should the current The following code snippet and images will show a solution with an added kwarg, but I expect this is not exactly what you had in mind.
Default
|
How would we squeeze this into the current |
I had no good solution for this either, but thought I would ask just in case. The next question is:
I think the latter makes a lot more sense, but I don't work with contour plots regularly. |
I think since the rcParam is separate, its fine to keep the (potential) kwarg separate. BTW I'm not wedded to this idea, but it does seem strange to have a feature only accessible by rcParam. As for bool vs string, I'd say both? right now the rcParam defaults to "dashed" - I think that's fine for a kwarg as well, but being able to say False to skip the behaviour would be nice as well. |
I can mock-up a basic solution. Maybe we can get opinions from other contributors and maintainers in the meantime. I think this would add value because it would make customization of negative contours more straightforward. Since this doesn't require removing any current functionality, I don't see any cons to adding the kwarg. |
Problem
if you contour a negative quantity, it gets dashed lines. Leaving aside whether this is a good default or not, the only way to toggle this is via
rcParams['contour.negative_linestyle']=False
.Proposed solution
I think this should be togglable via kwarg, though I appreciate that overlaps with
linestyle
and only is activated with monochrome contours.(I actually think the default should be False, FWIW - this surprises me every time, and I make quite a few contour plots).
The text was updated successfully, but these errors were encountered: