shuffle#

shuffle(data, dim=None, *, rng=None)#

Shuffle one 1-based dimension and return 1-based permutation indices.

dim is EEGLAB’s dimension, so 1 is the first axis. The default is the first dimension whose length is not 1, or the last dimension when every length is 1. EEGLAB only inspects the first three sizes and only shuffles dimensions 1 through 5. Subtract 1 before using the indices with NumPy: the forward indices rebuild the shuffled array and the inverse indices restore the original.

Parameters:
Return type:

tuple[ndarray, ndarray, ndarray]