sup3r.qa.utilities.frequency_spectrum

frequency_spectrum(var, f_range=None)[source]

Frequency Spectrum. Gives the portion of the variable associated with each frequency.

Parameters:
  • var (ndarray) – (lat, lon, temporal)

  • f_range (list | None) – List with min and max frequency. When comparing spectra for different domains this needs to be tailored to the specific domain. e.g. f = [1/max_time, …, 1/min_time] If this is not specified f with be set to [0, …, len(y)] where y is the fft output.

Returns:

  • ndarray – Array of frequencies corresponding to energy amplitudes

  • ndarray – 1D array of amplitudes corresponding to the portion of the variable with a given frequency