Hello all,
I’m trying to replicate this MATLAB code in Julia for zero-phase filtering:
d = designfilt('bandpassfir', 'StopbandFrequency1', 1e-9, ...
'PassbandFrequency1', 35, 'PassbandFrequency2', 45, ...
'StopbandFrequency2', 50, 'StopbandAttenuation1', 120, ...
'PassbandRipple', 1, 'StopbandAttenuation2', 120, 'SampleRate', 100);
Which results in a filter with the following properties:
d =
digitalFilter with properties:
Coefficients: [1×371 double]
Specifications:
FrequencyResponse: 'bandpass'
ImpulseResponse: 'fir'
SampleRate: 100
StopbandAttenuation1: 120
PassbandFrequency1: 1
StopbandFrequency2: 50
PassbandRipple: 1
PassbandFrequency2: 5
StopbandAttenuation2: 120
StopbandFrequency1: 1.0000e-09
DesignMethod: 'equiripple'
And I use this in filtfilt:
filteredData = filtfilt(d, data)
However, I’m having difficulty with the DSP package to replicate this. The FIR method asks for a window and I couldn’t find the equiripple design method for FIR in the documentation. Can anybody help me out?
Thanks,
Yasir