calcpk: Calculate Per-Challenge Probability of Infection

Description Usage Arguments Details Value Note Author(s) References See Also Examples

View source: R/calcpk.R

Description

This function estimates the per-challenge probability of infection.

Usage

1
calcpk(object, predlevel, CIlevel = 0.95)

Arguments

object

a fitted object of class inheriting from "rld".

predlevel

a value or a vector indicating covariate for prediction of per-challenge probability of infection.

CIlevel

confidence level. The default is 0.95.

Details

Calculate the per-challenge risk of infection for the contrast group and reference group.

Value

pk

risk of infection for the contrast group.

pk_se

standard error of the estimated pk.

lwr

lower bound value of the confidence interval of the estimated pk.

upr

upper bound value of the confidence interval of the estimated pk.

Note

The variable names in the predlevel should match the names in the data frame.

Author(s)

Bin Yao, Ying Huang and Chaeryon Kang

References

Kang, C., Huang, Y., and Miller, C. (2015). A discrete-time survival model with random effects for designing and analyzing repeated low-dose challenge experiments. Biostatistics, 16(2): 295-310.

See Also

calcVEk, calcVEt

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
data(SampleData)
newdata <- transdata(data = SampleData, ndlevel = 3, nexposure = c(10, 10, 2))
fitout <- rld(formula = survival::Surv(time, delta)~factor(dose)+trt+I(I(dose==3)*trt),
              data = newdata, frailty = TRUE)

predictdata <- 1
names(predictdata) <- c("trt")

pkout <- calcpk(object = fitout, predlevel = predictdata, CIlevel = 0.95)
summary(pkout)

rld documentation built on May 2, 2019, 5:57 a.m.