time series FFT and power law

I have a time series for which I would like to calculate the power law of the frequecy/power (Fourier).
any advice on how to do that and what package to use?