plotyy
Plot two data sets on different left and right y-axes.
Syntax
Section titled “Syntax”[ax, h1, h2] = plotyy(x1, y1, x2, y2, ...)Description
Section titled “Description”Plots y1 vs x1 against the left y-axis and y2 vs x2 against an overlay right y-axis. Useful when two series share the x-axis but have very different magnitudes. Returns the axes handle and the two graph handles.
Example
Section titled “Example”plotyy(x, temperature, x, pressure)See also
Section titled “See also”plot— 2D line / marker plot.yyaxis