[FieldTrip] ft_freqanalysis spitting out only NaNs
Yvonne Visser
y.visser at hotmail.com
Tue Sep 3 10:04:59 CEST 2019
Hi Jae,
Have you checked whether your input (data13 & data24) has NaNs in them already?
If that's not it, it might have to do with edge effects: the wavelet method is unable to transform all the way to the beginning/end of the window and leaves some NaNs around the edges. If the size of your wavelet is big (you set this with cfg.width & cfg.gwidth) and the data window is not very long, this could explain why you're getting NaNs. It can be helpful to generate a bigger data window in the step before ft_freqanalysis (e.g. in ft_definetrial set pre- and poststim wider than your window of interest to account for the edge effects).
Hope this helps, best of luck!
Yvonne
________________________________
From: fieldtrip <fieldtrip-bounces at science.ru.nl> on behalf of Jae Moon <jmoon at hollandbloorview.ca>
Sent: Monday, September 2, 2019 6:15 PM
To: fieldtrip at science.ru.nl <fieldtrip at science.ru.nl>
Subject: [FieldTrip] ft_freqanalysis spitting out only NaNs
Hi everyone,
I’m wondering if anyone has been confronted with the same issue of ft_freqanalysis spitting out only NaNs in the output. Here is the code I implemented:
cfg=[];
cfg.method = 'wavelet';
cfg.output = 'pow';
cfg.foilim = [1 60];
cfg.toi = [1:50:1200];
cfg.pad='nextpow2';
freq13=ft_freqanalysis(cfg,data13);
freq24=ft_freqanalysis(cfg,data24);
No matter what method I use or whichever output I use, I keep getting NaNs, and therefore, my granger causality analysis only spits out NaNs as well.
Your help is very much appreciated!
Best,
Jae
Confidentiality Notice:
E-mail may be intercepted between the sender and the receiver and is
therefore neither secure nor confidential. Your continued use of e-mail
communication confirms that you accept this risk. If this is an urgent
matter, please contact me at the phone number provided. This e-mail,
including any attachments, is for the sole use of the intended recipient(s)
and may contain private, confidential, and privileged information.
Any unauthorized review, use, disclosure or distribution is prohibited. If
you are not the intended recipient or this information has been
inappropriately forwarded to you, please contact the sender by reply
e-mail and destroy all copies of the original.
_______________________________________________
fieldtrip mailing list
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
https://doi.org/10.1371/journal.pcbi.1002202
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20190903/62dd97eb/attachment.html>
More information about the fieldtrip
mailing list