[FieldTrip] group blocks with preprocessed data

Barbara Tsogli Barbara.Tsogli at uib.no
Fri Nov 11 20:12:23 CET 2022


Hello Xavier,

Thank you for your response. I have tried ft_appendata and here is the result:
>> cfg = [];
cfg.keepsampleinfo = 'no';
data_all_sbj2 = ft_appenddata(cfg, allData{2,1}, allData{2,2}, allData{2,3});
Error using ft_appenddata
cannot append this data

Do you think a possible reason for this could be that the input datasets do not have the same number of trials or channels?

Block 1: allData{2, 1} has 39 channels and 44 trials
Block 2: allData{2, 2} has 47 channels and 49 trials
Block 3: allData{2, 3} has 45 channels and 57 trials

Is there any other way of doing this other than using the ft_appendata?

Any help is very much appreciated 🙂
Vera


________________________________
From: fieldtrip <fieldtrip-bounces at science.ru.nl> on behalf of fieldtrip-request at science.ru.nl <fieldtrip-request at science.ru.nl>
Sent: Friday, November 11, 2022 1:00 PM
To: fieldtrip at science.ru.nl <fieldtrip at science.ru.nl>
Subject: fieldtrip Digest, Vol 144, Issue 5

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. some general questions about gamma-related analyses
      (Ivaylo Iotchev)
   2. Within/Between Cluster Analysis (Erica Flaten)
   3. group blocks with preprocessed data (Barbara Tsogli)
   4. Re: group blocks with preprocessed data (Xavier Vrijdag)
   5. Re: some general questions about gamma-related analyses
      (Tzvetan Popov)


----------------------------------------------------------------------

Message: 1
Date: Thu, 10 Nov 2022 12:05:34 +0100
From: Ivaylo Iotchev <ivaylo.iotchev at gmail.com>
To: FieldTrip discussion list <fieldtrip at science.ru.nl>
Subject: [FieldTrip] some general questions about gamma-related
        analyses
Message-ID:
        <CAO-ud34t1SzLgrGLyjJTH9TBrSW+Ln1xdPB--ZS-j0zB7HKMzQ at mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

Dear all,

I am fairly new to frequency-band analyses and have dealt mostly with
transients (sleep spindles) so far. Thus forgive the maybe stupid
questions, however, one on-point professional answer could spare me
scavanging for parts across many unrelated papers.

The whole of the gamma range expands well beyond 30 Hz, the noise
threshold, and thus the first question is whether low-pass filtering below
30 Hz is at all applied when looking for gamma coherence, power etc. ...
One reason I kept the classical filter settings at first is to be
consistent across the many different analyses I apply to the same data
sets, not all of which have to do with gamma, but it dawned on me that
filtering out frequencies above 30 is probably not a good idea(?) for
gamma-related questions?

Moreover, is it acceptable to look for the point of maximum coherence
within that range, rather than average within the range? The data suggests
that the point of maximum coherence shifts across time to higher and higher
frequencies, thus I decided for the time being to report the maximum
coherence (across electrodes) value within the gamma range.

Let me know if there is any additional information I can provide to help
you help me, best wishes and regards,

Ivaylo Iotchev, PhD
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20221110/2bda60ea/attachment-0001.htm>

------------------------------

Message: 2
Date: Thu, 10 Nov 2022 15:38:04 +0000
From: Erica Flaten <flatene at mcmaster.ca>
To: "fieldtrip at science.ru.nl" <fieldtrip at science.ru.nl>
Subject: [FieldTrip] Within/Between Cluster Analysis
Message-ID:
        <YT2PR01MB82325F6A437A7189D87858B9B5019 at YT2PR01MB8232.CANPRD01.PROD.OUTLOOK.COM>

Content-Type: text/plain; charset="utf-8"

An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20221110/faf3d856/attachment-0001.htm>

------------------------------

Message: 3
Date: Thu, 10 Nov 2022 19:51:04 +0000
From: Barbara Tsogli <Barbara.Tsogli at uib.no>
To: "fieldtrip at science.ru.nl" <fieldtrip at science.ru.nl>
Subject: [FieldTrip] group blocks with preprocessed data
Message-ID:
        <PAXPR01MB9219EA0EFE6FD14B0E1BBC9DEE019 at PAXPR01MB9219.eurprd01.prod.exchangelabs.com>

Content-Type: text/plain; charset="iso-8859-1"

Dear FieltTripers,

I was given some preprocessed EEG data in order to perform a Time-Frequency analysis. The experiment has 3 blocks (or sessions); therefore, for each subject, there are 3 different .mat files (Subj1_Block1.mat, Subj1_Block2.mat, Subj1_Block3.mat). Given that we are not interested to consider the block as a factor in our statistical analysis, is there a way to group the 3 .mat files that represent the 3 blocks? in other words, is there a way to create a mat file that contains the information of the 3 blocks (i.e.: Subj1_Block1to3.mat)?

Thank you for your time in advance,
Vera



------------------------------

Message: 4
Date: Thu, 10 Nov 2022 20:47:45 +0000
From: Xavier Vrijdag <x.vrijdag at auckland.ac.nz>
To: FieldTrip discussion list <fieldtrip at science.ru.nl>
Subject: Re: [FieldTrip] group blocks with preprocessed data
Message-ID: <ED515986-3152-4117-8CFF-2120F0F7FFC9 at auckland.ac.nz>
Content-Type: text/plain; charset="utf-8"

Hello Vera,

If the .mat files contain fieldtrip data structures, you can use ft_appenddata to concatenate them into one data structure. You than can save that data structure into a new .mat file.

Regards,

Xavier

Dr Xavier Vrijdag, MSc PhD

Research fellow
Department of Anaesthesiology │ School of Medicine
Faculty of Medical & Health Sciences │ The University of Auckland
Private Bag 92019 │ Auckland 1142 │ New Zealand

M +64 21 0230 4558
E x.vrijdag at auckland.ac.nz<mailto:x.vrijdag at auckland.ac.nz>

[FMHS Logo]




From: fieldtrip <fieldtrip-bounces at science.ru.nl> on behalf of Barbara Tsogli via fieldtrip <fieldtrip at science.ru.nl>
Reply to: FieldTrip discussion list <fieldtrip at science.ru.nl>
Date: Friday, 11 November 2022 at 8:59 AM
To: "fieldtrip at science.ru.nl" <fieldtrip at science.ru.nl>
Cc: Barbara Tsogli <Barbara.Tsogli at uib.no>
Subject: [FieldTrip] group blocks with preprocessed data

Dear FieltTripers,

I was given some preprocessed EEG data in order to perform a Time-Frequency analysis. The experiment has 3 blocks (or sessions); therefore, for each subject, there are 3 different .mat files (Subj1_Block1.mat, Subj1_Block2.mat, Subj1_Block3.mat). Given that we are not interested to consider the block as a factor in our statistical analysis, is there a way to group the 3 .mat files that represent the 3 blocks? in other words, is there a way to create a mat file that contains the information of the 3 blocks (i.e.: Subj1_Block1to3.mat)?

Thank you for your time in advance,
Vera

_______________________________________________
fieldtrip mailing list
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip<https://mailman.science.ru.nl/mailman/listinfo/fieldtrip>
https://doi.org/10.1371/journal.pcbi.1002202<https://doi.org/10.1371/journal.pcbi.1002202>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20221110/1eb4cfda/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 22260 bytes
Desc: image001.png
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20221110/1eb4cfda/attachment-0001.png>

------------------------------

Message: 5
Date: Fri, 11 Nov 2022 09:39:08 +0100
From: Tzvetan Popov <tzvetan.popov at uni-konstanz.de>
To: FieldTrip discussion list <fieldtrip at science.ru.nl>
Subject: Re: [FieldTrip] some general questions about gamma-related
        analyses
Message-ID: <C996C864-719A-49C0-8F7A-43A8F5903DB3 at uni-konstanz.de>
Content-Type: text/plain; charset="utf-8"

Dear Ivo,

> The whole of the gamma range expands well beyond 30 Hz, the noise threshold, and thus the first question is whether low-pass filtering below 30 Hz is at all applied when looking for gamma coherence, power etc. ...  One reason I kept the classical filter settings at first is to be consistent across the many different analyses I apply to the same data sets, not all of which have to do with gamma, but it dawned on me that filtering out frequencies above 30 is probably not a good idea(?) for gamma-related questions?
No, do not apply 30Hz LP. You filter out your signal of interest.
>
> Moreover, is it acceptable to look for the point of maximum coherence within that range, rather than average within the range? The data suggests that the point of maximum coherence shifts across time to higher and higher frequencies, thus I decided for the time being to report the maximum coherence (across electrodes) value within the gamma range.
One typically applies smoothening in the frequency domain when evaluating gamma (power and coherence). I suggest to study this lecture https://www.youtube.com/watch?v=dHTuzMsjVJA <https://www.youtube.com/watch?v=dHTuzMsjVJA>. In particular, at minute 25:49 the advantage of the freq smoothening is highlighted. Given that example your peak frequency will change depending on your decision how much to smooth.

Of note, channel level coherence, particularly for gamma is not recommended. A lot of other stuff is added to the mix (e.g. cardiac, neck muscles etc.). Their contribution will change over time in your experiment. At the end you will not be able to interpret the results and/or you might be fooled.
I suggest you also study this lecture https://www.youtube.com/watch?v=ZBwh0Vm4fh4 <https://www.youtube.com/watch?v=ZBwh0Vm4fh4> and in particular the issues raised from minute 42:49 or so.

Good luck
Tzvetan

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20221111/c7a3f586/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 144, Issue 5
*****************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20221111/841229dc/attachment.htm>


More information about the fieldtrip mailing list