xmgr provides a command line interface and the ability to save plot parameters in a file for later retrieval. The syntax for the command line interpreter and parameter files is the same. It is instructive to read a parameter file into the command line interpreter and press the `Replay' button to verify this feature.
Case is ignored by the command line interpreter.
For the sake of clarity, however, CAPITALS are generally to be taken literally in the following examples while lower case words represent parameters:
The Julian date format is the long form. There are 2 programs in the subdirectory aux/ that can be used to convert data from Gregorian to Julian and vice versa. The Degrees format is for latitude and longitude. Below the equator latitudes are negative. Longitude is assumed positive east of Greenwich and negative to the west.
In the discussion to follow, printer refers to one of:
Set the printer command string to string.
Example:
print psmonop "lpr -Pps"
Spool hardcopy output to the printer. This command sets the output destination, but does not generate a hardcopy, see the HARDCOPY command.
Spool hardcopy output to a file, using the current value of the printer file string (see PRINT TO string above). This command sets the output destination, but does not generate a hardcopy, see the HARDCOPY command.
Spool hardcopy output to a file named string. This command sets the output destination, but does not generate a file, see the HARDCOPY command.
Example:
print to file "hardcopy.out" p>
Set the hardcopy device to printer.
Set the starting linewidth for the translation of internal lines to postscript lines.
Set the linewidth increment for the translation of internal lines to postscript lines.
Print to the current hardcopy device or file.
Set the screen device to integer. At the present time 0 (the X server) is the only value.
Define the page layout (FREE, LANDSCAPE, PORTRAIT, FIXED).
Refresh the display.
Toggle the automatic redrawing of the display.
Toggle the automatic redrawing of the display after set operations in the status window.
Update the status window.
Turn the respective bar on or off .
Turn the locator reading on the front panel on or off.
Set the background color of the drawing area.
Set the RGB values of a colormap entry. The value of color ranges from 2 to 29, The
three integer values following the color number are values from 0 to 255 and represent
red, green, and blue resp. Colors 0 and 1 are black and white (reversed if the -rvideo
command line option was selected), and cannot be changed. See the
-nofreecolors
command line switch if you have problems with button or background
colors changing.
Example:
To set colormap entry 5, use
cmap 5, 0, 0, 255
This sets color 5 to solid blue.
Page left, right, up, down, in. out.
Set the amount of scrolling, and integer value giving the amount of scroll in percent of the graph scaling. For example:
PAGE 100
would set the amount to scroll left, right, up, down to 100 percent of the graph axis scaling.
Set the amount to increase or decrease the graph scaling when using the In/Out buttons on the main panel. An integer value expressing the percent to expand or shrink.
Toggle linked scrolling. Linked scrolling affects the scroll buttons on the main panel, when linked scrolling is on, all graphs are scrolled simultaneously. Linked scrolling OFF makes scrolling affect the current graph only.
Read an Image from file named string (currently not available).
Set the location of the Image.
Their meaning is exactly as for the string-related commands.
Setnum, in the following descriptions, refer to the symbolic name of each set, i.e., the letter `s' followed by the integer number of the set. S0 would refer to set 0, s1 to set 1, etc. The following commands for setting set parameters have two prefixes, GRAPHS and SETS, that allow the setting to be made for all graphs, all sets, or a given set in all graphs. So, to set the line width for set 0 to be 3 in all graphs that have a set 0 active, the command would be:
graphs s0 linewidth 3
Likewise, to set the line width for all sets in the current graph, give the command:
sets linewidth 3
To set the line width for all sets in all graphs to 3, execute:
graphs sets linewidth 3
Toggle the active/inactive status of sets. This can be used to force xmgr to ignore a set(s), even though data are still attached to the set. For example, assuming S0 is an active set:
S0 ignore
will allow xmgr to ignore S0 for all purposes, except any operation that kills a set. Autoscaling will ignore this set, etc - in effect, S0 is dead. To bring it back to life:
S0 on
will reintroduce the set with its data intact. This operation may be performed in either Edit/Set operations/De-activate or in the File/Status popup.
Set the type of set setnum to xytype.
Set the font to use when the set type is xyz.
Set the precision when the set type is xyz.
Set the format to use when the set type is xyz.
Set the symbol for the set.
Set the size of the symbol.
Draw or don't draw a dot in the center of symbol.
Set the character to use when using the symbol type character. The value is the decimal representation of the character using the ASCII collating sequence.
Set the symbol color.
Set the fill type of the symbol (0: transparent, 1: filled with symbol foreground color, 2: filled with background color).
Set the number of points to skip before placing a symbol.
Set the symbol line style for the set.
Set the symbol line width for the set.
Set the line style for the set.
Set the line width for the set.
Set the color to use to draw the lines and symbol.
Set the type of fill for the set.
Set the type of fill for the set.
Set the type of fill for the set.
Set the color for the fill if the fill selected is color.
Set the color for the fill if the fill selected is color.
Set the the error bar display type. Opchoice is one of RIGHT, LEFT, or BOTH if the error bar type is xydx or xydxdx, or TOP, BOTTOM, or BOTH if the type is xydy or xydydy. The default in either case is BOTH, i.e. display both error bars.
Set the length of the error bar.
Set the line width for the error bar.
Set the linestyle for the error bar.
Toggle the display of the error bar riser.
Set the line style for the error bar riser.
Set the line width for the error bar riser.
Set the comment string for the set.
Activate a set in the current graph and set the length
Deactivate a set in the current graph.
Deactivate a set in the specified graph.
Reactivate a deactivated set in the current graph.
Reactivate a deactivated set in the specified graph.
Copy a set to another set
Copy a set from a particular graph to a set in another graph
Example
copy g0.s0 to g1.s5
Move a set to another set.
Example
move s0 to s1
Move a set from a particular graph to a set in another graph
Example
move g0.s0 to g1.s5
Kill a set. Plot parameters are set to their default values, unless SAVEALL is given.
Kill all sets of the current graph. Plot parameters are set to their default values, unless SAVEALL is given.
Add a point to a set, create the set if the set is inactive. The first version adds a point to set setnum in the current graph, the second adds a point to setnum in the graph graphno.
Drop points in setnum (or graphno.setnum). The parameters give the index of the first and last points to drop, respectively.
Sort setnum on X or Y. sortdir is ASCENDING or DESCENDING.
Define the named set to be used whenever a new set is about to be automatically selected and activated. If the set already exists (by the time a new set is needed), the command is ignored. Once the command succeeds, the target definition is cleared.
The two block data commands allow block data to be read and sets formed from the active set of block data.
Read a file of block data from file string.
Create a set of type xytype using columns coded in string. String describes columns as: "c1:c2:..."
Where c1, c2, ... are the numbers of the columns to use in the construction of the set from the block data.
Examples:
Create a set with error bars using x from column 1, y from column 2 and the errors in column 5:.
read block "block2.dat"
block xydy "1:2:5"
Create an XY type data set from columns 7 and 2.
block xy "7:2"
Set the current graph to graphno.
Set graphno on or off.
Set the method of autoscaling to a type developed by Paul Heckbert. This method makes nice tick spacing, but fiddles with scales of the axes.
Set the method of autoscaling to use the minimum and maximum values of the data.
Toggle the display of graphno.
Set the type of graphno to graphtype, where graphtype is one of:
Set the thickness of the bars in a bar chart.
Toggle the use of the graph fixed point, i.e., the point used as a reference for the locator display.
Set the value of the graph fixed point.
Set the type of display for the locator on the main panel.
Select the format to use for both X and Y in the locator display.
Set the number of places to display to the right of the decimal point in the locator display for both X and Y.
Kill graph graphno.
Kill all graphs and sets, but not annotative text, lines, and boxes.
Kill all graphs, sets, and annotation.
Arrange graphs in the given number of rows and columns.
Set the maximum number of sets per graph for all graphs (first version) or a specified graph (second version).
Set the current graph to graphno.
Focus fixed on the current graph.
Focus follows the pointer.
Set the focus by clicking on a graph.
Turn the drawing of the focus indicators on or off.
Toggle the display of the current graph's frame.
Set the type of frame for the current graph:
Set the line style of the current graph's frame.
Set the width of the line for the current graph's frame.
Set the color of the current graph's frame.
Toggle the fill of the graph frame.
Set the color to use for filling the current graph's frame.
Autoscale the current graph
Autoscale the current graph on a particular set
Autoscale the X-axis and the axis at Y = 0 in the current graph.
Autoscale the Y-axis and the axis at X = 0 in the current graph.
Suppress autoscaling on startup. Use this command in a data file that uses embedded parameter settings to set the axes scaling.
Set sensible values for all tick marks of the current graph.
Set the graph title.
Set the font for the graph title.
Set the character size for the graph title.
Set the color for the graph title.
Set the graph subtitle.
Set the font for the graph subtitle.
Set the character size for the graph subtitle.
Set the color for the graph subtitle.
Toggle display of the legend.
Position the legend in either world or viewport coordinates.
Set the vertical gap between legend entries in characters.
Specify the gap between the display of the symbol and the legend label in units of characters.
Set the length of the legend in units of characters.
Set the location of the legend.
Set the X value of the location.
Set the Y value of the legend.
Set the font to use for the legend labels.
Set the size of the characters in the legend label.
Set the line width to use to draw the legend labels.
Set the color of the legend labels.
Toggle the display of the bounding box for the legend.
Toggle the filling of the bounding box for the legend.
Set the line width to use to draw the bound box for the legend.
Set the line style to use to draw the bound box for the legend.
Set the color of the legend bounding box.
Set the color to use for the filled legend bounding box.
Set the pattern to use for the filled legend bounding box.
Set the type of fill for the bounding box, either COLOR or PATTERN.
Set the legend label for setnum integer.
The are two axes in each coordinate direction. In the case of the X coordinate direction, there is one that follows the world scaling, one at Y = 0 and another that may be used to display an alternate scale. The names used by xmgr to refer to these axes are, XAXIS, ZEROXAXIS, respectively. Likewise along Y there is the YAXIS, ZEROYAXIS. There are names that can be used to refer to all the axes along a coordinate direction or to both directions or to all graphs, these being AXES (both coordinate directions, current graph), XAXES (along X in the current graph), YAXES (along Y in the current graph), and preceding these with the key word GRAPHS, will cause the setting to be made throughout all the active graphs. In the following descriptions, axis refers to the choices described above.
Toggle the display of the axis or axes referred to by axis.
Set the color for the axis or axes specified by axis.
Set the line width for the axis or axes specified by axis.
Set the line style for the axis or axes specified by axis.
Set the font to use for text for the axis or axes specified by axis.
Set the character size for text for the axis or axes specified by axis.
Set the text string to use for the axis label.
Set the layout of the axis label to be perpendicular to the axis.
Set the layout of the axis label to be parallel to the axis.
Set the character size of the text used for the axis label.
Set the font to use for the axis label.
Set the color to use for the axis label.
Set the line width to use for drawing the axis label. Axes bar
Toggle the display of the axis bar. The default is OFF.
Set the color to use for the axis bar.
Set the line width to use when drawing the axis bar.
Set the line style to use for drawing the axis bar.
Turn on or off respective tick marks. Minor ticks are displayed only if also major ticks are on.
Set the tick spacing for major tick marks.
Set the spacing for minor tick marks.
Set sensible values for all tick marks of the current graph.
Set the amount to offset the axis, in viewport coordinates in the X direction.
Set the amount to offset the axis in viewport coordinates in the Y direction.
Toggle the use of the alternate map for the axis scaling.
Specific the minimum value to use for the alternate map.
Specify the maximum value to use for the alternate map.
Set the default number of ticks to use when autoscaling.
Set the display of tick marks to IN, OUT, or BOTH.
Currently has no effect.
Set the size of tick marks.
Set the size of major tick marks.
Set the size of minor tick marks.
Set the color to use for tick marks.
Set the color to use for major tick marks.
Set the color to use for minor tick marks.
Set the line width to use for grid lines at major tick marks.
Set the line style to use for grid lines at major tick marks.
Set the line width to use for grid lines at minor tick marks.
Set the line width to use for grid lines at minor tick marks.
Toggle the display of grid lines at major tick marks.
Toggle the display of grid lines at minor tick marks.
Set the display of tick marks on the axis to TOP, BOTTOM, or BOTH if the axis is in the X direction, or LEFT, RIGHT, or BOTH if the axis is in the Y direction. The default is BOTH in either case.
Use the values for major and minor spacing for draw the tick marks. See the next it for tick marks at specified locations.
Use specified values for drawing tick marks. These values are for major tick marks only.
Give the number of specified tick marks.
Set the value of specified tick mark number integer to value, expr.
Set the number of places to the right of the decimal point when drawing tick labels.
Set the format to use for drawing tick labels.
Append string to the tick labels.
Prepend string to the tick labels.
Set the angle of the axis tick labels to be horizontal.
Set the angle of the axis tick labels to be vertical.
Specify the use of the specified tick label angle.
Specify the angle to use for drawing the tick labels in degrees from 0 to 360 (0=horizontal, 90=vertical).
Put the ticklabels on the ticks.
Put the ticklabels between the ticks.
Specify the type of justification to use when drawing the tick label.
Set the number of major tick marks to skip before drawing a tick label.
Set the number of characters to use to offset the tick labels.
Set the side(s) to draw tick labels, LEFT, RIGHT, or BOTH for tick labels in the Y direction and TOP, BOTTOM, or BOTH for tick labels in the X direction. The default is LEFT for the Y axis tick labels and BOTTOM for the X axis tick labels.
Set the function to use on the numeric value used to create the tick mark label. One of NORMAL, ABSOLUTE, or NEGATE. The default is NORMAL, i.e., no transformation is applied. ABSOLUTE indicates that the absolute value of the tick label location is used, NEGATE is the negative of the tick mark location. The latter two can be used to achieve a reversal of axis or a reflection effect of the axes. Of course, the data will need to be transformed also.
Set the value to use to begin drawing tick labels.
Set the value to stop drawing tick labels.
Use the specified starting value for drawing tick mark labels.
Use the specified stopping value for drawing tick mark labels.
Use the graph minimum to use as the starting point for drawing tick labels, this is the default.
Use the graph maximum as the stopping point for drawing tick mark labels. This is the default.
Set the size of characters to use when drawing the tick mark labels.
Set the font to use when drawing tick mark labels.
Set the color to use for drawing tick mark labels.
Set the line width to use for drawing tick mark labels.
Use the values of major tick marks for position the tick mark labels.
Specify the tick mark label to use at each major tick mark.
See also the page about region operations.
Activate region regnum.
Set the type of region regnum to one of ABOVE, BELOW, LEFT, RIGHT, POLYI, POLYO.
Set the boundary color of region regnum to color.
Set the boundary linestyle of region regnum to number.
Set the boundary linewidth of region regnum to number.
Set the coordinates for region regnum, which has to be of type ABOVE, BELOW, LEFT or RIGHT.
Add a point to the boundary of region regnum, which has to be of type POLYI or POLYO.
Link region regnum to graph graphno.
The commands for boxes and ellipses are the exact same. Simply substitute ELLIPSE for BOX in the following commands.
NOTE: Boxes, used or not, are numbered from 0 to the maximum number of boxes. This is also true of ellipses, lines and strings.
Get the next available box and make it current. A box needs to be current before any of the following commands will apply.
Get the box numbered integer and make it the current box
Toggle the display of the current box.
Set the location of the box in world or viewport coordinates depending on the value of BOX LOCTYPE. The 4 values represent xmin, ymin, xmax, ymax respectively.
Set the location type of the next box created. World or viewport coordinates.
If the LOCTYPE is WORLD, set the graph to use.
Set the line style to use for the next box created.
Set the line width of the next box created.
Set the color to use for the box lines.
Set the type of fill to either COLOR or PATTERN.
Set the color to use to fill the next box created.
Set the pattern to use for the next box created.
Define the current box using the values set above.
Remove all boxes
xmgr uses an array of a data type called lines internally to hold the definition of lines. The actual construction of this data type is not important, but it is important to note that lines, used or not, are numbered from 0 to the maximum number of lines.
Make the next available line the current line.
Make line integer the current line.
Toggle the display of the current line.
Set the location of the current line created. The four expressions represent (X1, Y1), (X2, Y2) respectively.
Set the location type of the current line created. World or viewport coordinates.
If the line LOCTYPE is WORLD, set the graph to use for scaling.
Set the line width of the current line created.
Set the line style of the current line created.
Set the color of the current line created.
Define a line with or without arrow(s) and where they are located.
Set the size of the current line's arrowhead.
Set the type of the current line's arrowhead.
Define a line using the current set of line settings.
Remove all lines.
xmgr uses an array of a data type called plotstr internally to hold the definition of strings. The actual construction of this data type is not important, but it is important to note that strings, used or not, are numbered from 0 to the maximum number of strings.
Get the next available string
Get the particular string numbered integer.
Toggle the display of the current string.
Location of the string, in world or viewport coordinates depending on the value of LOCTYPE.
Set the location type of the string, either world or viewport coordinates. If the setting is WORLD, then the strings position is affected by changes in the axes scaling, if VIEW, then the string is fixed to that spot in viewport coordinates.
Set the graph to uses for scaling when the LOCTYPE is WORLD.
Set the line width of the current string.
Set the color of the current string.
Set the rotation of the current string from-360 to 360 in degrees
Set the font of the current string.
Set the justification for the current string. 0 is left justified, 1 is right justified, and 2 is centered.
Set the character size of the current string.
Define the current string using the values set above.
Remove all strings
Set the scaling limits for the current graph.
Set the scaling limits for a polar graph.
Push the current graph scaling limits and tick spacing onto the graph's world stack.
Pop the current graph's world stack and set the new scaling limits and tick spacing from the new stack top.
Cycle through the current graph's world stack.
Set the current graph's scaling limits and tick spacing to the value at position integer of the current graph's world stack.
Push specific values onto the current graph's world stack - primarily for use in parameter files generated by xmgr.
Clear the current graph's world stack.
Set the current graph's viewport (where on the device the graph is displayed).
Load a set sequentially
Regress a set where number is the degree of the fit in the range 1-5.
Difference a set using the method specified by number.
Run non-linear fit on set setnum from the current graph or graphno for number steps or until the required tolerance achived. The latter, alongside with other fit parameters are discussed in Non-linear fit settings
Integrate a set using a trapezoid rule.
Creates a new set in the first available spot with the cross/auto-correlation data of sets setno1 and setno2 (for auto-correlation, enter the same setnumber twice). The lag must be an integer, 0 < lag < length_of_set1&2 that specifies the maximum shift to use. The number of data points in the resulting set will therefore be equal to lag+1. See also this.
Draw a spline. splinetype is one of:
Interpolate setnum1 at the x values of setnum2; method is 0 (linear), 1 (cubic spline) or 2 (Akima spline)
Compute a DFT either forward or inverse, using the DFT or FFT.
ffttype is one of:
datatype is one of:
windowtype is one of:
loadx is one of:
loady is one of:
The command
ffttype(setnum, integer)is the old syntax of the FFT command and remains valid for backward compatibility. It corresponds to the command
ffttype(setnum, REAL, NONE, loadx(integer), MAGNITUDE)where loadx(0)=INDEX, loadx(1)=FREQUENCY, loadx(2)=PERIOD.
Compute a running average, standard deviation, median, maximum, or minimum. runtype is one of the following:
Compute a histogram using set setnum. Xmin is the minimum value, binw the bin width, and the integer is how many bins to create.
Define the title of the fit.
Define the fit function.
Set the number of the fit parameters.
Define the desired tolerance of the fit.
Whether upper/lower bounds should be used to constrain parameter fitparm. The parameters themselves as well as their bounds fitpmin and fitpmax can be treated as a part of any valid expression.
Define string1 to be treated as an alias to a single keyword string2
controls whether existing keywords can be overriden by aliases (off by default)
Set the source (DISK or PIPE) for reading XY data sets.
Set the type of the next set to be read.
Set the format of a file from which a set will be read.
Read an XY data set.
Read a batch file.
Read a data set of a particular type.
Read a data set of type xytype from source sourcetype.
Read a parameter file.
Write a parameter file.
Change working directory to string.
Write setnum to the standard output.
Write setnum to the standard output using string as format like printf, e.g. "%7.2f %7.2f".
Write setnum to filename.
Write setnum to filename using string as format like printf, e.g. "%7.2f %7.2f".
Write all sets of all graphs to filename.
Set default value for the respective property. SFORMAT is the format for saving (ascii) projects.
Abruptly leave xmgr.
Sleep for number seconds (not you, of course).
Print string to the status bar.
Evaluate expr and print result to the status bar.
Add string to the description of the current project.
Clear the description of the current project.
Load the user-defined external function "my_wrapper" from the file "/tmp/my_wrap.so". It can be given an ALIAS using the second version. Refer to the External Modules Page on how to write external functions.
Back to the main help page.