SattDF: Satterthwaite Approximation for Total Degrees of Freedom and...

View source: R/utils.R

SattDFR Documentation

Satterthwaite Approximation for Total Degrees of Freedom and for Single Variance Components

Description

This function estimates degrees of freedom of the total variance (type="total") in random models or individual variance components (type="individual"). It bases on the results of the unified approach to ANOVA-type estimation of variance components as implemented in functions anovaVCA and anovaMM.

Usage

SattDF(MS, Ci, DF, type = c("total", "individual"))

Arguments

MS

(numeric) vector of sequential mean squares (ANOVA type-1).

Ci

(matrix) where elements are numeric values representing the inverse of the coefficient matrix for calculation of expected mean squares (see anovaVCA).

DF

(numeric) vector with the degrees of freedom for each factor in a ANOVA type-1 model.

type

(character) string specifying whether "total" degrees of freedom should be approximated or those of individual variance components

Details

Function is used internally, thus, it is not exported. Option 'type="total"' is used in functions anovaVCA and anovaMM for approximating total DF. Option 'type="individual"' is used in function VCAinference when choosing 'ci.method="satterthwaite"' for approximating DFs for individual variance components.

Value

numeric value representing the Satterthwaite DFs of the total variance.

Author(s)

Andre Schuetzenmeister andre.schuetzenmeister@roche.com

Examples


## Not run: 
data(dataEP05A2_2)
res <- anovaVCA(y~day/run, dataEP05A2_2)
VCA:::SattDF(res$aov.tab[-1,"MS"], getMat(res, "Ci.MS"), res$aov.tab[-1,"DF"], type="tot")

# now approximating individual DF for variance components
VCA:::SattDF(res$aov.tab[-1,"MS"], getMat(res, "Ci.MS"), res$aov.tab[-1,"DF"], type="i")

## End(Not run)

VCA documentation built on Sept. 7, 2022, 5:07 p.m.