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

confint.lvmfit

Calculate confidence limits for parameters


Description

Calculate Wald og Likelihood based (profile likelihood) confidence intervals

Usage

## S3 method for class 'lvmfit'
confint(
  object,
  parm = seq_len(length(coef(object))),
  level = 0.95,
  profile = FALSE,
  curve = FALSE,
  n = 20,
  interval = NULL,
  lower = TRUE,
  upper = TRUE,
  ...
)

Arguments

object

lvm-object.

parm

Index of which parameters to calculate confidence limits for.

level

Confidence level

profile

Logical expression defining whether to calculate confidence limits via the profile log likelihood

curve

if FALSE and profile is TRUE, confidence limits are returned. Otherwise, the profile curve is returned.

n

Number of points to evaluate profile log-likelihood in over the interval defined by interval

interval

Interval over which the profiling is done

lower

If FALSE the lower limit will not be estimated (profile intervals only)

upper

If FALSE the upper limit will not be estimated (profile intervals only)

...

Additional arguments to be passed to the low level functions

Details

Calculates either Wald confidence limits:

\hat{θ} \pm z_{α/2}*\hatσ_{\hatθ}

or profile likelihood confidence limits, defined as the set of value τ:

logLik(\hatθ_{τ},τ)-logLik(\hatθ)< q_{α}/2

where q_{α} is the α fractile of the χ^2_1 distribution, and \hatθ_{τ} are obtained by maximizing the log-likelihood with tau being fixed.

Value

A 2xp matrix with columns of lower and upper confidence limits

Author(s)

Klaus K. Holst

See Also

bootstrap{lvm}

Examples

m <- lvm(y~x)
d <- sim(m,100)
e <- estimate(lvm(y~x), d)
confint(e,3,profile=TRUE)
confint(e,3)
 ## Reduce Ex.timings
B <- bootstrap(e,R=50)
B

lava

Latent Variable Models

v1.6.10
GPL-3
Authors
Klaus K. Holst [aut, cre], Brice Ozenne [ctb], Thomas Gerds [ctb]
Initial release
2021-09-01

We don't support your browser anymore

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