BookmarkSubscribeRSS Feed
GiaLee
Obsidian | Level 7

Dear all experts,

I'm running a linear mixed model and then plotting the trajectory figure using a plm effectplot. However, my data contains several missing covariates, which the mixed model cannot handle. Therefore, I plan to run multiple imputation to impute the missing covariates. The challenge I'm facing is obtaining a 'pooled' figure from the imputed datasets. Is anyone familiar with this method? Thank you very much."

 

I've attached my code, which works well. However, it only generates five separate figures instead of a 'pooled' figure: 

 

proc mi data=test     nimpute=5 out=mi_fcs ;
class a b c d e;
fcs logistic (a b c d e);
var a b c d e; run;

 

PROC MIXED DATA = mi_fcs METHOD = REML COVTEST;
CLASS id time_(ref="6") a b c d e;
MODEL Score = time_ a b c d e/ SOLUTION OUTpred=PREDDATA S CL;
RANDOM INTERCEPT / SUBJECT = id;
repeated time_ / type=ar(1) sub=id;
LSMEANS time_ /pdiff;
by _imputation_;
ods output solutionf=gm;

store out=MixedModel;
RUN;

 

proc plm restore=MixedModel;
effectplot interaction (x=time_ sliceby=a) / clm connect;

proc print data=gm ;
run ;


proc mianalyze parms(classvar=full)=gm;
class time_ a b c d e;
modeleffects time_ a b c d e;
ods output parameterestimates=outcombine_random ;
run;
proc print data=outcombine_random noobs ;
var parm estimate stderr tvalue probt ;
run ;

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 0 replies
  • 358 views
  • 0 likes
  • 1 in conversation