• SUMS creates a variable 2;COV that contains the covariance matrix
for the current statistics matrix 2;DAT.
• 2;GET extracts a number from the specified position in 2;COV.
• 2;X2 uses 2;GET to extract
• 2;Y2 uses 2;GET to extract
• 2;XY uses 2;GET to extract
If 2;DAT contains
columns, 2;COV is an
matrix. The pro-
grams 2;X2, 2;Y2, and 2;XY refer to 2;PAR
determine which columns contain the
data (called C
and the y
data (called C
• Matrix operations. These programs demonstrate how to transpose a
matrix, how to multiply two matrices, and how to extract one ele-
ment from a matrix.
• Programs usable in algebraic objects. Because 2;X2, 2;Y2, and 2;XY
conform to algebraic syntax (no arguments from the stack, one re-
sult put on the stack), you can use their names like ordinary
variables in an expression or equation.
• 2;PAR convention. Several paired-sample statistics commands use a
variable named 2;PAR to specify a pair of columns in 2;DAT. 2;PAR
contains a list with four numbers, the first two specifying columns.
(The other two numbers are the slope and intercept from linear re-
SUMS ensures that 2;PAR exists by executing 0 PREDV DROP; the
creates 2;PAR with default val-
ues if 2;PAR doesn't already exist, and DROP removes the
predicted value computed for O.
2;X2, 2;Y2, and 2;XY use the values stored in 2;PAR to determine
which element to extract from 2;COV.
SUMS (Summary Statistics Matrix)
Create a variable 2;COV that contains the covariance matrix of the
statistics matrix 2;DAT.
28: Programming Examples