Hello there.
I am struggling all the time that I try to analyse my data.
I am analyzing the milk production of two treatments (GROUP - treated and control).
I have 20 different cows in each group;
I have two parturition order (PO - multiparous and primiparous), seven days of lactation (DL - 1, 3, 5, 7, 15, 30, 45 and 60th day of lactation), month of the data collected (MONTH - if I collected the data in 8th May 2019, the my month will be 5), age (AGE - in moths).
I collected the milk production (MP) of each cow on days 1, 3, 5, 7, 15, 30, 45 and 60. So I have seven information for one cow.
My procedure is like this:
PROC MIXED;
CLASS group po dl cow;
MODEL MP= group dl po group*po group*dl month age/ solution;
repeated dl/subject = cow type=cs r rcorr;
lsmeans group/pdiff adjust=tukey;
lsmeans group*op/pdiff adjust=tukey;
RUN;
But, I am having problem when run it...
Group | 1 | 0 | 2.06 | . |
dl | 3 | 88 | 2.28 | 0.0851 |
PO | 1 | 39 | 0.53 | 0.4697 |
Group*po | 1 | 0 | 1.94 | . |
Group*dl | 3 | 88 | 0.70 | 0.5528 |
month | 1 | 88 | 3.45 | 0.0667 |
age | 1 | 39 | 0.00 | 0.9714 |
why the "Pr>F" of group and group*po is a dot...??
Can anyone help me please.
Thank you.
Aska.
A common cause for DenDF=0 and consequently Pr>F = . is that the model is overspecified in some way.
You have not provided enough detail about your experimental design to allow me to be any more specific. Some aspects are not clear:
1) DL takes values from 1 to 60, which span two months. You also have a MONTH factor. How are DL and MONTH related?
2) Multiparous cows are likely to be consistently older than primiparous cows; multiparous cows probably have a range of ages, but primiparous cows might not, and the ages of the two groups might not overlap. How are PO and AGE related? Presumably a cow is either primiparous or multiparous?
3) The Num DF for DL is 3, when you expect 6 (=7-1). This could be a coding problem, or some overlapping redundancy with MONTH.
4) How are AGE (measured in months) and MONTH related?
5) Is it reasonable to assume that milk production is a linear function of MONTH and AGE?
I find it helpful to use the TABULATE procedure to look at the data set structure, for example
proc tabulate data=<yourdataset>;
class dl month po age;
table dl, month;
table age, po;
run;
If you would like to post more information (including an example dataset that has the same structure as your dataset), then someone in the Community might be able to provide more insight.
Hello sld, thank you for helping me.
Sorry, I confuser here, actually my DL is 15, 30, 45 and 60 day of lactation of the cow, so the DF is correct.
My AGE is in months and the MONTH is the month of the collected data, because of the specific climate the month of the data collection can influence.
My PO is just two categories: multiparous and primiparous. And is true, the range between the primiparous is less than between multiparous.
I thought to make it a factorial.
PROC MIXED;
CLASS TREATMENT PO DL;
MODEL MP = TREATMENT|PO|DL;
repeated DL/ subject=COW(TREATMENT*PO) type=FA(1); /*(in this case, FA(1) was the best structure)*/
RUN;
Do you think is not possible to put month and age in the model??
Thank you.
Best.
You usually will want to have COW in the CLASS statement.
Is it possible to put MONTH and AGE in the model? I don't know. What happens when you do? (And is it reasonable to assume a linear relationship between MP and MONTH or AGE?)
If you get errors, or 0 Den DF, or missing p-values, or some other pathological output, then there is some conflict between MONTH and/or AGE and/or TREATMENT|PO|DL. Without knowing more about the structure of your dataset, I cannot say what the problem might be.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.