Skip to contents

A compact header (method, what changed, how many changepoints, the convention their locations follow, the penalty and the series length) followed by the first ten changepoints. For the segment table and the fitted parameters use summary(); for the changepoints as data use tidy().

Usage

# S3 method for class 'ggcpt'
print(x, ...)

Arguments

x

A ggcpt object.

...

Additional arguments (ignored).

Value

x, invisibly. Called for the side effect of printing.

Examples

set.seed(2026)
print(cpt_detect(c(rnorm(40), rnorm(40, 4)), method = "pelt"))
#> ggcpt (changepoint detection result)
#>   Method:             pelt
#>   Change in:          mean
#>   Changepoints found: 1
#>   CP convention:      left
#>   Penalty:            MBIC
#>   Series length:      80
#> 
#> Changepoints:
#> # A tibble: 1 × 2
#>      cp cp_value
#>   <int>    <dbl>
#> 1    40   -0.825