make new channel based on linear derivation of existing channels

External Email - Use Caution

Hello, I?m trying to find out how to add a new channel that is equal to Channel X ? Channel Y. How do I do this for raw data?
I know I could extract the data and do it that way, but surely theres a way to keep it in the raw data structure?

Thanks!

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20200810/118b9f6e/attachment.html

External Email - Use Caution

hi,

see if https://mne.tools/stable/generated/mne.set_bipolar_reference.html
can help

Alex

External Email - Use Caution

Sounds like maybe you want

https://mne.tools/dev/generated/mne.set_bipolar_reference.html

Alternatively, you could do equivalent calculations using raw.get_data(),
RawArray, and raw.add_channels.

Eric