Learn R Programming

maxLik (version 1.5-2.1)

confint.maxLik: confint method for maxLik objects

Description

Wald confidence intervals for Maximum Likelihood Estimates

Usage

# S3 method for maxLik
confint(object, parm, level=0.95,  ...)

Value

A matrix of lower and upper confidence interval limits (in the first and second column respectively). The matrix rows are labeled by the parameter names (if any) and columns by the corresponding distribution quantiles.

Arguments

object

object of class “maxLik” returned by maxLik function

parm

the name of parameters to compute the confidence intervals. If omitted, confidence intervals for all parameters are computed.

level

the level of confidence interval

...

additional arguments to be passed to the other methods

Author

Luca Scrucca

See Also

confint for the generic confint function, stdEr for computing standard errors and summary for summary output that includes statistical significance information.

Examples

Run this code
## compute MLE parameters of normal random sample
x <- rnorm(100)
loglik <- function(theta) {
   dnorm(x, mean=theta[1], sd=theta[2], log=TRUE)
}
m <- maxLik(loglik, start=c(mu=0, sd=1))
summary(m)
confint(m)
confint(m, "mu", level=0.1)

Run the code above in your browser using DataLab