Next: Variable Labels, Previous: Variable Value Labels, Up: Variables [Contents][Index]
Each variable has an associated pair of output formats, called its print format and write format. See Input and Output Formats in PSPP Users Guide, for an introduction to formats. See Input and Output Formats, for a developer’s description of format representation.
The print format is used to convert a variable’s data values to strings for human-readable output. The write format is used similarly for machine-readable output, primarily by the WRITE transformation (see WRITE in PSPP Users Guide). Most often a variable’s print and write formats are the same.
A newly created variable by default has format F8.2 if it is numeric or an A format with the same width as the variable if it is string. Many creators of variables override these defaults.
Both the print format and write format are output formats. Input
formats are not part of struct variable
. Instead, input programs
and transformations keep track of variable input formats themselves.
The following functions work with variable print and write formats.
Returns var’s print or write format, respectively.
Sets var’s print format, write format, or both formats, respectively, to a copy of format.
Next: Variable Labels, Previous: Variable Value Labels, Up: Variables [Contents][Index]