pyhctsa.operations.correlation.time_rev_kaplan

pyhctsa.operations.correlation.time_rev_kaplan(y, time_lag=1)

Time-reversal asymmetry statistic (D. Kaplan).

An estimator of the bicovariance difference \(E[x_t^2 x_{t+L}] - E[x_t x_{t+L}^2]\) (zero, in expectation, for a time-reversible process), computed on the triples \((x_t, x_{t+L}, x_{t+2L})\) as

\[\langle x_{t+L} (x_{t+2L}^2 - x_t^2) \rangle .\]

The mean is not removed (z-score the series first for a location-free statistic). See J. B. Ramsey and P. Rothman, “Time irreversibility and business cycle asymmetry”, J. Money Credit Bank. 28, 1 (1996). Statistic as used in D. Kaplan’s code (hctsa DK_timerev).

Parameters:
y : array-like

The input time series.

time_lag : int, optional

The time scale \(L\) (in samples). Default is 1.

Returns:

The time reversal asymmetry statistic (NaN if the series is too short, i.e., has no triple, fewer than 2 * time_lag + 1 samples).

Return type:

float