Time series classification algorithms are not widely available in R, so Stickleback interfaces with a Python package (sktime). These helper functions define time series classification models using the sktime package. Use create_tsc for univariate bio-logging data and compose_tsc for multivariate.

create_tsc(module, algorithm, params)

compose_tsc(module, algorithm, params, columns)

Arguments

module

[character(1)] Name of module in sktime.classification, e.g. "interval_based".

algorithm

[character(1)] Name of time series classification algorithm, e.g. "SupervisedTimeSeriesForest".

params

[list] Hyperparameters for algorithm, e.g. number of estimators.

columns

[character(1)] Names of columns for composition (compose_tsc only).

Value

[py:sktime.base.BaseEstimator] A time series classification model (see Stickleback).

Examples

# Load sample data
c(lunge_sensors, lunge_events) %<-% load_lunges()
# Define a time series classifier
tsc <- compose_tsc(module = "interval_based",
                   algorithm = "SupervisedTimeSeriesForest",
                   params = list(n_estimators = 2L, random_state = 4321L),
                   columns = columns(lunge_sensors))