plotyy
- : plotyy
(x1, y1, x2, y2)¶ - : plotyy
(…, fun)¶ - : plotyy
(…, fun1, fun2)¶ - :
[ax, h1, h2] =plotyy(…)¶ Plot two data sets against separate y axes, one on the left and one on the right.
The pair (x1, y1) is drawn on the left axes by the plotting function fun1 (default
plot) and (x2, y2) on the right axes by fun2 (default fun1). Each function is a function handle or a name such as"semilogx"or"stem"and is called asfun (ax, x, y).The right axes is transparent and lies on top of the left one; its y axis is on the right. Both x limits are made equal and only the left axes shows x tick labels. The y axis colours follow the first plotted object of their side. The outputs are the axes handles ax = [left right] and the handles h1, h2 of the objects created on each side.