Skip to contents

This function converts a set of Doppler frequency values into their corresponding Doppler bin indices within a SeaSondeR object.

Usage

seasonder_DopplerFreq2Bins(seasonder_cs_object, doppler_values)

Arguments

seasonder_cs_object

A SeaSondeR cross-spectral object containing metadata about the Doppler bins.

doppler_values

A numeric vector specifying the Doppler frequencies to be converted into bin indices.

Value

An integer vector of Doppler bin indices corresponding to the input Doppler frequencies. Values that fall outside the valid bin range are assigned NA.

Details

This function first retrieves the Doppler frequency bins from the given SeaSondeR object using seasonder_getDopplerBinsFrequency in non-normalized form. The spectral resolution, which defines the frequency step size (\(\Delta f\)), is obtained using seasonder_getDopplerSpectrumResolution.

The number of Doppler bins is then determined using seasonder_getnDopplerCells.

With this information, the function calls seasonder_computeDopplerFreq2Bins to determine the corresponding bin indices for each input Doppler frequency.

See also

seasonder_Bins2NormalizedDopplerFreq for the reverse operation. seasonder_computeDopplerFreq2Bins for the core computation logic.