LIMO-EEG-Toolbox / limo_tools

Hierarchical Linear Modelling for MEEG data
https://limo-eeg-toolbox.github.io/limo_meeg/
Other
58 stars 27 forks source link

Correct percent limit for trimmed mean #89

Closed NirOfir closed 2 months ago

NirOfir commented 2 years ago

limo_trimci() checks that the percent trimming is between 0 and 100. Since the same percent is trimmed from both sides of the distribution, if someone sets percent > 50, that means that more than 100% of the data should be removed... I suggest to limit percent in the range 0-50 (or maybe smaller, if the median is also not supported). What do you think?

CPernet commented 2 years ago

makes sense! maybe up to 30% and if more - warning message + return?

NirOfir commented 2 years ago

Sounds good. I think warning + return is like error(), right?

CPernet commented 2 years ago

i would instead set to the max say 30%, warning('maximum trimming set to 30%'); and not breaking code note we should have this info in the associated LIMO.mat

NirOfir commented 2 years ago

Ah, got you, that makes sense.