You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wanted to try playing around with my own LFP ephys recordings, but cannot seem to run my lfps array (shape=(7350,)) with the filter_ripple_band(lfps) function to get the filtered_lfps.
The ValueError I get is "The length of the input vector x must be greater than padlen, which is 954." which is traced back to the "filtered_data[~is_nan] = filtfilt(filter_numerator, filter_denominator, data[~is_nan], axis=0)" section of the code.
Let me know if you have any ideas or need any more information!
The text was updated successfully, but these errors were encountered:
The ripple filter here is designed for a signal sampled at 1500 Hz. If your signal is not this, then I would recommend constructing your own ripple filter.
I believe this function is expecting something of shape (7350,1) because it is built to process multiple LFPs.
The other possibility is that you have a bunch of NaNs in your input data.
Your second point answered the issue. I needed the extra dimension for the functions to work (I thought I saw in the code it was commented to be shape (X,) ).
Also, to your first point, am I correct in assuming this filter_ripple_band() function is essentially applying a bandpass filter in the high gamma range on the lfp signal?
Hello,
I wanted to try playing around with my own LFP ephys recordings, but cannot seem to run my lfps array (shape=(7350,)) with the filter_ripple_band(lfps) function to get the filtered_lfps.
The ValueError I get is "The length of the input vector x must be greater than padlen, which is 954." which is traced back to the "filtered_data[~is_nan] = filtfilt(filter_numerator, filter_denominator, data[~is_nan], axis=0)" section of the code.
Let me know if you have any ideas or need any more information!
The text was updated successfully, but these errors were encountered: