total_c_correlation {otsfeatures} | R Documentation |
Computes the total cumulative correlation of an ordinal time series
Description
total_c_correlation
returns the value of the total cumulative correlation for
an ordinal time series
Usage
total_c_correlation(series, lag = 1, states, features = FALSE)
Arguments
series |
An OTS. |
lag |
The considered lag (default is 1). |
states |
A numerical vector containing the corresponding states. |
features |
Logical. If |
Details
Given an OTS of length with range
,
, and
the cumulative binarized time series, which is defined as
,
with
such that
if
(
), the function computes the estimated average
,
where
is the estimated correlation
,
. If
features = TRUE
, the function
returns a matrix whose components are the quantities ,
.
Value
If features = FALSE
(default), returns the value of the total cumulative correlation. Otherwise, the function
returns a matrix of features, i.e., the matrix contains the features employed to compute the
total cumulative correlation.
Author(s)
Ángel López-Oriona, José A. Vilar
Examples
tcc <- total_c_correlation(series = AustrianWages$data[[100]],
states = 0 : 5) # Computing the total cumulative correlation
# for one of the series in dataset AustrianWages
feature_matrix <- total_c_correlation(series = AustrianWages$data[[100]],
states = 0 : 5) # Computing the corresponding matrix of features