Synopsis
Change the scaling of one or more variables in a scatter plot.
Syntax
scatterlog(ids) scatterlin(ids) The routines are also available as chips_contrib.scatter.slog() and chips_contrib.scatter.slin()
Description
Change the scaling used to display one or more variables in a grid of plots created by the scatterplots() command. The scatterlog() routine changes the variables to use a logarithmic scale while scatterlin() changes them to a linear scale.
Selecting the variables
The ids argument is a list of variable names or integers, where the first variable in the plot has the value 0. Unknown variables are ignored, and name comparisons are case insensitive.
Loading the routines
The routines can be loaded into a ChIPS, Sherpa or Python session by saying:
from chips_contrib.scatter import *
or, to access the qualified versions,
from chips_contrib import scatter
after which the scatter.slog() and scatter.slin() routines can be used.
Example
chips> from chips_contrib.scatter import * chips> add_window(9, 9, 'inches') chips> scatterplots('iris.fits') chips> scatterlog([1,3])
The first line - "from chips_contrib.scatter import *" - loads the scatterplot routines; it only needs to be made once per ChIPS session. The scatterlog command changes the second and fourth variables to use a log scale (that is the second and fourth column and rows)
Changing scales
The axes created by the scatterplots() commands use a linear scale and - unless the ticks argument is set to None - will use the count mode for the majortick.mode. This mode is unlikely to be useful when changing to a logarithmic scale, so the mode is changed to "limits" by scatterlog() for any axes it changes.
When scatterlin() changes the axis, it does not change the majortick mode, which means that the output of
chips> scatterlog([3]) chips> scatterlin([3])
will likely result in a slightly different display to
chips> scatterlog([3]) chips> undo()
Changes in the scripts 4.7.1 (December 2014) release
These routines are new in this release.
Bugs
See the bug pages on the CIAO website for an up-to-date listing of known bugs.
See Also
- contrib
- scatterlimits, scatterplots