'Drop bad epochs without retaining the epochs data.
Should be used before slicing operations.
.. warning:: This operation is slow since all epochs have to be read
from disk. To avoid reading epochs from disk multiple
times, use :func:`mne.Epochs.load_data()`.
Parameters
reject : dict | str | None
Rejection parameters based on peak-to-peak amplitude.
Valid keys are \'grad\' | \'mag\' | \'eeg\' | \'eog\' | \'ecg\'.
If reject is None then no rejection is done. If \'existing\',
then the rejection parameters set at instantiation are used.
flat : dict | str | None
Rejection parameters based on flatness of signal.
Valid keys are \'grad\' | \'mag\' | \'eeg\' | \'eog\' | \'ecg\', and values
are floats that set the minimum acceptable peak-to-peak amplitude.
If flat is None then no rejection is done. If \'existing\',
then the flat parameters set at instantiation are used.
verbose : bool, str, int, or None
If not None, override default verbose level (see
:func:`mne.verbose` and :ref:`Logging documentation <tut_logging>`
for more). Defaults to self.verbose.
Returns
epochs : instance of Epochs
The epochs with bad epochs dropped. Operates in-place.
Notes
Dropping bad epochs can be done multiple times with different
``reject`` and ``flat`` parameters. However, once an epoch is
dropped, it is dropped forever, so if more lenient thresholds may
subsequently be applied, `epochs.copy` should be used.'

@verbose
def drop_bad(self, reject='existing', flat='existing', verbose=None):

    if (reject == 'existing'):
        if ((flat == 'existing') and self._bad_dropped):
            return
        reject = self.reject
    if (flat == 'existing'):
        flat = self.flat
    if any(((isinstance(rej, string_types) and (rej != 'existing')) for rej in (reject, flat))):
        raise ValueError('reject    and    flat,    if    strings,    must    be    "existing"')
    self._reject_setup(reject, flat)
    self._get_data(out=False)
    return self
