@@ -3332,7 +3332,7 @@ def _reflow_param_docstring(docstring, has_first_line=True, width=75):
3332
3332
difference will be preserved.
3333
3333
"""
3334
3334
3335
- docdict ["reject_drop_bad" ] = """
3335
+ docdict ["reject_drop_bad" ] = """\
3336
3336
reject : dict | str | None
3337
3337
Reject epochs based on **maximum** peak-to-peak signal amplitude (PTP)
3338
3338
or custom functions. Peak-to-peak signal amplitude is defined as
@@ -3354,10 +3354,17 @@ def _reflow_param_docstring(docstring, has_first_line=True, width=75):
3354
3354
3355
3355
Custom rejection criteria can be also be used by passing a callable,
3356
3356
e.g., to check for 99th percentile of absolute values of any channel
3357
- across time being bigger than 1mV. The callable must return a good, reason tuple.
3358
- Where good must be bool and reason must be str, list, or tuple where each entry is a str.::
3359
-
3360
- reject = dict(eeg=lambda x: ((np.percentile(np.abs(x), 99, axis=1) > 1e-3).any(), "> 1mV somewhere"))
3357
+ across time being bigger than :unit:`1 mV`. The callable must return a
3358
+ ``(good, reason)`` tuple: ``good`` must be :class:`bool` and ``reason``
3359
+ must be :class:`str`, :class:`list`, or :class:`tuple` where each entry
3360
+ is a :class:`str`::
3361
+
3362
+ reject = dict(
3363
+ eeg=lambda x: (
3364
+ (np.percentile(np.abs(x), 99, axis=1) > 1e-3).any(),
3365
+ "signal > 1 mV somewhere",
3366
+ )
3367
+ )
3361
3368
3362
3369
.. note:: If rejection is based on a signal **difference**
3363
3370
calculated for each channel separately, applying baseline
0 commit comments