Learn R Programming

harbinger (version 1.2.767)

hcp_chow: Chow Test (structural break)

Description

Change-point detection for linear models using F-based structural break tests from the strucchange package doi:10.18637/jss.v007.i02. It wraps the Fstats and breakpoints implementation available in the strucchange library.

Usage

hcp_chow()

Arguments

Value

hcp_chow object

Examples

Run this code
library(daltoolbox)

# Load change-point example data
data(examples_changepoints)

# Use a simple example
dataset <- examples_changepoints$simple
head(dataset)

# Configure the Chow detector
model <- hcp_chow()

# Fit the detector (no-op for Chow)
model <- fit(model, dataset$serie)

# Run detection
detection <- detect(model, dataset$serie)

# Show detected change points
print(detection[(detection$event),])

Run the code above in your browser using DataLab