The goal of the package is to allow easy applications of continuous time CUSUM procedures on survival data. Specifically, the Biswas & Kalbfleisch CUSUM (2008) and the CGR-CUSUM (2021).
Besides this, it allows for the construction of the Binary CUSUM chart and funnel plot on survival data as well.
You can install the released version of success from CRAN with:
install.packages("success")
And the development version from GitHub with:
# install.packages("devtools")
::install_github("d-gomon/success") devtools
This is a basic example which shows you how to construct a CGR-CUSUM chart on a hospital from the attached data set “surgerydat”:
<- subset(surgerydat, unit == 1)
dat <- as.formula("Surv(survtime, censorid) ~ age + sex + BMI")
exprfit <- coxph(exprfit, data = surgerydat)
tcoxmod
<- cgr_cusum(data = dat, coxphmod = tcoxmod, stoptime = 200)
cgr plot(cgr)
You can plot the figure with control limit by using:
plot(cgr, h = 10)
And determine the runlength of the chart when using control limit :
runlength(cgr, h = 10)
#> [1] 151
Hospital 1 would be detected by a CGR-CUSUM with control limit after days.
Alternatively, you can construct the CGR-CUSUM only until it crosses control limit by:
<- cgr_cusum(data = dat, coxphmod = tcoxmod, h = 10)
cgr plot(cgr)
The theory behind the methods in this package can be found in:
Gomon D., Putter H., Nelissen R.G.H.H., van der Pas S (2022): CGR-CUSUM: A Continuous time Generalized Rapid Response Cumulative Sum chart, arXiv: a preprint