ordinal_cohens_kappa {otsfeatures} | R Documentation |
Computes the estimated ordinal Cohen's kappa of an ordinal time series
Description
ordinal_cohens_kappa
computes the estimated ordinal Cohen's kappa
of an ordinal time series
Usage
ordinal_cohens_kappa(series, states, distance = "Block", lag = 1)
Arguments
series |
An OTS. |
states |
A numerical vector containing the corresponding states. |
distance |
A function defining the underlying distance between states. The Hamming, block and Euclidean distances are already implemented by means of the arguments "Hamming", "Block" (default) and "Euclidean". Otherwise, a function taking as input two states must be provided. |
lag |
The considered lag. |
Details
Given an OTS of length with range
(
),
, the function computes the
estimated ordinal Cohen's kappa given by
,
where
is the DIVC estimate of the dispersion, with
being a distance between ordinal states and
being the
standard estimate of the marginal probability for state
,
and
.
Value
The estimated ordinal Cohen's kappa.
Author(s)
Ángel López-Oriona, José A. Vilar
References
Weiß CH (2019). “Distance-based analysis of ordinal data and ordinal time series.” Journal of the American Statistical Association.
Examples
estimated_ock <- ordinal_cohens_kappa(series = AustrianWages$data[[100]],
states = 0 : 5) # Computing the estimated ordinal Cohen's kappa
# for one series in dataset AustrianWages using the block distance