solarspatialtools.signalproc.tf_delay
- solarspatialtools.signalproc.tf_delay(tf, coh, coh_limit=0.6, freq_limit=0.02, method='fit')
Compute the delay based on the phase of a transfer function
Parameters
- tfpd.DataFrame
The transfer functions, produced by signalproc.averaged_tf.
- cohpd.DataFrame
The coherence, produced by signalproc.averaged_tf. Must match shape of tf.
- coh_limitfloat
The coherence limit to use for filtering the phase. Set to None to include all points.
- freq_limitfloat
The frequency limit to use for filtering the phase. Set to None to include all points.
- methodstr
The method to use for computing the delay.
- Options are:
‘diff’ - unwrap phase and take derivative (not well validated) ‘fit’ - fit a line to the phase ‘multi’ - fit a line to the phase for multiple tfs at once
Returns
- delayfloat
The delay in seconds
- ixnp.array(bool)
The mask used for filtering the phase