runlength | R Documentation |
This function can be used to calculate the run length of a 'cgrcusum', 'bkcusum' or 'bercusum' chart when using control limit h
runlength(chart, h) ## S3 method for class 'cgrcusum' runlength(chart, h, ...) ## S3 method for class 'bkcusum' runlength(chart, h, ...) ## S3 method for class 'bercusum' runlength(chart, h, ...)
chart |
A |
h |
Control limit h to be used when determining the run length |
... |
Other parameters |
The run length of the chart with the given control limit.
cgrcusum
: determines runlength of cgrcusum
object
bkcusum
: determines runlength of bkcusum
object
bercusum
: determines runlength of bercusum
object
Daniel Gomon
exprfitber <- as.formula("(survtime <= 100) & (censorid == 1) ~ age + sex + BMI") glmmodber <- glm(exprfitber, data = surgerydat, family = binomial(link = "logit")) bercus <- bernoulli_cusum(data = subset(surgerydat, hosp_num == 14), glmmod = glmmodber, followup = 100, theta = log(2)) #Determine the run length of the above Bernoulli CUSUM when using a control limit #of h = 1. runlength(bercus, h = 1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.