pyActigraphy.analysis.Fractal.crossover_search¶
- classmethod Fractal.crossover_search(F_n, n_array, n_min=3, log=False)[source]¶
- Search for crossovers - A crossover is defined as a change in scaling properties of the fluctuations with respect time scales. A search is performed by calculating the series of ratios between the generalized Hurst exponent \(h(q)\) obtained at time scales \(n<n_x\) and time scales \(n>n_x\), for various values of \(n_x\). - Parameters
- F_n (array) – Array of fluctuations. 
- n_array (array of int) – Time scales (i.e window sizes). In minutes. 
- n_min (int, optional) – Minimal number of time scales required to estimate the generalized Hurst exponent. Default is 3. 
- log (bool, optional) – If set to True, assume that the input values have already been log-transformed. Default is False. 
 
- Returns
- h_ratios, h_ratios_err, n_x – Ratio of h(q), and associated uncertainties, obtained for various time scales n_x. 
- Return type
- arrays of floats 
 - Notes - Warning - The calculation of the uncertainty on the ratio of scaling exponents assumes uncorrelated variables: \(\sigma_{A/B}^2=(A/B)^2(\sigma_{A}^2/A^2+\sigma_{B}^2/B^2)\). Most likely, the scaling exponents calculated for time scales \(n<n_x\) is not uncorrelated to the scaling exponents calculated for time scales \(n>n_x\). Therefore, the resulting uncertainty is either overestimated in case of positively correlated variables or underestimated otherwise. However, the magnitude of the calculated uncertainty provides a rough estimate.