yorick banner

Home

Manual

Packages

Global Index

Keywords

Quick Reference

Back: Plot limits Forward: mouse zooming   FastBack: Plotting primitives Up: Plot limits FastForward: logxy         Top: Yorick Contents: Table of Contents Index: Concept Index About: About this document

3.2.1 limits

There are several ways to change the plot limits: The limits command, the range command, and mouse clicks or drags. Also, the unzoom command undoes all mouse zooming operations.

The syntax of the limits command is:

 
limits, xmin, xmax, ymin, ymax

Each of the specified limits can be a number, the string "e" to signal the corresponding extreme value of the data, or nil to leave the limit unchanged. For example, to set the plot limits to run from 0.0 to the maximum x in the data plotted, and from the current minimum y value to the maximum y in the data, you would use:

 
limits, 0.0, "e", , "e"

If both xmin and xmax (or ymin and ymax) are numbers, you can put xmin greater than xmax (or ymin greater than ymax) to get a scale that increases to the right (or down) instead of the more conventional default scale increasing to the left (or up).

As a special case, limits with no arguments is the same as setting all four limits to their extreme values (rather than the no-op of leaving all four limits unchanged). Hence, if you can't see what you just plotted, a very simple way to guarantee that you'll be able to see everything in the current picture is to type:

 
limits

If you just want to change the x axis limits, type:

 
limits, xmin, xmax

As a convenience, if you just want to change the y axis limits, you can use the range function (instead of typing three consecutive commas after the limits command):

 
range, ymin, ymax

3.2.1.1 Zooming with the mouse  How to zoom by mouse clicks.
3.2.1.2 Saving plot limits  Save and restore plot limits.
3.2.1.3 Forcing square limits  Assure that circles are not ellipses.


Back: Plot limits Forward: mouse zooming   FastBack: Plotting primitives Up: Plot limits FastForward: logxy         Top: Yorick Contents: Table of Contents Index: Concept Index About: About this document