Learn R Programming

lmreg (version 1.2)

cisimult: Simultaneous confidence intervals in a linear model

Description

Produces two-sided Bonferroni and Scheffe simultaneous confidence intervals, together with corresponding single confidence intervals, for any vector of estimable functions A.beta in a linear model.

Usage

cisimult(y, X, A, alpha, tol=sqrt(.Machine$double.eps))

Arguments

y

Responese vector in linear model.

X

Design/model matrix or matrix containing values of explanatory variables (generally including intercept).

A

Coefficient matrix (A.beta is the vector for which confidence interval is needed).

alpha

Collective non-coverage probability of confidence intervals.

tol

A relative tolerance to detect zero singular values while computing generalized inverse, in case X is rank deficient (default = sqrt(.Machine$double.eps)).

Value

The three sets of confidence intervals listed as below:

BFCB

Two-sided Bonferroni simultaneous confidence intervals.

SFCB

Two-sided Scheffe simultaneous confidence intervals.

SNCB

The single confidence intervals.

Details

Normal distribution of response (given explanatory variables and/or factors) is assumed.

References

Sengupta and Jammalamadaka (2019), Linear Models and Regression with R: An Integrated Approach.

Examples

Run this code
# NOT RUN {
data(denim)
attach(denim)
X <- cbind(1, binaries(Denim), binaries(Laundry))
A <- rbind(c(0,1,-1,0,0,0,0), c(0,1,0,-1,0,0,0), c(0,0,1,-1,0,0,0))
cisimult(Abrasion, X, A, 0.05, tol = 1e-10)
detach(denim)
# }

Run the code above in your browser using DataLab