dfSigma: Degree of Freedom for the Chi-Square Test

View source: R/sCorrect-compare2.R

dfSigmaR Documentation

Degree of Freedom for the Chi-Square Test

Description

Computation of the degrees of freedom of the chi-squared distribution relative to the model-based variance

Usage

dfSigma(contrast, score, vcov, rvcov, dVcov, dRvcov, keep.param, type)

Arguments

contrast

[numeric vector] the linear combination of parameters to test

score

[numeric matrix] the individual score for each parameter.

vcov

[numeric matrix] the model-based variance-covariance matrix of the parameters.

rvcov

[numeric matrix] the robust variance-covariance matrix of the parameters.

dVcov

[numeric array] the first derivative of the model-based variance-covariance matrix of the parameters.

dRvcov

[numeric array] the first derivative of the robust variance-covariance matrix of the parameters.

keep.param

[character vector] the name of the parameters with non-zero first derivative of their variance parameter.

type

[integer] 1 corresponds to the Satterthwaite approximation of the the degrees of freedom applied to the model-based variance, 2 to the Satterthwaite approximation of the the degrees of freedom applied to the robust variance, 3 to the approximation described in (Pan, 2002) section 2 and 3.1.

References

Wei Pan and Melanie M. Wall, Small-sample adjustments in using the sandwich variance estiamtor in generalized estimating equations. Statistics in medicine (2002) 21:1429-1441.


lavaSearch2 documentation built on April 12, 2023, 12:33 p.m.