mne_hfo.utils.apply_std#

mne_hfo.utils.apply_std(metric, threshold_dict, kwargs)[source]#

Calculate and apply the threshold based on number of standard deviations.

Parameters:
metricnp.ndarray

Values to apply the threshold to.

threshold_dictdict

Dictionary of threshold values. Should just have thresh, which is the number of standard deviations to check against.

kwargsdict

Additional key-word args from the detector needed to apply the threshold. Step_size, win_size, and n_times are required keys.

Returns:
output: List of tuple

List of detected events that pass the threshold.