Hello,
I wanted to ask about the subtraction of the average from the LFP data. I think it is common to rectify EEG data but not LFP (what I have seen from the papers). In your lectures about the General Eigendecomposition you said it is important to subtract the mean before computation of the covariance matrix, so my question is: Should I compute the mean from the rectified signal or original one?
I am asking because there are two different ways to do it:
1) I can just subtract the mean from the original data. In this case it will be close to 0, because the signal is not rectified. Not big difference from the original signal.
LFP = LFP - mean(LFP)
2) I can take absolute of the signal and then compute the mean then subtract the mean from the rectified signal. After this, revert negative values back.
mask = LFP<0
mean = abs(LFP).mean()
LFP_norm = abs(LFP) - mean
LFP_norm[mask] = LFP_norm[mask] * (-1)
I attached plots generated from two different approaches.
The same applies to the baseline subtraction, which way is the proper way of doing this?
Thanks,