DESCRIBE procedure
Saves and/or prints summary statistics for variates (R.C. Butler & D.A. Murray).
Options
Parameters
Description
DESCRIBE calculates up to 22 different summary statistics for values stored in a variate. The statistics may be saved, or printed, or both. The statistics to be calculated are indicated by the SELECTION option; the available settings are:
by default the mean, min, max, nobs, nmv, median and both quartiles are calculated.
Printing is controlled by the PRINT option. The statistics are printed by default, so to suppress printing you need to put PRINT=*.
The GROUPS option allows groups of observations to be defined. Summaries are then given for each group.
The SUMMARIES parameter allows the statistics to be saved in a variate, or a pointer to a set of variates if there are groups. These need not be declared in advance. The units of the variate(s) are labelled by the corresponding strings from the settings (in capital letters) of the SELECTION option, to simplify the subsequent access of any individual statistic. For example, the minimum value can be copied from a SUMMARIES variate v into a scalar m by
CALCULATE m = v$['MIN']
Options: PRINT, SELECTION, GROUPS. Parameters: DATA, SUMMARIES.
Method
The statistics are calculated in a variate which is then restricted to print only those that were required, and to obtain the unit numbers of those to be copied into the SUMMARIES variate.
SE Variance is calculated as
√((N (M4 - 4 M1 M3 + 6 M1 M1 M2 - 3 M14)/(N-1) - (N (M2 - M1 M1)/(N-1))2)/N)
Skewness is calculated as (M3 - 3 M1 M2 + 2 M13 ) / (M2 - M1 M1)3/2
SE Skewness is calculated as √({6N×(N-1)}/{(N-2)×(N+1)×(N+3)})
Kurtosis is calculated as (M4 - 4 M1 M3 + 6 M12 M2 - 3 M14)/(M2 - M1 M1)2 - 3
SE Kurtosis is calculated as √({24N(N-1)2}/{(N-2)(N-3)(N+5)(N+3)})
where Mi = ∑ xi / N
and N = NOBSERVATIONS(DATA)
Action with
RESTRICT
The statistics are calculated for the restricted set of units from each DATA variate. Any existing restrictions are not affected by the procedure.