Hi all, I am working with forest inventory data where some field plots were not visited in the field. I would like to impute the missing values of forest cover within the plots. I have tried using PROC MI (SAS ver. 9.4), but keep getting the message: "ERROR: Fewer than two analysis variables". In the inserted code NFI2KMCL and ssu form an identifier of the plot, "forest" is wether the plot has been identified as forest (can be 1 or 2) and "A_forest" is the measured forest area, that is sometimes missing and needs to be imputed (values can only be 0 to 0.0706 hectar as the circular plots have a radius of 15 m). Hope that someone can help me out! Thomas data NFI;
input nfi2kmcl ssu $ forest A_forest;
cards;
2km_6396_588_EUREF89 C 0 0
2km_6396_588_EUREF89 E 0 0
2km_6070_660_EUREF89 E 1 0.070685835
2km_6070_660_EUREF89 G 1 0.018552237
2km_6070_662_EUREF89 A 1 .
2km_6070_662_EUREF89 G 1 .
2km_6070_666_EUREF89 A 1 .
2km_6070_666_EUREF89 G 1 .
2km_6070_672_EUREF89 C 1 0.070685835
2km_6070_672_EUREF89 E 1 0.070685835
2km_6070_672_EUREF89 G 1 0.070685835
2km_6070_688_EUREF89 A 1 0.070685835
2km_6070_688_EUREF89 E 1 0.070685835
2km_6070_688_EUREF89 G 1 0.070685835
2km_6080_524_EUREF89 C 1 0
2km_6080_524_EUREF89 E 1 0.070685835
2km_6080_526_EUREF89 A 1 .
2km_6080_526_EUREF89 G 1 .
2km_6080_528_EUREF89 A 1 .
2km_6080_528_EUREF89 C 1 .
;
proc mi data=NFI seed=501213 nimpute=6 min=0 max=0.070686 out=NFI_out;
mcmc;
var A_forest;
by forest;
run;
... View more