SAVE Subcommand (CSORDINAL command)

The SAVE subcommand writes optional model variables to the active dataset.

  • Specify one or more temporary variables, each followed by an optional new name in parentheses.
  • The optional names must be valid variable names.
  • If new names are not specified, CSORDINAL uses the default names.
  • If a subpopulation is defined on the DOMAIN subcommand, then SAVE applies only to cases within the subpopulation.

The following rules describe the functionality of the SAVE subcommand in relation to the predictor values for each case.

  • If all factors and covariates in the model have valid values for the case, then the procedure computes the predicted values. (The MISSING subcommand setting is taken into account when defining valid/invalid values for a factor.)
  • An additional restriction for factors is that only those values of the factor actually used in building the model are considered valid. For example, suppose factor A takes values 1, 2, and 3 when the procedure builds the model. Also suppose there is a case with a value of 4 on factor A, and valid values on all other factors and covariates. For this case, no predicted values are saved because there is no model coefficient corresponding to factor A = 4.

Computation of predicted values for a given case does not depend on the value of the dependent variable; it could be missing.

CUMPROB (rootname:n). Cumulative probability. The user-specified or default name is treated as the root name, and a suffix is added to get new unique variable names. The root name can be followed by a colon and a positive integer giving the number of predicted cumulative probabilities to save. The predicted cumulative probabilities of the first n response categories are saved. One cumulative predicted probability variable can be saved for each category of the dependent variable. The default root name is CumulativeProbability. The default n is 25. To specify n without a root name, enter a colon before the number.

PREDPROB (rootname:n). Predicted probability. The user-specified or default name is treated as the root name, and a suffix is added to get new unique variable names. The root name can be followed by a colon and a positive integer giving the number of predicted probabilities to save. The predicted probabilities of the first n response categories are saved. One predicted probability variable can be saved for each category of the dependent variable. The default root name is PredictedProbability. The default n is 25. To specify n without a root name, enter a colon before the number.

PREDVAL (varname). Predicted value. The class or value predicted by the model. The optional variable name must be unique. If the default name is used and it conflicts with existing variable names, then a suffix is added to the default name to make it unique. The default variable name is PredictedValue.

PREDVALPROB (varname). Predicted value probability. The probability of value predicted by the model. This probability is the maximum probability predicted by the model for a given case. The optional variable name must be unique. If the default name is used and it conflicts with existing variable names, then a suffix is added to the default name to make it unique. The default variable name is PredictedValueProbability.

OBSVALPROB (varname). Observed value probability. The probability predicted for the observed response value. The optional variable name must be unique. If the default name is used and it conflicts with existing variable names, then a suffix is added to the default name to make it unique. The default variable name is ObservedValueProbability.