maad.features.frequency_raoq
- maad.features.frequency_raoq(S_power, fn, bin_step=1000)[source]
Compute Rao’s quadratic entropy on a power spectrum (1d). [1]
- Parameters:
- S_powerndarray of floats
Spectrum (1d)
- fn1d ndarray of floats
frequency vector
- bin_stepscalar, optional, default is 1000
Frequency step in Hz
- Returns:
- RAOQscalar
Rao quadratic entropy
References
[1]Zhao, Yueqin. “Rao’s Quadratic Entropy and Some New Applications” (2010). Doctor of Philosophy (PhD), dissertation,Mathematics and Statistics, Old Dominion University. DOI: 10.25777/qgak-sf09
Examples
>>> import maad >>> s, fs = maad.sound.load('../data/spinetail.wav') >>> Sxx_power,tn,fn,_ = maad.sound.spectrogram(s,fs) >>> S_power = maad.sound.avg_power_spectro(Sxx_power) >>> maad.features.frequency_raoq(S_power, fn) 0.10556621228886422