Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Adjust the amount of jitter for a Plotly strip plot?

Is there a way to adjust the amount of jitter for a plotly strip plot? That is, the equivolent of the jitter parameter in seaborn.stripplot. I could not find anything from the plotly strip documentation. Thank you.

>Solution :

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Jitter is enabled for graph updates, although it cannot be specified directly in plotly.express. 1.0 is the maximum value. Jitter is enabled from the reference example.

import plotly.express as px

df = px.data.tips()
fig = px.strip(df, x="total_bill", y="day",)

fig.update_traces(jitter=1.0)
fig.show()

enter image description here

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading