0
votes

I have set of data (x) for power spectral density (Gaussian white noise), and I am trying to find the standard deviation from it. The result looks wrong because I know that the standard deviation must be with a range of 5.

I used below code

sd=std(x)

Data

Thanks

1
That code works, my guess: your knoledge of the range of std is wrong.Ander Biguri
std(x) will give you the standard deviation of the spectrum amplitude. But it sounds like you want the standard deviation of the time-series signal. This questions is a math/statistics question, not a programming one.Eric

1 Answers

2
votes

Take the inverse fourier transform, and look at the element at time zero. Note that this is actually just the sum of all the values (\int{X(w)e^{iwt}}dw | t=0 = \int X(w) dw), with some scaling constant applied which depends on how you defined the psd in a discrete frequency domain


The power spectral density, S_xx(w), is equal to F{R_xx(tau)}, the fourier transform of the autocorrelation, R_xx(tau) = E[x(t)x(t+tau)].

Since you want the standard deviation, you can get R_xx(0) = E[x(t)^2], and then std^2 = E[x(t)^2] - E[x(t)]^2.


Unfortunately, it seems you have no way to recover E[x(t)]. Perhaps you already know this is 0?