BookmarkSubscribeRSS Feed
gdr1
New User | Level 1

Hello SAS community! 

 

I am very new to SAS and I have used R to run some linear mixed models. I now have to run the exact same in SAS but I have a few questions. 

*For context, I am looking at interest variables to see the level of interest in using herbs and spices (interest1 variable) before and after (time variable) watching short and long (randomization variable) nutrition videos.*

 

1) After running this model in R using the code below, I tried to run it in SAS. I am not sure if this code is right, but the p values aren't the same (in R and in SAS) and some significant variables in R are not significant in SAS. Does anyone have recommendations on how to correct my code in SAS so I am able to get the same outputs in both softwares?

gdr1_3-1720704506853.png

 

proc mixed data=results.cormick;
class record_id education time income randomization;
model interest1=time randomization age education sex income time*randomization /solution;
random record_id;
repeated /subject=record_id type=un;
run;

 

2) Also, I am not sure which p-values I should be reporting from these two tables. Does anyone have recommendations?

gdr1_1-1720704256081.png

gdr1_2-1720704290791.png

3) I am unable to get these graphs in SAS, does anyone know what code I could use?

gdr1_4-1720704671203.png

 

 

 

Thanks so much!

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
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
  • 65 views
  • 0 likes
  • 1 in conversation