Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

deltaMethod

Variance Matrix of a Nonlinear Estimator Using the Delta Method


Description

Computes the variance of a nonlinear parameter using the delta method.

Usage

deltaMethod(derived.pars, est, Sigma, h=1e-05)

Arguments

derived.pars

Vector of derived parameters written in R formula framework (see Examples).

est

Vector of parameter estimates

Sigma

Covariance matrix of parameters

h

Numerical differentiation parameter

Value

coef

Vector of nonlinear parameters

vcov

Covariance matrix of nonlinear parameters

se

Vector of standard errors

A

First derivative of nonlinear transformation

univarTest

Data frame containing univariate summary of nonlinear parameters

WaldTest

Multivariate parameter test for nonlinear parameter

See Also

See car::deltaMethod or msm::deltamethod.

Examples

#############################################################################
# EXAMPLE 1: Nonlinear parameter
#############################################################################

#-- parameter estimate
est <- c( 510.67, 102.57)
names(est) <- c("mu", "sigma")
#-- covariance matrix
Sigma <- matrix( c(5.83, 0.45, 0.45, 3.21 ), nrow=2, ncol=2 )
colnames(Sigma) <- rownames(Sigma) <- names(est)
#-- define derived nonlinear parameters
derived.pars <- list( "d"=~ I( ( mu - 508 ) / sigma ),
                      "dsig"=~ I( sigma / 100 - 1) )

#*** apply delta method
res <- CDM::deltaMethod( derived.pars, est, Sigma )
res

CDM

Cognitive Diagnosis Modeling

v7.5-15
GPL (>= 2)
Authors
Alexander Robitzsch [aut, cre], Thomas Kiefer [aut], Ann Cathrice George [aut], Ali Uenlue [aut]
Initial release
2020-03-10 14:19:21

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.