Plotyy y axis properties

2 vues (au cours des 30 derniers jours)
Ziv Kassner
Ziv Kassner le 1 Oct 2015
Commenté : Ziv Kassner le 1 Oct 2015
My script is:
[a,az,b2t] = plotyy(1:r , Vazimuth , 1:r , b2t);
set(az(1),'YLim',[0 159])
set(az(1),'YTick',[0:10:159])
set(b2t(2),'YLim',[-2000 2499])
set(b2t(2),'YTick',[-2000:100:2499])
and i keep getting an error of:
endError using matlab.graphics.chart.primitive.Line/set
endThere is no YLim property on the Line class.
I just want to control both 'y' axes limits.
thank you,
Ziv

Réponse acceptée

Walter Roberson
Walter Roberson le 1 Oct 2015
[a,az,b2t] = plotyy(1:r , Vazimuth , 1:r , b2t);
set(a(1),'YLim',[0 159])
set(a(1),'YTick',[0:10:159])
set(a(2),'YLim',[-2000 2499])
set(a(2),'YTick',[-2000:100:2499])
  1 commentaire
Ziv Kassner
Ziv Kassner le 1 Oct 2015
Great!

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Two y-axis dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by