BookmarkSubscribeRSS Feed
Joshblackie
Calcite | Level 5

Diet intakeDiet intakeMultiple Measures Plasma OsmMultiple Measures Plasma Osm

 

 

Dear all,

 

Above are some of my results and I've got a question about the difference in Den DF between the analyses.

Could someone please let me know if I've done my coding correctly for the following:

I want to measure the difference in diet intake between 3 diets, 3 periods, 6 animals, done in a Latin square. Results are in the Diet intake picture.

 

I then want to see if the diet has an effect on multiple measurements of plasma osmolality. (I have quite a few missing samples).

Results are in the Multiple Measures Plasma Osm picture.

 

 

My questions: Why are the Den DF for, for example, period so different between the proc mixed and the repeated measures proc mixed? I thought the Den DF had to do with number of observations and, as it is the same study, I've still only got 3 periods and 3 diets.

Is my coding correct? If not, how do I change it to get the same number of Den DF in both models if that's what I'm supposed to have?

I'm using SAS 9.4, code and data are attached.

Thank you very much!

 

 

1st code:

data DietIntake; input animal gender $ period diet $ intake; cards;
proc mixed; class animal gender period diet; model intake = gender period diet period*diet; lsmeans diet period*diet period gender/ pdiff; random animal; run;

Multiple Measures code:
data PlasmaOsmolality;
input animal gender $ diet $ period time $ osmolality;
cards;

proc mixed;
class animal gender period diet time;
model osmolality = gender period diet time diet*time period*diet period(time);
lsmeans diet gender period time diet*time period*diet period(time)/ pdiff;
repeated / subject=animal;
run;

 

sas-innovate-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


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
  • 2084 views
  • 0 likes
  • 1 in conversation