Why does filtfilt provide me wrong results?
조회 수: 2 (최근 30일)
이전 댓글 표시
Hi all,
I'm using filtfilt function to filter some signals since i would like to minimize the phase lag between the original signal and the filtered one.
Here my code:
LPsig= designfilt('lowpassiir','FilterOrder',10,'PassbandFrequency',1,'PassbandRipple',0.2, ...
'SampleRate',Fs);
dfCoeff=double(LPsig);
FilteredSignalP=filtfilt(dfCoeff.Coefficients,1,Signal);
In this plot the filtered and non filtered signal are compared: http://s9.postimg.org/46qlzkz67/Immagine.jpg
There is the edge effect with a huge ripple. I found out that both effect are increased with the filter order, with a filter order of 10 both of them are negligeble. Could someone explain to me why? Anytime I have to filter data, I change almost randomly the filter parameter (filter order, filter type, passband ripple, etc) until I get a good result. How may I select the filter parameters?
Thanks
Regards
Pietro
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Single-Rate Filters에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!