MATLAB: Dealing with NaN values in FFT

fftnan

Hi, I'm working with a large data set of voxel information from MRI scans of multiple subjects, and as part of the analysis I use FFT. Prior to this, the data already goes through some modifications, removing specific values deemed too low (insignificant data) and replacing it with NaN values. After checking the results I realized there is an issue with FFT and NaN values. Is there some solution or workaround that someone perhaps knows that might help resolve this issue?

Best Answer

If you have R2016b or later, the fillmissing function is an option.