Attribute types |

Version 2.33 Jun'06
| |
|
Manual page for Attribute_types(PL)
DESCRIPTION
Many ploticus script attributes and prefab parameters are of standard types.
POSITION UNITS
Absolute space is measured in inches by default.
It can be centimeters if set using the
-cm command line option
or in your
config file.
Origin (0,0) is always the lower-left corner of the page or drawing area.
You can get absolute locations by previewing a graph in X11 mode and clicking with
the mouse.. coordinates will be written to standard error for each click.
Scaled space is measured in whatever data units are currently in effect
(numeric, date, time, categories, etc.).
For more information, see
scaleunits
ATTRIBUTE TYPES
The basic attribute types, listed from simplest to most complex, are:
n
-
-
A single number.
May be floating point or integer.
Example: Offset: 3.2
dfield or datafield
-
-
A reference to a field in the plot data.
Plot data must already have been read in.
A dfield may be an integer (1 or greater), e.g.
1 would refer to the first data field.
If field names have been defined for the current data set,
dfield may also be one of these field names.
Field names may include any alphanumeric characters with a maximum length of 38,
and are case-insensitive. Field names may not contain embedded spaces or commas.
plotvalue
-
-
A plottable value conforming to the the scale type and ranges currently in effect
(numeric, date, time, category value, etc.)
for either X or Y axis.
May not contain embedded white space.
See also the above description of
position units
locvalue
-
-
A number or value that
describes a location or length.
May be either absolute units or scaled units.
-
-
If a suffix of (s) is attached to the end
of the number, the number is taken as being in scaled
space, and must be a plottable value (a number for numeric scaling,
a date where date scaling is being used, etc.)
-
-
If the number does not have a (s) suffix, it is interpreted as
being in absolute space.
-
-
Special operators: min may be used to indicate the
minima of a defined plot area, and max to indicate the maxima.
-
-
Offsets: A +/- offset may be given after the value
(no embedded spaces allowed). The offset is always an
absolute value. See the examples below.
Note: a locvalue cannot contain embedded whitespace.
Note: it is impossible to specify a negative offset when using date scaling
with a date notation that uses embedded dashes such as mm-dd-yyyy.
-
-
See the above description of
position units.
-
-
Example: 3.5 = 3.5 absolute units (inches or centimeters).
Example: 142(s) = 142 in scaled units (whatever was defined in the
most recent areadef).
Example: min = the plot area minima
Example: min-0.1 = 0.1 inch below plot area minima
Example: 23jan98(s)+0.5 = 0.5 inch above the point where 23jan98 (in scaled units) would lie
Example: blue(s) = location of the category blue
lenvalue
-
-
Uses same notation as locvalue except that it
describes a distance rather than a location.
Distances may be given in absolute units or scaled units (the latter requires (s) be tacked onto the end).
For date and datetime this should be expressed in days; for time scaling use minutes).
See the above description of
locvalue
x y
-
-
A coordinate pair. Both x and y are locvalues.
See the above description of
locvalue
Example: Location: 5.3 1
printf-spec
-
-
A format specifier as used in the "C" programming language,
used to control the display of numeric values. Here are some
examples; for more information check any good C language reference.
Ploticus generally uses %g as the default spec, which
displays numbers using the shortest possible
representation, and generally switches to scientific notation on
very large numbers or very small numbers.
printf-spec typical results
----------- -----------------------------------
%7.0f 500000 4500000
%5.2f 239.62 8491.50
$%.2f $82.54
$%6.2f $ 82.54
%3.0f%% 44%
string
-
-
A character string value containing no embedded white space. All
white space before and after the string is discarded.
text
-
-
A character string value that may contain embedded white space.
The specification may not occupy more than one line, however embedded
newlines may be represented using backslash n (\n) .
There is a notation for inline superscripts and subscripts
within text items.
More on special characters, fonts, etc.
Example:
Yaxis.label: Number of Attempts\nBefore Success
multilinetext
-
-
Text that may be specified using one or more lines.
The end of the multiline text is indicated by a blank line.
If #endproc is encountered, this will also terminate the multiline item.
Blank lines that are to be part of the text may be escaped using a backslash (\).
Leading whitespace (normally stripped off) may be retained by using a backslash (\),
followed by the desired whitespace, followed by text (see 3rd example below).
There is a notation for inline superscripts and subscripts
within multilinetext items.
More on special characters, fonts, etc.
Title: Comparison of Survey Techniques
By Region
\
Fall, 1997
-
-
It is also ok to leave the first line blank as in the following
example:
Title:
Comparison of Survey Techniques
By Region
\
Fall, 1997
-
-
Here's an example where leading whitespace is preserved:
text:
Data: 0.08 0.10 0.15 0.17 0.24 0.34 0.38 0.42 0.49 0.50 0.70
\ 0.94 0.95 1.26 1.37 1.55 1.75 3.20 6.98 50.57
RELATED TO GRAPHICS RENDERING
pointsize
-
-
An integer point size (usable range is 5 - 30 or so).
font
- a font name
color
- a color name
textdetails
linedetails
symboldetails
select
|
 data display engine
Copyright Steve Grubb
|