Add pspp-dev.dvi to CLEANFILES.
[pspp-builds.git] / doc / variables.texi
index afca8cbfc90c95a6e8658628023ec56b76efa25b..a66e423292054adf60892eb059449e8db7dff2a1 100644 (file)
@@ -1,4 +1,4 @@
-@node Variable Attributes, Data Manipulation, System and Portable Files, Top
+@node Variable Attributes
 @chapter Manipulating variables
 
 The variables in the active file dictionary are important.  There are
@@ -6,6 +6,7 @@ several utility functions for examining and adjusting them.
 
 @menu
 * ADD VALUE LABELS::            Add value labels to variables.
+* DELETE VARIABLES::            Delete variables.
 * DISPLAY::                     Display variable names & descriptions.
 * DISPLAY VECTORS::             Display a list of vectors.
 * FORMATS::                     Set print and write formats.
@@ -25,7 +26,7 @@ several utility functions for examining and adjusting them.
 * WRITE FORMATS::               Set variable write formats.
 @end menu
 
-@node ADD VALUE LABELS, DISPLAY, Variable Attributes, Variable Attributes
+@node ADD VALUE LABELS
 @section ADD VALUE LABELS
 @vindex ADD VALUE LABELS
 
@@ -38,7 +39,24 @@ ADD VALUE LABELS
 LABELS} (@pxref{VALUE LABELS}), but it does not clear value
 labels from the variables before adding the ones specified.
 
-@node DISPLAY, DISPLAY VECTORS, ADD VALUE LABELS, Variable Attributes
+@node DELETE VARIABLES
+@section DELETE VARIABLES
+@vindex DELETE VARIABLES
+
+@display
+DELETE VARIABLES var_list.
+@end display
+
+@cmd{DELETE VARIABLES} deletes the specified variables from the
+dictionary.  It may not be used to delete all variables from the
+dictionary; use @cmd{NEW FILE} to do that (@pxref{NEW FILE}).
+
+@cmd{DELETE VARIABLES} should not used after defining transformations
+and before executing a procedure.  If it is used in such a context, it
+causes the data to be read.  If it is used while @cmd{TEMPORARY} is in
+effect, it causes the temporary transformations to become permanent.
+
+@node DISPLAY
 @section DISPLAY
 @vindex DISPLAY
 
@@ -81,7 +99,7 @@ If SORTED is specified, then the variables are displayed in ascending
 order based on their names; otherwise, they are displayed in the order
 that they occur in the active file dictionary.
 
-@node DISPLAY VECTORS, FORMATS, DISPLAY, Variable Attributes
+@node DISPLAY VECTORS
 @section DISPLAY VECTORS
 @vindex DISPLAY VECTORS
 
@@ -91,7 +109,7 @@ DISPLAY VECTORS.
 
 @cmd{DISPLAY VECTORS} lists all the currently declared vectors.
 
-@node FORMATS, LEAVE, DISPLAY VECTORS, Variable Attributes
+@node FORMATS
 @section FORMATS
 @vindex FORMATS
 
@@ -113,7 +131,7 @@ delimited by a slash (@samp{/}).
 @cmd{FORMATS} takes effect immediately.  It is not affected by
 conditional and looping structures such as @cmd{DO IF} or @cmd{LOOP}.
 
-@node LEAVE, MISSING VALUES, FORMATS, Variable Attributes
+@node LEAVE
 @section LEAVE
 @vindex LEAVE
 
@@ -162,7 +180,7 @@ procedure command, because the left status of variables is reset by
 certain transformations---for instance, @cmd{COMPUTE} and @cmd{IF}.
 Left status is also reset by all procedure invocations.
 
-@node MISSING VALUES, MODIFY VARS, LEAVE, Variable Attributes
+@node MISSING VALUES
 @section MISSING VALUES
 @vindex MISSING VALUES
 
@@ -196,7 +214,7 @@ The @cmd{MISSING VALUES} command takes effect immediately.  It is not
 affected by conditional and looping constructs such as @cmd{DO IF} or
 @cmd{LOOP}.
 
-@node MODIFY VARS, NUMERIC, MISSING VALUES, Variable Attributes
+@node MODIFY VARS
 @section MODIFY VARS
 @vindex MODIFY VARS
 
@@ -243,7 +261,7 @@ not.
 @cmd{MODIFY VARS} may not be specified following @cmd{TEMPORARY}
 (@pxref{TEMPORARY}).
 
-@node NUMERIC, PRINT FORMATS, MODIFY VARS, Variable Attributes
+@node NUMERIC
 @section NUMERIC
 @vindex NUMERIC
 
@@ -262,7 +280,7 @@ Formats}); otherwise, the default is F8.2.
 Variables created with @cmd{NUMERIC} are initialized to the
 system-missing value.
 
-@node PRINT FORMATS, RENAME VARIABLES, NUMERIC, Variable Attributes
+@node PRINT FORMATS
 @section PRINT FORMATS
 @vindex PRINT FORMATS
 
@@ -276,7 +294,7 @@ numeric variables to the specified format specification.
 Its syntax is identical to that of @cmd{FORMATS} (@pxref{FORMATS}),
 but @cmd{PRINT FORMATS} sets only print formats, not write formats.
 
-@node RENAME VARIABLES, VALUE LABELS, PRINT FORMATS, Variable Attributes
+@node RENAME VARIABLES
 @section RENAME VARIABLES
 @vindex RENAME VARIABLES
 
@@ -297,7 +315,7 @@ to be read.
 @cmd{RENAME VARIABLES} may not be specified following @cmd{TEMPORARY}
 (@pxref{TEMPORARY}).
 
-@node VALUE LABELS, STRING, RENAME VARIABLES, Variable Attributes
+@node VALUE LABELS
 @section VALUE LABELS
 @vindex VALUE LABELS
 
@@ -320,7 +338,7 @@ are cleared from the variables specified.  Use @cmd{ADD VALUE LABELS}
 (@pxref{ADD VALUE LABELS}) to add value labels without clearing those
 already present.
 
-@node STRING, VARIABLE LABELS, VALUE LABELS, Variable Attributes
+@node STRING
 @section STRING
 @vindex STRING
 
@@ -339,7 +357,7 @@ implicitly derived from the specified output formats.
 Created variables are initialized to spaces.
 
 
-@node VARIABLE LABELS, VARIABLE ALIGNMENT, STRING, Variable Attributes
+@node VARIABLE LABELS
 @section VARIABLE LABELS
 @vindex VARIABLE LABELS
 
@@ -360,10 +378,10 @@ statistical procedures.
 To assign a variable label to a group of variables, specify a 
 list of variable names and the variable label as a string.
 To assign different labels to different variables in the same command, 
-preceed the subsequent variable list with a slash (@samp{/}).
+precede the subsequent variable list with a slash (@samp{/}).
 
 
-@node VARIABLE ALIGNMENT, VARIABLE WIDTH, VARIABLE LABELS, Variable Attributes
+@node VARIABLE ALIGNMENT
 @comment  node-name,  next,  previous,  u
 @section VARIABLE ALIGNMENT
 @vindex VARIABLE ALIGNMENT
@@ -385,7 +403,7 @@ the display of variables in the PSPP output.
 
 
 
-@node VARIABLE WIDTH, VARIABLE LEVEL, VARIABLE ALIGNMENT, Variable Attributes
+@node VARIABLE WIDTH
 @comment  node-name,  next,  previous,  up
 @section VARIABLE WIDTH
 @vindex VARIABLE WIDTH
@@ -404,7 +422,7 @@ purposes.   This only affects third party software.  It does not affect
 the display of variables in the PSPP output.
 
 
-@node VARIABLE LEVEL, VECTOR, VARIABLE WIDTH, Variable Attributes
+@node VARIABLE LEVEL
 @comment  node-name,  next,  previous,  up
 @section VARIABLE LEVEL
 @vindex VARIABLE LEVEL
@@ -422,32 +440,33 @@ VARIABLE LEVEL
 Currently, this has no effect except for certain third party software.
 
 
-@node VECTOR, WRITE FORMATS, VARIABLE LEVEL, Variable Attributes
+@node VECTOR
 @section VECTOR
 @vindex VECTOR
 
 @display
 Two possible syntaxes:
         VECTOR vec_name=var_list.
-        VECTOR vec_name_list(count).
+        VECTOR vec_name_list(count [format]).
 @end display
 
 @cmd{VECTOR} allows a group of variables to be accessed as if they
 were consecutive members of an array with a vector(index) notation.
 
-To make a vector out of a set of existing variables, specify a name for
-the vector followed by an equals sign (@samp{=}) and the variables that
-belong in the vector.
+To make a vector out of a set of existing variables, specify a name
+for the vector followed by an equals sign (@samp{=}) and the variables
+to put in the vector.  All the variables in the vector must be the same
+type.  String variables in a vector must all have the same width.
 
 To make a vector and create variables at the same time, specify one or
 more vector names followed by a count in parentheses.  This will cause
 variables named @code{@var{vec}1} through @code{@var{vec}@var{count}}
-to be created as numeric variables with print and write format F8.2.
-Variable names including numeric suffixes may not exceed 64 characters
-in length, and none of the variables may exist prior to @cmd{VECTOR}.
-
-All the variables in a vector must be the same type.  String variables
-in a vector must all have the same width.
+to be created as numeric variables.  By default, the new variables
+have print and write format F8.2, but an alternate format may be
+specified inside the parentheses before or after the count and
+separated from it by white space or a comma.  Variable names including
+numeric suffixes may not exceed 64 characters in length, and none of
+the variables may exist prior to @cmd{VECTOR}.
 
 Vectors created with @cmd{VECTOR} disappear after any procedure or
 procedure-like command is executed.  The variables contained in the
@@ -457,10 +476,7 @@ Variables}).
 Variables within a vector may be referenced in expressions using
 @code{vector(index)} syntax.
 
-
-
-
-@node WRITE FORMATS,  , VECTOR, Variable Attributes
+@node WRITE FORMATS
 @section WRITE FORMATS
 @vindex WRITE FORMATS