I am trying to perform a fourier analysis for a time series but there are NaNs where data is missing and I just get nothing.
Anyone got any idea how I can get around this??
Thanks in advance
Sure. Don't include NaNs in the data to be processed.
Of course, what to do instead is a totally different
question...
Rune
Matthias
It means exactly what I said: Don't inlcude NaNs in
any inputs to numerical routines.
> I have a data set with NaNs, how would you suggest I dont include them??
Then you have a serious problem.
> I am a matlab novice but I dont see how your post can possibly be helpful?
As I said, you have a problem. Like it or not - it is *your*
responsibility as analyst to make sure your data are useful.
> Perhaps you are bored?
Of course I am. Your question is a bit too representative
of the level at CSSM these days.
Rune
> I am trying to perform a fourier analysis for a time series but there
> are NaNs where data is missing and I just get nothing.
> Anyone got any idea how I can get around this??
It sounds to me as if you are _not_ attempting to do a fourier analysis, but
rather that you are attempting to do a discrete fourier transform (DFT) of
regularly sampled data that has NaN's in place of some of the data.
If you search through the back postings, there are some references on how to
perform a dft on irregularly spaced data... it isn't the easiest of tasks, but
the mathematics is well defined.
It looks like you are the only one who couldn't work out that the data was given to me with the NaNs in it
> > Perhaps you are bored?
>
> Of course I am. Your question is a bit too representative
> of the level at CSSM these days.
I don't understand you attitude? So what if my question is a stupid one, nowhere does it state on this website that it is reserved exclusively for experts.
You need to be reminded that you were once a novice as well and knew nothing until someone helped you.
Then deal with it. Either remove the NaNs yourself, or
ask whoever gave you the data for data without NaNs.
> > > Perhaps you are bored?
>
> > Of course I am. Your question is a bit too representative
> > of the level at CSSM these days.
>
> I don't understand you attitude? So what if my question is a stupid one, nowhere does it state on this website that it is reserved exclusively for experts.
> You need to be reminded that you were once a novice as well and knew nothing until someone helped you.
Wrong. I might have been a novice, but I never relied
on help from others. I learned how to find the answers
myself.
Rune