You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
mlab.psd should probably just be calling np.fft.fftfreq here.
In [1]: import numpy as np
In [2]: import matplotlib.pyplot as plt
In [3]: pxx, f = plt.psd(np.ones(1025), 1025, 10e3, sides='twosided')
In [4]: f
Out[4]:
array([-5004.87804878, -4995.12195122, -4985.36585366, ..., 4965.85365854,
4975.6097561 , 4985.36585366])
In this example I have set Fs = 10 kHz, meaning that the highest frequency can't be any larger in than 5 kHz.