I have constructed a high pass filter using scipy:
l_freq = 0.1
fs = 500
normal_cutoff = l_freq / (0.5 * fs)
sos = butter(4, normal_cutoff, btype = 'high', output = 'sos')
scipy_iir_continuous_data = sosfilt(sos, data)
As well as a bandpass filter using scipy:
l_freq = 1
h_freq = 4
normal_cutoff = [l_freq / (0.5 * fs), h_freq / (0.5 * fs)]
sos = butter(4, normal_cutoff, btype = 'bandpass', output = 'sos')
scipy_iir_continuous_data = sosfilt(sos, data)
I would like to calculate an approximate settling time, or number of samples I need to filter and then discard to arrive at an approximate steady state.
I looked at this answer as well as this old thesis (which seem to have different solutions), but can't figure out how to apply a general settling time formula for a high pass, a low pass, and a bandpass filter given the sampling frequency and the cutoff frequencies.
Thanks for your help.