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.

lineplot: rotate fig in 90° (plot x as a function of y)

See original GitHub issue

Adding an optiion to rotate a seaborn.lineplot so that the result will be as a function of y and not a function of x.

For example, this code:

    import pandas as pd
    import seaborn as sns
    df = pd.DataFrame([[0,1],[0,2],[0,1.5],[1,1],[1,5]], columns=['group','val'])
    sns.lineplot(x='group',y='val',data=df)

Create this figure:

enter image description here

But as far as I understand there is no way to rotate the figure in 90° ? so that in the X we will have “val” and in Y we will have “group” and the std will go from left to right and not from bottom to up.

I assume something like

sns.lineplot(x='group',y='val',data=df, orientation='vertica') #orient : “v” | “h”, optional

will be great.

See also: https://stackoverflow.com/questions/54445044/how-to-rotate-a-seaborn-lineplot/54448926#54448926 Thanks

Issue Analytics

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

github_iconTop GitHub Comments

21reactions
mwaskomcommented, Jan 31, 2019

No, sorry.

7reactions
orena1commented, Jan 31, 2019

I understand that currently it is not possible? but can’t you reopen the ticket and mark is a feature request? Thanks

Read more comments on GitHub >

github_iconTop Results From Across the Web

How can I rotate a matplotlib plot through 90 degrees?
I'd like to rotate the top left quadrant subplot through 90deg counterclockwise, so that the x-axis of that plot lies along the y-axis...
Read more >
Rotating axis labels in matplotlib and seaborn
Rotating axis labels is the classic example of something that seems like an obvious tweak, but can be tricky.
Read more >
Rotate axis tick labels in Seaborn and Matplotlib
So we solve this problem by Rotating x-axis labels or y-axis labels. Rotating X-axis Labels in Matplotlib. We use plt.xticks(rotation=#) where # ...
Read more >
Rotate Tick Labels in Matplotlib - Stack Abuse
In this tutorial, we'll take a look at how to rotate tick text/labels in a Matplotlib plot. Creating a Plot. Let's create a...
Read more >
Chapter 4. Visualization with Matplotlib - O'Reilly
At this point, any plt plot command will cause a figure window to open, ... simplest of all plots is the visualization of...
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