question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Feature request: allow non-symmetrical violint plots

See original GitHub issue

Hi! I love violinplots, but I always found that it might not be needed to plot them as symmetrical, the information is doubly present for no real reason. I will send a tiny pull request that adds a key-word argument nonsymmetrical to seaborn.violint, it can be False (the default), or "left" or "right" (or "bottom" or "top") to allow to only plot half of the violin.

Here are two tiny demos, for a single violin or more violins, for horizontal (top/bottom) or vertical (left/right) cases: proposal nonsymmetrical violin plots 1 proposal nonsymmetrical violin plots 2

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
givenxcommented, Sep 30, 2019

kind='kde'to sns.catplot would be perfect. We have had multiple requests from our clients to drop the symmetry as it can be off-putting. I think it is more important than you realise, @mwaskom, imho.

1reaction
njvackcommented, Apr 22, 2019

For what it’s worth, I’m looking for half-violin plots for Raincloud plots. That package has its own implementation but… it’s mainly a copy of your code.

You can jigger seaborn to do half-violins by adding fake off-scale data to yourset and abusing the hue parameter, but that’s pretty gross.

A more useful alternative, though, might be to add kind='kde'to sns.catplot — really, a violin plot is just two kdeplots pasted together.

Thoughts?

Read more comments on GitHub >

github_iconTop Results From Across the Web

A Complete Guide to Violin Plots | Tutorial by Chartio
Violin plots are used to compare the distribution of data between groups. Learn how violin plots are constructed and how to use them...
Read more >
Analyzing the fine structure of distributions - PLOS
The Python density and violin plots draw data above and below the limits of the data but show the bimodality of the ITS...
Read more >
Box Plot Blunders
Still, it offers one extra goodie: asymmetrical plotting. An asymmetrical beanplot. The distribution-mirroring in violin plots is just a visual convention and ...
Read more >
Violin Plots 101: Visualizing Distribution and Probability Density
A violin plot is a hybrid of a box plot and a kernel density plot, which shows peaks in the data. It is...
Read more >
Violin plots - GraphPad Prism 9 User Guide
What is a violin plot? When you enter replicate values in side-by-side replicates in an XY or Grouped table, or stacked in a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found