An error in filtfilt
조회 수: 8 (최근 30일)
이전 댓글 표시
load P01EC1
sig= P01EC1(:,:)';
sig is 4x30800 double
When I did like this:
subs_cd1_alpha=filtfilt(b,a,sig);
I’ve got this error:
Error using filtfilt>getCoeffsAndInitialConditions (line 228)
Data length must be larger than 18 samples.
Error in filtfilt>efiltfilt (line 129)
[b2,a2,zi,nfact,L] = getCoeffsAndInitialConditions(b,a,Npts);
Error in filtfilt (line 89)
y=efiltfilt(b,a,x);
Error in subject_01_EC1Ac (line 287)
subs_cd1_alpha=filtfilt(b,a,sig);
And
In this case:
for i=1:4
subs_cd1_alpha=filtfilt(b,a,sig(:,i));
end
This error happened:
Error using filtfilt>getCoeffsAndInitialConditions (line 228)
Data length must be larger than 18 samples.
Error in filtfilt>efiltfilt (line 129)
[b2,a2,zi,nfact,L] = getCoeffsAndInitialConditions(b,a,Npts);
Error in filtfilt (line 89)
y=efiltfilt(b,a,x);
Error in subject_01_EC1Ac (line 285)
subs_cd1_alpha=filtfilt(b,a,sig(:,i));
댓글 수: 0
채택된 답변
Bruno Luong
2022년 10월 1일
편집: Bruno Luong
2022년 10월 1일
Don't tranpose your date if you want to filter along the long dimension
sig= P01EC1(:,:);
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Digital Filtering에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!