Standard Library procedure that establishes a newposition for the rectangular plot area based on input values specified using the normalized coordinate system.
xmax The position of the right edge of the rectangular plot area in normal coordinates.
ymin (optional) The position of the bottom edge of the rectangular plot area in normal coordinates.
ymax (optional) The position of the top edge of the rectangular plot area in normal coordinates.
If only xmin and xmax are provided, the values for ymin and ymax are calculated. Calling SET_VIEWPORT with four input parameters is the same as setting the !P.Postion system variable or using the Position keyword with the plotting commands.
SET_VIEWPORT overrides the effect of the system variables !X.Margin and !Y.Margin.
SET_VIEWPORT, .2, .5 PLOT, [3, 5, 2] SET_VIEWPORT, .1, .45, .55, .90 PLOT, [3, 4, 5], Title='Upper left plot' SET_VIEWPORT, .1, .45, .1, .45 PLOT, [5, 1, 6], Title='Lower left plot', /Noerase SET_VIEWPORT, .55, .90, .55, .90 PLOT, [3, 4, 5], Title='Upper right plot', /Noerase SET_VIEWPORT, .55, .90, .1, .45 PLOT, [2, 4, 3], Title='Lower right plot', /Noerase SET_VIEWPORT, 1, 1, 1, 1, /Cursor
PLOT, [3, 5, 4] SET_VIEWPORT, .2, .8, .2, .8 PLOT, [3, 4, 5], Title='Without setting the region keyword' SET_VIEWPORT, .2, .8, .2, .8, /Region PLOT, [3, 4, 5], Title='With the region keyword set', /Noerase
System Variables: !P.Position, !P.Region