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

Generate jitter plots in Matplotlib #486

Merged
merged 6 commits into from
Apr 10, 2023
Merged

Generate jitter plots in Matplotlib #486

merged 6 commits into from
Apr 10, 2023

Conversation

yoda-vid
Copy link
Collaborator

@yoda-vid yoda-vid commented Apr 3, 2023

This PR is a round-up that adds a couple options to the wrapper for generating scatter plots in Matplotlib. These settings extend similar functionality from the swarm plot wrapper in Seaborn to the scatter plot wrapper.

  • jitter parameter to add "jitter" to point x-value positions, which helps distinguish overlapping points
  • rotation parameter to rotate x-tick labels

Additional changes:

  • Fixed more NumPy references to data types now that these references have been removed from NumPy
  • Matplotlib core fonts are set for PDF and PS export so text is editable without embedding font info

Support jitter to distinguish points that have similar x-values. This parameter allows titrating the width of jittering.
Support label rotation similarly to the swarm plot wrapper, but default to no rotation.
- Change additional NumPy references to data types that must now be accessed directly as Python types
- Remove trailing spaces in a related function
Add settings to use core fonts when exporting these file formats as recommended by Matplotlib to avoid needed to embed any font information (https://matplotlib.org/stable/users/explain/fonts.html#core-fonts) and to fix vector text in some PDF readers. Add these parameters whenever setting up a new style since included style groups may often override these settings. Allow them to be overridden by individual style settings, however.
@yoda-vid yoda-vid merged commit a4e0472 into master Apr 10, 2023
@yoda-vid yoda-vid deleted the jitter_plot branch April 10, 2023 06:27
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.

1 participant