[FieldTrip] fieldtrip Digest, Vol 124, Issue 5
Andrade Rey René
rene.andrade at edu.uah.es
Thu Mar 4 12:37:37 CET 2021
Thank you Jan Mathijs I will reconsider the number of dipoles.
Sent from my iPhone
> On 4 Mar 2021, at 12:13, fieldtrip-request at science.ru.nl wrote:
>
> Send fieldtrip mailing list submissions to
> fieldtrip at science.ru.nl
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> or, via email, send a message with subject or body 'help' to
> fieldtrip-request at science.ru.nl
>
> You can reach the person managing the list at
> fieldtrip-owner at science.ru.nl
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of fieldtrip digest..."
>
>
> Today's Topics:
>
> 1. Re: psd for brief segments (Stephen Whitmarsh)
> 2. Re: Computing connectivity matrix EEG 'array exceeds maximum
> array size preference' (Schoffelen, J.M. (Jan Mathijs))
> 3. Re: cluster-based permutation test for PSD
> (Schoffelen, J.M. (Jan Mathijs))
> 4. Re: Design matrix for using ft_statfun_actvsblT
> (Schoffelen, J.M. (Jan Mathijs))
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Thu, 4 Mar 2021 08:18:27 +0100
> From: Stephen Whitmarsh <stephen.whitmarsh at gmail.com>
> To: FieldTrip discussion list <fieldtrip at science.ru.nl>
> Subject: Re: [FieldTrip] psd for brief segments
> Message-ID:
> <CAFrxm=zom5UVhtKSXCi7vtVubAAG+O0P1AN9Gar8ttP1CsJkXg at mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> Hi Mubeen,
>
> I think it depends partly on what you consider "reliable". Any time series
> can be expressed in the frequency domain, and that would be
> an accurate representation.
> Typically reliability would be a consideration based on how reproducible a
> phenomenon can be shown to be, and in this case you only have one event.
> However, it occurs on multiple electrodes, so that might give you a sense
> of reliability (And the possibility of averaging the spectrum)
>
> Perhaps try something like this:
> A) Do an FFT on every electrode in the green timewindow (cfg.method =
> 'mtmfft' in ft_freqanalysis, no need for tapers).
> B) Do an FFT on every electrode in a window of equal size right before.
> Plot the results in the same figure: B in black, A in red. Plot an average
> for both time windows as well. You can see whether you can spot a
> difference in the spectra that is consistent over electrodes.
> You can then try out different window sizes to see how much that makes a
> difference.
>
> In the end though, expressing something in terms of frequencies only makes
> sense to me if there is some periodicity in the signal, so I am not sure a
> frequency analysis is appropriate for describing (the low frequency) part
> of spike-waves. As I said earlier, a peak detection (perhaps after some
> high-pass filtering) might be more to the point, depending on what you're
> after.
>
> Hope this helps,
> Stephen
>
>
>
>
> Op do 4 mrt. 2021 om 06:12 schreef mubeen afzal <mubafzal at hotmail.com>:
>
>> Hi fieldtrip team,
>>
>> I wanted to ask the experts here if power can be calculated on such brief
>> segment of generalised spike/wave. In the 30 minute recording this subject
>> had only this single spike. Can a peak PSD be reliably calculated for such
>> a brief segment and if so what window size and taper should ideally be
>> used. I am using 4 second windows for other subjects who have 2 or more
>> cycles of the spike/slow wave. I am not really interested in time-resolved
>> frequency band. Just the freq-power relationship. This is quite confusing
>> for me. All help will be highly appreciated.
>>
>> Regards,
>> Mubeen
>>
>> _______________________________________________
>> 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/20210304/6e1eac6e/attachment-0001.htm>
>
> ------------------------------
>
> Message: 2
> Date: Thu, 4 Mar 2021 08:01:40 +0000
> From: "Schoffelen, J.M. (Jan Mathijs)" <jan.schoffelen at donders.ru.nl>
> To: FieldTrip discussion list <fieldtrip at science.ru.nl>
> Subject: Re: [FieldTrip] Computing connectivity matrix EEG 'array
> exceeds maximum array size preference'
> Message-ID: <DA277CFC-DDBF-43C9-9FB8-081F93BF5E2F at donders.ru.nl>
> Content-Type: text/plain; charset="utf-8"
>
> Hi Rene,
>
> I would recommend you to take a step back and think a bit about what you try to achieve. It looks as if you want to compute an all-pairwise connectivity matrix for source-reconstructed EEG, where the number of dipolar sources is more than 40.000. Does your underlying scientific question require you to have that many sources? Related to this, is there a reason to assume that the spatial resolution of your reconstruction will be so high that it requires such a high spatial resolution?
>
> If the answer to both those questions is ’no’, you should consider to use a source model that has way fewer dipole positions, e.g. on the order of 4000 or so.
>
> On the off chance that the answer to one (or both) of the above questions is ‘yes’, you should get yourself a big computer, with a lot of RAM, and a MATLAB configuration that can handle very big matrices.
>
> Best wishes,
> Jan-Mathijs
>
>
>> On 3 Mar 2021, at 19:10, Andrade Rey René <rene.andrade at edu.uah.es> wrote:
>>
>> Dear Fieldtrip experts:
>>
>> I am trying to run a modified version of the field trip tutorial for connectivity analysis for eeg. I am still struggling for one issue.
>>
>> Requested 42432x42432 (26.8GB) array exceeds maximum array size preference. Creation of
>> arrays greater than this limit may take a long time and cause MATLAB to become unresponsive.
>> See array size limit or preference panel for more information.
>>
>> Error in univariate2bivariate (line 263)
>> data.crsspctrm = (mom*mom')./nrpt;
>>
>> Error in ft_connectivityanalysis (line 488)
>> [data, powindx, hasrpt] = univariate2bivariate(data, 'mom', 'crsspctrm', dtype,
>> 'channelcmb', cfg.refindx, 'keeprpt', 0);
>>
>> Error in fieldtrip_coherence (line 225)
>> source_conn = ft_connectivityanalysis(cfg, source);
>>
>>
>> How could I overcome this issue? Dividing the sample?
>>
>> Best,
>> Rene Andrade.
>> _______________________________________________
>> fieldtrip mailing list
>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>> https://doi.org/10.1371/journal.pcbi.1002202
>
>
>
>
> ------------------------------
>
> Message: 3
> Date: Thu, 4 Mar 2021 08:10:07 +0000
> From: "Schoffelen, J.M. (Jan Mathijs)" <jan.schoffelen at donders.ru.nl>
> To: FieldTrip discussion list <fieldtrip at science.ru.nl>
> Subject: Re: [FieldTrip] cluster-based permutation test for PSD
> Message-ID: <A2E9F96D-D7C1-4E9E-97D6-E5CB6B3ACBBF at donders.ru.nl>
> Content-Type: text/plain; charset="utf-8"
>
> Hi Omid,
>
>
> 1) I would like to know how I can have these kinds of plots & analysis in Fieldtrip.
>
> Yes.
>
>
> 2)I have preprocced my raw data on EEglab. Can I use them in Fieldtrip?
>
> Yes. There’s a function in EEGlab, called eeglab2fieldtrip that can convert data from an EEG ‘format’ to a structure that fieldtrip can work with. As far as I know, it does not support the conversion of data defined in the spectral domain however, so you can transform the time-domain data from EEGlab into fieldtrip format, and would need to redo the spectral analysis in Fieldtrip. Alternatively, you can try and be creative, and write some code yourself to convert the PSDs and associated metadata into a structure that the statistics-functions in Fieldtrip can handle. For this you may want to investigate the documentation of ft_datatype_freq
>
> Good luck,
> Jan-Mathijs
>
>
>
> In advance thank you for attention.
>
> Best regards
>
>
> <41598_2019_42693_Fig3_HTML.jpg>
>
>
>
>
> --
> Omid Sefat
> PhD student
> Institute for Cognitive Science Studies
>
>
> [Mailtrack] <https://mailtrack.io/?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality5&> Sender notified by
> Mailtrack<https://mailtrack.io/?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality5&> 03/03/21, 12:45:52 PM
>
> _______________________________________________
> 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/20210304/29ac8762/attachment-0001.htm>
>
> ------------------------------
>
> Message: 4
> Date: Thu, 4 Mar 2021 08:18:04 +0000
> From: "Schoffelen, J.M. (Jan Mathijs)" <jan.schoffelen at donders.ru.nl>
> To: FieldTrip discussion list <fieldtrip at science.ru.nl>
> Subject: Re: [FieldTrip] Design matrix for using ft_statfun_actvsblT
> Message-ID: <7652B767-0F89-44D8-B92B-230056695E9C at donders.ru.nl>
> Content-Type: text/plain; charset="utf-8"
>
> Hi Paul,
>
> Related to the specific error message (which does not seem to have anything to do with the actual test-statistic that you specified): Are you sure that the input into ft_timelockstatistics is correctly formatted? The error message suggests that there is no ‘observation’ dimension, i.e. that the individual subjects are not ‘available’.
>
> Unrelated to this, are you sure that you want to use the ‘actvsblT’ for the statistical comparison? I have never used this function myself, but reading the low-level code, line 85 ft_statfun_actvsblT throws an error if the input data is not a time-frequency representation, i.e. it suggests that this function has been written to be only applied to spectral data. You mention that you want to do a(n as of yet underspecified statistical inferential test - e.g. what’s the null hypothesis to be tested) on ERP data.
>
> Good luck,
>
> Jan-Mathijs
>
>
> On 4 Mar 2021, at 02:47, Paul Dhami <pdhami06 at gmail.com<mailto:pdhami06 at gmail.com>> wrote:
>
> Dear FieldTrip community,
>
> I have 30 participants who conducted an ERP study with one condition.
>
> Accordingly, I first averaged the trials within each participant, and now would like to use the ft_statfun_actvsblT to compare the baseline versus post ERP modulation.
>
> However, I am having trouble creating the design matrix.
>
> As I have 30 participants, I used the following code:
>
> cfg.ivar = 1;
> cfg.uvar = 2;
> cfg.design(1,:) = [ones(1,30) ones(1,30)*2];
> cfg.design(2,:) = [1:30 1:30];
>
> But I get the following error:
>
> Error using ft_timelockstatistics (line 171)
> the length of the design matrix (2) does not match the number of observations in the data
> (30)
>
> Could anyone provide help as to how to appropriately create a design matrix when using ft_statfun_actvsblT?
>
> Thank you,
> Paul
> _______________________________________________
> 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/20210304/714a7004/attachment-0001.htm>
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> fieldtrip mailing list
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> _______________________________________________
> fieldtrip mailing list
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> https://doi.org/10.1371/journal.pcbi.1002202
>
>
> ------------------------------
>
> End of fieldtrip Digest, Vol 124, Issue 5
> *****************************************
More information about the fieldtrip
mailing list