# NOT RUN {
# Make a serie with three jumps, same as yamamoto example
set.seed(524)
x <- c(rnorm(30,1,1),rnorm(30,2,1),rnorm(30,1,1),rnorm(20,2,1))
# Look up to 5 breaks using pettit
break_prosition <- N_break_point(serie=x, n_max = 5, method='pettit',
auto_select=TRUE,alpha=0.1)
plot(x)
abline(v = break_prosition$breaks, col='red')
# }
Run the code above in your browser using DataLab