Contributor
Posts: 43

# PROC MIXED Degrees of Freedom Options

Hello,

I'm currently running a simulation study exploring the degrees of freedom options in SAS PROC MIXED. I noticed that when running the simulation, my fixed effects and standard errors are the same for a given sample size regardless of which degrees of freedom method I use (Kenward Roger, Satterthwaite, Containment, Between-Within, and Residual). From my understanding, shouldn't these parameters be different depending on which method I use?

Thanks,

Tim

Valued Guide
Posts: 684

## Re: PROC MIXED Degrees of Freedom Options

They could all be the same for SOME models. In general, however, they will differ substantially. You didn't say what model you are using. What random effects, etc.

Only KR affects standard errors and fixed effect estimates.

Contributor
Posts: 43

## Re: PROC MIXED Degrees of Freedom Options

I am using a linear mixed model for repeated measures data with four time points. There is a fixed intercept/slope and a random intercept/slope. I'm assuming that the G matrix is VC structured and that the R matrix is autoregressive. Is there anything else I'm missing? For my study, I hypothesized that the different methods would produce different parameter estimates for the fixed effects and the standard errors.

Posts: 2,655

## Re: PROC MIXED Degrees of Freedom Options

Can you share the code?  I am guessing that there are no CLASS variables other than for time, so that between-within and containment would yield the same df, and that the data are completely balanced, so that the Satterthwaite and KR degrees of freedom are unchanged from the defaults.

Steve Denham

Contributor
Posts: 43

## Re: PROC MIXED Degrees of Freedom Options

Hi Steve,

Here is the relevant part of the code that uses PROC MIXED to fit a model to each iteration of data:

proc mixed data = SimulatedData;

by Size Iter;

class Subject;

ods output CovParms = CovParms_&ddfm SolutionF = SolutionF_&ddfm;

model Response = Time /s ddfm = &ddfm;

repeated / subject = Subject;

random int Time / subject = Subject type = &CovStructure.;

run;

where &ddfm is a macro variable defined by the user and is one of the possible degrees of freedom method options in PROC MIXED. Further, &CovStructure is also a macro variable defined by the user and is one of the possible covariance structures for repeated measures data. I'm assuming AR(1) for my simulation.

Thanks,

Tim

Posts: 2,655

## Re: PROC MIXED Degrees of Freedom Options

I see now.  It is a smooth linear regression on time, not with time as a class variable.  I think I would approach this a little differently:

proc mixed data = SimulatedData;

by Size Iter;

class Subject Time; /* Add time as a class variable, so that covariance structures are more easily fit */

ods output CovParms = CovParms_&ddfm SolutionF = SolutionF_&ddfm;

model Response = Time /s ddfm = &ddfm;

repeated Time / subject = Subject type=&CovStructure;

random int  / subject = Subject .;/* I would only include this for covariance structures that model a correlation between time points, such as AR(1), ARH(1), ARMA, SP(POW), and not for UN, CS or CSH */

run;

If you truly need a single degree of freedom test in the MODEL statement, you will probably have to shift over to GLIMMIX and use the EFFECT statement.

Steve Denham

Discussion stats
• 5 replies
• 451 views
• 0 likes
• 3 in conversation