pyhctsa.operations.spectral.spectral_summaries_phase

pyhctsa.operations.spectral.spectral_summaries_phase(y)

Statistics of the Fourier phase spectrum of a time series.

cf. spectral_summaries(), which characterizes the magnitude spectrum in detail but discards phase entirely. For a linear, Gaussian stochastic process, Fourier phases are theoretically i.i.d. uniform on (-pi, pi] – that’s exactly why phase randomization works as a surrogate null model (cf. J. Theiler et al., “Testing for nonlinearity in time series: the method of surrogate data”, Physica D 58(1-4), 77 (1992)). This operation characterizes the phase spectrum directly: deviations from uniformity/independence across frequency are a direct signature of determinism, nonlinearity, or transient/localized structure that the magnitude spectrum alone cannot see.

Phases are weighted by their bin’s magnitude throughout (a standard approach in circular statistics for data of uneven reliability): a single pure tone concentrates essentially all energy in 1-2 bins, and every other bin’s magnitude is set by numerical noise, so its “phase” is meaningless and must not be allowed to swamp an unweighted average. The DC and Nyquist bins (both purely real, phase undefined in the usual oscillatory sense) are excluded throughout.

Parameters:
y : array-like

The input time series.

Returns:

Statistics of the phase spectrum.

Return type:

dict