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.

Secondary and Multiple x and y axis

See original GitHub issue

Hello,

searched repository and documentation for secondary x & y axis, @has2k1 you mentioned in #63 , “When Matplotlib ships the constraint layout manager, I’ll look into adding secondary axes functionality.”

Do you have any idea what the approx timeframe for this is, months or quarters away?

For the finance guys having not only secondary but multiple x & y axes is extremely handy, which is something that users of bloomberg and reuters eikon are familiar with, and has been a major problem for excel users as they still haven’t managed to even introduce a tertiary, or let alone even more levels in axes options, people have to index data if they need to compare more than 2 different time series still even in excel 2016 as we all know, which is a time consuming pain.

2017-10-19_14-15-32

e.g.

(ggplot(df, aes(x1="", x2="", x3="", ...  , y1="" y2="", y3="", ... ))
+ scale_x1_datetime(breaks=date_breaks('1 year'), 
+ scale_x2_datetime(breaks=date_breaks('1 quarter'),
+ scale_x3_datetime(breaks=date_breaks('1 month'), 
+ geom_line(aes(y1='US'), color='#00355F', size=1)
+ geom_line(aes(y2='Turkey'), color='#2494EA', size=1)
+ geom_line(aes(y3='Australia'), color='#0222FF', size=1)
+ labs(x1="", x2="", x3="", y1="" y2="", y3="")

matplot example code: multiple_yaxis_with_spines.py https://matplotlib.org/gallery/ticks_and_spines/multiple_yaxis_with_spines.html

Kind Regards,

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:1
  • Comments:11 (4 by maintainers)

github_iconTop GitHub Comments

26reactions
xuhuizhangcommented, Nov 17, 2018

Looking forward to the Secondary y axis in the coming version. Now I have to use the pyplot.twinx() after the ggplot command, but clearly not a good solution for Secondary y axis . Really Wish to have the scale_y_continuous(sec.axis = sec_axis(~./200)) as same as the R-ggplot2.

16reactions
himalayajungcommented, Mar 17, 2021

This feature would be hugely helpful. Thank you for this great package.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Add or remove a secondary axis in a chart in Excel
The scale of the secondary vertical axis shows the values for the associated data series. A secondary axis works well in a chart...
Read more >
Display Data with Multiple Scales and Axes Limits - MathWorks
Learn about techniques for visualizing data with multiple x- and y-axes, multiple colorbars, or with an x-axis that is broken into intervals.
Read more >
How to Add a Secondary Axis in Excel Charts (Easy Guide)
In this tutorial, I will show you how to add a secondary axis to a chart in ... Note that in the above...
Read more >
Dual Y axis with R and ggplot2 - The R Graph Gallery
This post describes how to build a dual Y axis chart using R and ggplot2. It uses the sec.axis attribute to add the...
Read more >
Multiple axes in Python - Plotly
How to make a graph with multiple axes (dual y-axis plots, plots with secondary axes) in python. New to Plotly?
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