# Nyquist Frequency on semi-unevenly sampled data

I have a data set that has 'kind of' constant sampling rate - it switches between 1 min and 2 min. About 70% of the times, samples are taken every 1 minute, and about 30%, samples are taken every 2 minutes.

I tried using FFT, but it didn't work because samples aren't evenly spaced. Instead I applied Lomb-Scargle transformation, and obtained a good looking plot. Upper plot is a Lomb-Scargle periodogram, and lower plot is the original sample data with varying sampling rate (1 min or 2 min).

What should I use for Nyquist Frequency in this case?

## 1 Answer

the lomb scargle in matlab, (plomb) returns a frequency vector as the second output. i would be surprised if the routine you are using doesn’t do the same. there is a common tendency for python signal processing libraries to be functionally equivalent to matlab conventions.

your plots show symmetry around a “center” frequency which is the same as what a FFT does for real inputs, except a FFT would not extend to start a third interval. The high half frequencies(above $$\approx$$ .017 to .033) are the negative frequencies in FFT speak. you can ignore them when you have a real signal.

There really isn’t a simple “Nyquist” frequency with nonuniform sampling.

The documentation of the library you are using should detail how frequency is treated. If it doesn’t, you can find a routine that does or do your own calibration by using test sines of known frequency.

• thanks for your answer. I'm a bit confused what "high half frequencies" mean. Does it mean anything beyoned 0.008 in my plot can be ignored? Also, what does it mean that they are negative frequencies in FFT? – Eric Kim Jun 13 '19 at 13:52
• essentially yes – user28715 Jun 13 '19 at 13:53