<div dir="ltr"><div>Thanks!<br><br>For the record I did:<br><br>noise_freq = 60. # US line noise<br></div><div>width = 2. # notch widh in Hz<br></div><div><br># harmonics until nquist<br>n_harm = <a href="http://raw.info">raw.info</a>['sfreq'] // (2. * noise_freq) + 1 <br><br># band pass first to last harmonics<br>harmonics = noise_freq * np.arange(1, n_harm)<br>raw.filter(noise_freq - width, harmonics[-1] + width)<br><br></div><div># band stop filter in between harmonics (it's not really a notch, since the freq width is very large)<br></div><div>raw.notch_filter(freqs=harmonics[:-1]+noise_freq//2, notch_widths=noise_freq - 2*width)<br><br></div>JR<br></div><div class="gmail_extra"><br><div class="gmail_quote">On 23 March 2016 at 10:13, dgw <span dir="ltr"><<a href="mailto:dgwakeman@gmail.com" target="_blank">dgwakeman@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi JR,<br>
<br>
what about:<br>
bandpass: 55: 245, plus notch filters for the other gaps<br>
<br>
d<br>
<div><div class="h5"><br>
On Wed, Mar 23, 2016 at 10:11 AM, JR KING <<a href="mailto:jeanremi.king@gmail.com">jeanremi.king@gmail.com</a>> wrote:<br>
> Hi all,<br>
><br>
> Is there a way in MNE to do the opposite of notch-filtering so as to filter<br>
> out everything but the line noise and its harmonics?<br>
><br>
> I'm typically trying to filter the signals so as to only keep the 60, 120,<br>
> 180, 240 Hz frequency bands.<br>
><br>
> Thanks!<br>
><br>
> JR<br>
><br>
><br>
><br>
</div></div>> _______________________________________________<br>
> Mne_analysis mailing list<br>
> <a href="mailto:Mne_analysis@nmr.mgh.harvard.edu">Mne_analysis@nmr.mgh.harvard.edu</a><br>
> <a href="https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis" rel="noreferrer" target="_blank">https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis</a><br>
><br>
><br>
> The information in this e-mail is intended only for the person to whom it is<br>
> addressed. If you believe this e-mail was sent to you in error and the<br>
> e-mail<br>
> contains patient information, please contact the Partners Compliance<br>
> HelpLine at<br>
> <a href="http://www.partners.org/complianceline" rel="noreferrer" target="_blank">http://www.partners.org/complianceline</a> . If the e-mail was sent to you in<br>
> error<br>
> but does not contain patient information, please contact the sender and<br>
> properly<br>
> dispose of the e-mail.<br>
><br>
_______________________________________________<br>
Mne_analysis mailing list<br>
<a href="mailto:Mne_analysis@nmr.mgh.harvard.edu">Mne_analysis@nmr.mgh.harvard.edu</a><br>
<a href="https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis" rel="noreferrer" target="_blank">https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis</a><br>
</blockquote></div><br></div>