How to remove DC bias from continous raw eeg signal?

I need to remove DC offset from my raw eeg signal. I have found that remove_dc=True parameter in mne.io.Raw.plot does it only for visualization. Is there any way to remove the dc bias from the EEG raw signal? or subtract the channel mean with the original raw signal?

When plotting raw data, signals only come up with scaling='auto' parameter is passed.

Thanks in advance.

1 Like

Hello @Mukil and welcome to the forum!

I suggest you high-pass filter the data with a small lower bound, like 0.1 Hz. This should remove DC shifts.

raw_filtered = raw.copy().filter(l_freq=0.1, h_freq=None)

Best wishes,
Richard

1 Like

Thank you @richard

1 Like

2 posts were split to a new topic: PSD: Power peaks at 25 and 0 Hz?

A post was merged into an existing topic: PSD: Power peaks at 25 and 0 Hz?