[Scipy-tickets] [SciPy] #1410: Incorrect calculation of extended signal in signal.filtfilt
SciPy Trac
scipy-tickets@scipy....
Mon Mar 14 21:11:02 CDT 2011
#1410: Incorrect calculation of extended signal in signal.filtfilt
------------------------------+---------------------------------------------
Reporter: warren.weckesser | Owner: somebody
Type: defect | Status: new
Priority: normal | Milestone: 0.10.0
Component: scipy.signal | Version: 0.9.0
Keywords: |
------------------------------+---------------------------------------------
Old description:
> The function signal.filtfilt extends the input signal x on both ends with
> this code:
> {{{
> s=r_[2*x[0]-x[edge:1:-1],x,2*x[-1]-x[-1:-edge:-1]]
> }}}
> where edge is an integer that is three times the filter length. The
> attached plot shows the values when edge = 11 and the x = np.linspace(0,
> 10, 11). Presumably the data should be a straight line.
New description:
The function signal.filtfilt extends the input signal x on both ends with
this code:
{{{
s=r_[2*x[0]-x[edge:1:-1],x,2*x[-1]-x[-1:-edge:-1]]
}}}
where edge is an integer that is three times the filter length. The
attached plot shows the values when edge = 10 and the x = np.linspace(0,
10, 11). Presumably the data should be a straight line.
--
Comment(by warren.weckesser):
Fixed value of edge mentioned in the description.
--
Ticket URL: <http://projects.scipy.org/scipy/ticket/1410#comment:2>
SciPy <http://www.scipy.org>
SciPy is open-source software for mathematics, science, and engineering.
More information about the Scipy-tickets
mailing list