vcov.clv.fitted: Calculate Variance-Covariance Matrix for CLV Models fitted...

View source: R/f_s3generics_clvfitted.R

vcov.clv.fittedR Documentation

Calculate Variance-Covariance Matrix for CLV Models fitted with Maximum Likelihood Estimation

Description

Returns the variance-covariance matrix of the parameters of the fitted model object. The variance-covariance matrix is derived from the Hessian that results from the optimization procedure. First, the Moore-Penrose generalized inverse of the Hessian is used to obtain an estimate of the variance-covariance matrix. Next, because some parameters may be transformed for the purpose of restricting their value during the log-likelihood estimation, the variance estimates are adapted to be comparable to the reported coefficient estimates. If the result is not positive definite, Matrix::nearPD is used with standard settings to find the nearest positive definite matrix.

If multiple estimation methods were used, the Hessian of the last method is used.

Usage

## S3 method for class 'clv.fitted'
vcov(object, ...)

Arguments

object

a fitted clv model object

...

Ignored

Value

A matrix of the estimated covariances between the parameters of the model. The row and column names correspond to the parameter names given by the coef method.

See Also

MASS::ginv, Matrix::nearPD


CLVTools documentation built on Oct. 13, 2024, 9:07 a.m.