DP.regression {changepoints} | R Documentation |
Dynamic programming algorithm for regression change points localisation with l_0
penalisation.
Description
Perform dynamic programming algorithm for regression change points localisation.
Usage
DP.regression(y, X, gamma, lambda, delta, eps = 0.001)
Arguments
y |
A |
X |
A |
gamma |
A positive |
lambda |
A positive |
delta |
A positive |
eps |
A |
Value
An object of class
"DP", which is a list
with the following structure:
partition |
A vector of the best partition. |
cpt |
A vector of change points estimation. |
Author(s)
Daren Wang & Haotian Xu
References
Rinaldo, Wang, Wen, Willett and Yu (2020) <arxiv:2010.10410>
Examples
d0 = 10
p = 20
n = 100
cpt_true = c(30, 70)
data = simu.change.regression(d0, cpt_true, p, n, sigma = 1, kappa = 9)
temp = DP.regression(y = data$y, X = data$X, gamma = 2, lambda = 1, delta = 5)
cpt_hat = temp$cpt
[Package changepoints version 1.1.0 Index]