**[ME] estat df** -- Calculate degrees of freedom for fixed effects

__Syntax__

**estat** **df** [**,** __meth__**od(***df_methods***)** **post**[**(***df_method***)**] **eim** **oim**]

__Menu for estat__

**Statistics > Postestimation**

__Description__

**estat df** is for use after estimation with **mixed**.

**estat df** calculates and displays the degrees of freedom (DF) for each
fixed effect using the specified methods. This allows for a comparison of
different DF methods. **estat df** can also be used to continue with
postestimation using a different DF method without rerunning the model.

__Options__

**method(***df_methods***)** specifies a list of methods to compute DF. The
supported methods are **residual**, **repeated**, **anova**, **satterthwaite**, and
**kroger**; more than one method may be specified. Methods **satterthwaite**
and **kroger** are only available with REML estimation. If option
**dfmethod()** was not specified in the most recently fit **mixed** model,
then option **method()** is required. See *Small-sample inference for*
*fixed effects* under *Remarks and examples* in **[ME] mixed** for more
details.

**post** causes **estat df** to behave like a Stata estimation command. When
**post** is specified, **estat df** will post the DF for each fixed effect as
well as everything related to the DF computation to **e()** for the
method specified in **method()**. Thus, after posting, you could
continue to use this DF for other postestimation commands. For
example, you could use **test, small** to perform Wald F tests on linear
combination of the fixed effects.

**post** may also be specified using the syntax **post(***df_method***)**. You must
use this syntax if you specify multiple *df_methods* in option
**method()**. With this syntax, **estat df** computes the DF using the
method specified in **post()** and stores the results in **e()**. Only one
computation method may be specified using the syntax **post()**.

The *df_method* specified in **post()** must be one of the DF methods
specified in option **method()**. If only one method is specified in
option **method()**, then one can simply use **post** to make this DF method
active for postestimation and for **mixed** replay.

**eim** specifies that the expected information matrix be used in the DF
computation. It can be used only when **method()** contains **kroger** or
**satterthwaite**. **eim** is the default.

**oim** specifies that the observed information matrix be used in the DF
computation. It can be used only when **method()** contains **kroger** or
**satterthwaite**.

__Examples__

Setup
**. webuse pig**
**. mixed weight i.week || id:, reml**

Calculate and compare the DFs using three different methods
**. estat df, method(kroger anova repeated)**

Post the **kroger** method to **e()**
**. estat df, method(kroger) post**

__Stored results__

**estat df** stores the following in **r()**:

Macros
**r(dfmethods)** DF methods

Matrices
**r(df)** parameter-specific DF for each method specified in
**method()**
**r(V_df)** variance-covariance matrix of the estimators when **kroger**
method is specified

If **post()** is specified, **estat df** also stores the following in **e()**:

Scalars
**e(F)** overall F test statistic for the method specified in
**post()**
**e(ddf_m)** model DDF for the method specified in **post()**
**e(df_max)** maximum DF for the method specified in **post()**
**e(df_avg)** average DF for the method specified in **post()**
**e(df_min)** minimum DF for the method specified in **post()**

Macros
**e(dfmethod)** DF method specified in **post()**
**e(dftitle)** title for DF method

Matrices
**e(df)** parameter-specific DFs for the method specified in
**post()**
**e(V_df)** variance-covariance matrix of the estimators when **kroger**
method is posted