Skip to content
Prev 351274 / 398502 Next

Simulating a time series with a given spectrum

On 27/05/2015 16:54, Roy Mendelssohn - NOAA Federal wrote:
It is relatively simple to do for series of lengths a power of two (and 
you can simulate a longer series to achieve this).  Use the spectrum 
values to simulate independent complex normals with uniform phase and 
variance proportional to the spectral density at the Fourier frequencies 
then use the inverse fft() to get the series.

You should be able to copy some code from boot::tsboot()'s 'scramble' 
method.