cp_aic_eta: Changepoint analysis of different layer models

View source: R/cp_aic_eta.R

cp_aic_etaR Documentation

Changepoint analysis of different layer models

Description

Calculates and plots the AIC and eta-squared statistics for diferent layer models based on a changepoint analysis using the mean and variance.

Usage

cp_aic_eta(data, m = 10, nl = 3)

Arguments

data

A data frame containing the location variable (depth or distance) in the first column, and the value of interest in the second column

m

The maximum number of breakpoints (# layers - 1) to look for

nl

The minimum number of points per layer to be considered

Details

The example data given is intended to show the structure needed for input data. The user should follow this structure, which in general corresponds with a data frame with a sequence in the first column and the observed/measured values in the second column

Value

A ggplot and plotly objects showing the AIC and eta-squared statistics, and a data frame with all the data and possible layer models

Examples

cp_aic_eta(DPM_data, m = 10, nl = 3)


maxgav13/GMisc documentation built on June 12, 2022, 3:48 a.m.