The MI Procedure |
This example uses discriminant monotone methods to impute values of a CLASS variable from the observed observation values in a data set with a monotone missing pattern.
The following statements impute the continuous variables Height and Width with the regression method and the classification variable Species with the discriminant function method:
proc mi data=Fish2 seed=7545417 nimpute=3 out=outex5; class Species; monotone reg( Height Width) discrim( Species= Length3 Height Width/ details); var Length3 Height Width Species; run;
The "Model Information" table in Output 54.5.1 describes the method and options used in the multiple imputation process.
The "Monotone Model Specification" table in Output 54.5.2 describes methods and imputed variables in the imputation model. The procedure uses the regression method to impute the variables Height and Width, and uses the logistic regression method to impute the variable Species in the model.
The "Missing Data Patterns" table in Output 54.5.3 lists distinct missing data patterns with corresponding frequencies and percents. The table confirms a monotone missing pattern for these variables.
When you use the DETAILS option, the parameters estimated from the observed data and the parameters used in each imputation are displayed in Output 54.5.4.
Group Means for Monotone Discriminant Method | |||||
---|---|---|---|---|---|
Species | Variable | Obs-Data | Imputation | ||
1 | 2 | 3 | |||
Gp1 | Length3 | 0.68104 | 0.766779 | 0.724277 | 0.577304 |
Gp1 | Height | 0.74011 | 0.809770 | 0.794103 | 0.671612 |
Gp1 | Width | 0.63865 | 0.700122 | 0.725179 | 0.579870 |
Gp2 | Length3 | -1.00022 | -0.809466 | -0.999101 | -0.908734 |
Gp2 | Height | -1.09007 | -0.965672 | -1.089324 | -1.024453 |
Gp2 | Width | -0.88135 | -0.710969 | -0.827099 | -0.746598 |
The following statements list the first 10 observations of the data set outex5 in Output 54.5.5. Note that all missing values of the variables Width and Species are imputed.
proc print data=outex5(obs=10); title 'First 10 Observations of the Imputed Data Set'; run;
First 10 Observations of the Imputed Data Set |
Obs | _Imputation_ | Species | Length3 | Height | Width |
---|---|---|---|---|---|
1 | 1 | Gp1 | 30.0 | 11.5200 | 4.02000 |
2 | 1 | Gp1 | 31.2 | 12.4800 | 4.30560 |
3 | 1 | Gp1 | 31.1 | 12.3778 | 4.69610 |
4 | 1 | Gp1 | 33.5 | 12.7300 | 4.67966 |
5 | 1 | Gp2 | 34.0 | 12.4440 | 5.13400 |
6 | 1 | Gp1 | 34.7 | 13.6024 | 4.92740 |
7 | 1 | Gp1 | 34.5 | 14.1795 | 5.27850 |
8 | 1 | Gp1 | 35.0 | 12.6700 | 4.69000 |
9 | 1 | Gp1 | 35.1 | 14.0049 | 4.84380 |
10 | 1 | Gp1 | 36.2 | 14.2266 | 4.95940 |
Copyright © SAS Institute, Inc. All Rights Reserved.