View source: R/gkwreg-methods.R
| confint.gkwreg | R Documentation |
Computes confidence intervals for model parameters in fitted gkwreg objects using Wald (normal approximation) method based on asymptotic theory.
## S3 method for class 'gkwreg'
confint(object, parm, level = 0.95, ...)
object |
An object of class |
parm |
A specification of which parameters are to be given confidence intervals, either a vector of numbers or a vector of names. If missing, all parameters are considered. |
level |
The confidence level required. Default is 0.95. |
... |
Additional arguments (currently unused). |
The confidence intervals are computed using the Wald method based on asymptotic normality of maximum likelihood estimators:
CI = \hat{\theta} \pm z_{\alpha/2} \times SE(\hat{\theta})
where z_{\alpha/2} is the appropriate normal quantile and
SE(\hat{\theta}) is the standard error from the Hessian matrix.
The model must have been fitted with hessian = TRUE (the default)
in gkw_control. If standard errors are not available, an
error is raised.
A matrix (or vector) with columns giving lower and upper confidence limits for each parameter. These will be labeled as (1-level)/2 and 1 - (1-level)/2 in percent (by default 2.5 percent and 97.5 percent).
Lopes, J. E.
gkwreg, summary.gkwreg,
confint
data(GasolineYield)
fit <- gkwreg(yield ~ batch + temp, data = GasolineYield, family = "kw")
# 95 percent confidence intervals
confint(fit)
# 90 percent confidence intervals
confint(fit, level = 0.90)
# Specific parameters
confint(fit, parm = "alpha:(Intercept)")
confint(fit, parm = 1:3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.