I have a time series, which I believe should have daily periodicity, the signal is sampled once every 15 minutes, which means that one period is 288 samples.
When I am trying to validate this result based on the FFT of the signal I get different results based on the number of points I sample from the FFT.
I am doing this in python, and first the number of points I sample the FFT is the same as the input array (900).
SEGMENT = np.fft.fft(segment-np.mean(segment))
freqs = np.arange(len(SEGMENT.T))/len(SEGMENT.T)
segment_abs = np.abs(SEGMENT)
fig = plt.figure(); ax = fig.add_subplot(111)
plt.plot(freqs,segment_abs.T,'o--')
plt.ylabel('Mangitude')
plt.xlim((0,0.05));
plt.xticks([0, 1/288], labels=['inf','Daily'])
ax.grid(); plt.show()
When I take the inverse of the X-axis I get that the top 2 frequencies are 245 and 332.
If I instead set the number of points to sample from FFT to 288, I get a clean peak which occurs at the 1/288 frequency.
I'm not sure how to interpret this, or how to think here.
If I want to determine if there is a period of 288 samples, which graph is better to look at?