Connect scatter line in multiple y axis
3 views (last 30 days)
Show older comments
Commented: Matt on 19 Sep 2014
I have two y axis and one x axis plot.
[ax, h1, h2] = plotyy(x,y1,x,y2,'scatter');
It connected the first scatter lines. But i cant conned the second scatter lines. Please help?
per isakson on 19 Sep 2014
Edited: per isakson on 19 Sep 2014
Add this line to the code
line( x, y2, 'Parent', ax(2) )
plotyy adds two axes on top of each other with ax(2) on top. Don't ask me why, but this line of code seems to add a visible line object. (I look forward to HG2.)
More Answers (0)
Find more on Two y-axis in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!