The goal of backCUSUM is to provide functionality to apply the methods developed in the paper “Backward CUSUM for Testing and Monitoring Structural Change with an Application to COVID-19 Pandemic Data” by Sven Otto and Jörg Breitung. The repository also provides code to replicate all simulation results in this paper.
Paper: https://doi.org/10.1017/S0266466622000159
Preprint: https://arxiv.org/abs/2003.02682
You can install the package using the following command:
library(remotes)
install_github("ottosven/backCUSUM")
This is a basic example:
library(backCUSUM)
T <- 100
breakpoint <- floor(3*T/4)
beta1 = 0
beta2 = 1
u <- rnorm(T,0,1)
y <- c(rep(beta1,breakpoint), rep(beta2,T-breakpoint)) + u
Q.test(y~1)
BQ.test(y~1)
SBQ.test(y~1)
get.recresid(y~1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.