python
python copied to clipboard
Consider using `filtfilt` instead of `lfilter` for `interp`
I found that in your implementation of interp (in the multirate module), if you use filtfilt instead of lfilter, and don't cut off the results (ie. with [r*l+1:-1]) the result is much closer to that produced by MATLAB's interp. In particular, it's closer to meeting the constraint that existing points are preserved.