BookmarkSubscribeRSS Feed
GS2
Obsidian | Level 7 GS2
Obsidian | Level 7

Hello,

 

Using SAS 9.4

I have the following data:

 

data normality;
length pod $5 rand_group $20 total_pod_mean 5 group_mean 5;
infile datalines delimiter=',';
input pod $ rand_group $ total_pod_mean group_mean;
datalines;
pod1, Group 2 (Control), 4.94, 6.00,
pod1, Group 1 (MMA), 4.94, 3.94,
pod2, Group 2 (Control), 5.96, 6.08,
pod2, Group 1 (MMA), 5.96, 5.82,
pod3, Group 2 (Control), 5.27, 7.00,
pod3, Group 1 (MMA), 5.27, 3.83,
pod4, Group 2 (Control), 5.33, 6.33,
pod4, Group 1 (MMA), 5.33, 4.33,
;
run;

 

I am running the code below:

 

proc glm data= normality;
CLASS rand_group pod;
model group_mean = rand_group pod pod*rand_group /ss3;
lsmeans rand_group pod rand_group*pod/ stderr adj=tukey;
run;
quit;

 

When I run this my output is not as expected for a LSmeans. My question initially is if the setup of my data or application of code is incorrect? Thank you

1 REPLY 1
data_null__
Jade | Level 19

pod*rand_group is the same as error in this two way ANOVA.  Removed pod*rand_group from the model and lsmeans statements.  And you probably don't need LSMEANS for POD.

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
  • 1 reply
  • 311 views
  • 1 like
  • 2 in conversation