anyway to add grid based on right yyaxis
Show older comments
Hi:
is there anyway to add grid based on right yyaxis instead of the left one?

Thanks!
Yu
Accepted Answer
More Answers (2)
Cris LaPierre
on 19 Dec 2018
0 votes
It does not appear to be possible to add a grid line to the right axis when plotting using yyaxis. There are methods available in Answers if you use plotyy.
Grid Lines
Grid lines correspond with the tick mark locations along the left y-axis.
Matthew Wiser
on 25 Oct 2022
0 votes
Well, then swap your plotting variables so that the variable you want to have aligned grid lines is on the left.
Not being a smart alec, but if you can't beat the system, then use the system.
Categories
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!