tensorpac.methods.time_lag

tensorpac.methods.time_lag(pha, amp, random_state=None)[source]

Compute surrogates by introducing a time lag on phase series.

This function destroys the relation between the phase and the amplitude in order to correct for PAC that could be obtained by chance. To this end, a random temporal lag is introduced at the beginning of the phase. For a more detailed description, see [4].

Parameters
pha, amparray_like

Respectively the arrays of phases of shape (n_pha, …, n_times) and the array of amplitudes of shape (n_amp, …, n_times).

random_stateint | None

Fix the random state of the machine for reproducible results.

Returns
pha, amparray_like

The phase and amplitude to use to compute the distribution of permutations

References

Canolty et al. 2006 [4]