From pooneh.baniasad at gmail.com Mon Aug 1 10:17:08 2016 From: pooneh.baniasad at gmail.com (pooneh baniasad) Date: Mon, 1 Aug 2016 12:47:08 +0430 Subject: [FieldTrip] Generating EEG & Source model function Message-ID: Dear FieldTrip community, ​ ​I'm trying to generate EEG signal without using raw datas. I used the 'Subject01.mri' as my anatomical model, the BEM method for preparing a headmodel and 'standard_1020.elc' for aligning electrodes. For a source model I loaded template grid (cortex_20484.surf.gii). Now my questions are how can I set dipole's location (in other words, my grid's resolution)? How can I allocate a source model (sin, cos, ...) to each dipole? Is there any function in Fieldtrip doing that? or I have to writing the code by myself. After having the source model for each dipole and calculating leadfield matrix what should I do for plotting the EEG signal? -- Bests Pouneh Baniasad -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrejakosticln at gmail.com Mon Aug 1 15:41:17 2016 From: andrejakosticln at gmail.com (=?UTF-8?Q?Andreja_Kosti=C4=87?=) Date: Mon, 1 Aug 2016 15:41:17 +0200 Subject: [FieldTrip] Generating EEG & Source model function In-Reply-To: References: Message-ID: Hello Pouneh Baniasad, I had a similar issue some time ago, and found my solution within Fieldtrip, so I might be able to offer a bit of advice. There is a function for in Fieldtrip that will (partially) allow you to simulate dipoles. It's called ft_dipolesimulation.m. Unfortunately, in its current state, it only allows you to simulate 1 dipole. It does have quite a bit potential, however, since the function seems to be originally intended to work with multiple dipoles, but in its current implementation, it will not actually cycle through multiple dipoles and will crash if you give it more than 1. The function will allow you to set frequency, phase, amplitude, sample rate, orientation vector etc. for the dipoles but I didn't test how that works for more than one dipole, since I used externally generated data as my dipole waveforms. With only a couple of extra lines of code (basically just 1 extra for loop around the part that does lead-field calculation), it can be edited to go through a matrix of dipole coordinates and orientations. I'm currently on vacation, so it might take some time for me to dig up modifications I did for it to go through multiple dipoles, but it it took me maybe 10 minutes to fix in total, so it's really easy. I think that the coordinates that you need to give for each dipole are voxel positions from the MRI. There's also a bug near the end of the function, at the place where ft_senstype is called. It will set to MEG in both cases, so that needs fixing as well. Later on, when you get the EEG, you can plot it like this, for example: %View the EEG cfg=[]; cfg.viewmode='vertical'; ft_databrowser(cfg,data_from_ft_dipolesimulation); All the best, Andreja Kostić 2016-08-01 10:17 GMT+02:00 pooneh baniasad : > Dear FieldTrip community, > ​ > ​I'm trying to generate EEG signal without using raw datas. > I used the 'Subject01.mri' as my anatomical model, the BEM method for > preparing a headmodel and 'standard_1020.elc' for aligning electrodes. > For a source model I loaded template grid (cortex_20484.surf.gii). > Now my questions are how can I set dipole's location (in other words, my > grid's resolution)? > How can I allocate a source model (sin, cos, ...) to each dipole? Is there > any function in Fieldtrip doing that? or I have to writing the code by > myself. > After having the source model for each dipole and calculating leadfield > matrix what should I do for plotting the EEG signal? > > > -- > Bests > > Pouneh Baniasad > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From tmadsen at emory.edu Mon Aug 1 17:03:40 2016 From: tmadsen at emory.edu (Teresa Madsen) Date: Mon, 1 Aug 2016 11:03:40 -0400 Subject: [FieldTrip] queries_related to_error In-Reply-To: References: Message-ID: Maybe you accidentally deleted the "utilities" folder? I would try updating to the latest version of FieldTrip. On Sun, Jul 31, 2016 at 6:22 AM, Laxmi Shaw wrote: > Dear Fieldtrip users, > > Suddenly i got one error while compiling any fieldtrip function based > code.Please need your help to remove this error. I have attach the screen > shot of that matlab program. > [image: Inline image 1] > Your helps always been appreciated. > > > Regards > -- > Laxmi Shaw > Research Scholar(PhD) > IIT Kharagpur > West Bengal > Ph no-08388837821 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- Teresa E. Madsen, PhD Division of Behavioral Neuroscience and Psychiatric Disorders Yerkes National Primate Research Center Emory University Rainnie Lab, NSB 5233 954 Gatewood Rd. NE Atlanta, GA 30329 (770) 296-9119 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 103003 bytes Desc: not available URL: From roycox.roycox at gmail.com Mon Aug 1 17:33:59 2016 From: roycox.roycox at gmail.com (Roy Cox) Date: Mon, 1 Aug 2016 11:33:59 -0400 Subject: [FieldTrip] Fwd: postdoc and research assistant position available in Center for Sleep and Cognition In-Reply-To: References: Message-ID: hello all, A postdoc position and RA position are now available in the Center for Sleep and Cognition (PI: Robert Stickgold). Feel free to forward these ads to anyone that may be interested. Best, Roy Cox ------------------------------------------------ *Postdoctoral position in Stickgold lab* Applications are invited for a full-time postdoctoral position at the Center for Sleep and Cognition (sleepandcognition.org ), PI Robert Stickgold, The position is for two years, with possible extension contingent on funding. The lab is at Beth Israel Deaconess Medical Center / Harvard Medical School, in Boston. Research in the lab is focused on the role of sleep in memory consolidation, with current projects investigating emotional memory, memory integration, the algorithms of memory prioritization/selection for consolidation, and the mechanistic role of neural oscillations in these processes. Approaches include targeted memory reactivation, time-frequency analyses of learning- and sleep-associated oscillatory activity, and computational modeling. The lab is also interested in deficits in these processes associated with sleep disorders as well as a range of psychiatric and neurological disorders. A current study, in collaboration with Dara Manoach and Matcheri Keshavan, investigates memory consolidation deficits in patients with schizophrenia. Facilities include two fully equipped sleep rooms for measuring high-density EEG/PSG and several units for behavioral testing. Access to several clinical populations is possible. A PhD in psychology or neuroscience (or a related discipline) and a strong research background are required. The following are beneficial: experience with EEG measurements/analyses, experience running behavioral experiments, programming skills, and strong statistical and quantitative skills. Please send your CV and a brief statement of research interest to Elaine Parr: mparr at bidmc.harvard.edu. Applications will be reviewed until the position is filled. Start date is flexible. *Research assistant position in Stickgold lab* The Center for Sleep and Cognition at Beth Israel Deaconess Medical Center is seeking a college graduate with strong organizational and interpersonal skills as a full time research assistant for projects investigating sleep and memory consolidation. If hired, you will be responsible for screening subjects for participation in experimental studies, enrolling subjects into these studies, administering cognitive tests, and recording the overnight sleep of subjects. This includes actively monitoring subjects’ sleep in the sleep laboratory. You will be expected to work closely with the Principal Investigator, lab mates, and collaborators on all aspects of the project. Training in recording sleep EEGs, behavioral test administration, and data analysis will be provided. Administrative duties will include helping to maintain accurate records, and assist with grant applications, human subject applications, and publications. Some computer programming experience is an asset, as is a high level of comfort with novel computer applications and environments. A bachelor’s degree and prior research experience are required. A background in psychology, statistics, and neuroscience, as well as a prior mentored research project would be preferred. You must be mature and responsible, with excellent oral and written communication skills. You must be able to work independently in a fast-paced environment, juggle and prioritize multiple tasks, feel comfortable working with clinical and non-clinical study populations, and seek assistance when appropriate. This is an excellent research opportunity for someone bound for graduate school in psychology, cognitive neuroscience, or medicine. Position is available immediately. A two-year commitment is required. Please send a resume, (unofficial) transcript, writing sample, and contact information for three references to Elaine Parr: mparr at bidmc.harvard.edu. -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.vanEs at donders.ru.nl Tue Aug 2 13:25:02 2016 From: M.vanEs at donders.ru.nl (Es, M.W.J. van (Mats)) Date: Tue, 2 Aug 2016 11:25:02 +0000 Subject: [FieldTrip] sourcestatistics spm_bwlabel issue Message-ID: <3FC79061C73BEF44A3BEDA5DFC0ADBDF4ECD563F@exprd01.hosting.ru.nl> Hi FieldTrippers, After doing DICS source analysis, I get an error with source statistics: Error using spm_bwlabel spm_bwlabel: CONN must be 6, 18 or 26 Error in clusterstat (line 184) [posclusobs, posnum] = spm_bwlabel(tmp, 2*numdims); Error in ft_statistics_montecarlo (line 347) [stat, cfg] = clusterstat(cfg, statrand, statobs); Error in ft_sourcestatistics (line 205) [stat, cfg] = statmethod(cfg, dat, design); Error in source_analysis (line 143) stat = ft_sourcestatistics(cfg, sourceAct, sourceBl); I uploaded the data here (https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0)https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0 and this is the code that I am executing: cfg = []; cfg.method = 'montecarlo'; cfg.statistic = 'ft_statfun_depsamplesT'; cfg.parameter = 'pow'; cfg.correctm = 'cluster'; cfg.clusteralpha = 0.05; % this is the treshold for clustering, not the % statistical test of the cluster cfg.clusterstatistic = 'maxsum'; cfg.numrandomization = 1000; cfg.alpha = 0.05; % note that this only implies single-sided testing cfg.tail = 0; cfg.clustertail = 0; cfg.uvar = 1; % row of design matrix that contains unit variable (in this case: trials) cfg.ivar = 2; % row of design matrix that contains independent variable (the conditions) cfg.dim = [2400 1 1]; design = [1:length(dataAct.trial), 1:length(dataBl.trial); ones(1,length(dataAct.trial)), ones(1,length(dataBl.trial))*2]; cfg.design = design; stat = ft_sourcestatistics(cfg, sourceAct, sourceBl); Any help would be appreciated! Best, Mats -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Thu Aug 4 20:25:38 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Thu, 4 Aug 2016 18:25:38 +0000 Subject: [FieldTrip] Constrain Source solution space Message-ID: Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From RICHARDS at mailbox.sc.edu Fri Aug 5 15:51:34 2016 From: RICHARDS at mailbox.sc.edu (RICHARDS, JOHN) Date: Fri, 5 Aug 2016 13:51:34 +0000 Subject: [FieldTrip] constrain source solution space Message-ID: https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/MediaObjects/10548_2016_505_MOESM3_ESM.docx 1--prepare a grid, for the source volume 2-prepare a head volume 3-prepare electrode (or meg) scalp locations These three elements are used for a lead field. LF and other elements are used w EEG in ft_sourceanalysis. There are several tutorials on FT site to do this. John -----Original Message----- From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of fieldtrip-request at science.ru.nl Sent: Friday, August 5, 2016 6:00 AM To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 69, Issue 4 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. Constrain Source solution space (Nakhnikian, Alexander) ---------------------------------------------------------------------- Message: 1 Date: Thu, 4 Aug 2016 18:25:38 +0000 From: "Nakhnikian, Alexander" To: "fieldtrip at science.ru.nl" Subject: [FieldTrip] Constrain Source solution space Message-ID: Content-Type: text/plain; charset="iso-8859-1" Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 69, Issue 4 **************************************** From Alexander_Nakhnikian at hms.harvard.edu Fri Aug 5 18:07:12 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Fri, 5 Aug 2016 16:07:12 +0000 Subject: [FieldTrip] constrain source solution space In-Reply-To: References: Message-ID: Hi John, Thank you for your feedback. I'm not sure, however, I understand your suggestion. Is the idea to exclude the white matter from the head model? If so, aren't we discarding an important part of the volume conductor model? Furthermore, if I'm correctly interpreting the FAQ page I provided, it should be possible to apply a tissue mask after we've completed the 3 steps you listed since ft_sourceanalysis and ft_prepare_leadfield are both called after we have the grid, head volume, and sensor locations. Thanks, Alexander ________________________________ From: RICHARDS, JOHN Sent: Friday, August 5, 2016 9:51:34 AM To: fieldtrip at science.ru.nl; Nakhnikian, Alexander Subject: constrain source solution space https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/MediaObjects/10548_2016_505_MOESM3_ESM.docx 1--prepare a grid, for the source volume 2-prepare a head volume 3-prepare electrode (or meg) scalp locations These three elements are used for a lead field. LF and other elements are used w EEG in ft_sourceanalysis. There are several tutorials on FT site to do this. John -----Original Message----- From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of fieldtrip-request at science.ru.nl Sent: Friday, August 5, 2016 6:00 AM To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 69, Issue 4 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. Constrain Source solution space (Nakhnikian, Alexander) ---------------------------------------------------------------------- Message: 1 Date: Thu, 4 Aug 2016 18:25:38 +0000 From: "Nakhnikian, Alexander" To: "fieldtrip at science.ru.nl" Subject: [FieldTrip] Constrain Source solution space Message-ID: Content-Type: text/plain; charset="iso-8859-1" Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 69, Issue 4 **************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Fri Aug 5 18:25:34 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Fri, 5 Aug 2016 16:25:34 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol Message-ID: Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich -------------- next part -------------- An HTML attachment was scrubbed... URL: From xiew1202 at gmail.com Fri Aug 5 19:02:07 2016 From: xiew1202 at gmail.com (Xie Wanze) Date: Fri, 5 Aug 2016 13:02:07 -0400 Subject: [FieldTrip] constrain source solution space In-Reply-To: References: Message-ID: Alexander, In John's step 1 (creating the grid, source volume), you exclude the WM because they WM are fibers not neurons, i.e., they are not generating the activity. In step 2 (creating the head model), you don't exclude the WM. Instead, you do segmentation of the head/brain, so WM, GM, and OM(CSF) are separated. So you are not discarding or losing an "important part of the volume conductor model". Wanze 2016-08-05 12:07 GMT-04:00 Nakhnikian, Alexander < Alexander_Nakhnikian at hms.harvard.edu>: > Hi John, > > > Thank you for your feedback. I'm not sure, however, I understand your > suggestion. Is the idea to exclude the white matter from the head model? If > so, aren't we discarding an important part of the volume conductor model? > Furthermore, if I'm correctly interpreting the FAQ page I provided, it > should be possible to apply a tissue mask after we've completed the 3 steps > you listed since ft_sourceanalysis and ft_prepare_leadfield are both called > after we have the grid, head volume, and sensor locations. > > > Thanks, > > > Alexander > ------------------------------ > *From:* RICHARDS, JOHN > *Sent:* Friday, August 5, 2016 9:51:34 AM > *To:* fieldtrip at science.ru.nl; Nakhnikian, Alexander > *Subject:* constrain source solution space > > https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/ > MediaObjects/10548_2016_505_MOESM3_ESM.docx > > 1--prepare a grid, for the source volume > 2-prepare a head volume > 3-prepare electrode (or meg) scalp locations > > These three elements are used for a lead field. > > LF and other elements are used w EEG in ft_sourceanalysis. > > There are several tutorials on FT site to do this. > > John > -----Original Message----- > From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces@ > science.ru.nl ] On Behalf Of > fieldtrip-request at science.ru.nl > Sent: Friday, August 5, 2016 6:00 AM > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 69, Issue 4 > > 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. Constrain Source solution space (Nakhnikian, Alexander) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 4 Aug 2016 18:25:38 +0000 > From: "Nakhnikian, Alexander" > To: "fieldtrip at science.ru.nl" > Subject: [FieldTrip] Constrain Source solution space > Message-ID: > namprd07.prod.outlook.com> > > Content-Type: text/plain; charset="iso-8859-1" > > Hello All, > > > I'm trying to constrain my source space to gray matter and I found > suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox. > org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter > > [http://www.fieldtriptoolbox.org/_media/logo-share.png]< > http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_ > source_reconstruction_to_the_grey_matter> > > faq:can_i_restrict_the_source_reconstruction_to_the_grey ... fieldtriptoolbox.org/faq/can_i_restrict_the_source_ > reconstruction_to_the_grey_matter> > www.fieldtriptoolbox.org > Yes, there are two strategies you can use. You can either make a regular > 3D grid spanning the whole brain in which only grid locations in grey > matter are considered ... > > > > > The problem is that I cannot figure out how to actually do this. For > example, I don't see options in ft_sourceanalysis for inputing segmented > mir with the tissue types of interest, now for giving the program an > anatomic mask. Any feedback would be greatly appreciated. > > > Best, > > > Alexander > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: attachments/20160804/48cc4c8e/attachment-0001.html> > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 69, Issue 4 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From xkshu at outlook.com Sun Aug 7 14:37:29 2016 From: xkshu at outlook.com (shu xiaokang) Date: Sun, 7 Aug 2016 12:37:29 +0000 Subject: [FieldTrip] fieldtrip for Mac Message-ID: Hi, I have met a problem when I was using fieldtrip to plot a topography with my macbook. Detailly, the colors of topographies drawn (using ft_topoplotTFR) with macbook are different from that drawn with windows (as attached figures). Actually, the pictures drawn with macbook are really ugly. Anyone know how to solve the problem? Shu[cid:6982C939-293A-42AA-8724-7439D84214AA][cid:2912BE42-6DE2-41B8-A818-5B88C95A997C] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Mac.png Type: image/png Size: 167415 bytes Desc: Mac.png URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Win.png Type: image/png Size: 333207 bytes Desc: Win.png URL: From tiago.lopes56 at yahoo.com Mon Aug 8 04:39:17 2016 From: tiago.lopes56 at yahoo.com (tiago lopes) Date: Mon, 8 Aug 2016 02:39:17 +0000 (UTC) Subject: [FieldTrip] calculate ERD / ERS References: <2107718987.18605392.1470623957848.JavaMail.yahoo.ref@mail.yahoo.com> Message-ID: <2107718987.18605392.1470623957848.JavaMail.yahoo@mail.yahoo.com> Hi,i am using the toolbox fieldtrip to calculate ERD / ERS in different groups. However, i do not know if I should use a relative or absolute power density in function cfg.baselinetype. I am using the following script, cfg                                 = [ ];cfg.method                     = 'wavelet';cfg.width                        = 7cfg.output                        = 'pow'cfg.foi                           =4:0.2:30;cfg.toi                           = -.68:0.01:1.5;cfg.keeptrials                ='no';cfg.baseline                    =[-0.4 -0.1];cfg.baselinetype            ='relative';         (I do not know if I should use a relative or absolute.)TFRtot                          = ft_freqanalysis(cfg, date)TFRtotal                       = ft_freqbaseline(cfg, TFRtot); Can anyone help me with this problem please? Federal University of Bahia, BrazilProgram in Medicine and Health Att. Tiago Lopes -------------- next part -------------- An HTML attachment was scrubbed... URL: From ayelet.landau at gmail.com Mon Aug 8 09:18:34 2016 From: ayelet.landau at gmail.com (Ayelet Landau) Date: Mon, 8 Aug 2016 10:18:34 +0300 Subject: [FieldTrip] Postdoc/PhD positions - Cognitive Neuroscience @ the Hebrew University of Jersusalem Message-ID: *Post Doc and PhD positions at the Brain Attention and Time Lab, at the Hebrew University of Jerusalem, Israel* Full-time post doc and PhD positions are available in the Brain Attention and Time Lab of Dr. Ayelet N. Landau at the Hebrew University of Jerusalem. Initial appointment will be for one year with the option to renew annually up to 4 years. Preferred starting date: October 2016 The lab’s core research areas include the guidance of attention and temporal processing and their underlying neural mechanisms. As cognitive neuroscientists we try to construe models of cognition and examine them using both in perception and in physiology. The positions are part of two externally funded projects focused on: (1) Fluctuations in attention and rhythmic attentional sampling. (2) Neural mechanisms of interval timing. Both research programs examine the role of brain rhythms in cognition. In the lab, we measure perception in different modalities (tactile, visual and auditory) together with non-invasive physiology (MEG/EEG) and eye-tracking. You can read about the research and the lab here. We are seeking a highly qualified post doc with a doctorate in a relevant field (e.g., Psychology, Neuroscience, and Cognitive Science) and shared interests in the core research areas described above. The researcher, ideally, should have extensive experience with EEG/MEG methodology and neural oscillations measurement. Experience with other techniques - such as fMRI, computational modeling, etc. - is also welcome but not required. In addition, we are looking for strong candidates for a funded PhD studentship. The Hebrew University offers several training opportunities in different departments. The successful candidate will be competitive for one of the flagship programs (psychology, cognitive science or neuroscience) and will have demonstrated experience in research from their post-bac or BA education (as research assistants or honors students). Knowledge of programming is an advantage. For both positions, a passion and a commitment to science, strong social skills, trouble shooting skills and fast learning abilities are a requirement. Interested candidates should send a CV, a brief statement of research interests, and the names and contact details of two academic references to ayelet.landau at huji.ac.il preferably by September 15th. Applications will be considered until the positions are filled. I look forward to hearing from you! Ayelet -- Ayelet N. Landau, PhD *Senior Lecturer* *Department of Psychology & Department of Cognitive SciencesThe Hebrew University of JerusalemJerusalem 91905Israel* -- Ayelet N. Landau, PhD *Senior Lecturer* *Department of Psychology & Department of Cognitive SciencesThe Hebrew University of JerusalemJerusalem 91905Israel* -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Mon Aug 8 11:36:41 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Mon, 08 Aug 2016 11:36:41 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> Message-ID: <10097d8526f9118870bfd95571e9cdd6@inserm.fr> Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: From anna.wieczorek.taraday at gmail.com Mon Aug 8 11:44:19 2016 From: anna.wieczorek.taraday at gmail.com (Anna Wieczorek-Taraday) Date: Mon, 8 Aug 2016 11:44:19 +0200 Subject: [FieldTrip] fieldtrip for Mac In-Reply-To: References: Message-ID: Hi Shu, If I understood correctly, you would you topoplot to be 'blue-yellow-red' instead of being 'blue-green'? If that is the case, you should specify the colormap in configuration structure when drawing figure (probably your default colormap on MacBook is set to 'parula' and the one on Win is 'jet'). try this: cfg.colormap = 'jet' and here you can find some more info about colormaps in Matlab: http://nl.mathworks.com/help/matlab/ref/colormap.html Good luck, Anna 2016-08-07 14:37 GMT+02:00 shu xiaokang : > Hi, > > I have met a problem when I was using fieldtrip to plot a topography with > my macbook. Detailly, the colors of topographies drawn (using > ft_topoplotTFR) with macbook are different from that drawn with windows > (as attached figures). Actually, the pictures drawn with macbook are really > ugly. Anyone know how to solve the problem? > > Shu > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Win.png Type: image/png Size: 333207 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Mac.png Type: image/png Size: 167415 bytes Desc: not available URL: From daniel.haehnke at tum.de Mon Aug 8 11:51:08 2016 From: daniel.haehnke at tum.de (=?utf-8?B?SMOkaG5rZSwgRGFuaWVs?=) Date: Mon, 8 Aug 2016 09:51:08 +0000 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <10097d8526f9118870bfd95571e9cdd6@inserm.fr> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> Message-ID: <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> Dear Laetitia, I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? Best, Daniel -- Daniel Hähnke PhD student Technische Universität München Institute of Neuroscience Translational NeuroCognition Laboratory Biedersteiner Straße 29, Bau 601 80802 Munich Germany Email: daniel.haehnke at tum.de Phone: +49 89 4140 3356 On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From xkshu at outlook.com Mon Aug 8 12:19:56 2016 From: xkshu at outlook.com (shu xiaokang) Date: Mon, 8 Aug 2016 10:19:56 +0000 Subject: [FieldTrip] fieldtrip for Mac In-Reply-To: References: Message-ID: Hi, Anna Thanks very much! It really works to add the code ‘cfg.colormap=‘jet’’, the default colormap on my mac has been set to ‘parula’. Shu 在 2016年8月8日,下午5:44,Anna Wieczorek-Taraday > 写道: Hi Shu, If I understood correctly, you would you topoplot to be 'blue-yellow-red' instead of being 'blue-green'? If that is the case, you should specify the colormap in configuration structure when drawing figure (probably your default colormap on MacBook is set to 'parula' and the one on Win is 'jet'). try this: cfg.colormap = 'jet' and here you can find some more info about colormaps in Matlab: http://nl.mathworks.com/help/matlab/ref/colormap.html Good luck, Anna 2016-08-07 14:37 GMT+02:00 shu xiaokang >: Hi, I have met a problem when I was using fieldtrip to plot a topography with my macbook. Detailly, the colors of topographies drawn (using ft_topoplotTFR) with macbook are different from that drawn with windows (as attached figures). Actually, the pictures drawn with macbook are really ugly. Anyone know how to solve the problem? Shu _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruil3 at student.unimelb.edu.au Tue Aug 9 08:34:18 2016 From: ruil3 at student.unimelb.edu.au (Rui Li) Date: Tue, 9 Aug 2016 16:34:18 +1000 Subject: [FieldTrip] Data Frequency Range for SAM(g2) Message-ID: Dear FieldTrippers, Currently, I am trying to reconstruct the source space using SAM(fg2) from MEG data of epilepsy patients. I read the paper "Kirsch_et_l+2006+Clinical_Neurophysiology+Automated_localization_of_magnetoencephalographic_interictal_spikes_by_adaptive_spatial_filtering" as the reference. However, it is a little confusing that the frequency range used to operate SAM(g2) was 20 - 70Hz. Does anybody have the idea why this frequency range was used? Are there any pieces of literature recommended for this issue? Regards, Rui. -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Tue Aug 9 19:19:32 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Tue, 9 Aug 2016 17:19:32 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol In-Reply-To: References: Message-ID: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Pomper, Ulrich Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Wed Aug 10 11:01:51 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Wed, 10 Aug 2016 11:01:51 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> Message-ID: <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> Hi Daniel, Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : Operation terminated by user during ft_checkdata>fixcsd (line 1072) In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1170) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 416) data = ft_checkdata(data, 'cmbrepresentation', 'full'); Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? Thanks a lot for your help. Best, Laetitia On 08-08-2016 11:51, Hähnke wrote: > Dear Laetitia, > > I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? > > Best, > > Daniel > > -- > Daniel Hähnke > PhD student > > Technische Universität München > Institute of Neuroscience > Translational NeuroCognition Laboratory > Biedersteiner Straße 29, Bau 601 > 80802 Munich > Germany > > Email: daniel.haehnke at tum.de > Phone: +49 89 4140 3356 > >> On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: >> >> Hello fieldtrippers, >> first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! >> >> I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended [1]. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >>> cfg=[]; >>> cfg.method='granger'; >>> granger=ft_connectivityanalysis(cfg, freq); >> to compute the granger causality. >> However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : >> >> Operation terminated by user during ft_checkdata>fixcsd (line 1255) >> >> In ft_checkdata (line 797) >> data = fixcsd(data, cmbrepresentation, channelcmb); >> >> In ft_checkdata>fixcsd (line 1351) >> data = ft_checkdata(data, 'cmbrepresentation', 'full'); >> >> In ft_checkdata (line 797) >> data = fixcsd(data, cmbrepresentation, channelcmb); >> >> In ft_connectivityanalysis (line 392) >> data = ft_checkdata(data, 'cmbrepresentation', 'full'); >> >> I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. >> >> Thanks a lot for your help. >> >> Regards, >> >> Laetitia Lalla >> PhD student in INMED, Marseille, France _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip Links: ------ [1] http://www.fieldtriptoolbox.org/tutorial/connectivityextended -------------- next part -------------- An HTML attachment was scrubbed... URL: From daniel.haehnke at tum.de Wed Aug 10 11:49:46 2016 From: daniel.haehnke at tum.de (=?utf-8?B?SMOkaG5rZSwgRGFuaWVs?=) Date: Wed, 10 Aug 2016 09:49:46 +0000 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> Message-ID: <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> Hi Laetitia, could you provide the code that you used for the calculation of your input structure ‘freq’? When I had a similar looking issue it was because I used a trial-resolved structure, whereas GC calculation seems to require trial-averaged data. Best, Daniel On 10.08.2016, at 11:01, laetitia.lalla at inserm.fr wrote: Hi Daniel, Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : Operation terminated by user during ft_checkdata>fixcsd (line 1072) In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1170) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 416) data = ft_checkdata(data, 'cmbrepresentation', 'full'); Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? Thanks a lot for your help. Best, Laetitia On 08-08-2016 11:51, Hähnke wrote: Dear Laetitia, I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? Best, Daniel -- Daniel Hähnke PhD student Technische Universität München Institute of Neuroscience Translational NeuroCognition Laboratory Biedersteiner Straße 29, Bau 601 80802 Munich Germany Email: daniel.haehnke at tum.de Phone: +49 89 4140 3356 On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Wed Aug 10 12:01:52 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Wed, 10 Aug 2016 10:01:52 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol References: <3D66B259-F956-4001-9AD3-1247F36D5E7C@gmail.com> Message-ID: <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> Dear Bumper, It may be helpful to provide the list with some example code + data, should anybody be keen to look into this. Best, Jan-Mathijs On 09 Aug 2016, at 19:19, Pomper, Ulrich > wrote: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Pomper, Ulrich > Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Wed Aug 10 12:44:06 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Wed, 10 Aug 2016 10:44:06 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol In-Reply-To: <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> References: <3D66B259-F956-4001-9AD3-1247F36D5E7C@gmail.com>, <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> Message-ID: Dear all, Below please find some code which illustrates the issue I'm having. Example data can be found here: https://www.dropbox.com/s/5bgpawph49vkgoo/data_fft_vs_conv.mat?dl=0 The code results in a plot of the PSD, showing how both mtmfft and mtmconvol yield (more or less) similar results, but only after the results from mtmfft are multiplied by 10. Again, I'd be grateful for any clarification on why this might be! Cheers, Ulrich %%%%%%%%%%%%% MTMFFT code %%%%%%%%%%%%%%%%%%%%%%%%% cfg = []; cfg.continuous = 'no'; cfg.channel = {'all', '-VEOG', '-HEOG'} cfg.output = 'pow'; cfg.method = 'mtmfft'; cfg.foi = 1:0.5:30; cfg.taper = 'hanning'; cfg.tapsmofrq = 2 +(0*(cfg.foi)); cfg.keeptapers = 'no'; cfg.keeptrials = 'no'; cfg.pad = 5; freq_fft = ft_freqanalysis(cfg, data); %%%%%%%%%%%%% MTMCONVOL code %%%%%%%%%%%%%%%%%%%%%%%%% taplen = 695; cfg = []; cfg.continuous = 'no'; cfg.channel = {'all', '-VEOG', '-HEOG'} cfg.output = 'pow'; cfg.method = 'mtmconvol'; cfg.foi = 1:0.5:30; cfg.toi = 0.25; cfg.taper = 'hanning'; cfg.tapsmofrq = 2 +(0*(cfg.foi)); cfg.t_ftimwin = ones(length(cfg.foi),1).* (taplen /1000); % cfg.keeptapers = 'no'; cfg.keeptrials = 'no'; cfg.pad = 5; freq_conv = ft_freqanalysis(cfg, data); %%%%%%%%%% plot the two different results for comparison %%%%%%%%%%%%%%%%% CH1_mean_fft = freq_fft.powspctrm(1,:); CH1_mean_conv = freq_conv.powspctrm(1,:); % mtmfft data multiplied by 10, which puts them in a similar order of magnitude as the results from mtmconvol CH1_mean_fft10 = freq_fft.powspctrm(1,:) * 10; figure; plot(CH1_mean_conv); hold on; plot(CH1_mean_fft10); hold on; plot(CH1_mean_fft); ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Schoffelen, J.M. (Jan Mathijs) Sent: 10 August 2016 11:01 To: FieldTrip discussion list Subject: Re: [FieldTrip] mtmfft vs. mtmconvol Dear Bumper, It may be helpful to provide the list with some example code + data, should anybody be keen to look into this. Best, Jan-Mathijs On 09 Aug 2016, at 19:19, Pomper, Ulrich > wrote: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Pomper, Ulrich > Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Wed Aug 10 16:29:09 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Wed, 10 Aug 2016 16:29:09 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> Message-ID: Hello ! Sure, this is the code that I use after the preprocessing : %------------------------------------------------------------------------------- cfg = []; cfg.method = 'mtmconvol'; cfg.output = 'powandcsd'; cfg.channel = data.label; cfg.channelcmb = {'Str' 'Ctx'}; cfg.taper = 'dpss'; cfg.foi = 0.5:100; cfg.tapsmofrq = 1.5*ones(1, length(cfg.foi)); cfg.t_ftimwin = 2*ones(1, length(cfg.foi)); cfg.toi = data.time{1,1}; cfg.keeptrials = 'no'; freq = ft_freqanalysis(cfg, data); % cfg=[]; % cfg.method='coh'; % coh=ft_connectivityanalysis(cfg, freq); cfg=[]; cfg.method='granger'; granger=ft_connectivityanalysis(cfg, freq); %------------------------------------------------------------------------------ I succesfully compute the Time-Frequency Map of the coherence (this was to check), but it won't work for the Granger causality... Thanks a lot for your help ! Best, Laetitia On 10-08-2016 11:49, Hähnke wrote: > Hi Laetitia, > > could you provide the code that you used for the calculation of your input structure 'freq'? > > When I had a similar looking issue it was because I used a trial-resolved structure, whereas GC calculation seems to require trial-averaged data. > > Best, Daniel > > On 10.08.2016, at 11:01, laetitia.lalla at inserm.fr wrote: > > Hi Daniel, > Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : > > Operation terminated by user during ft_checkdata>fixcsd (line 1072) > In ft_checkdata (line 595) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_checkdata>fixcsd (line 1170) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > In ft_checkdata (line 595) > data = fixcsd(data, cmbrepresentation, channelcmb); > In ft_connectivityanalysis (line 416) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? > > Thanks a lot for your help. > > Best, > > Laetitia > > On 08-08-2016 11:51, Hähnke wrote: Dear Laetitia, > > I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? > > Best, > > Daniel > > -- > Daniel Hähnke > PhD student > > Technische Universität München > Institute of Neuroscience > Translational NeuroCognition Laboratory > Biedersteiner Straße 29, Bau 601 > 80802 Munich > Germany > > Email: daniel.haehnke at tum.de > Phone: +49 89 4140 3356 > > On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: > > Hello fieldtrippers, > first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! > > I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended [1]. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >> cfg=[]; >> cfg.method='granger'; >> granger=ft_connectivityanalysis(cfg, freq); > to compute the granger causality. > However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : > > Operation terminated by user during ft_checkdata>fixcsd (line 1255) > > In ft_checkdata (line 797) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_checkdata>fixcsd (line 1351) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > In ft_checkdata (line 797) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_connectivityanalysis (line 392) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. > > Thanks a lot for your help. > > Regards, > > Laetitia Lalla > PhD student in INMED, Marseille, France _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip Links: ------ [1] http://www.fieldtriptoolbox.org/tutorial/connectivityextended -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 17:42:29 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 15:42:29 +0000 Subject: [FieldTrip] reading .mat in fieldtrip Message-ID: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 17:42:30 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 15:42:30 +0000 Subject: [FieldTrip] reformat .mat data - example script Message-ID: Hi Did you solve your problem with reading .mat in field trip? I have the same problem do you have any idea? -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 18:33:03 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 09:33:03 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) : > Hi All, > > > > I have a “.mat” file which contais: <8x10350000 double> and sampling rate. > > How should I import this data to field trip? By using [data] = > ft_preprocessing( cfg); > > I am getting an error that the data should be in the format of raw or > raw + comp. > > > > Any idea? > > > > Thanks! > > > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 18:44:49 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 16:44:49 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 18:59:12 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 09:59:12 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: You could try to make one long trial, and take it from there. Load that matrix stored in your mat file (type 'help load'), and then data.trial{1,1} = matrix; data.time{1,1} = 1:size(matrix,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; .. data.label{8,1} = 'chan 8'; See that page, and/or type 'help ft_datatype_raw'. When your data is in raw format, you can process it with ft_preprocessing (e.g. to filter) or ft_redefinetrial (to create trials). Hope that gets you on your way, Arjen 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) : > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = > ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: > > Hi Bahareh, > > To get you started, see this page: > http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat > > It describes what fieldtrip expects your raw data to look like. > > Arjen > > 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: > >> Hi All, >> >> >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling >> rate. >> >> How should I import this data to field trip? By using [data] = >> ft_preprocessing( cfg); >> >> I am getting an error that the data should be in the format of raw or >> raw + comp. >> >> >> >> Any idea? >> >> >> >> Thanks! >> >> >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 19:15:51 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 17:15:51 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> I tried all these options before. The problem with ft_preprossecing is with cfg.dataset: I gave it my data's file name and path but the error is related to header and it says "unsupported header format"! And to use ft_predefintrial I need to creat Cfg apart of data that I do not have have anything at this time to include in Cfg. Thanks for your help! Bahar On Aug 11, 2016, at 12:00 PM, Arjen Stolk > wrote: You could try to make one long trial, and take it from there. Load that matrix stored in your mat file (type 'help load'), and then data.trial{1,1} = matrix; data.time{1,1} = 1:size(matrix,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; .. data.label{8,1} = 'chan 8'; See that page, and/or type 'help ft_datatype_raw'. When your data is in raw format, you can process it with ft_preprocessing (e.g. to filter) or ft_redefinetrial (to create trials). Hope that gets you on your way, Arjen 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) >: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 19:27:00 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 10:27:00 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> References: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> Message-ID: You will no longer need to specify cfg.dataset once the data is already read into the matlab environment. Try, for instance, cfg = []; cfg.demean = 'yes'; preproc = ft_preprocessing(cfg, data); 2016-08-11 10:15 GMT-07:00 Bahareh Elahian (belahian) : > I tried all these options before. > > The problem with ft_preprossecing is with cfg.dataset: I gave it my data's > file name and path but the error is related to header and it says > "unsupported header format"! > And to use ft_predefintrial I need to creat Cfg apart of data that I do > not have have anything at this time to include in Cfg. > > Thanks for your help! > > Bahar > > > On Aug 11, 2016, at 12:00 PM, Arjen Stolk wrote: > > You could try to make one long trial, and take it from there. Load that > matrix stored in your mat file (type 'help load'), and then > > data.trial{1,1} = matrix; > data.time{1,1} = 1:size(matrix,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > .. > data.label{8,1} = 'chan 8'; > > See that page, and/or type 'help ft_datatype_raw'. When your data is in > raw format, you can process it with ft_preprocessing (e.g. to filter) or > ft_redefinetrial (to create trials). > > Hope that gets you on your way, > Arjen > > > > > 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) >: > >> Thanks for the answer, >> >> I have had a look on this page before and I tried to follow the steps. >> The problem is ;I do not have any cfg to define cfg.trl and use newdata >> = ft_redefinetrial(cfg,data); >> >> Any other idea? >> >> >> >> On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: >> >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) < >> belahian at memphis.edu>: >> >>> Hi All, >>> >>> >>> >>> I have a “.mat” file which contais: <8x10350000 double> and sampling >>> rate. >>> >>> How should I import this data to field trip? By using [data] = >>> ft_preprocessing( cfg); >>> >>> I am getting an error that the data should be in the format of raw or >>> raw + comp. >>> >>> >>> >>> Any idea? >>> >>> >>> >>> Thanks! >>> >>> >>> >>> >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From toni.rbaena at gmail.com Thu Aug 11 20:47:18 2016 From: toni.rbaena at gmail.com (Antonio Rodriguez) Date: Thu, 11 Aug 2016 20:47:18 +0200 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" < belahian at memphis.edu> escribió: > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = > ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: > > Hi Bahareh, > > To get you started, see this page: > http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat > > It describes what fieldtrip expects your raw data to look like. > > Arjen > > 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: > >> Hi All, >> >> >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling >> rate. >> >> How should I import this data to field trip? By using [data] = >> ft_preprocessing( cfg); >> >> I am getting an error that the data should be in the format of raw or >> raw + comp. >> >> >> >> Any idea? >> >> >> >> Thanks! >> >> >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 21:00:52 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 19:00:52 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Antonio Rodriguez Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribi?: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 21:23:30 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 19:23:30 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , , Message-ID: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Bahareh Elahian (belahian) Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Antonio Rodriguez Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribi?: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From K.Vogt at donders.ru.nl Thu Aug 11 23:05:55 2016 From: K.Vogt at donders.ru.nl (Katharina Vogt) Date: Thu, 11 Aug 2016 22:05:55 +0100 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: <9D133336-632C-4227-9076-710E03043F9F@donders.ru.nl> Hi Bahareh, I had the same issue before too. I also created the needed structure and then used ft_redefinetrial. Not optimal, but it did the job!! However, I asked Robert Oostenveld to add my file format and he did. I might have to add that I work at the same Uni as he does and I was able to do it in person. I guess you can at least ask. Best, Katharina > On 11 Aug 2016, at 20:23, Bahareh Elahian (belahian) wrote: > > I did something and it works but it is not correct . > I specified cfg.trl = data.trial{1,1} > > cfg = []; > cfg.bpfilter = 'yes'; > cfg.demean = 'yes'; > data.trial{1,1} = eeg.eeg_data; > cfg.trl = data.trial{1,1}; > data.time{1,1} = 1:size(eeg.eeg_data,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > data.label{3,1} = 'chan 3'; > data.label{4,1} = 'chan 4'; > data.label{5,1} = 'chan 5'; > data.label{6,1} = 'chan 6'; > data.label{7,1} = 'chan 7'; > data.label{8,1} = 'chan 8'; > data.fsample = eeg.samp_rate; > newdata = ft_redefinetrial(cfg,data); > > the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. > > > From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > > Sent: Thursday, August 11, 2016 2:00:52 PM > To: FieldTrip discussion list > Subject: Re: [FieldTrip] reading .mat in fieldtrip > > Thanks but none of the options works. > The error is : > you should specify at least one configuration option. > > Even cfg.demean = 'yes'; is not enough. > > From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > > Sent: Thursday, August 11, 2016 1:47:18 PM > To: FieldTrip discussion list > Subject: Re: [FieldTrip] reading .mat in fieldtrip > > Hi. > You can create an empty cfg structure, and fill with data : > cfg =[]; > newdata = ft_redefinetrial(cfg,data); > > El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: > >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: >> Hi All, >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling rate. >> How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); >> I am getting an error that the data should be in the format of raw or raw + comp. >> >> Any idea? >> >> Thanks! >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 23:25:13 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 14:25:13 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) : > I did something and it works but it is not correct . > > I specified cfg.trl = data.trial{1,1} > > > cfg = []; > cfg.bpfilter = 'yes'; > cfg.demean = 'yes'; > data.trial{1,1} = eeg.eeg_data; > cfg.trl = data.trial{1,1}; > data.time{1,1} = 1:size(eeg.eeg_data,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > data.label{3,1} = 'chan 3'; > data.label{4,1} = 'chan 4'; > data.label{5,1} = 'chan 5'; > data.label{6,1} = 'chan 6'; > data.label{7,1} = 'chan 7'; > data.label{8,1} = 'chan 8'; > data.fsample = eeg.samp_rate; > newdata = ft_redefinetrial(cfg,data); > > the newdata.time and newdata.trial are <1*8 cell > . some of the cells > are empty and one is NAN. > > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > *Sent:* Thursday, August 11, 2016 2:00:52 PM > > *To:* FieldTrip discussion list > *Subject:* Re: [FieldTrip] reading .mat in fieldtrip > > > Thanks but none of the options works. > > The error is : > > you should specify at least one configuration option. > > > Even cfg.demean = 'yes'; is not enough. > > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > *Sent:* Thursday, August 11, 2016 1:47:18 PM > *To:* FieldTrip discussion list > *Subject:* Re: [FieldTrip] reading .mat in fieldtrip > > > Hi. > > You can create an empty cfg structure, and fill with data : > > cfg =[]; > newdata = ft_redefinetrial(cfg,data); > > El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" < > belahian at memphis.edu> escribió: > >> Thanks for the answer, >> >> I have had a look on this page before and I tried to follow the steps. >> The problem is ;I do not have any cfg to define cfg.trl and use newdata >> = ft_redefinetrial(cfg,data); >> >> Any other idea? >> >> >> >> On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: >> >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) < >> belahian at memphis.edu>: >> >>> Hi All, >>> >>> >>> >>> I have a “.mat” file which contais: <8x10350000 double> and sampling >>> rate. >>> >>> How should I import this data to field trip? By using [data] = >>> ft_preprocessing( cfg); >>> >>> I am getting an error that the data should be in the format of raw or >>> raw + comp. >>> >>> >>> >>> Any idea? >>> >>> >>> >>> Thanks! >>> >>> >>> >>> >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 23:32:18 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 21:32:18 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: That was a good point. The problem is I do not want to specify any trial for my configuration. As I mentioned before if I leave cfg =[]; if gives me an error. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Arjen Stolk Sent: Thursday, August 11, 2016 4:25:13 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) >: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a “.mat” file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 23:38:33 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 21:38:33 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks all, The problem is fixed: Here is the answer : cfg = []; cfg.demean = 'yes'; % base correction data.trial{1,1} = eeg.eeg_data; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; [data1] = ft_preprocessing (cfg, data); _____ Bahar ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Arjen Stolk Sent: Thursday, August 11, 2016 4:25 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_redefinetrial – FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type “help ft_redefinetrial”. FT_REDEFINETRIAL allows you to ... [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_redefinetrial – FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type “help ft_redefinetrial”. FT_REDEFINETRIAL allows you to ... cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) >: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a “.mat” file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 12 02:19:48 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 00:19:48 +0000 Subject: [FieldTrip] FEM in FieldTrip Message-ID: Hello, I would like to implement subject-specific FEM head/dipole models in FieldTrip. Searching the FieldTrip site has not given me enough information, and some of the simbio links are broken. Can someone please inform me as to the state of the FEM code in FieldTrip, and where I can find the documentation? I can find the simbio folder with about 25 files, but no documentation. Thanks, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 12 02:52:43 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 00:52:43 +0000 Subject: [FieldTrip] how do embed a dipole model in a FEM head model? Message-ID: Please ignore my previous request for FEM documentation, as I finally found this: http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. Please advise how to create a source model in this case. Thanks, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorw01 at gmail.com Fri Aug 12 03:47:00 2016 From: j.vorw01 at gmail.com (Johannes Vorwerk) Date: Thu, 11 Aug 2016 19:47:00 -0600 Subject: [FieldTrip] how do embed a dipole model in a FEM head model? In-Reply-To: References: Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54@googlemail.com> Hi Jeff, I am not sure if we have the same understanding of a „source model“, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ¨ J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267–278. C. H. Wolters, H. Kostler, C. M ¨ oller, J. H ¨ ardtlein, and A. Anwander ¨ , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189–192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. I hope this helps. Best, Johannes > Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : > > Please ignore my previous request for FEM documentation, as I finally found this: > > http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio > > Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. > > Please advise how to create a source model in this case. > > Thanks, > -Jeff > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From rhancock at email.arizona.edu Fri Aug 12 05:44:04 2016 From: rhancock at email.arizona.edu (Roeland Hancock) Date: Thu, 11 Aug 2016 20:44:04 -0700 Subject: [FieldTrip] Postdoctoral and Research Associate Positions at Haskins Laboratories Message-ID: Please see the below announcements for two research associate positions and one postdoctoral position at Haskins Laboratories — successful applicants for all positions will work on NIH funded projects focused on the neurobiology of reading development and reading disability. *Job Announcement, July 2016: Postdoctoral Fellow* Haskins Laboratories, 300 George Street, Suite 900, New Haven CT 06511 Qualified individuals are invited to apply for a full-time Postdoctoral Fellow position in the Haskins Imaging Lab (http://www.haskins.yale.edu/hil/) at Haskins Laboratories. This position is supported by a new 5-year NIH grant on the cognitive neuroscience of language and reading development in children ages 6-12. Specifically, this project will use Magnetic Resonance Spectroscopy (MRS) alongside fMRI, EEG, and behavioral techniques to understand typical and atypical language development. The successful candidate will report to Project Co-Investigators Dr. Kenneth Pugh and Dr. Fumiko Hoeft, work closely with Director of Neuroimaging Research Dr. Einar Mencl and the Director of EEG research Dr. Nicole Landi, and be responsible for coordination of multimodal imaging, data analysis, journal article reporting, and supervision of Research Associates. The successful candidate will join a team of researchers investigating the neural bases of speech, language and reading using data from fMRI, EEG/ERP, fNIRS, ultrasound, EMG and behavioral data from typical individuals, and individuals with language disorders. This candidate will have the opportunity to work on several projects on this grant, and to collaborate with researchers at Haskins, University of Connecticut and Yale University. *Minimum Qualifications* • Ph.D. in Psychology, Cognitive Science, Neuroscience, Communication Disorders, Linguistics, or related field • Significant research in cognitive neuroscience of language • Excellent interpersonal skills • Excellent verbal and written communication skills *Preferred Qualifications* • Experience with fMRI/sMRI, MRS, EEG data collection and analysis • Experience with experimental presentation software such as E-Prime or PsychoPy • Experience working with children • Data analysis and manipulation skills (e.g., Matlab, R, Python) The initial appointment will be for one year, renewable after the first year. Interested applicants should contact Tammy Ursini, Administrative Coordinator (ursini at haskins.yale.edu) with cover letter, resume, copy of (unofficial) transcripts, and the names of three potential references. Please note “Job Posting 5016”, in the subject line of your email. This position will remain open until filled, with an anticipated start date in fall 2016. Compensation is commensurate with skills and experience. Haskins Laboratories (www.haskins.yale.edu) is a private, non-profit research institute with a primary focus on speech, language, reading, and their biological basis. Haskins has long-standing, formal affiliations with the University of Connecticut and Yale University. Haskins Laboratories is an Equal Opportunity Employer. ------------------------------ *Job Announcement, July 2016: Research Associate (2)* Haskins Laboratories, 300 George Street, Suite 900, New Haven CT 06511 Project Director: Dr. Kenneth Pugh Qualified individuals are invited to apply for two full-time Research Associate positions at Haskins Laboratories. The successful candidates will join a team of researchers investigating the cognitive and neural bases of reading and language development using behavioral and neuroimaging data (fMRI, EEG and NIRS) in typically developing and language impaired children and adolescents. We are accepting applications for two related positions: 1) *Behavioral testing and coordination*. This position will involve hands on collection of behavioral and neuroimaging data, including standardized assessments, with young children and adolescents. Applicants for this position must have experience working with young children. 2) *Neuroimaging analysis and management*. This position will involve both routine data manipulation and organization of neuroimaging data (MRI/fMRI, EEG, fNIRS), as well as assisting with development of new analysis strategies. Specific requirements for this position include strong computing skills (scripting, data management) and data analysis skills. Requirements include: • BA or BS in Psychology, Cognitive Science, Computer Science or related field Additional relevant skills include: • Experience with human research • Experience administering standardized assessments • Experience with neuroimaging • Experience with experimental presentation software packages (e.g., E-PRIME, Presentation, PsychoPy) • Experience with statistical analysis (e.g., SPSS, R, Matlab) • Experience with data management software (e.g., FileMaker, Access, RedCap) Interested applicants should contact Tammy Ursini, Administrative Coordinator (ursini at haskins.yale.edu ) with cover letter, resume, copy of (unofficial) transcripts, and the names of three potential references. Please note “Job Posting 5015”, in the subject line of your email and also indicate which of the two positions you are interested in. These positions will remain open until filled, with an anticipated start date of September, 2016. Compensation is commensurate with skills and experience. Haskins Laboratories (www.haskins.yale.edu) is a private, non-profit research institute with a primary focus on speech, language, reading, and their biological basis. Haskins has long-standing, formal affiliations with the University of Connecticut and Yale University. Haskins Laboratories is an Equal Opportunity Employer. Roeland Hancock, PhD Postdoctoral Researcher Department of Psychiatry UCSF Weill Institute for Neurosciences University of California, San Francisco 401 Parnassus Avenue San Francisco, CA 94143 brainLENS.org -------------- next part -------------- An HTML attachment was scrubbed... URL: From Adham.Elshahabi at med.uni-tuebingen.de Fri Aug 12 10:06:44 2016 From: Adham.Elshahabi at med.uni-tuebingen.de (Adham Elshahabi) Date: Fri, 12 Aug 2016 10:06:44 +0200 Subject: [FieldTrip] =?utf-8?q?Postdoc_Position_in_T=C3=BCbingen=2C_German?= =?utf-8?q?y?= Message-ID: <57AD9FB4020000EF0001D6FA@vslgwd5> Dear Fieldtrip community, please find attached a job offer for 1 Postdoc positon in Tübingen for simultaneous PET/fMRI/EEG in small animals. For mor information, please contact Hans directly: hans.wehrl at med.uni-tuebingen.de Best regards, Adham Elshahabi University Hospital Tübingen MEG Center http://meg.medizin.uni-tuebingen.de -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: PostDoc_PETMREEG_Tuebingen.pdf Type: application/pdf Size: 231850 bytes Desc: Acrobat URL: From brungio at gmail.com Fri Aug 12 13:52:47 2016 From: brungio at gmail.com (Bruno L. Giordano) Date: Fri, 12 Aug 2016 12:52:47 +0100 Subject: [FieldTrip] Optimizing leadfield computation Message-ID: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Hi, I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? Thank you, Bruno -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bruno L. Giordano, PhD Institute of Neuroscience and Psychology 58 Hillhead Street, University of Glasgow Glasgow, G12 8QB, Scotland T +44 (0) 141 330 5484 Www: http://www.brunolgiordano.net Email charter: http://www.emailcharter.org/ From jan.schoffelen at donders.ru.nl Fri Aug 12 14:16:17 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 12:16:17 +0000 Subject: [FieldTrip] Optimizing leadfield computation In-Reply-To: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> References: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Message-ID: Hi Bruno, I don’t know about the low-level details of the computation in meg_forward, but I’d take your word on that it allows for multiple positions simultaneously. With respect to the leadfield calculation as such, we typically recommend to pre-compute them once (and store them for later use), and input a source-model with these pre-computed leadfields in ft_sourceanalysis. This typically works if you keep the signal subspace for which you computed your leadfields consistent with the signal subspace of the sensor-data. We are aware that apart from this FT's beamformer code is relatively slow (even with precomputed leadfields), but at some point in the past we decided to go for code clarity and correctness, rather than to go for computational speed. Doing all computations vectorized will make the code quite opaque (and moreover is not really straightforward if one would like to stay flexible with respect to location specific dimensions of vector leadfields (e.g. regional sources). Given all other steps in typical data processing pipelines, the beamformer step is usually not the time limiting one. Best, Jan-Mathijs > On 12 Aug 2016, at 13:52, Bruno L. Giordano wrote: > > Hi, > > I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). > > It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? > > Thank you, > > Bruno > > > -- > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > Bruno L. Giordano, PhD > Institute of Neuroscience and Psychology > 58 Hillhead Street, University of Glasgow > Glasgow, G12 8QB, Scotland > T +44 (0) 141 330 5484 > Www: http://www.brunolgiordano.net > Email charter: http://www.emailcharter.org/ > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip From brungio at gmail.com Fri Aug 12 15:10:00 2016 From: brungio at gmail.com (Bruno L. Giordano) Date: Fri, 12 Aug 2016 14:10:00 +0100 Subject: [FieldTrip] Optimizing leadfield computation In-Reply-To: References: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Message-ID: <1b80e222-21e2-ef03-9e4b-36481b9b7a74@gmail.com> Hi Jan-Mathijs, thanks. I will check what I can do then. Leadfield computation becomes quite lengthy when one has a large number of blocks for a large number of participants, and would like to have finer than usual grids ;-) And yes, I compute them only once. I understand the philosophy of the development team, it makes perfect sense. Indeed, optimized code can be at times not very transparent. However, the most important aspect of the optimization would simply require replacing loops through the dipoles with mtimesx-based matrix multiplications. If you guys are interested, I can send the functions I have written, so that you can see how they operate. Cheers, Bruno On 12/08/2016 13:16, Schoffelen, J.M. (Jan Mathijs) wrote: > Hi Bruno, > > I don’t know about the low-level details of the computation in meg_forward, but I’d take your word on that it allows for multiple positions simultaneously. > > With respect to the leadfield calculation as such, we typically recommend to pre-compute them once (and store them for later use), and input a source-model with these pre-computed leadfields in ft_sourceanalysis. This typically works if you keep the signal subspace for which you computed your leadfields consistent with the signal subspace of the sensor-data. > > We are aware that apart from this FT's beamformer code is relatively slow (even with precomputed leadfields), but at some point in the past we decided to go for code clarity and correctness, rather than to go for computational speed. Doing all computations vectorized will make the code quite opaque (and moreover is not really straightforward if one would like to stay flexible with respect to location specific dimensions of vector leadfields (e.g. regional sources). Given all other steps in typical data processing pipelines, the beamformer step is usually not the time limiting one. > > Best, > Jan-Mathijs > >> On 12 Aug 2016, at 13:52, Bruno L. Giordano wrote: >> >> Hi, >> >> I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). >> >> It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? >> >> Thank you, >> >> Bruno >> >> >> -- >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> Bruno L. Giordano, PhD >> Institute of Neuroscience and Psychology >> 58 Hillhead Street, University of Glasgow >> Glasgow, G12 8QB, Scotland >> T +44 (0) 141 330 5484 >> Www: http://www.brunolgiordano.net >> Email charter: http://www.emailcharter.org/ >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bruno L. Giordano, PhD Institute of Neuroscience and Psychology 58 Hillhead Street, University of Glasgow Glasgow, G12 8QB, Scotland T +44 (0) 141 330 5484 Www: http://www.brunolgiordano.net Email charter: http://www.emailcharter.org/ From belahian at memphis.edu Fri Aug 12 16:51:32 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 14:51:32 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis Message-ID: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 17:08:20 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 15:08:20 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: Message-ID: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Fri Aug 12 17:15:54 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 15:15:54 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> References: , <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Schoffelen, J.M. (Jan Mathijs) Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 17:59:13 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 15:59:13 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: It is correct as far as the data.fsample is consistent with this (which I suspect it isn’t). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Fri Aug 12 18:09:22 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 16:09:22 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> , Message-ID: Thanks for suggestions. The data.fsample is 30K. I want to see HFOs in time- frequency plot. Wavelet is one solution of that. The error which I am getting is coming from padding and I do not know where should I fix it. What should I do if I do not want any padding? Bahar On Aug 12, 2016, at 11:04 AM, Schoffelen, J.M. (Jan Mathijs) > wrote: It is correct as far as the data.fsample is consistent with this (which I suspect it isn't). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 18:32:42 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 16:32:42 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: If your sampling rate is 30K, then your time axis should be something like (1:size(data.trial{1},1))./data.fsample; rather than 1:some-number On 12 Aug 2016, at 18:09, Bahareh Elahian (belahian) > wrote: Thanks for suggestions. The data.fsample is 30K. I want to see HFOs in time- frequency plot. Wavelet is one solution of that. The error which I am getting is coming from padding and I do not know where should I fix it. What should I do if I do not want any padding? Bahar On Aug 12, 2016, at 11:04 AM, Schoffelen, J.M. (Jan Mathijs) > wrote: It is correct as far as the data.fsample is consistent with this (which I suspect it isn’t). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Sat Aug 13 00:53:09 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 22:53:09 +0000 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 In-Reply-To: References: Message-ID: Johannes, I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. In my naïve view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. Thanks, -Jeff Message: 3 Date: Thu, 11 Aug 2016 19:47:00 -0600 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] how do embed a dipole model in a FEM head model? Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54 at googlemail.com> Content-Type: text/plain; charset="utf-8" Hi Jeff, I am not sure if we have the same understanding of a ?source model?, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ? J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267?278. C. H. Wolters, H. Kostler, C. M ? oller, J. H ? ardtlein, and A. Anwander ? , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189?192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. I hope this helps. Best, Johannes > Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : > > Please ignore my previous request for FEM documentation, as I finally found this: > > http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio > mbio> > > Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. > > Please advise how to create a source model in this case. > > Thanks, > -Jeff > From j.vorw01 at gmail.com Sat Aug 13 01:09:29 2016 From: j.vorw01 at gmail.com (Johannes Vorwerk) Date: Fri, 12 Aug 2016 17:09:29 -0600 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 In-Reply-To: References: Message-ID: <41C233E2-F2D6-46A0-A9F3-0A317F1A82CD@googlemail.com> I see. Your missunderstanding is that the dipoles are „represented“ through hexaedrons (and that you need to implement this ;-)). The idea that is usually used to derive FEM for EEG is to stick to the model of a dipole and to represent this dipole through the FEM basis functions. One method to do this (the „Venant approach“) is already implemented in fieldtrip. The way this representation is achieved is described in the papers I mentioned. If you do not want to use a different approach here, no further work on your side is needed. What you refer to as a „source model“ is what I would call „source space“ (since „source model“ can be easily mixed up…). The source space can be defined just as you would do it for spheres and BEM in fieldtrip. To apply FEM, you have to indicate to fieldtrip to generate a hexahedral head model and „simbio“ as method of forward computation. Best, Johannes > Am 12.08.2016 um 16:53 schrieb K Jeffrey Eriksen : > > Johannes, > > I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. > > In my naïve view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. > > I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. > > Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. > > Thanks, > -Jeff > > Message: 3 > Date: Thu, 11 Aug 2016 19:47:00 -0600 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] how do embed a dipole model in a FEM head > model? > Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Jeff, > > I am not sure if we have the same understanding of a ?source model?, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example > > H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ? J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267?278. > C. H. Wolters, H. Kostler, C. M ? oller, J. H ? ardtlein, and A. Anwander ? , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189?192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. > J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). > > or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. > > I hope this helps. > > Best, > Johannes > >> Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : >> >> Please ignore my previous request for FEM documentation, as I finally found this: >> >> http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio >> > mbio> >> >> Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. >> >> Please advise how to create a source model in this case. >> >> Thanks, >> -Jeff >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip From c.monroy at donders.ru.nl Mon Aug 15 15:34:41 2016 From: c.monroy at donders.ru.nl (Monroy, C.D. (Claire)) Date: Mon, 15 Aug 2016 13:34:41 +0000 Subject: [FieldTrip] ft_singleplotER Message-ID: <88359EE60C7B4649B4765DEE86343C614F106DF3@exprd01.hosting.ru.nl> Hi! Has anyone ever tried to plot shaded error bars around the ERP waveforms when using ft_singleplotER? If so, could someone share with me how they did this? Claire Monroy PhD student Baby Research Center Donders Institute for Brain, Cognition and Behaviour, Centre for Cognition Room B.01.18 Phone: +31 (0) 24 36 55977 Email: c.monroy at donders.ru.nl -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Mon Aug 15 16:18:15 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Mon, 15 Aug 2016 14:18:15 +0000 Subject: [FieldTrip] Odd behavior in DICS Message-ID: Hello All, I'm getting strange results from DICS applied to EEG data. I'm wondering if anyone else has run into these issues and/or can suggest a solution. I don't have individual sMRI so I'm using the standard BEM and MRI that come with FT. I constructed the lead fields as follows. First, I constrain the dipoles of interest to the cortical mantle using the AAL atlas. I then compute the lead fields using ft_prepare_leadfields; I don't have a baseline for these data so the lead fields are normalized. I feed the precomputed lead fields and data into ft_sourceanalysis to find the source-level power for each subject. 1) DICS, but not eLORETA, returns extremely large results at certain voxels. These extrema dominate the grand averages. In each subject, these voxels are always at the edge of the cortex, near the skull. The voxel locations are not exactly the same across subjects, but for any given subject they tend to appear in one of a few locations (i.e. over the right occipital cortex). The lead fields have the same magnitude (following normalization) across all voxels. I did notice, however, that voxels at which extreme values appear tend to have a larger condition number (~12) than voxels at which abnormal values do not appear in any subject (~2). I do not know whether this is relevant but I thought it might have some effect on adaptive but not non-adaptive filters. Since I'm constructing the forward model using FT templates, I thought someone else might have encountered this problem before. 2) As I mentioned above, eLORETA does not return such extreme results; furthermore, when we contrast controls with schizophrenia patients using an independent samples t-test with cluster control for multiple comparisons we find significant differences between groups using eLORETA but not DICS. The raw differences between the grand averages returned by DICS and eLORETA are similar, but when we run stats using DICS most of the correct p values are equal to 1 with one or two in the 0.8-0.9 range. I'm looking for converging evidence between different source analysis methods and it's not clear to me why DICS and eLORETA return such different results. 3) I thought that voxels are which unusually large values occur in controls and patients could be throwing off the stats; however, DICS does not return significant contrasts between control and schizophrenia even when I mask out the extreme voxels. Thanks in advance for any advice. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From dippel.g at gmail.com Mon Aug 15 17:46:30 2016 From: dippel.g at gmail.com (gab dippel) Date: Mon, 15 Aug 2016 17:46:30 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: Dear Fieldtrippers, my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. So the goal is to compute the virtual channels of a certain atlas region let say the SMA. As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) --> So here I construct an MRI based grid 
 load standard_mri.mat cfg = []; cfg.mri = mri; template_grid = ft_prepare_sourcemodel(cfg); this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) --> this is obsolete in my case i guess 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': cfg = []; cfg.grid.xgrid = -90:1:90; cfg.grid.ygrid = -108:1:108; cfg.grid.zgrid = -90:1:90; cfg.grid.unit = 'mm'; cfg.grid.tight = 'yes'; cfg.mri = mri; high_res_grid_mm = ft_prepare_sourcemodel(cfg) 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. I would appreciate any feedback and ideas on this issue. Kind regards, Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From azeez.adebimpe5 at gmail.com Mon Aug 15 17:50:18 2016 From: azeez.adebimpe5 at gmail.com (Azeez Adebimpe) Date: Mon, 15 Aug 2016 11:50:18 -0400 Subject: [FieldTrip] Odd behavior in DICS In-Reply-To: References: Message-ID: Hi Alexander, DICS also works similarly to eLORETA but you need to remove bias after you compute the source. 1. Estimate the noise from the data with cfg.dics.projectnoise='yes'; the default is no, so you need to set it while computing source. 2. Divide the pow by noise estimate Sourcedb=source; Sourcedb.avg.pow=sourcedb.avg.pow./sourcedb.avg.noise; 3. plot the Sourcedb.avg.pow; to see hope it help, Best, Azeez On Mon, Aug 15, 2016 at 10:18 AM, Nakhnikian, Alexander < Alexander_Nakhnikian at hms.harvard.edu> wrote: > Hello All, > > > I'm getting strange results from DICS applied to EEG data. I'm wondering > if anyone else has run into these issues and/or can suggest a solution. > > > I don't have individual sMRI so I'm using the standard BEM and MRI that > come with FT. I constructed the lead fields as follows. First, I constrain > the dipoles of interest to the cortical mantle using the AAL atlas. I then > compute the lead fields using ft_prepare_leadfields; I don't have a > baseline for these data so the lead fields are normalized. I feed the > precomputed lead fields and data into ft_sourceanalysis to find the > source-level power for each subject. > > > 1) DICS, but not eLORETA, returns extremely large results at certain > voxels. These extrema dominate the grand averages. In each subject, these > voxels are always at the edge of the cortex, near the skull. The voxel > locations are not exactly the same across subjects, but for any given > subject they tend to appear in one of a few locations (i.e. over the right > occipital cortex). The lead fields have the same magnitude (following > normalization) across all voxels. I did notice, however, that voxels at > which extreme values appear tend to have a larger condition number (~12) > than voxels at which abnormal values do not appear in any subject (~2). I > do not know whether this is relevant but I thought it might have some > effect on adaptive but not non-adaptive filters. Since I'm constructing the > forward model using FT templates, I thought someone else might have > encountered this problem before. > > > 2) As I mentioned above, eLORETA does not return such extreme results; > furthermore, when we contrast controls with schizophrenia patients using an > independent samples t-test with cluster control for multiple comparisons we > find significant differences between groups using eLORETA but not DICS. The > raw differences between the grand averages returned by DICS and eLORETA are > similar, but when we run stats using DICS most of the correct p values are > equal to 1 with one or two in the 0.8-0.9 range. I'm looking for converging > evidence between different source analysis methods and it's not clear to me > why DICS and eLORETA return such different results. > > > 3) I thought that voxels are which unusually large values occur in > controls and patients could be throwing off the stats; however, DICS does > not return significant contrasts between control and schizophrenia even > when I mask out the extreme voxels. > > > Thanks in advance for any advice. > > > Best, > > > Alexander > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Mon Aug 15 17:56:31 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Mon, 15 Aug 2016 15:56:31 +0000 Subject: [FieldTrip] Voxel Size Message-ID: Hi All, Sorry for putting up two posts in one day but these are different issues so I didn't want to cram them into one thread. How does FT determine the voxel size used in source analysis? Does it come from the resolution of the grid used to generate the lead fields or are there other factors? If the voxel size varies depending on the source localization parameters, does FT store this information? I'd like to be able to report the voxel size used for out analysis. Thank you, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From evergreenlifeyangying at gmail.com Mon Aug 15 21:21:59 2016 From: evergreenlifeyangying at gmail.com (Ying Yang) Date: Mon, 15 Aug 2016 15:21:59 -0400 Subject: [FieldTrip] Stimulus(trigger) as an output channel in the biosemi2ft? Message-ID: Dear FieldTrip Community, My name is Ying Yang and I am a PhD candidate in the Center for the Neural Basis of Cognition, Carnegie Mellon University. I am trying to do real-time EEG acquisition with our Biosemi system. I am used to EEG processing/analysis in python, and would like use the "mne-python" package with the FieldTrip acquisition tool "biosemi2ft". In some initial tests on our Windows 64 bit platform, I ran in cmd biosemi2ft config.txt outputfile - 1972 and used the client object in FieldTrip.py. It seemed to work well. However, it would be really convenient if the recorded data also included the stimulus channel (the trigger channel or "status" channel). I know I can get some info about the trigger events with FieldTrip.Client.getEvents(), but it is more convenient to actually have the trigger channel as one of the channels in the data. >From the limited documentation on http://www.fieldtriptoolbox.org/development/realtime/biosemi, I could not figure out whether it was possible to do so. When I ran "biosemi2ft" on our system, the prompt output said there were 280 channels. So I have customized "config.txt" to select all 280 channels, but none of them seemed to be the trigger channel. So I would like to ask the community if it is possible to record the trigger channel. And if yes, how should I specify it in the "config.txt" file. I will appreciate any input or comment. Thank you. Best, Ying -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Tue Aug 16 00:44:17 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Mon, 15 Aug 2016 22:44:17 +0000 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 14 In-Reply-To: References: Message-ID: Johannes, I understand now, at least about the dipole implementation. The rest should come as I work with FieldTrip some more. Thanks for your help, -Jeff Message: 11 Date: Fri, 12 Aug 2016 17:09:29 -0600 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 Message-ID: <41C233E2-F2D6-46A0-A9F3-0A317F1A82CD at googlemail.com> Content-Type: text/plain; charset=utf-8 I see. Your misunderstanding is that the dipoles are ?represented? through hexahedrons (and that you need to implement this ;-)). The idea that is usually used to derive FEM for EEG is to stick to the model of a dipole and to represent this dipole through the FEM basis functions. One method to do this (the ?Venant approach?) is already implemented in fieldtrip. The way this representation is achieved is described in the papers I mentioned. If you do not want to use a different approach here, no further work on your side is needed. What you refer to as a ?source model? is what I would call ?source space? (since ?source model? can be easily mixed up?). The source space can be defined just as you would do it for spheres and BEM in fieldtrip. To apply FEM, you have to indicate to fieldtrip to generate a hexahedral head model and ?simbio? as method of forward computation. Best, Johannes > Am 12.08.2016 um 16:53 schrieb K Jeffrey Eriksen : > > Johannes, > > I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. > > In my naive view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. > > I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. > > Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. > > Thanks, > -Jeff ************* From eriksenj at ohsu.edu Tue Aug 16 02:05:29 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Tue, 16 Aug 2016 00:05:29 +0000 Subject: [FieldTrip] importing Brainstorm head and source models and leftfields Message-ID: Hi, I am trying to do some forward and inverse simulations using a 3-shell BEM, and would prefer to import my model from Brainstorm where I have already created it. I can find one example of importing the cortical mesh from Brainstorm using ft_read_headshape with the 'matlab' format, but I cannot find anything on how to import the Brainstorm BEM head model or leadfield. Please point me to any further information on this topic, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Tue Aug 16 07:20:06 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Tue, 16 Aug 2016 05:20:06 +0000 Subject: [FieldTrip] importing Brainstorm head and source models and leftfields In-Reply-To: References: Message-ID: Hi Jeff, Probably this is not yet implemented. Since it is all matlab-based it should be pretty straightforward, once you know how the headmodel is represented in the Brainstorm .mat file. Once you have figured this out, it probably takes just a few lines of code in ft_read_headshape. If you have an updated version of this function, you can easily contribute it to the code-base for everyone’s use through git. How this can be done, is shown here: http://www.fieldtriptoolbox.org/development/git Best, Jan-Mathijs On 16 Aug 2016, at 02:05, K Jeffrey Eriksen > wrote: Hi, I am trying to do some forward and inverse simulations using a 3-shell BEM, and would prefer to import my model from Brainstorm where I have already created it. I can find one example of importing the cortical mesh from Brainstorm using ft_read_headshape with the ‘matlab’ format, but I cannot find anything on how to import the Brainstorm BEM head model or leadfield. Please point me to any further information on this topic, -Jeff _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Tue Aug 16 13:44:13 2016 From: julian.keil at gmail.com (Julian Keil) Date: Tue, 16 Aug 2016 13:44:13 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI In-Reply-To: References: Message-ID: <5B3236ED-05F6-41F3-9942-126116A25F9B@gmail.com> Hi Gabriel, have you tried using a grid with the exact same dimensions as the MRI, i.e.: %% Set the start and End of the x,y,z axis vox1 = mri.transform*[mri.dim,1]'; % start vox1 = vox1(1:3)/10; % convert to mm vox2 = mri.transform*[1,1,1,1]'; %end vox2 = vox2(1:3)/10; % convert to mm %% Choose the Minima vox_min = min([vox1,vox2]')'; vox_max = max([vox1,vox2]')'; %% Set the spacing vox_delta = abs(mri.transform*[1,1,1,1]'-mri.transform*[2,2,2,1]'); vox_delta = vox_delta(1:3)/10; % convert to mm RES = vox_delta(1); and then use: cfg.grid.xgrid = vox_min(1):RES:vox_max(1); cfg.grid.ygrid = vox_min(2):RES:vox_max(2); cfg.grid.zgrid = vox_min(3):RES:vox_max(3); Good luck, Julian Am 15.08.2016 um 17:46 schrieb gab dippel: > Dear Fieldtrippers, > > my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. > > So the goal is to compute the virtual channels of a certain atlas region let say the SMA. > As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. > > Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: > 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) > --> So here I construct an MRI based grid > > load standard_mri.mat > cfg = []; > cfg.mri = mri; > template_grid = ft_prepare_sourcemodel(cfg); > > this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. > > 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) > --> this is obsolete in my case i guess > > 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) > --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': > cfg = []; > cfg.grid.xgrid = -90:1:90; > cfg.grid.ygrid = -108:1:108; > cfg.grid.zgrid = -90:1:90; > cfg.grid.unit = 'mm'; > cfg.grid.tight = 'yes'; > cfg.mri = mri; > high_res_grid_mm = ft_prepare_sourcemodel(cfg) > > > 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) > --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. > > 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. > --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. > > I would appreciate any feedback and ideas on this issue. > > Kind regards, > > Gabriel > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From marco.rotonda at gmail.com Wed Aug 17 08:32:29 2016 From: marco.rotonda at gmail.com (Marco Rotonda) Date: Wed, 17 Aug 2016 08:32:29 +0200 Subject: [FieldTrip] FFT and filtering Message-ID: Hi Fieldtrippers, I had a quite simple question, even though I was not so sure how to respond. Let suppose I have an EEG raw signal and I'm interested on the mean amplitude of some bands (delta, theta, etc.). The signal is continuous so I take chunks of data (let say one second). Let suppose the signal is clean (no artifacts). Should I have to filter the signal before doing the FFT or I can just do the FFT of the signal and take the mean of the bands I'm interested on? Take care Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: From Gabriel.Dippel at uniklinikum-dresden.de Mon Aug 15 15:44:06 2016 From: Gabriel.Dippel at uniklinikum-dresden.de (Dippel, Gabriel) Date: Mon, 15 Aug 2016 13:44:06 +0000 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: <5C7F3323D8D9804D90AF6A7ED2611DE362F3D1E9@G06EDBN1.med.tu-dresden.de> Dear Fieldtrippers, my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. So the goal is to compute the virtual channels of a certain atlas region let say the SMA. As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) --> So here I construct an MRI based grid 
 load standard_mri.mat cfg = []; cfg.mri = mri; template_grid = ft_prepare_sourcemodel(cfg); this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) --> this is obsolete in my case i guess 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': cfg = []; cfg.grid.xgrid = -90:1:90; cfg.grid.ygrid = -108:1:108; cfg.grid.zgrid = -90:1:90; cfg.grid.unit = 'mm'; cfg.grid.tight = 'yes'; cfg.mri = mri; high_res_grid_mm = ft_prepare_sourcemodel(cfg) 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. I would appreciate any feedback and ideas on this issue. Kind regards, Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From ankanb06 at gmail.com Wed Aug 17 16:33:29 2016 From: ankanb06 at gmail.com (Ankan Biswas) Date: Wed, 17 Aug 2016 20:03:29 +0530 Subject: [FieldTrip] FFT and filtering In-Reply-To: References: Message-ID: *Hello Marco,* I think depending upon the sampling rate, you have set in the recording equipment, you may have a anti-aliasing filter. And as you don't know what are the frequency components in your signal before doing a fft, you may do a fft on the raw data which will give you the frequency components and then take the mean of the amplitude of the frequencies of the band you are interested in. Please correct *fieldtripers* if I am wrong. Thanks, Ankan On Wed, Aug 17, 2016 at 12:02 PM, Marco Rotonda wrote: > Hi Fieldtrippers, > I had a quite simple question, even though I was not so sure how to > respond. > Let suppose I have an EEG raw signal and I'm interested on the mean > amplitude of some bands (delta, theta, etc.). > The signal is continuous so I take chunks of data (let say one second). > Let suppose the signal is clean (no artifacts). > Should I have to filter the signal before doing the FFT or I can just do > the FFT of the signal and take the mean of the bands I'm interested on? > > Take care > > Marco > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Wed Aug 17 17:11:56 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Wed, 17 Aug 2016 15:11:56 +0000 Subject: [FieldTrip] Wavelet and time-frequency plot Message-ID: Hello All, I am trying to apply wavelet on my signal to see HFOs in time-frequency plot. The sampling rate of my signal is 30K. I will get an error: " Error using fft Out of memory. Type HELP MEMORY for your options. " here is what I wrote according to http://www.fieldtriptoolbox.org/reference/ft_freqanalysis: [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_freqanalysis - FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type "help ft_freqanalysis". FT_FREQANALYSIS performs ... cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; %cfg.channel = 'chan 4'; cfg.toi = (1:size(eeg.eeg_data,2))/Fs; % cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); Do you have any idea? is it realted to my sampling rate? Thanks! Bahar -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Wed Aug 17 17:24:25 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 17 Aug 2016 17:24:25 +0200 Subject: [FieldTrip] valid workaround for nonparametric stats on cortical surface data? Message-ID: Hello Fieldtrip community, ft_statistics_montecarlo fails when it is called through ft_sourcestatistics with cortical surface (as opposed to a 3D volumetric grid) source data. To avoid this limitation, I can change my source level time series avg.mom into a sensor data structure (my electrodes are simply 'virtual' then), provide the source level neighborhood structure, and run ft_timelockstatistics on my 'virtual sensor' data set. As far as I can tell, this effectively gives source level statistics, just through the wrong function, so to speak. Since I am reading that ft_statistics_montecarlo might behave differently depending on which function is calling it.... FT_STATISTICS_MONTECARLO should not be called directly, instead you should call the function that is associated with the type of data on which you want to perform the test. % Use as % stat = ft_timelockstatistics(cfg, data1, data2, data3, ...) % stat = ft_freqstatistics (cfg, data1, data2, data3, ...) % stat = ft_sourcestatistics (cfg, data1, data2, data3, ...) ...I wanted to know whether there are some additional things to be aware of when using ft_timelockstatistics on source level virtual electrode time series. Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From V.Peter at westernsydney.edu.au Thu Aug 18 05:10:11 2016 From: V.Peter at westernsydney.edu.au (Varghese Peter) Date: Thu, 18 Aug 2016 03:10:11 +0000 Subject: [FieldTrip] Issues with trial by trial bad channel rejection Message-ID: <617B8E9395E43D47B7479C8FB3185E755320908C@hall.AD.UWS.EDU.AU> Dear fieldtrip community, I have 128 channel EEG data collected from young infants in an ERP paradigm. Since the EEG data from young infants are noisier than adults, I tried to implement a trial by trial bad channel correction. If a trial has more than 20 bad channels, reject the trial altogether and if the number of bad channels are less than 20, interpolate the bad channels. I have implemented this using the following script. It seems to work, but when I load the file after this step, it takes a long time to load it (up to 20 minutes) and all subsequent processing takes very long time. Is there a way to fix this? Thank you, Varghese indx=1; BadChannelCriterion=100; AllTrialsBadChannelLabels={}; datr={}; TrialNos=[]; for loop =1:length(I09_ADSStd_epochs2.trial), AllTrialsBadchannelIndex = find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion); SingleTrialBadChannelLabels= I09_ADSStd_epochs2.label(AllTrialsBadchannelIndex ); AllTrialsBadChannelLabels= [AllTrialsBadChannelLabels; SingleTrialBadChannelLabels]; if length(find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion))<20, BadchannelIndex = find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion); BadchannelLabels=I09_ADSStd_epochs2.label(BadchannelIndex); cfg = []; cfg.layout= lay; cfg.badchannel = BadchannelLabels; cfg.method = 'spline'; cfg.neighbours = EEG_neighbours; cfg.trials = loop; datr{indx} = ft_channelrepair(cfg,I09_ADSStd_epochs2); TrialNos(indx)=loop; indx=indx+1; end end cfg = []; I09_ADSStd_epochs_clean = ft_appenddata(cfg, datr{:}); -------------- next part -------------- An HTML attachment was scrubbed... URL: From k.kessler at aston.ac.uk Fri Aug 19 12:39:33 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Fri, 19 Aug 2016 10:39:33 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham’s focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Professor Klaus Kessler Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From pooneh.baniasad at gmail.com Sun Aug 21 11:40:43 2016 From: pooneh.baniasad at gmail.com (pooneh baniasad) Date: Sun, 21 Aug 2016 14:10:43 +0430 Subject: [FieldTrip] The compartment nesting cannot be determined Message-ID: Dear FieldTrip community, I'm Pouneh baniasad and I'm working with FieldTrip due to my thesis. I've just read the conversation with this title in the FieldTrip listing mail but it didn't answer completely. I segmented the "Subject01.mri" into four slices as {'gray','csf','skull','scalp'}. After preparing mesh when I wanted to use ft_prepare_headmodel i got this error: "The compartment nesting cannot be determined". Furthermore I use BEM method for calculating. My nesting matrix and numboundries are as follows: numboundaries = 4 nesting = [0, 0, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1; 0, 0, 0, 0] ​I know the nesting matrix is not correct but don't have any idea what should i do. -- Bests Pouneh Baniasad -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Mon Aug 22 17:24:29 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Mon, 22 Aug 2016 15:24:29 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter Message-ID: Dear Fieldtrip Users, I am trying to compute non-parametric granger causality between several ROIs in source-space. I am using the following code to obtain the fourier-spectra of my sensor-level data. cfg = []; cfg.output = 'fourier'; cfg.method = 'mtmfft'; cfg.taper = 'dpss'; cfg.tapsmofrq = 4; cfg.keeptrials = 'yes'; cfg.pad = 1; cfg.padtype = 'zero'; freq = ft_freqanalysis(cfg, data_fix); I was wondering how to project the sensor level fourier-data into source space using the spatial filters computed when calling ft_sourceanalysis? I.e. how to multiply the freq*filter? I am little unsure how the fourierspctrm is represented and how this will feed into ft_connectivity analysis? Many thanks, Robert Seymour (PhD Student, Aston Brain Centre) -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Mon Aug 22 21:50:26 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Mon, 22 Aug 2016 19:50:26 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter In-Reply-To: References: Message-ID: <250771CD-30C7-451D-B7C7-EDE9C622FEEB@donders.ru.nl> Hi Robert, In principle it’s OK, and computationally efficient, to (left)-multiply the spatial filter with the fourier coefficients (in a for-loop across frequencies, or something like that), to get the source-level fourier representation. Practically, you would need to do something like: nchan = numel(freq.label); nfreq = numel(freq.freq); nrpttap = size(freq.fourierspctrm,1); fourier_source = filter*reshape(permute(freq.fourierspctrm,[2 3 1]), [nchan nfreq*nrpttap])); fourier_source = reshape(fourier_source, [nfreq nrpttap]); Now you have a nfreq*nrpttap matrix that represents per tapered data segment the fourierspctrm. From this representation, you would want to create the source pair-wise cross-spectral density that can be subjected to the non-parametric factorization code to compute Granger causality. That is, it’s more or less OK if you know what you’re doing, but can become tricky in terms of correct data administration/bookkeeping. Otherwise, and perhaps more straightforwardly, I’d recommend to do a time-domain source reconstruction (create a set of ‘virtual channels’, there’s are some examples in the wiki’s tutorials how to do it), and then use ft_freqanalysis and ft_connectivityanalysis on the virtual channel data. Best wishes, Jan-Mathijs On 22 Aug 2016, at 17:24, Seymour, Robert (Research Student) > wrote: Dear Fieldtrip Users, I am trying to compute non-parametric granger causality between several ROIs in source-space. I am using the following code to obtain the fourier-spectra of my sensor-level data. cfg = []; cfg.output = 'fourier'; cfg.method = 'mtmfft'; cfg.taper = 'dpss'; cfg.tapsmofrq = 4; cfg.keeptrials = 'yes'; cfg.pad = 1; cfg.padtype = 'zero'; freq = ft_freqanalysis(cfg, data_fix); I was wondering how to project the sensor level fourier-data into source space using the spatial filters computed when calling ft_sourceanalysis? I.e. how to multiply the freq*filter? I am little unsure how the fourierspctrm is represented and how this will feed into ft_connectivity analysis? Many thanks, Robert Seymour (PhD Student, Aston Brain Centre) _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruil3 at student.unimelb.edu.au Tue Aug 23 08:49:57 2016 From: ruil3 at student.unimelb.edu.au (Rui Li) Date: Tue, 23 Aug 2016 16:49:57 +1000 Subject: [FieldTrip] A Problem using cfg.channel = {'MEG'} and ft_preprocessing Message-ID: Dear fieldtrip users, I downloaded the fieldtrip toolbox: fieldtrip-20160820; cfg = []; cfg.dataset = dataset; cfg.channel = {'MEG'}; data = ft_preprocessing(cfg); The 'label' field in data is an empty cell, which leads to the mistakes in the following processing. I am wondering do you found the same problem? Is this a bug? Regards, Rui. -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Tue Aug 23 11:10:35 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Tue, 23 Aug 2016 09:10:35 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter Message-ID: Thanks Jan-Mathijs, I'll try that. I've actually implemented your second suggestion (averaging over virtual electrodes and then calculating fourier/CSD) - do you think there would be any major difference between the two approaches? Cheers, Rob -------------- next part -------------- An HTML attachment was scrubbed... URL: From k.kessler at aston.ac.uk Tue Aug 23 11:59:10 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Tue, 23 Aug 2016 09:59:10 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham's focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Klaus Kessler (Professor of Cognitive Neuroscience) Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From haristz at umn.edu Wed Aug 24 04:05:56 2016 From: haristz at umn.edu (Haris Tzagarakis) Date: Tue, 23 Aug 2016 21:05:56 -0500 Subject: [FieldTrip] cluster statistics on dynamic ROI Message-ID: <57BD0104.1020204@umn.edu> Dear Fieldtripers, I have a question about cluster-based statistics at the source level using an ROI. The option cfg.roi exists in ft_sourceanalysis but requires the use of atlas anatomic labels. My case is slightly different in that I have an ROI defined dymamically by a prior source level analysis and I want to evaluate source level statistics only within the voxels of that ROI for a different parameter. I ended up creating volumes with the appropriate dimensions and setting all the volume array values for the parameter I want to test to NaN except for the voxels of the ROI. I also set up the "inside" field to contain the index values of the ROI voxels only. This seems to work when using cfg.correctm = 'cluster' (which is what I want) but was wondering if anyone can see a potential problem that I might be missing? With Best Wishes Haris -- Charidimos [Haris] Tzagarakis MD, PhD, MRCPsych University of Minnesota Dept of Neuroscience office: Brain Sciences Center Minneapolis VA Medical Center Tel:612-467-1363 From k.kessler at aston.ac.uk Wed Aug 24 15:11:53 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Wed, 24 Aug 2016 13:11:53 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: <52122e491dc744b2ba985d9d8fe45306@EXPRD03.hosting.ru.nl> Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham’s focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Klaus Kessler (Professor of Cognitive Neuroscience) Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From joseluisblues at gmail.com Wed Aug 24 18:04:07 2016 From: joseluisblues at gmail.com (Jose) Date: Wed, 24 Aug 2016 18:04:07 +0200 Subject: [FieldTrip] on spectral analysis of MEG data Message-ID: dear Fieldtrip community, I'm performing analysis of CTF MEG data. I have two conditions of interest: A and B, and I have performed spectral decomposition with the wavelet method to obtain the power (frequencies from 6 to 50 Hz). I have some questions regarding my analysis: 1. As a first approach I wanted to do analysis at the sensor level and then to move at the source level. This is a rather exploratory analysis. I have noted oscillatory activity when analysing ERFs, so I decided to perform spectral analysis but I don't have any a priori hypothesis about any frequency or sensor. I'm using a cluster-based permutation (CBP) test to evaluate significance, but I'm not sure how to do a multi-sensor analysis. Since I have computed the power from frequencies ranging from 6 to 50 Hz, I could perform a CBP test for each frequency, but this would become a multiple comparison problem isn't? Otherwise what I have see in some publications is to average across sensors, and do a permutation test similar to what is done in single-sensor analysis, 2. I have performed spectral analysis of my data for magnetometers and gradiometers. I was wondering if I should expect the same results for both magnetometers and gradiometers. Since the activity of the planar gradient do not cover the same sensors than the magnetometers I wouldn't expect it. However, perhaps the effects should fall within the same frequency boundaries? 3. I was wondering why in the "Within subjects experiments" example of the tutorial "Cluster-based permutation tests on time-frequency data" ( http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) the cfg.alpha is set to 0.025. Since the data are planar gradients, thus positive values, one would need to perform a one-side test, and thus an alpha of 0.05? Maybe in this case the data was baseline corrected and thus one would then have positive and negative values, might that be the case? As a general question, if I'm working with planar gradient data, I should need differentially set my alpha value regarding if is baseline-corrected or not, is that correct? 4. I have seen some publications that include an additional correction to the analysis after performing a permutation test. For instance, Busch et al (J Neurosc 2009) use a resampling test and the FDR method to test significance of differences in power in the Fz channel. The general question is when one can apply only a resampling/permutation test, and when one have to include a correction like FDR? Thanks in advance, Jose -------------- next part -------------- An HTML attachment was scrubbed... URL: From nugenta at mail.nih.gov Wed Aug 24 18:11:00 2016 From: nugenta at mail.nih.gov (Nugent, Allison C. (NIH/NIMH) [E]) Date: Wed, 24 Aug 2016 16:11:00 +0000 Subject: [FieldTrip] NIH MEG Workshop Message-ID: Reminder! A call for abstracts is currently open! We are soliciting abstracts based on the four themes for discussion below, as well as for a general scientific session. Visit http://megworkshop.nih.gov for more details. The abstract deadline has been extended to September 15st. At this meeting, we plan to address the following four themes: 1. What does MEG add to the field of neuroscience above and beyond other existing techniques? 2. How can we support the evolution of MEG acquisition and methods, through both software and hardware? 3. How can we develop and support infrastructure to share data and facilitate big science? 4. How could an MEG-North America consortium work to address these issues? Keynote Speakers: Sylvain Baillet, PhD, Director, MEG Core McGill University, McConnell Brain Imaging Center Dimitrios Pantazis, PhD, Director of MEG Lab, Martinos Imaging Center Timothy P. Roberts, PhD, Vice Chair of Research, Department of Radiology, The Children's Hospital of Philadelphia Julia M. Stephen, PhD, Director, MEG/EEG Core, The Mind Research Network For more details, visit http://megworkshop.nih.gov Registration to this NIH sponsored event is free of charge. We hope to see you in Bethesda in November! Dr. Richard Coppola, Director, NIMH MEG Core Dr. Allison C Nugent, Director of Neuroimaging Research, Experimental Therapeutics and Pathophysiology Branch, NIMH Register Now at Eventbrite! Allison Nugent, PhD Director of Neuroimaging Research Experimental Therapeutics and Pathophysiology Branch NIMH/NIH/DHHS Ph 301-451-8863 -------------- next part -------------- An HTML attachment was scrubbed... URL: From russgport at gmail.com Wed Aug 24 18:45:49 2016 From: russgport at gmail.com (Russell Port) Date: Wed, 24 Aug 2016 12:45:49 -0400 Subject: [FieldTrip] NIH MEG Workshop In-Reply-To: References: Message-ID: Will you pay for me to go to this? Sent from my iPhone > On Aug 24, 2016, at 12:11 PM, Nugent, Allison C. (NIH/NIMH) [E] wrote: > > Reminder! > > A call for abstracts is currently open! We are soliciting abstracts based on the four themes for discussion below, as well as for a general scientific session. Visit http://megworkshop.nih.gov for more details. The abstract deadline has been extended to September 15st. > > At this meeting, we plan to address the following four themes: > > 1. What does MEG add to the field of neuroscience above and beyond other existing techniques? > 2. How can we support the evolution of MEG acquisition and methods, through both software and hardware? > 3. How can we develop and support infrastructure to share data and facilitate big science? > 4. How could an MEG-North America consortium work to address these issues? > > Keynote Speakers: > > Sylvain Baillet, PhD, Director, MEG Core McGill University, McConnell Brain Imaging Center > Dimitrios Pantazis, PhD, Director of MEG Lab, Martinos Imaging Center > Timothy P. Roberts, PhD, Vice Chair of Research, Department of Radiology, The Children’s Hospital of Philadelphia > Julia M. Stephen, PhD, Director, MEG/EEG Core, The Mind Research Network > > For more details, visit http://megworkshop.nih.gov > > Registration to this NIH sponsored event is free of charge. > > We hope to see you in Bethesda in November! > > Dr. Richard Coppola, Director, NIMH MEG Core > Dr. Allison C Nugent, Director of Neuroimaging Research, Experimental Therapeutics and Pathophysiology Branch, NIMH > > Register Now at Eventbrite! > > > Allison Nugent, PhD > Director of Neuroimaging Research > Experimental Therapeutics and Pathophysiology Branch > NIMH/NIH/DHHS > Ph 301-451-8863 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 26 01:49:14 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Thu, 25 Aug 2016 23:49:14 +0000 Subject: [FieldTrip] errors while trying to run beamformer tutorial Message-ID: I am trying to learn how to apply the LCMV beamformer to EEG data. To that end I am starting to go through this tutorial: http://www.fieldtriptoolbox.org/tutorial/beamformer_lcmv?s[]=lcmv I downloaded the data from this link: The ft_definetrial and ft_preprocessing functions require the original MEG dataset, which is available from ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/tutorial/SubjectSEF.zip. Then I tried this code: % find the interesting segments of data cfg = []; cfg.dataset = 'SubjectSEF.ds'; cfg.trialdef.eventtype = 'Blue'; cfg.trialdef.prestim = .1; % .1 sec prior to trigger cfg.trialdef.poststim = .2; % .2 sec following trigger cfg.continuous = 'yes'; cfg = ft_definetrial(cfg); and got this output: Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In dataset2files (line 42) In ft_checkconfig (line 557) In ft_definetrial (line 131) In fieldtrip_test_lcmv (line 13) Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' Error using ft_read_header (line 2248) unsupported header format "unknown" Error in ft_trialfun_general (line 78) hdr = ft_read_header(cfg.headerfile, 'headerformat', cfg.headerformat); Error in ft_definetrial (line 177) [trl, event] = feval(cfg.trialfun, cfg); Error in fieldtrip_test_lcmv (line 13) cfg = ft_definetrial(cfg); So I am totally lost here. Any suggestions? Thanks, -Jeff Eriksen -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 26 07:36:49 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 26 Aug 2016 05:36:49 +0000 Subject: [FieldTrip] errors while trying to run beamformer tutorial In-Reply-To: References: Message-ID: <931E197F-6020-4237-90ED-67E105B06151@donders.ru.nl> Hi Jeff, I assume that you have unzipped the data, and have the data (i.e. the ‘SubjectSEF.ds’) in directoryX. You need to specify the full path to the data in cfg.dataset (or your current working directory should be directoryX), i.e. cfg.dataset = ‘directoryX/SubjectSEF.ds’; Hope this helps, Jan-Mathijs On 26 Aug 2016, at 01:49, K Jeffrey Eriksen > wrote: I am trying to learn how to apply the LCMV beamformer to EEG data. To that end I am starting to go through this tutorial: http://www.fieldtriptoolbox.org/tutorial/beamformer_lcmv?s[]=lcmv I downloaded the data from this link: The ft_definetrial and ft_preprocessing functions require the original MEG dataset, which is available from ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/tutorial/SubjectSEF.zip. Then I tried this code: % find the interesting segments of data cfg = []; cfg.dataset = 'SubjectSEF.ds'; cfg.trialdef.eventtype = 'Blue'; cfg.trialdef.prestim = .1; % .1 sec prior to trigger cfg.trialdef.poststim = .2; % .2 sec following trigger cfg.continuous = 'yes'; cfg = ft_definetrial(cfg); and got this output: Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In dataset2files (line 42) In ft_checkconfig (line 557) In ft_definetrial (line 131) In fieldtrip_test_lcmv (line 13) Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' Error using ft_read_header (line 2248) unsupported header format "unknown" Error in ft_trialfun_general (line 78) hdr = ft_read_header(cfg.headerfile, 'headerformat', cfg.headerformat); Error in ft_definetrial (line 177) [trl, event] = feval(cfg.trialfun, cfg); Error in fieldtrip_test_lcmv (line 13) cfg = ft_definetrial(cfg); So I am totally lost here. Any suggestions? Thanks, -Jeff Eriksen _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From christine.blume at sbg.ac.at Fri Aug 26 15:09:06 2016 From: christine.blume at sbg.ac.at (Blume Christine) Date: Fri, 26 Aug 2016 13:09:06 +0000 Subject: [FieldTrip] ft_clusterplot with 3D clusters from ft_freqstatistics Message-ID: Dear community, Following TF analysis I am using ft_freqstatistics for a cluster-based permutation test. Subsequently, I would like to review significant clusters using ft_clusterplot. That works very well as long as my input to ft_freqstatistics is only 2D (channels x frequencies). However, when I include time, the call to ft_clusterplot results in an error message telling me that either time or frequency needs to be a singleton dimension. Unfortunately, I do not find anything in the FT documentation on this issue. Is there a recommendable way to use ft_clusterplot with 3D clusters, i.e. channel x freq x time clusters? Best, Christine -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 26 23:54:09 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 26 Aug 2016 21:54:09 +0000 Subject: [FieldTrip] Localizing sources using beamformer techniques web tutorial Message-ID: Jan-Mathijs, Your path suggestion got me going, thanks. I then encountered some other errors as I went further along in the tutorial. The one that stopped me was the last listed below, #5. I do not know if I have the folders and files set up right, so have included a screenshot of how they appear on my computer. In particular it seems that SubjectSEF.ds appears to be a folder at some times, and a file at others. -Jeff 1. cfg = ft_definetrial(cfg); -> Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' reading the events from 'E:\Staff\Jeff\Jeff_Matlab\FieldTrip_KJE\data\SubjectSEF\SubjectSEF.ds\SubjectSEF.res4' found 7826 events created 204 trials the call to "ft_definetrial" took 8 seconds 2. cfg.neighbours = ft_prepare_neighbours(cfg, timelock); -> clicking on sensor did NOT show its label 3. timelock_planar = ft_megplanar(cfg, timelock); -> the input is timelock data with 274 channels and 360 timebins Warning: the trial definition in the configuration is inconsistent with the actual data > In ft_warning (line 184) In fixsampleinfo (line 68) In ft_datatype_raw (line 175) In ft_checkdata (line 362) In ft_megplanar (line 98) In fieldtrip_test_lcmv (line 49) Warning: reconstructing sampleinfo by assuming that the trials are consecutive segments of a continuous recording > In ft_warning (line 184) In fixsampleinfo (line 79) In ft_datatype_raw (line 175) In ft_checkdata (line 362) In ft_megplanar (line 98) In fieldtrip_test_lcmv (line 49) the call to "ft_selectdata" took 0 seconds average number of neighbours is 7.35 minimum distance between neighbours is 2.00 cm maximum distance between gradiometers is 4.41 cm Warning: copying input chanunit to montage > In ft_apply_montage (line 120) In ft_megplanar (line 325) In fieldtrip_test_lcmv (line 49) the call to "ft_megplanar" took 2 seconds 4. vol = ft_prepare_headmodel(cfg, seg); -> Warning: please specify cfg.method='projectmesh', 'iso2mesh' or 'isosurface' > In ft_prepare_mesh (line 138) In ft_prepare_headmodel (line 348) In fieldtrip_test_lcmv (line 80) Warning: using 'projectmesh' as default > In ft_prepare_mesh (line 139) In ft_prepare_headmodel (line 348) In fieldtrip_test_lcmv (line 80) triangulating the outer boundary of compartment 1 (brain) with 3000 vertices the call to "ft_prepare_mesh" took 4 seconds the call to "ft_prepare_headmodel" took 4 seconds 5. hdr = ft_read_header('SubjectSEF.ds'); -> Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In ft_read_header (line 159) In fieldtrip_test_lcmv (line 84) Error using ft_read_header (line 2248) unsupported header format "unknown" Error in fieldtrip_test_lcmv (line 84) hdr = ft_read_header('SubjectSEF.ds'); Message: 2 Date: Fri, 26 Aug 2016 05:36:49 +0000 From: "Schoffelen, J.M. (Jan Mathijs)" To: FieldTrip discussion list Subject: Re: [FieldTrip] errors while trying to run beamformer tutorial Message-ID: <931E197F-6020-4237-90ED-67E105B06151 at donders.ru.nl> Content-Type: text/plain; charset="utf-8" Hi Jeff, I assume that you have unzipped the data, and have the data (i.e. the ?SubjectSEF.ds?) in directoryX. You need to specify the full path to the data in cfg.dataset (or your current working directory should be directoryX), i.e. cfg.dataset = ?directoryX/SubjectSEF.ds?; Hope this helps, Jan-Mathijs -------------- next part -------------- A non-text attachment was scrubbed... Name: FT_data_folder.JPG Type: image/jpeg Size: 36806 bytes Desc: FT_data_folder.JPG URL: From dippel.g at gmail.com Mon Aug 29 13:03:50 2016 From: dippel.g at gmail.com (Gabriel Dippel) Date: Mon, 29 Aug 2016 13:03:50 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: Dear Julian, thanks for your help! With some minor changes it finally worked out with the following code: vox1 = mri_cm.transform*[mri_cm.dim,1]'; % start vox1 = vox1(1:3)*10; % convert to mm vox2 = mri_cm.transform*[1,1,1,1]'; %end vox2 = vox2(1:3)*10; % convert to mm % Choose the Minima vox_min = min([vox1,vox2]')'; vox_max = max([vox1,vox2]')'; % Set the spacing vox_delta = abs(mri_cm.transform*[1,1,1,1]'-mri_cm.transform*[2,2,2,1]'); vox_delta = vox_delta(1:3)*10; % convert to mm RES = vox_delta(1); cfg = []; %cfg.inwardshift = -0.5; cfg.grid.xgrid = vox_min(1):RES:vox_max(1)+1; cfg.grid.ygrid = vox_min(2):RES:vox_max(2)+1; cfg.grid.zgrid = vox_min(3):RES:vox_max(3)+1; cfg.grid.tight = 'no'; template_grid_mm = ft_prepare_sourcemodel(cfg, vol_mm); Cheers Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From markus.gschwind at gmail.com Mon Aug 29 16:54:00 2016 From: markus.gschwind at gmail.com (Markus Gschwind) Date: Mon, 29 Aug 2016 16:54:00 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? Message-ID: Dear EEGers, We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). We came across the Zebris system http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php Is there anyone who has experience with this? Thank you in advance, Best, Markus -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Mon Aug 29 17:02:47 2016 From: julian.keil at gmail.com (Julian Keil) Date: Mon, 29 Aug 2016 17:02:47 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: Message-ID: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Dear Markus, we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. I'd say it takes no more than 10 minutes per subject. Let me know if you need more info, Julian Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > Dear EEGers, > > We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). > > We came across the Zebris system > http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php > > Is there anyone who has experience with this? > > Thank you in advance, > Best, > Markus > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From markus.gschwind at gmail.com Mon Aug 29 21:57:21 2016 From: markus.gschwind at gmail.com (Markus Gschwind) Date: Mon, 29 Aug 2016 21:57:21 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: Hi Julain, Thanks for that input. With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? Thanks in advance! Best, Markus 2016-08-29 17:02 GMT+02:00 Julian Keil : > Dear Markus, > > we use the Polhemus Patriot together with the BrainStrom toolbox for our > 128-channel EEG caps. > Once you get it set up and all quirks worked out (e.g. using a > serial-to-USB converter instead of just the USB-connection), it works quite > fast and without problems. > I'd say it takes no more than 10 minutes per subject. > > Let me know if you need more info, > > Julian > > Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > > Dear EEGers, > > We would like to get in contact with people having experience with > electrode positioning systems,which can be used in a reasonable amount of > time (especially with patients), and on high-density caps (we use EGI 256 > channels). > > We came across the Zebris system > http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php > > Is there anyone who has experience with this? > > Thank you in advance, > Best, > Markus > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorn at artinis.com Tue Aug 30 09:02:09 2016 From: jorn at artinis.com (=?utf-8?Q?J=C3=B6rn_M._Horschig?=) Date: Tue, 30 Aug 2016 09:02:09 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: <004901d2028c$6d3c96d0$47b5c470$@artinis.com> Hi Markus, The fastest digitization method I saw up to date is this one: http://www.brainproducts.com/productdetails.php?id=60 - I hope no one from my company sees this mail ;) However it only works with the BrainProducts Acticap and is quite pricy. Commercially, there are two types of product available. One type are devices similar to Zebris, that would be e.g. xensor from ANT, EEG Pinpoint from Localite and BrainProduct should also have one. They are usually in the price range of around 15k€ and imho a big overkill if you are just interested in localizing the electrodes. They all work with using an (infrared) camera to track the position of a pin pointing device. Their actual use for realtime neuronavigation with TMS, but they can be utilized also for stationary, one-time tracking of electrode positions. A cheaper option are the Polhemus devices, where the Patriot is the cheapest one (but still with a relatively good accuracy) of 1.5mm RMS at a sampling rate of 60Hz (yes, we also sell these with our devices, that’s why I know). Polhemus works with creating an electromagnetic field and measuring the position of a sensor within this field. The disadvantage with the Polhemus devices is that there is no proprietary software for electrode digitization. We built our own integration in our software, which is possible because Polhemus makes an SDK available (but we are a NIRS company, so no option for you). There are also some Matlab codes flying around the world wide web for EEG digitization. All in all, they are however not extremely user friendly and/or stable (imho, but I might have high standards). Despite the differences in the technique (camera vs. electromagnetic field), price and software, both require the same amount of manual labour: ticking each electrode manually and continuing to the next one. Only the BrainProducts solution mentioned above works differently. There are several other ideas and papers out there, but nothing that is commercially available in a package. Btw, I just googled, EGI has a similar system as ANT, Localite and Brain Products: https://www.egi.com/clinical-division/clinical-division-clinical-products/ges-400-series I have no experience with this and never saw it in action. But, all companies should be willing to come over to give you a demo of their device (we would, but again, wrong modality). So, just drop them a mail stating your problem (and available budget!) and they will contact you and most likely suggest a demo (otherwise, ask them). I hope this helps! Best, Jörn -- Jörn M. Horschig, PhD, Software Engineer & Project Leader NeuroGuard XS Artinis Medical Systems | +31 481 350 980 From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Markus Gschwind Sent: Monday, August 29, 2016 21:57 To: FieldTrip discussion list Subject: Re: [FieldTrip] Best EEG electrode positioning system? Hi Julain, Thanks for that input. With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? Thanks in advance! Best, Markus 2016-08-29 17:02 GMT+02:00 Julian Keil >: Dear Markus, we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. I'd say it takes no more than 10 minutes per subject. Let me know if you need more info, Julian Am 29.08.2016 um 16:54 schrieb Markus Gschwind: Dear EEGers, We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). We came across the Zebris system http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php Is there anyone who has experience with this? Thank you in advance, Best, Markus _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Tue Aug 30 11:26:58 2016 From: julian.keil at gmail.com (Julian Keil) Date: Tue, 30 Aug 2016 11:26:58 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: Hi Markus, in our setup, we mount the source on a tripod that is positioned behind the subject. We then attach the reference sensor to the forehead (this corrects for movements of the subject) and mark the single electrodes with the stylus. Thus, the head of the subject does not need to be fixed, as long as the source is not moved. I'm not sure what is included in the 2800 $ but here's what we use: * Polhemus Patriot * 1x Stylus (Sensor 1) * 1x Reference (Sensor 2) * 1x Source * Serial Cable Additionally we use: * Serial-to-USB Converter * BrainStorm Toolbox for Matlab (Free after registration from: http://neuroimage.usc.edu/brainstorm/) The Polhemus Software (I think it's included) can be useful for basic troubleshooting, such as checking if there is a connection to the PC, but is not needed otherwise. Cheers, Julian Am 29.08.2016 um 21:57 schrieb Markus Gschwind: > Hi Julain, > > Thanks for that input. > > With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? > > On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? > > Thanks in advance! > Best, Markus > > > > > > 2016-08-29 17:02 GMT+02:00 Julian Keil : > Dear Markus, > > we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. > Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. > I'd say it takes no more than 10 minutes per subject. > > Let me know if you need more info, > > Julian > > Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > >> Dear EEGers, >> >> We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). >> >> We came across the Zebris system >> http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php >> >> Is there anyone who has experience with this? >> >> Thank you in advance, >> Best, >> Markus >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From andrejakosticln at gmail.com Tue Aug 30 13:37:34 2016 From: andrejakosticln at gmail.com (=?UTF-8?Q?Andreja_Kosti=C4=87?=) Date: Tue, 30 Aug 2016 13:37:34 +0200 Subject: [FieldTrip] Which units are used for the "dippos" argument in ft_compute_leadfield and friends? Message-ID: Hello everyone! Background: I'm using ft_dipolesimulation to generate a simulated EEG from dipoles in specific locations inside of a brain. I'm using a BEM volume conduction model made with dipoli. Since I want specific locations inside of the brain, I need a way to specify where they actually are. Problem: Going through the ft_dipolesimulation, I was unable to find an explanation about which units I'm supposed to use. I do see that the position argument is passed on to ft_compute_leadfield. Going through the ft_compute_leadfield, I see that, in my specific case, the position will be passed onto eeg_leadfieldb, which then passes it on to inf_medium_leadfield which does the actual calculation. However, when I was reading inf_medium_leadfield, I couldn't figure out which units are being used there. Since ft_compute_leadfield seems to be commonly used function, I was wondering if anyone could tell me which measurement units are used for the dippos argument in it. All the best, Andreja Kostić -------------- next part -------------- An HTML attachment was scrubbed... URL: From marco.rotonda at gmail.com Wed Aug 31 22:35:45 2016 From: marco.rotonda at gmail.com (Marco Rotonda) Date: Wed, 31 Aug 2016 22:35:45 +0200 Subject: [FieldTrip] Strange plots with ft_clusterplot Message-ID: Hi there, I'm trying to plot some data but I have some strange behaviour not from ft_clusterplot, but from ft_topoplotTFR. I ran the code on matlab 2015b and 2016a, fiedtrip version of 30/08 and 01/06 I mean it seems that the configuration options of ft_clusterplot are taken fine, while the options of ft_topoplotTFR (like the colormap!) is not. Seems like a problem of Axes. I've exaggerated a bit the configuration to have a better idea. Here is the code: cfg = []; cfg.alpha = 0.05; cfg.parameter = 'stat'; % cfg.interactive = 'yes'; cfg.highlightcolorpos =[255 255 255]; cfg.layout = 'easycapM11.mat'; % cfg.maskparameter = 1; cfg.colorbar = 'yes'; cfg.zlim = [-9 18]; cfg.shading = 'interp'; cfg.gridscale = 300; cfg.contournum = 10; cfg.colormap = gray(10); cfg.markersymbol = '.'; cfg.markersize = 12; cfg.markercolor = [0 0.69 0.94]; cfg.subplotsize = [1 1]; cfg.marker = 'on'; cfg.highlight = 'on'; ft_clusterplot(cfg, statdelta); Here the console log: >> plot_cluster the input is freq data with 30 channels, 1 frequencybins and no timebins Warning: The field cfg.highlight is forbidden, it will be removed from your configuration > In ft_checkconfig (line 208) In ft_clusterplot (line 82) In plot_cluster (line 20) reading layout from file easycapM11.mat the call to "ft_prepare_layout" took 0 seconds There are 6 clusters smaller than alpha (0.05) Negative cluster: 1, pvalue: 0.00019996 (*), f = 2.4414 to 2.4414 Negative cluster: 2, pvalue: 0.00079984 (*), f = 2.4414 to 2.4414 Negative cluster: 3, pvalue: 0.0091982 (*), f = 2.4414 to 2.4414 Negative cluster: 4, pvalue: 0.015797 (x), f = 2.4414 to 2.4414 Negative cluster: 5, pvalue: 0.017596 (x), f = 2.4414 to 2.4414 Negative cluster: 6, pvalue: 0.04819 (x), f = 2.4414 to 2.4414 making subplot 1 from 1 the call to "ft_clusterplot" took 2 seconds >> Here the result: [image: Immagine incorporata 1] Any Idea? Thanks in advance Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 1.png Type: image/png Size: 69210 bytes Desc: not available URL: From pooneh.baniasad at gmail.com Mon Aug 1 10:17:08 2016 From: pooneh.baniasad at gmail.com (pooneh baniasad) Date: Mon, 1 Aug 2016 12:47:08 +0430 Subject: [FieldTrip] Generating EEG & Source model function Message-ID: Dear FieldTrip community, ​ ​I'm trying to generate EEG signal without using raw datas. I used the 'Subject01.mri' as my anatomical model, the BEM method for preparing a headmodel and 'standard_1020.elc' for aligning electrodes. For a source model I loaded template grid (cortex_20484.surf.gii). Now my questions are how can I set dipole's location (in other words, my grid's resolution)? How can I allocate a source model (sin, cos, ...) to each dipole? Is there any function in Fieldtrip doing that? or I have to writing the code by myself. After having the source model for each dipole and calculating leadfield matrix what should I do for plotting the EEG signal? -- Bests Pouneh Baniasad -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrejakosticln at gmail.com Mon Aug 1 15:41:17 2016 From: andrejakosticln at gmail.com (=?UTF-8?Q?Andreja_Kosti=C4=87?=) Date: Mon, 1 Aug 2016 15:41:17 +0200 Subject: [FieldTrip] Generating EEG & Source model function In-Reply-To: References: Message-ID: Hello Pouneh Baniasad, I had a similar issue some time ago, and found my solution within Fieldtrip, so I might be able to offer a bit of advice. There is a function for in Fieldtrip that will (partially) allow you to simulate dipoles. It's called ft_dipolesimulation.m. Unfortunately, in its current state, it only allows you to simulate 1 dipole. It does have quite a bit potential, however, since the function seems to be originally intended to work with multiple dipoles, but in its current implementation, it will not actually cycle through multiple dipoles and will crash if you give it more than 1. The function will allow you to set frequency, phase, amplitude, sample rate, orientation vector etc. for the dipoles but I didn't test how that works for more than one dipole, since I used externally generated data as my dipole waveforms. With only a couple of extra lines of code (basically just 1 extra for loop around the part that does lead-field calculation), it can be edited to go through a matrix of dipole coordinates and orientations. I'm currently on vacation, so it might take some time for me to dig up modifications I did for it to go through multiple dipoles, but it it took me maybe 10 minutes to fix in total, so it's really easy. I think that the coordinates that you need to give for each dipole are voxel positions from the MRI. There's also a bug near the end of the function, at the place where ft_senstype is called. It will set to MEG in both cases, so that needs fixing as well. Later on, when you get the EEG, you can plot it like this, for example: %View the EEG cfg=[]; cfg.viewmode='vertical'; ft_databrowser(cfg,data_from_ft_dipolesimulation); All the best, Andreja Kostić 2016-08-01 10:17 GMT+02:00 pooneh baniasad : > Dear FieldTrip community, > ​ > ​I'm trying to generate EEG signal without using raw datas. > I used the 'Subject01.mri' as my anatomical model, the BEM method for > preparing a headmodel and 'standard_1020.elc' for aligning electrodes. > For a source model I loaded template grid (cortex_20484.surf.gii). > Now my questions are how can I set dipole's location (in other words, my > grid's resolution)? > How can I allocate a source model (sin, cos, ...) to each dipole? Is there > any function in Fieldtrip doing that? or I have to writing the code by > myself. > After having the source model for each dipole and calculating leadfield > matrix what should I do for plotting the EEG signal? > > > -- > Bests > > Pouneh Baniasad > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From tmadsen at emory.edu Mon Aug 1 17:03:40 2016 From: tmadsen at emory.edu (Teresa Madsen) Date: Mon, 1 Aug 2016 11:03:40 -0400 Subject: [FieldTrip] queries_related to_error In-Reply-To: References: Message-ID: Maybe you accidentally deleted the "utilities" folder? I would try updating to the latest version of FieldTrip. On Sun, Jul 31, 2016 at 6:22 AM, Laxmi Shaw wrote: > Dear Fieldtrip users, > > Suddenly i got one error while compiling any fieldtrip function based > code.Please need your help to remove this error. I have attach the screen > shot of that matlab program. > [image: Inline image 1] > Your helps always been appreciated. > > > Regards > -- > Laxmi Shaw > Research Scholar(PhD) > IIT Kharagpur > West Bengal > Ph no-08388837821 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- Teresa E. Madsen, PhD Division of Behavioral Neuroscience and Psychiatric Disorders Yerkes National Primate Research Center Emory University Rainnie Lab, NSB 5233 954 Gatewood Rd. NE Atlanta, GA 30329 (770) 296-9119 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 103003 bytes Desc: not available URL: From roycox.roycox at gmail.com Mon Aug 1 17:33:59 2016 From: roycox.roycox at gmail.com (Roy Cox) Date: Mon, 1 Aug 2016 11:33:59 -0400 Subject: [FieldTrip] Fwd: postdoc and research assistant position available in Center for Sleep and Cognition In-Reply-To: References: Message-ID: hello all, A postdoc position and RA position are now available in the Center for Sleep and Cognition (PI: Robert Stickgold). Feel free to forward these ads to anyone that may be interested. Best, Roy Cox ------------------------------------------------ *Postdoctoral position in Stickgold lab* Applications are invited for a full-time postdoctoral position at the Center for Sleep and Cognition (sleepandcognition.org ), PI Robert Stickgold, The position is for two years, with possible extension contingent on funding. The lab is at Beth Israel Deaconess Medical Center / Harvard Medical School, in Boston. Research in the lab is focused on the role of sleep in memory consolidation, with current projects investigating emotional memory, memory integration, the algorithms of memory prioritization/selection for consolidation, and the mechanistic role of neural oscillations in these processes. Approaches include targeted memory reactivation, time-frequency analyses of learning- and sleep-associated oscillatory activity, and computational modeling. The lab is also interested in deficits in these processes associated with sleep disorders as well as a range of psychiatric and neurological disorders. A current study, in collaboration with Dara Manoach and Matcheri Keshavan, investigates memory consolidation deficits in patients with schizophrenia. Facilities include two fully equipped sleep rooms for measuring high-density EEG/PSG and several units for behavioral testing. Access to several clinical populations is possible. A PhD in psychology or neuroscience (or a related discipline) and a strong research background are required. The following are beneficial: experience with EEG measurements/analyses, experience running behavioral experiments, programming skills, and strong statistical and quantitative skills. Please send your CV and a brief statement of research interest to Elaine Parr: mparr at bidmc.harvard.edu. Applications will be reviewed until the position is filled. Start date is flexible. *Research assistant position in Stickgold lab* The Center for Sleep and Cognition at Beth Israel Deaconess Medical Center is seeking a college graduate with strong organizational and interpersonal skills as a full time research assistant for projects investigating sleep and memory consolidation. If hired, you will be responsible for screening subjects for participation in experimental studies, enrolling subjects into these studies, administering cognitive tests, and recording the overnight sleep of subjects. This includes actively monitoring subjects’ sleep in the sleep laboratory. You will be expected to work closely with the Principal Investigator, lab mates, and collaborators on all aspects of the project. Training in recording sleep EEGs, behavioral test administration, and data analysis will be provided. Administrative duties will include helping to maintain accurate records, and assist with grant applications, human subject applications, and publications. Some computer programming experience is an asset, as is a high level of comfort with novel computer applications and environments. A bachelor’s degree and prior research experience are required. A background in psychology, statistics, and neuroscience, as well as a prior mentored research project would be preferred. You must be mature and responsible, with excellent oral and written communication skills. You must be able to work independently in a fast-paced environment, juggle and prioritize multiple tasks, feel comfortable working with clinical and non-clinical study populations, and seek assistance when appropriate. This is an excellent research opportunity for someone bound for graduate school in psychology, cognitive neuroscience, or medicine. Position is available immediately. A two-year commitment is required. Please send a resume, (unofficial) transcript, writing sample, and contact information for three references to Elaine Parr: mparr at bidmc.harvard.edu. -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.vanEs at donders.ru.nl Tue Aug 2 13:25:02 2016 From: M.vanEs at donders.ru.nl (Es, M.W.J. van (Mats)) Date: Tue, 2 Aug 2016 11:25:02 +0000 Subject: [FieldTrip] sourcestatistics spm_bwlabel issue Message-ID: <3FC79061C73BEF44A3BEDA5DFC0ADBDF4ECD563F@exprd01.hosting.ru.nl> Hi FieldTrippers, After doing DICS source analysis, I get an error with source statistics: Error using spm_bwlabel spm_bwlabel: CONN must be 6, 18 or 26 Error in clusterstat (line 184) [posclusobs, posnum] = spm_bwlabel(tmp, 2*numdims); Error in ft_statistics_montecarlo (line 347) [stat, cfg] = clusterstat(cfg, statrand, statobs); Error in ft_sourcestatistics (line 205) [stat, cfg] = statmethod(cfg, dat, design); Error in source_analysis (line 143) stat = ft_sourcestatistics(cfg, sourceAct, sourceBl); I uploaded the data here (https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0)https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0 and this is the code that I am executing: cfg = []; cfg.method = 'montecarlo'; cfg.statistic = 'ft_statfun_depsamplesT'; cfg.parameter = 'pow'; cfg.correctm = 'cluster'; cfg.clusteralpha = 0.05; % this is the treshold for clustering, not the % statistical test of the cluster cfg.clusterstatistic = 'maxsum'; cfg.numrandomization = 1000; cfg.alpha = 0.05; % note that this only implies single-sided testing cfg.tail = 0; cfg.clustertail = 0; cfg.uvar = 1; % row of design matrix that contains unit variable (in this case: trials) cfg.ivar = 2; % row of design matrix that contains independent variable (the conditions) cfg.dim = [2400 1 1]; design = [1:length(dataAct.trial), 1:length(dataBl.trial); ones(1,length(dataAct.trial)), ones(1,length(dataBl.trial))*2]; cfg.design = design; stat = ft_sourcestatistics(cfg, sourceAct, sourceBl); Any help would be appreciated! Best, Mats -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Thu Aug 4 20:25:38 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Thu, 4 Aug 2016 18:25:38 +0000 Subject: [FieldTrip] Constrain Source solution space Message-ID: Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From RICHARDS at mailbox.sc.edu Fri Aug 5 15:51:34 2016 From: RICHARDS at mailbox.sc.edu (RICHARDS, JOHN) Date: Fri, 5 Aug 2016 13:51:34 +0000 Subject: [FieldTrip] constrain source solution space Message-ID: https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/MediaObjects/10548_2016_505_MOESM3_ESM.docx 1--prepare a grid, for the source volume 2-prepare a head volume 3-prepare electrode (or meg) scalp locations These three elements are used for a lead field. LF and other elements are used w EEG in ft_sourceanalysis. There are several tutorials on FT site to do this. John -----Original Message----- From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of fieldtrip-request at science.ru.nl Sent: Friday, August 5, 2016 6:00 AM To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 69, Issue 4 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. Constrain Source solution space (Nakhnikian, Alexander) ---------------------------------------------------------------------- Message: 1 Date: Thu, 4 Aug 2016 18:25:38 +0000 From: "Nakhnikian, Alexander" To: "fieldtrip at science.ru.nl" Subject: [FieldTrip] Constrain Source solution space Message-ID: Content-Type: text/plain; charset="iso-8859-1" Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 69, Issue 4 **************************************** From Alexander_Nakhnikian at hms.harvard.edu Fri Aug 5 18:07:12 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Fri, 5 Aug 2016 16:07:12 +0000 Subject: [FieldTrip] constrain source solution space In-Reply-To: References: Message-ID: Hi John, Thank you for your feedback. I'm not sure, however, I understand your suggestion. Is the idea to exclude the white matter from the head model? If so, aren't we discarding an important part of the volume conductor model? Furthermore, if I'm correctly interpreting the FAQ page I provided, it should be possible to apply a tissue mask after we've completed the 3 steps you listed since ft_sourceanalysis and ft_prepare_leadfield are both called after we have the grid, head volume, and sensor locations. Thanks, Alexander ________________________________ From: RICHARDS, JOHN Sent: Friday, August 5, 2016 9:51:34 AM To: fieldtrip at science.ru.nl; Nakhnikian, Alexander Subject: constrain source solution space https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/MediaObjects/10548_2016_505_MOESM3_ESM.docx 1--prepare a grid, for the source volume 2-prepare a head volume 3-prepare electrode (or meg) scalp locations These three elements are used for a lead field. LF and other elements are used w EEG in ft_sourceanalysis. There are several tutorials on FT site to do this. John -----Original Message----- From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of fieldtrip-request at science.ru.nl Sent: Friday, August 5, 2016 6:00 AM To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 69, Issue 4 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. Constrain Source solution space (Nakhnikian, Alexander) ---------------------------------------------------------------------- Message: 1 Date: Thu, 4 Aug 2016 18:25:38 +0000 From: "Nakhnikian, Alexander" To: "fieldtrip at science.ru.nl" Subject: [FieldTrip] Constrain Source solution space Message-ID: Content-Type: text/plain; charset="iso-8859-1" Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 69, Issue 4 **************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Fri Aug 5 18:25:34 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Fri, 5 Aug 2016 16:25:34 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol Message-ID: Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich -------------- next part -------------- An HTML attachment was scrubbed... URL: From xiew1202 at gmail.com Fri Aug 5 19:02:07 2016 From: xiew1202 at gmail.com (Xie Wanze) Date: Fri, 5 Aug 2016 13:02:07 -0400 Subject: [FieldTrip] constrain source solution space In-Reply-To: References: Message-ID: Alexander, In John's step 1 (creating the grid, source volume), you exclude the WM because they WM are fibers not neurons, i.e., they are not generating the activity. In step 2 (creating the head model), you don't exclude the WM. Instead, you do segmentation of the head/brain, so WM, GM, and OM(CSF) are separated. So you are not discarding or losing an "important part of the volume conductor model". Wanze 2016-08-05 12:07 GMT-04:00 Nakhnikian, Alexander < Alexander_Nakhnikian at hms.harvard.edu>: > Hi John, > > > Thank you for your feedback. I'm not sure, however, I understand your > suggestion. Is the idea to exclude the white matter from the head model? If > so, aren't we discarding an important part of the volume conductor model? > Furthermore, if I'm correctly interpreting the FAQ page I provided, it > should be possible to apply a tissue mask after we've completed the 3 steps > you listed since ft_sourceanalysis and ft_prepare_leadfield are both called > after we have the grid, head volume, and sensor locations. > > > Thanks, > > > Alexander > ------------------------------ > *From:* RICHARDS, JOHN > *Sent:* Friday, August 5, 2016 9:51:34 AM > *To:* fieldtrip at science.ru.nl; Nakhnikian, Alexander > *Subject:* constrain source solution space > > https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/ > MediaObjects/10548_2016_505_MOESM3_ESM.docx > > 1--prepare a grid, for the source volume > 2-prepare a head volume > 3-prepare electrode (or meg) scalp locations > > These three elements are used for a lead field. > > LF and other elements are used w EEG in ft_sourceanalysis. > > There are several tutorials on FT site to do this. > > John > -----Original Message----- > From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces@ > science.ru.nl ] On Behalf Of > fieldtrip-request at science.ru.nl > Sent: Friday, August 5, 2016 6:00 AM > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 69, Issue 4 > > 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. Constrain Source solution space (Nakhnikian, Alexander) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 4 Aug 2016 18:25:38 +0000 > From: "Nakhnikian, Alexander" > To: "fieldtrip at science.ru.nl" > Subject: [FieldTrip] Constrain Source solution space > Message-ID: > namprd07.prod.outlook.com> > > Content-Type: text/plain; charset="iso-8859-1" > > Hello All, > > > I'm trying to constrain my source space to gray matter and I found > suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox. > org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter > > [http://www.fieldtriptoolbox.org/_media/logo-share.png]< > http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_ > source_reconstruction_to_the_grey_matter> > > faq:can_i_restrict_the_source_reconstruction_to_the_grey ... fieldtriptoolbox.org/faq/can_i_restrict_the_source_ > reconstruction_to_the_grey_matter> > www.fieldtriptoolbox.org > Yes, there are two strategies you can use. You can either make a regular > 3D grid spanning the whole brain in which only grid locations in grey > matter are considered ... > > > > > The problem is that I cannot figure out how to actually do this. For > example, I don't see options in ft_sourceanalysis for inputing segmented > mir with the tissue types of interest, now for giving the program an > anatomic mask. Any feedback would be greatly appreciated. > > > Best, > > > Alexander > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: attachments/20160804/48cc4c8e/attachment-0001.html> > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 69, Issue 4 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From xkshu at outlook.com Sun Aug 7 14:37:29 2016 From: xkshu at outlook.com (shu xiaokang) Date: Sun, 7 Aug 2016 12:37:29 +0000 Subject: [FieldTrip] fieldtrip for Mac Message-ID: Hi, I have met a problem when I was using fieldtrip to plot a topography with my macbook. Detailly, the colors of topographies drawn (using ft_topoplotTFR) with macbook are different from that drawn with windows (as attached figures). Actually, the pictures drawn with macbook are really ugly. Anyone know how to solve the problem? Shu[cid:6982C939-293A-42AA-8724-7439D84214AA][cid:2912BE42-6DE2-41B8-A818-5B88C95A997C] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Mac.png Type: image/png Size: 167415 bytes Desc: Mac.png URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Win.png Type: image/png Size: 333207 bytes Desc: Win.png URL: From tiago.lopes56 at yahoo.com Mon Aug 8 04:39:17 2016 From: tiago.lopes56 at yahoo.com (tiago lopes) Date: Mon, 8 Aug 2016 02:39:17 +0000 (UTC) Subject: [FieldTrip] calculate ERD / ERS References: <2107718987.18605392.1470623957848.JavaMail.yahoo.ref@mail.yahoo.com> Message-ID: <2107718987.18605392.1470623957848.JavaMail.yahoo@mail.yahoo.com> Hi,i am using the toolbox fieldtrip to calculate ERD / ERS in different groups. However, i do not know if I should use a relative or absolute power density in function cfg.baselinetype. I am using the following script, cfg                                 = [ ];cfg.method                     = 'wavelet';cfg.width                        = 7cfg.output                        = 'pow'cfg.foi                           =4:0.2:30;cfg.toi                           = -.68:0.01:1.5;cfg.keeptrials                ='no';cfg.baseline                    =[-0.4 -0.1];cfg.baselinetype            ='relative';         (I do not know if I should use a relative or absolute.)TFRtot                          = ft_freqanalysis(cfg, date)TFRtotal                       = ft_freqbaseline(cfg, TFRtot); Can anyone help me with this problem please? Federal University of Bahia, BrazilProgram in Medicine and Health Att. Tiago Lopes -------------- next part -------------- An HTML attachment was scrubbed... URL: From ayelet.landau at gmail.com Mon Aug 8 09:18:34 2016 From: ayelet.landau at gmail.com (Ayelet Landau) Date: Mon, 8 Aug 2016 10:18:34 +0300 Subject: [FieldTrip] Postdoc/PhD positions - Cognitive Neuroscience @ the Hebrew University of Jersusalem Message-ID: *Post Doc and PhD positions at the Brain Attention and Time Lab, at the Hebrew University of Jerusalem, Israel* Full-time post doc and PhD positions are available in the Brain Attention and Time Lab of Dr. Ayelet N. Landau at the Hebrew University of Jerusalem. Initial appointment will be for one year with the option to renew annually up to 4 years. Preferred starting date: October 2016 The lab’s core research areas include the guidance of attention and temporal processing and their underlying neural mechanisms. As cognitive neuroscientists we try to construe models of cognition and examine them using both in perception and in physiology. The positions are part of two externally funded projects focused on: (1) Fluctuations in attention and rhythmic attentional sampling. (2) Neural mechanisms of interval timing. Both research programs examine the role of brain rhythms in cognition. In the lab, we measure perception in different modalities (tactile, visual and auditory) together with non-invasive physiology (MEG/EEG) and eye-tracking. You can read about the research and the lab here. We are seeking a highly qualified post doc with a doctorate in a relevant field (e.g., Psychology, Neuroscience, and Cognitive Science) and shared interests in the core research areas described above. The researcher, ideally, should have extensive experience with EEG/MEG methodology and neural oscillations measurement. Experience with other techniques - such as fMRI, computational modeling, etc. - is also welcome but not required. In addition, we are looking for strong candidates for a funded PhD studentship. The Hebrew University offers several training opportunities in different departments. The successful candidate will be competitive for one of the flagship programs (psychology, cognitive science or neuroscience) and will have demonstrated experience in research from their post-bac or BA education (as research assistants or honors students). Knowledge of programming is an advantage. For both positions, a passion and a commitment to science, strong social skills, trouble shooting skills and fast learning abilities are a requirement. Interested candidates should send a CV, a brief statement of research interests, and the names and contact details of two academic references to ayelet.landau at huji.ac.il preferably by September 15th. Applications will be considered until the positions are filled. I look forward to hearing from you! Ayelet -- Ayelet N. Landau, PhD *Senior Lecturer* *Department of Psychology & Department of Cognitive SciencesThe Hebrew University of JerusalemJerusalem 91905Israel* -- Ayelet N. Landau, PhD *Senior Lecturer* *Department of Psychology & Department of Cognitive SciencesThe Hebrew University of JerusalemJerusalem 91905Israel* -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Mon Aug 8 11:36:41 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Mon, 08 Aug 2016 11:36:41 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> Message-ID: <10097d8526f9118870bfd95571e9cdd6@inserm.fr> Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: From anna.wieczorek.taraday at gmail.com Mon Aug 8 11:44:19 2016 From: anna.wieczorek.taraday at gmail.com (Anna Wieczorek-Taraday) Date: Mon, 8 Aug 2016 11:44:19 +0200 Subject: [FieldTrip] fieldtrip for Mac In-Reply-To: References: Message-ID: Hi Shu, If I understood correctly, you would you topoplot to be 'blue-yellow-red' instead of being 'blue-green'? If that is the case, you should specify the colormap in configuration structure when drawing figure (probably your default colormap on MacBook is set to 'parula' and the one on Win is 'jet'). try this: cfg.colormap = 'jet' and here you can find some more info about colormaps in Matlab: http://nl.mathworks.com/help/matlab/ref/colormap.html Good luck, Anna 2016-08-07 14:37 GMT+02:00 shu xiaokang : > Hi, > > I have met a problem when I was using fieldtrip to plot a topography with > my macbook. Detailly, the colors of topographies drawn (using > ft_topoplotTFR) with macbook are different from that drawn with windows > (as attached figures). Actually, the pictures drawn with macbook are really > ugly. Anyone know how to solve the problem? > > Shu > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Win.png Type: image/png Size: 333207 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Mac.png Type: image/png Size: 167415 bytes Desc: not available URL: From daniel.haehnke at tum.de Mon Aug 8 11:51:08 2016 From: daniel.haehnke at tum.de (=?utf-8?B?SMOkaG5rZSwgRGFuaWVs?=) Date: Mon, 8 Aug 2016 09:51:08 +0000 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <10097d8526f9118870bfd95571e9cdd6@inserm.fr> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> Message-ID: <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> Dear Laetitia, I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? Best, Daniel -- Daniel Hähnke PhD student Technische Universität München Institute of Neuroscience Translational NeuroCognition Laboratory Biedersteiner Straße 29, Bau 601 80802 Munich Germany Email: daniel.haehnke at tum.de Phone: +49 89 4140 3356 On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From xkshu at outlook.com Mon Aug 8 12:19:56 2016 From: xkshu at outlook.com (shu xiaokang) Date: Mon, 8 Aug 2016 10:19:56 +0000 Subject: [FieldTrip] fieldtrip for Mac In-Reply-To: References: Message-ID: Hi, Anna Thanks very much! It really works to add the code ‘cfg.colormap=‘jet’’, the default colormap on my mac has been set to ‘parula’. Shu 在 2016年8月8日,下午5:44,Anna Wieczorek-Taraday > 写道: Hi Shu, If I understood correctly, you would you topoplot to be 'blue-yellow-red' instead of being 'blue-green'? If that is the case, you should specify the colormap in configuration structure when drawing figure (probably your default colormap on MacBook is set to 'parula' and the one on Win is 'jet'). try this: cfg.colormap = 'jet' and here you can find some more info about colormaps in Matlab: http://nl.mathworks.com/help/matlab/ref/colormap.html Good luck, Anna 2016-08-07 14:37 GMT+02:00 shu xiaokang >: Hi, I have met a problem when I was using fieldtrip to plot a topography with my macbook. Detailly, the colors of topographies drawn (using ft_topoplotTFR) with macbook are different from that drawn with windows (as attached figures). Actually, the pictures drawn with macbook are really ugly. Anyone know how to solve the problem? Shu _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruil3 at student.unimelb.edu.au Tue Aug 9 08:34:18 2016 From: ruil3 at student.unimelb.edu.au (Rui Li) Date: Tue, 9 Aug 2016 16:34:18 +1000 Subject: [FieldTrip] Data Frequency Range for SAM(g2) Message-ID: Dear FieldTrippers, Currently, I am trying to reconstruct the source space using SAM(fg2) from MEG data of epilepsy patients. I read the paper "Kirsch_et_l+2006+Clinical_Neurophysiology+Automated_localization_of_magnetoencephalographic_interictal_spikes_by_adaptive_spatial_filtering" as the reference. However, it is a little confusing that the frequency range used to operate SAM(g2) was 20 - 70Hz. Does anybody have the idea why this frequency range was used? Are there any pieces of literature recommended for this issue? Regards, Rui. -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Tue Aug 9 19:19:32 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Tue, 9 Aug 2016 17:19:32 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol In-Reply-To: References: Message-ID: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Pomper, Ulrich Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Wed Aug 10 11:01:51 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Wed, 10 Aug 2016 11:01:51 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> Message-ID: <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> Hi Daniel, Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : Operation terminated by user during ft_checkdata>fixcsd (line 1072) In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1170) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 416) data = ft_checkdata(data, 'cmbrepresentation', 'full'); Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? Thanks a lot for your help. Best, Laetitia On 08-08-2016 11:51, Hähnke wrote: > Dear Laetitia, > > I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? > > Best, > > Daniel > > -- > Daniel Hähnke > PhD student > > Technische Universität München > Institute of Neuroscience > Translational NeuroCognition Laboratory > Biedersteiner Straße 29, Bau 601 > 80802 Munich > Germany > > Email: daniel.haehnke at tum.de > Phone: +49 89 4140 3356 > >> On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: >> >> Hello fieldtrippers, >> first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! >> >> I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended [1]. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >>> cfg=[]; >>> cfg.method='granger'; >>> granger=ft_connectivityanalysis(cfg, freq); >> to compute the granger causality. >> However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : >> >> Operation terminated by user during ft_checkdata>fixcsd (line 1255) >> >> In ft_checkdata (line 797) >> data = fixcsd(data, cmbrepresentation, channelcmb); >> >> In ft_checkdata>fixcsd (line 1351) >> data = ft_checkdata(data, 'cmbrepresentation', 'full'); >> >> In ft_checkdata (line 797) >> data = fixcsd(data, cmbrepresentation, channelcmb); >> >> In ft_connectivityanalysis (line 392) >> data = ft_checkdata(data, 'cmbrepresentation', 'full'); >> >> I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. >> >> Thanks a lot for your help. >> >> Regards, >> >> Laetitia Lalla >> PhD student in INMED, Marseille, France _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip Links: ------ [1] http://www.fieldtriptoolbox.org/tutorial/connectivityextended -------------- next part -------------- An HTML attachment was scrubbed... URL: From daniel.haehnke at tum.de Wed Aug 10 11:49:46 2016 From: daniel.haehnke at tum.de (=?utf-8?B?SMOkaG5rZSwgRGFuaWVs?=) Date: Wed, 10 Aug 2016 09:49:46 +0000 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> Message-ID: <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> Hi Laetitia, could you provide the code that you used for the calculation of your input structure ‘freq’? When I had a similar looking issue it was because I used a trial-resolved structure, whereas GC calculation seems to require trial-averaged data. Best, Daniel On 10.08.2016, at 11:01, laetitia.lalla at inserm.fr wrote: Hi Daniel, Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : Operation terminated by user during ft_checkdata>fixcsd (line 1072) In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1170) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 416) data = ft_checkdata(data, 'cmbrepresentation', 'full'); Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? Thanks a lot for your help. Best, Laetitia On 08-08-2016 11:51, Hähnke wrote: Dear Laetitia, I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? Best, Daniel -- Daniel Hähnke PhD student Technische Universität München Institute of Neuroscience Translational NeuroCognition Laboratory Biedersteiner Straße 29, Bau 601 80802 Munich Germany Email: daniel.haehnke at tum.de Phone: +49 89 4140 3356 On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Wed Aug 10 12:01:52 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Wed, 10 Aug 2016 10:01:52 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol References: <3D66B259-F956-4001-9AD3-1247F36D5E7C@gmail.com> Message-ID: <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> Dear Bumper, It may be helpful to provide the list with some example code + data, should anybody be keen to look into this. Best, Jan-Mathijs On 09 Aug 2016, at 19:19, Pomper, Ulrich > wrote: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Pomper, Ulrich > Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Wed Aug 10 12:44:06 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Wed, 10 Aug 2016 10:44:06 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol In-Reply-To: <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> References: <3D66B259-F956-4001-9AD3-1247F36D5E7C@gmail.com>, <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> Message-ID: Dear all, Below please find some code which illustrates the issue I'm having. Example data can be found here: https://www.dropbox.com/s/5bgpawph49vkgoo/data_fft_vs_conv.mat?dl=0 The code results in a plot of the PSD, showing how both mtmfft and mtmconvol yield (more or less) similar results, but only after the results from mtmfft are multiplied by 10. Again, I'd be grateful for any clarification on why this might be! Cheers, Ulrich %%%%%%%%%%%%% MTMFFT code %%%%%%%%%%%%%%%%%%%%%%%%% cfg = []; cfg.continuous = 'no'; cfg.channel = {'all', '-VEOG', '-HEOG'} cfg.output = 'pow'; cfg.method = 'mtmfft'; cfg.foi = 1:0.5:30; cfg.taper = 'hanning'; cfg.tapsmofrq = 2 +(0*(cfg.foi)); cfg.keeptapers = 'no'; cfg.keeptrials = 'no'; cfg.pad = 5; freq_fft = ft_freqanalysis(cfg, data); %%%%%%%%%%%%% MTMCONVOL code %%%%%%%%%%%%%%%%%%%%%%%%% taplen = 695; cfg = []; cfg.continuous = 'no'; cfg.channel = {'all', '-VEOG', '-HEOG'} cfg.output = 'pow'; cfg.method = 'mtmconvol'; cfg.foi = 1:0.5:30; cfg.toi = 0.25; cfg.taper = 'hanning'; cfg.tapsmofrq = 2 +(0*(cfg.foi)); cfg.t_ftimwin = ones(length(cfg.foi),1).* (taplen /1000); % cfg.keeptapers = 'no'; cfg.keeptrials = 'no'; cfg.pad = 5; freq_conv = ft_freqanalysis(cfg, data); %%%%%%%%%% plot the two different results for comparison %%%%%%%%%%%%%%%%% CH1_mean_fft = freq_fft.powspctrm(1,:); CH1_mean_conv = freq_conv.powspctrm(1,:); % mtmfft data multiplied by 10, which puts them in a similar order of magnitude as the results from mtmconvol CH1_mean_fft10 = freq_fft.powspctrm(1,:) * 10; figure; plot(CH1_mean_conv); hold on; plot(CH1_mean_fft10); hold on; plot(CH1_mean_fft); ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Schoffelen, J.M. (Jan Mathijs) Sent: 10 August 2016 11:01 To: FieldTrip discussion list Subject: Re: [FieldTrip] mtmfft vs. mtmconvol Dear Bumper, It may be helpful to provide the list with some example code + data, should anybody be keen to look into this. Best, Jan-Mathijs On 09 Aug 2016, at 19:19, Pomper, Ulrich > wrote: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Pomper, Ulrich > Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Wed Aug 10 16:29:09 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Wed, 10 Aug 2016 16:29:09 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> Message-ID: Hello ! Sure, this is the code that I use after the preprocessing : %------------------------------------------------------------------------------- cfg = []; cfg.method = 'mtmconvol'; cfg.output = 'powandcsd'; cfg.channel = data.label; cfg.channelcmb = {'Str' 'Ctx'}; cfg.taper = 'dpss'; cfg.foi = 0.5:100; cfg.tapsmofrq = 1.5*ones(1, length(cfg.foi)); cfg.t_ftimwin = 2*ones(1, length(cfg.foi)); cfg.toi = data.time{1,1}; cfg.keeptrials = 'no'; freq = ft_freqanalysis(cfg, data); % cfg=[]; % cfg.method='coh'; % coh=ft_connectivityanalysis(cfg, freq); cfg=[]; cfg.method='granger'; granger=ft_connectivityanalysis(cfg, freq); %------------------------------------------------------------------------------ I succesfully compute the Time-Frequency Map of the coherence (this was to check), but it won't work for the Granger causality... Thanks a lot for your help ! Best, Laetitia On 10-08-2016 11:49, Hähnke wrote: > Hi Laetitia, > > could you provide the code that you used for the calculation of your input structure 'freq'? > > When I had a similar looking issue it was because I used a trial-resolved structure, whereas GC calculation seems to require trial-averaged data. > > Best, Daniel > > On 10.08.2016, at 11:01, laetitia.lalla at inserm.fr wrote: > > Hi Daniel, > Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : > > Operation terminated by user during ft_checkdata>fixcsd (line 1072) > In ft_checkdata (line 595) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_checkdata>fixcsd (line 1170) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > In ft_checkdata (line 595) > data = fixcsd(data, cmbrepresentation, channelcmb); > In ft_connectivityanalysis (line 416) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? > > Thanks a lot for your help. > > Best, > > Laetitia > > On 08-08-2016 11:51, Hähnke wrote: Dear Laetitia, > > I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? > > Best, > > Daniel > > -- > Daniel Hähnke > PhD student > > Technische Universität München > Institute of Neuroscience > Translational NeuroCognition Laboratory > Biedersteiner Straße 29, Bau 601 > 80802 Munich > Germany > > Email: daniel.haehnke at tum.de > Phone: +49 89 4140 3356 > > On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: > > Hello fieldtrippers, > first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! > > I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended [1]. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >> cfg=[]; >> cfg.method='granger'; >> granger=ft_connectivityanalysis(cfg, freq); > to compute the granger causality. > However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : > > Operation terminated by user during ft_checkdata>fixcsd (line 1255) > > In ft_checkdata (line 797) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_checkdata>fixcsd (line 1351) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > In ft_checkdata (line 797) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_connectivityanalysis (line 392) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. > > Thanks a lot for your help. > > Regards, > > Laetitia Lalla > PhD student in INMED, Marseille, France _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip Links: ------ [1] http://www.fieldtriptoolbox.org/tutorial/connectivityextended -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 17:42:29 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 15:42:29 +0000 Subject: [FieldTrip] reading .mat in fieldtrip Message-ID: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 17:42:30 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 15:42:30 +0000 Subject: [FieldTrip] reformat .mat data - example script Message-ID: Hi Did you solve your problem with reading .mat in field trip? I have the same problem do you have any idea? -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 18:33:03 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 09:33:03 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) : > Hi All, > > > > I have a “.mat” file which contais: <8x10350000 double> and sampling rate. > > How should I import this data to field trip? By using [data] = > ft_preprocessing( cfg); > > I am getting an error that the data should be in the format of raw or > raw + comp. > > > > Any idea? > > > > Thanks! > > > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 18:44:49 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 16:44:49 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 18:59:12 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 09:59:12 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: You could try to make one long trial, and take it from there. Load that matrix stored in your mat file (type 'help load'), and then data.trial{1,1} = matrix; data.time{1,1} = 1:size(matrix,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; .. data.label{8,1} = 'chan 8'; See that page, and/or type 'help ft_datatype_raw'. When your data is in raw format, you can process it with ft_preprocessing (e.g. to filter) or ft_redefinetrial (to create trials). Hope that gets you on your way, Arjen 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) : > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = > ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: > > Hi Bahareh, > > To get you started, see this page: > http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat > > It describes what fieldtrip expects your raw data to look like. > > Arjen > > 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: > >> Hi All, >> >> >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling >> rate. >> >> How should I import this data to field trip? By using [data] = >> ft_preprocessing( cfg); >> >> I am getting an error that the data should be in the format of raw or >> raw + comp. >> >> >> >> Any idea? >> >> >> >> Thanks! >> >> >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 19:15:51 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 17:15:51 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> I tried all these options before. The problem with ft_preprossecing is with cfg.dataset: I gave it my data's file name and path but the error is related to header and it says "unsupported header format"! And to use ft_predefintrial I need to creat Cfg apart of data that I do not have have anything at this time to include in Cfg. Thanks for your help! Bahar On Aug 11, 2016, at 12:00 PM, Arjen Stolk > wrote: You could try to make one long trial, and take it from there. Load that matrix stored in your mat file (type 'help load'), and then data.trial{1,1} = matrix; data.time{1,1} = 1:size(matrix,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; .. data.label{8,1} = 'chan 8'; See that page, and/or type 'help ft_datatype_raw'. When your data is in raw format, you can process it with ft_preprocessing (e.g. to filter) or ft_redefinetrial (to create trials). Hope that gets you on your way, Arjen 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) >: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 19:27:00 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 10:27:00 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> References: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> Message-ID: You will no longer need to specify cfg.dataset once the data is already read into the matlab environment. Try, for instance, cfg = []; cfg.demean = 'yes'; preproc = ft_preprocessing(cfg, data); 2016-08-11 10:15 GMT-07:00 Bahareh Elahian (belahian) : > I tried all these options before. > > The problem with ft_preprossecing is with cfg.dataset: I gave it my data's > file name and path but the error is related to header and it says > "unsupported header format"! > And to use ft_predefintrial I need to creat Cfg apart of data that I do > not have have anything at this time to include in Cfg. > > Thanks for your help! > > Bahar > > > On Aug 11, 2016, at 12:00 PM, Arjen Stolk wrote: > > You could try to make one long trial, and take it from there. Load that > matrix stored in your mat file (type 'help load'), and then > > data.trial{1,1} = matrix; > data.time{1,1} = 1:size(matrix,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > .. > data.label{8,1} = 'chan 8'; > > See that page, and/or type 'help ft_datatype_raw'. When your data is in > raw format, you can process it with ft_preprocessing (e.g. to filter) or > ft_redefinetrial (to create trials). > > Hope that gets you on your way, > Arjen > > > > > 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) >: > >> Thanks for the answer, >> >> I have had a look on this page before and I tried to follow the steps. >> The problem is ;I do not have any cfg to define cfg.trl and use newdata >> = ft_redefinetrial(cfg,data); >> >> Any other idea? >> >> >> >> On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: >> >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) < >> belahian at memphis.edu>: >> >>> Hi All, >>> >>> >>> >>> I have a “.mat” file which contais: <8x10350000 double> and sampling >>> rate. >>> >>> How should I import this data to field trip? By using [data] = >>> ft_preprocessing( cfg); >>> >>> I am getting an error that the data should be in the format of raw or >>> raw + comp. >>> >>> >>> >>> Any idea? >>> >>> >>> >>> Thanks! >>> >>> >>> >>> >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From toni.rbaena at gmail.com Thu Aug 11 20:47:18 2016 From: toni.rbaena at gmail.com (Antonio Rodriguez) Date: Thu, 11 Aug 2016 20:47:18 +0200 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" < belahian at memphis.edu> escribió: > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = > ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: > > Hi Bahareh, > > To get you started, see this page: > http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat > > It describes what fieldtrip expects your raw data to look like. > > Arjen > > 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: > >> Hi All, >> >> >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling >> rate. >> >> How should I import this data to field trip? By using [data] = >> ft_preprocessing( cfg); >> >> I am getting an error that the data should be in the format of raw or >> raw + comp. >> >> >> >> Any idea? >> >> >> >> Thanks! >> >> >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 21:00:52 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 19:00:52 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Antonio Rodriguez Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribi?: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 21:23:30 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 19:23:30 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , , Message-ID: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Bahareh Elahian (belahian) Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Antonio Rodriguez Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribi?: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From K.Vogt at donders.ru.nl Thu Aug 11 23:05:55 2016 From: K.Vogt at donders.ru.nl (Katharina Vogt) Date: Thu, 11 Aug 2016 22:05:55 +0100 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: <9D133336-632C-4227-9076-710E03043F9F@donders.ru.nl> Hi Bahareh, I had the same issue before too. I also created the needed structure and then used ft_redefinetrial. Not optimal, but it did the job!! However, I asked Robert Oostenveld to add my file format and he did. I might have to add that I work at the same Uni as he does and I was able to do it in person. I guess you can at least ask. Best, Katharina > On 11 Aug 2016, at 20:23, Bahareh Elahian (belahian) wrote: > > I did something and it works but it is not correct . > I specified cfg.trl = data.trial{1,1} > > cfg = []; > cfg.bpfilter = 'yes'; > cfg.demean = 'yes'; > data.trial{1,1} = eeg.eeg_data; > cfg.trl = data.trial{1,1}; > data.time{1,1} = 1:size(eeg.eeg_data,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > data.label{3,1} = 'chan 3'; > data.label{4,1} = 'chan 4'; > data.label{5,1} = 'chan 5'; > data.label{6,1} = 'chan 6'; > data.label{7,1} = 'chan 7'; > data.label{8,1} = 'chan 8'; > data.fsample = eeg.samp_rate; > newdata = ft_redefinetrial(cfg,data); > > the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. > > > From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > > Sent: Thursday, August 11, 2016 2:00:52 PM > To: FieldTrip discussion list > Subject: Re: [FieldTrip] reading .mat in fieldtrip > > Thanks but none of the options works. > The error is : > you should specify at least one configuration option. > > Even cfg.demean = 'yes'; is not enough. > > From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > > Sent: Thursday, August 11, 2016 1:47:18 PM > To: FieldTrip discussion list > Subject: Re: [FieldTrip] reading .mat in fieldtrip > > Hi. > You can create an empty cfg structure, and fill with data : > cfg =[]; > newdata = ft_redefinetrial(cfg,data); > > El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: > >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: >> Hi All, >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling rate. >> How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); >> I am getting an error that the data should be in the format of raw or raw + comp. >> >> Any idea? >> >> Thanks! >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 23:25:13 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 14:25:13 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) : > I did something and it works but it is not correct . > > I specified cfg.trl = data.trial{1,1} > > > cfg = []; > cfg.bpfilter = 'yes'; > cfg.demean = 'yes'; > data.trial{1,1} = eeg.eeg_data; > cfg.trl = data.trial{1,1}; > data.time{1,1} = 1:size(eeg.eeg_data,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > data.label{3,1} = 'chan 3'; > data.label{4,1} = 'chan 4'; > data.label{5,1} = 'chan 5'; > data.label{6,1} = 'chan 6'; > data.label{7,1} = 'chan 7'; > data.label{8,1} = 'chan 8'; > data.fsample = eeg.samp_rate; > newdata = ft_redefinetrial(cfg,data); > > the newdata.time and newdata.trial are <1*8 cell > . some of the cells > are empty and one is NAN. > > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > *Sent:* Thursday, August 11, 2016 2:00:52 PM > > *To:* FieldTrip discussion list > *Subject:* Re: [FieldTrip] reading .mat in fieldtrip > > > Thanks but none of the options works. > > The error is : > > you should specify at least one configuration option. > > > Even cfg.demean = 'yes'; is not enough. > > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > *Sent:* Thursday, August 11, 2016 1:47:18 PM > *To:* FieldTrip discussion list > *Subject:* Re: [FieldTrip] reading .mat in fieldtrip > > > Hi. > > You can create an empty cfg structure, and fill with data : > > cfg =[]; > newdata = ft_redefinetrial(cfg,data); > > El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" < > belahian at memphis.edu> escribió: > >> Thanks for the answer, >> >> I have had a look on this page before and I tried to follow the steps. >> The problem is ;I do not have any cfg to define cfg.trl and use newdata >> = ft_redefinetrial(cfg,data); >> >> Any other idea? >> >> >> >> On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: >> >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) < >> belahian at memphis.edu>: >> >>> Hi All, >>> >>> >>> >>> I have a “.mat” file which contais: <8x10350000 double> and sampling >>> rate. >>> >>> How should I import this data to field trip? By using [data] = >>> ft_preprocessing( cfg); >>> >>> I am getting an error that the data should be in the format of raw or >>> raw + comp. >>> >>> >>> >>> Any idea? >>> >>> >>> >>> Thanks! >>> >>> >>> >>> >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 23:32:18 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 21:32:18 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: That was a good point. The problem is I do not want to specify any trial for my configuration. As I mentioned before if I leave cfg =[]; if gives me an error. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Arjen Stolk Sent: Thursday, August 11, 2016 4:25:13 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) >: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a “.mat” file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 23:38:33 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 21:38:33 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks all, The problem is fixed: Here is the answer : cfg = []; cfg.demean = 'yes'; % base correction data.trial{1,1} = eeg.eeg_data; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; [data1] = ft_preprocessing (cfg, data); _____ Bahar ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Arjen Stolk Sent: Thursday, August 11, 2016 4:25 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_redefinetrial – FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type “help ft_redefinetrial”. FT_REDEFINETRIAL allows you to ... [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_redefinetrial – FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type “help ft_redefinetrial”. FT_REDEFINETRIAL allows you to ... cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) >: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a “.mat” file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 12 02:19:48 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 00:19:48 +0000 Subject: [FieldTrip] FEM in FieldTrip Message-ID: Hello, I would like to implement subject-specific FEM head/dipole models in FieldTrip. Searching the FieldTrip site has not given me enough information, and some of the simbio links are broken. Can someone please inform me as to the state of the FEM code in FieldTrip, and where I can find the documentation? I can find the simbio folder with about 25 files, but no documentation. Thanks, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 12 02:52:43 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 00:52:43 +0000 Subject: [FieldTrip] how do embed a dipole model in a FEM head model? Message-ID: Please ignore my previous request for FEM documentation, as I finally found this: http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. Please advise how to create a source model in this case. Thanks, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorw01 at gmail.com Fri Aug 12 03:47:00 2016 From: j.vorw01 at gmail.com (Johannes Vorwerk) Date: Thu, 11 Aug 2016 19:47:00 -0600 Subject: [FieldTrip] how do embed a dipole model in a FEM head model? In-Reply-To: References: Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54@googlemail.com> Hi Jeff, I am not sure if we have the same understanding of a „source model“, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ¨ J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267–278. C. H. Wolters, H. Kostler, C. M ¨ oller, J. H ¨ ardtlein, and A. Anwander ¨ , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189–192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. I hope this helps. Best, Johannes > Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : > > Please ignore my previous request for FEM documentation, as I finally found this: > > http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio > > Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. > > Please advise how to create a source model in this case. > > Thanks, > -Jeff > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From rhancock at email.arizona.edu Fri Aug 12 05:44:04 2016 From: rhancock at email.arizona.edu (Roeland Hancock) Date: Thu, 11 Aug 2016 20:44:04 -0700 Subject: [FieldTrip] Postdoctoral and Research Associate Positions at Haskins Laboratories Message-ID: Please see the below announcements for two research associate positions and one postdoctoral position at Haskins Laboratories — successful applicants for all positions will work on NIH funded projects focused on the neurobiology of reading development and reading disability. *Job Announcement, July 2016: Postdoctoral Fellow* Haskins Laboratories, 300 George Street, Suite 900, New Haven CT 06511 Qualified individuals are invited to apply for a full-time Postdoctoral Fellow position in the Haskins Imaging Lab (http://www.haskins.yale.edu/hil/) at Haskins Laboratories. This position is supported by a new 5-year NIH grant on the cognitive neuroscience of language and reading development in children ages 6-12. Specifically, this project will use Magnetic Resonance Spectroscopy (MRS) alongside fMRI, EEG, and behavioral techniques to understand typical and atypical language development. The successful candidate will report to Project Co-Investigators Dr. Kenneth Pugh and Dr. Fumiko Hoeft, work closely with Director of Neuroimaging Research Dr. Einar Mencl and the Director of EEG research Dr. Nicole Landi, and be responsible for coordination of multimodal imaging, data analysis, journal article reporting, and supervision of Research Associates. The successful candidate will join a team of researchers investigating the neural bases of speech, language and reading using data from fMRI, EEG/ERP, fNIRS, ultrasound, EMG and behavioral data from typical individuals, and individuals with language disorders. This candidate will have the opportunity to work on several projects on this grant, and to collaborate with researchers at Haskins, University of Connecticut and Yale University. *Minimum Qualifications* • Ph.D. in Psychology, Cognitive Science, Neuroscience, Communication Disorders, Linguistics, or related field • Significant research in cognitive neuroscience of language • Excellent interpersonal skills • Excellent verbal and written communication skills *Preferred Qualifications* • Experience with fMRI/sMRI, MRS, EEG data collection and analysis • Experience with experimental presentation software such as E-Prime or PsychoPy • Experience working with children • Data analysis and manipulation skills (e.g., Matlab, R, Python) The initial appointment will be for one year, renewable after the first year. Interested applicants should contact Tammy Ursini, Administrative Coordinator (ursini at haskins.yale.edu) with cover letter, resume, copy of (unofficial) transcripts, and the names of three potential references. Please note “Job Posting 5016”, in the subject line of your email. This position will remain open until filled, with an anticipated start date in fall 2016. Compensation is commensurate with skills and experience. Haskins Laboratories (www.haskins.yale.edu) is a private, non-profit research institute with a primary focus on speech, language, reading, and their biological basis. Haskins has long-standing, formal affiliations with the University of Connecticut and Yale University. Haskins Laboratories is an Equal Opportunity Employer. ------------------------------ *Job Announcement, July 2016: Research Associate (2)* Haskins Laboratories, 300 George Street, Suite 900, New Haven CT 06511 Project Director: Dr. Kenneth Pugh Qualified individuals are invited to apply for two full-time Research Associate positions at Haskins Laboratories. The successful candidates will join a team of researchers investigating the cognitive and neural bases of reading and language development using behavioral and neuroimaging data (fMRI, EEG and NIRS) in typically developing and language impaired children and adolescents. We are accepting applications for two related positions: 1) *Behavioral testing and coordination*. This position will involve hands on collection of behavioral and neuroimaging data, including standardized assessments, with young children and adolescents. Applicants for this position must have experience working with young children. 2) *Neuroimaging analysis and management*. This position will involve both routine data manipulation and organization of neuroimaging data (MRI/fMRI, EEG, fNIRS), as well as assisting with development of new analysis strategies. Specific requirements for this position include strong computing skills (scripting, data management) and data analysis skills. Requirements include: • BA or BS in Psychology, Cognitive Science, Computer Science or related field Additional relevant skills include: • Experience with human research • Experience administering standardized assessments • Experience with neuroimaging • Experience with experimental presentation software packages (e.g., E-PRIME, Presentation, PsychoPy) • Experience with statistical analysis (e.g., SPSS, R, Matlab) • Experience with data management software (e.g., FileMaker, Access, RedCap) Interested applicants should contact Tammy Ursini, Administrative Coordinator (ursini at haskins.yale.edu ) with cover letter, resume, copy of (unofficial) transcripts, and the names of three potential references. Please note “Job Posting 5015”, in the subject line of your email and also indicate which of the two positions you are interested in. These positions will remain open until filled, with an anticipated start date of September, 2016. Compensation is commensurate with skills and experience. Haskins Laboratories (www.haskins.yale.edu) is a private, non-profit research institute with a primary focus on speech, language, reading, and their biological basis. Haskins has long-standing, formal affiliations with the University of Connecticut and Yale University. Haskins Laboratories is an Equal Opportunity Employer. Roeland Hancock, PhD Postdoctoral Researcher Department of Psychiatry UCSF Weill Institute for Neurosciences University of California, San Francisco 401 Parnassus Avenue San Francisco, CA 94143 brainLENS.org -------------- next part -------------- An HTML attachment was scrubbed... URL: From Adham.Elshahabi at med.uni-tuebingen.de Fri Aug 12 10:06:44 2016 From: Adham.Elshahabi at med.uni-tuebingen.de (Adham Elshahabi) Date: Fri, 12 Aug 2016 10:06:44 +0200 Subject: [FieldTrip] =?utf-8?q?Postdoc_Position_in_T=C3=BCbingen=2C_German?= =?utf-8?q?y?= Message-ID: <57AD9FB4020000EF0001D6FA@vslgwd5> Dear Fieldtrip community, please find attached a job offer for 1 Postdoc positon in Tübingen for simultaneous PET/fMRI/EEG in small animals. For mor information, please contact Hans directly: hans.wehrl at med.uni-tuebingen.de Best regards, Adham Elshahabi University Hospital Tübingen MEG Center http://meg.medizin.uni-tuebingen.de -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: PostDoc_PETMREEG_Tuebingen.pdf Type: application/pdf Size: 231850 bytes Desc: Acrobat URL: From brungio at gmail.com Fri Aug 12 13:52:47 2016 From: brungio at gmail.com (Bruno L. Giordano) Date: Fri, 12 Aug 2016 12:52:47 +0100 Subject: [FieldTrip] Optimizing leadfield computation Message-ID: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Hi, I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? Thank you, Bruno -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bruno L. Giordano, PhD Institute of Neuroscience and Psychology 58 Hillhead Street, University of Glasgow Glasgow, G12 8QB, Scotland T +44 (0) 141 330 5484 Www: http://www.brunolgiordano.net Email charter: http://www.emailcharter.org/ From jan.schoffelen at donders.ru.nl Fri Aug 12 14:16:17 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 12:16:17 +0000 Subject: [FieldTrip] Optimizing leadfield computation In-Reply-To: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> References: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Message-ID: Hi Bruno, I don’t know about the low-level details of the computation in meg_forward, but I’d take your word on that it allows for multiple positions simultaneously. With respect to the leadfield calculation as such, we typically recommend to pre-compute them once (and store them for later use), and input a source-model with these pre-computed leadfields in ft_sourceanalysis. This typically works if you keep the signal subspace for which you computed your leadfields consistent with the signal subspace of the sensor-data. We are aware that apart from this FT's beamformer code is relatively slow (even with precomputed leadfields), but at some point in the past we decided to go for code clarity and correctness, rather than to go for computational speed. Doing all computations vectorized will make the code quite opaque (and moreover is not really straightforward if one would like to stay flexible with respect to location specific dimensions of vector leadfields (e.g. regional sources). Given all other steps in typical data processing pipelines, the beamformer step is usually not the time limiting one. Best, Jan-Mathijs > On 12 Aug 2016, at 13:52, Bruno L. Giordano wrote: > > Hi, > > I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). > > It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? > > Thank you, > > Bruno > > > -- > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > Bruno L. Giordano, PhD > Institute of Neuroscience and Psychology > 58 Hillhead Street, University of Glasgow > Glasgow, G12 8QB, Scotland > T +44 (0) 141 330 5484 > Www: http://www.brunolgiordano.net > Email charter: http://www.emailcharter.org/ > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip From brungio at gmail.com Fri Aug 12 15:10:00 2016 From: brungio at gmail.com (Bruno L. Giordano) Date: Fri, 12 Aug 2016 14:10:00 +0100 Subject: [FieldTrip] Optimizing leadfield computation In-Reply-To: References: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Message-ID: <1b80e222-21e2-ef03-9e4b-36481b9b7a74@gmail.com> Hi Jan-Mathijs, thanks. I will check what I can do then. Leadfield computation becomes quite lengthy when one has a large number of blocks for a large number of participants, and would like to have finer than usual grids ;-) And yes, I compute them only once. I understand the philosophy of the development team, it makes perfect sense. Indeed, optimized code can be at times not very transparent. However, the most important aspect of the optimization would simply require replacing loops through the dipoles with mtimesx-based matrix multiplications. If you guys are interested, I can send the functions I have written, so that you can see how they operate. Cheers, Bruno On 12/08/2016 13:16, Schoffelen, J.M. (Jan Mathijs) wrote: > Hi Bruno, > > I don’t know about the low-level details of the computation in meg_forward, but I’d take your word on that it allows for multiple positions simultaneously. > > With respect to the leadfield calculation as such, we typically recommend to pre-compute them once (and store them for later use), and input a source-model with these pre-computed leadfields in ft_sourceanalysis. This typically works if you keep the signal subspace for which you computed your leadfields consistent with the signal subspace of the sensor-data. > > We are aware that apart from this FT's beamformer code is relatively slow (even with precomputed leadfields), but at some point in the past we decided to go for code clarity and correctness, rather than to go for computational speed. Doing all computations vectorized will make the code quite opaque (and moreover is not really straightforward if one would like to stay flexible with respect to location specific dimensions of vector leadfields (e.g. regional sources). Given all other steps in typical data processing pipelines, the beamformer step is usually not the time limiting one. > > Best, > Jan-Mathijs > >> On 12 Aug 2016, at 13:52, Bruno L. Giordano wrote: >> >> Hi, >> >> I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). >> >> It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? >> >> Thank you, >> >> Bruno >> >> >> -- >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> Bruno L. Giordano, PhD >> Institute of Neuroscience and Psychology >> 58 Hillhead Street, University of Glasgow >> Glasgow, G12 8QB, Scotland >> T +44 (0) 141 330 5484 >> Www: http://www.brunolgiordano.net >> Email charter: http://www.emailcharter.org/ >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bruno L. Giordano, PhD Institute of Neuroscience and Psychology 58 Hillhead Street, University of Glasgow Glasgow, G12 8QB, Scotland T +44 (0) 141 330 5484 Www: http://www.brunolgiordano.net Email charter: http://www.emailcharter.org/ From belahian at memphis.edu Fri Aug 12 16:51:32 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 14:51:32 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis Message-ID: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 17:08:20 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 15:08:20 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: Message-ID: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Fri Aug 12 17:15:54 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 15:15:54 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> References: , <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Schoffelen, J.M. (Jan Mathijs) Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 17:59:13 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 15:59:13 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: It is correct as far as the data.fsample is consistent with this (which I suspect it isn’t). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Fri Aug 12 18:09:22 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 16:09:22 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> , Message-ID: Thanks for suggestions. The data.fsample is 30K. I want to see HFOs in time- frequency plot. Wavelet is one solution of that. The error which I am getting is coming from padding and I do not know where should I fix it. What should I do if I do not want any padding? Bahar On Aug 12, 2016, at 11:04 AM, Schoffelen, J.M. (Jan Mathijs) > wrote: It is correct as far as the data.fsample is consistent with this (which I suspect it isn't). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 18:32:42 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 16:32:42 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: If your sampling rate is 30K, then your time axis should be something like (1:size(data.trial{1},1))./data.fsample; rather than 1:some-number On 12 Aug 2016, at 18:09, Bahareh Elahian (belahian) > wrote: Thanks for suggestions. The data.fsample is 30K. I want to see HFOs in time- frequency plot. Wavelet is one solution of that. The error which I am getting is coming from padding and I do not know where should I fix it. What should I do if I do not want any padding? Bahar On Aug 12, 2016, at 11:04 AM, Schoffelen, J.M. (Jan Mathijs) > wrote: It is correct as far as the data.fsample is consistent with this (which I suspect it isn’t). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Sat Aug 13 00:53:09 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 22:53:09 +0000 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 In-Reply-To: References: Message-ID: Johannes, I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. In my naïve view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. Thanks, -Jeff Message: 3 Date: Thu, 11 Aug 2016 19:47:00 -0600 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] how do embed a dipole model in a FEM head model? Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54 at googlemail.com> Content-Type: text/plain; charset="utf-8" Hi Jeff, I am not sure if we have the same understanding of a ?source model?, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ? J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267?278. C. H. Wolters, H. Kostler, C. M ? oller, J. H ? ardtlein, and A. Anwander ? , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189?192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. I hope this helps. Best, Johannes > Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : > > Please ignore my previous request for FEM documentation, as I finally found this: > > http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio > mbio> > > Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. > > Please advise how to create a source model in this case. > > Thanks, > -Jeff > From j.vorw01 at gmail.com Sat Aug 13 01:09:29 2016 From: j.vorw01 at gmail.com (Johannes Vorwerk) Date: Fri, 12 Aug 2016 17:09:29 -0600 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 In-Reply-To: References: Message-ID: <41C233E2-F2D6-46A0-A9F3-0A317F1A82CD@googlemail.com> I see. Your missunderstanding is that the dipoles are „represented“ through hexaedrons (and that you need to implement this ;-)). The idea that is usually used to derive FEM for EEG is to stick to the model of a dipole and to represent this dipole through the FEM basis functions. One method to do this (the „Venant approach“) is already implemented in fieldtrip. The way this representation is achieved is described in the papers I mentioned. If you do not want to use a different approach here, no further work on your side is needed. What you refer to as a „source model“ is what I would call „source space“ (since „source model“ can be easily mixed up…). The source space can be defined just as you would do it for spheres and BEM in fieldtrip. To apply FEM, you have to indicate to fieldtrip to generate a hexahedral head model and „simbio“ as method of forward computation. Best, Johannes > Am 12.08.2016 um 16:53 schrieb K Jeffrey Eriksen : > > Johannes, > > I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. > > In my naïve view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. > > I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. > > Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. > > Thanks, > -Jeff > > Message: 3 > Date: Thu, 11 Aug 2016 19:47:00 -0600 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] how do embed a dipole model in a FEM head > model? > Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Jeff, > > I am not sure if we have the same understanding of a ?source model?, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example > > H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ? J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267?278. > C. H. Wolters, H. Kostler, C. M ? oller, J. H ? ardtlein, and A. Anwander ? , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189?192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. > J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). > > or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. > > I hope this helps. > > Best, > Johannes > >> Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : >> >> Please ignore my previous request for FEM documentation, as I finally found this: >> >> http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio >> > mbio> >> >> Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. >> >> Please advise how to create a source model in this case. >> >> Thanks, >> -Jeff >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip From c.monroy at donders.ru.nl Mon Aug 15 15:34:41 2016 From: c.monroy at donders.ru.nl (Monroy, C.D. (Claire)) Date: Mon, 15 Aug 2016 13:34:41 +0000 Subject: [FieldTrip] ft_singleplotER Message-ID: <88359EE60C7B4649B4765DEE86343C614F106DF3@exprd01.hosting.ru.nl> Hi! Has anyone ever tried to plot shaded error bars around the ERP waveforms when using ft_singleplotER? If so, could someone share with me how they did this? Claire Monroy PhD student Baby Research Center Donders Institute for Brain, Cognition and Behaviour, Centre for Cognition Room B.01.18 Phone: +31 (0) 24 36 55977 Email: c.monroy at donders.ru.nl -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Mon Aug 15 16:18:15 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Mon, 15 Aug 2016 14:18:15 +0000 Subject: [FieldTrip] Odd behavior in DICS Message-ID: Hello All, I'm getting strange results from DICS applied to EEG data. I'm wondering if anyone else has run into these issues and/or can suggest a solution. I don't have individual sMRI so I'm using the standard BEM and MRI that come with FT. I constructed the lead fields as follows. First, I constrain the dipoles of interest to the cortical mantle using the AAL atlas. I then compute the lead fields using ft_prepare_leadfields; I don't have a baseline for these data so the lead fields are normalized. I feed the precomputed lead fields and data into ft_sourceanalysis to find the source-level power for each subject. 1) DICS, but not eLORETA, returns extremely large results at certain voxels. These extrema dominate the grand averages. In each subject, these voxels are always at the edge of the cortex, near the skull. The voxel locations are not exactly the same across subjects, but for any given subject they tend to appear in one of a few locations (i.e. over the right occipital cortex). The lead fields have the same magnitude (following normalization) across all voxels. I did notice, however, that voxels at which extreme values appear tend to have a larger condition number (~12) than voxels at which abnormal values do not appear in any subject (~2). I do not know whether this is relevant but I thought it might have some effect on adaptive but not non-adaptive filters. Since I'm constructing the forward model using FT templates, I thought someone else might have encountered this problem before. 2) As I mentioned above, eLORETA does not return such extreme results; furthermore, when we contrast controls with schizophrenia patients using an independent samples t-test with cluster control for multiple comparisons we find significant differences between groups using eLORETA but not DICS. The raw differences between the grand averages returned by DICS and eLORETA are similar, but when we run stats using DICS most of the correct p values are equal to 1 with one or two in the 0.8-0.9 range. I'm looking for converging evidence between different source analysis methods and it's not clear to me why DICS and eLORETA return such different results. 3) I thought that voxels are which unusually large values occur in controls and patients could be throwing off the stats; however, DICS does not return significant contrasts between control and schizophrenia even when I mask out the extreme voxels. Thanks in advance for any advice. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From dippel.g at gmail.com Mon Aug 15 17:46:30 2016 From: dippel.g at gmail.com (gab dippel) Date: Mon, 15 Aug 2016 17:46:30 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: Dear Fieldtrippers, my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. So the goal is to compute the virtual channels of a certain atlas region let say the SMA. As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) --> So here I construct an MRI based grid 
 load standard_mri.mat cfg = []; cfg.mri = mri; template_grid = ft_prepare_sourcemodel(cfg); this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) --> this is obsolete in my case i guess 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': cfg = []; cfg.grid.xgrid = -90:1:90; cfg.grid.ygrid = -108:1:108; cfg.grid.zgrid = -90:1:90; cfg.grid.unit = 'mm'; cfg.grid.tight = 'yes'; cfg.mri = mri; high_res_grid_mm = ft_prepare_sourcemodel(cfg) 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. I would appreciate any feedback and ideas on this issue. Kind regards, Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From azeez.adebimpe5 at gmail.com Mon Aug 15 17:50:18 2016 From: azeez.adebimpe5 at gmail.com (Azeez Adebimpe) Date: Mon, 15 Aug 2016 11:50:18 -0400 Subject: [FieldTrip] Odd behavior in DICS In-Reply-To: References: Message-ID: Hi Alexander, DICS also works similarly to eLORETA but you need to remove bias after you compute the source. 1. Estimate the noise from the data with cfg.dics.projectnoise='yes'; the default is no, so you need to set it while computing source. 2. Divide the pow by noise estimate Sourcedb=source; Sourcedb.avg.pow=sourcedb.avg.pow./sourcedb.avg.noise; 3. plot the Sourcedb.avg.pow; to see hope it help, Best, Azeez On Mon, Aug 15, 2016 at 10:18 AM, Nakhnikian, Alexander < Alexander_Nakhnikian at hms.harvard.edu> wrote: > Hello All, > > > I'm getting strange results from DICS applied to EEG data. I'm wondering > if anyone else has run into these issues and/or can suggest a solution. > > > I don't have individual sMRI so I'm using the standard BEM and MRI that > come with FT. I constructed the lead fields as follows. First, I constrain > the dipoles of interest to the cortical mantle using the AAL atlas. I then > compute the lead fields using ft_prepare_leadfields; I don't have a > baseline for these data so the lead fields are normalized. I feed the > precomputed lead fields and data into ft_sourceanalysis to find the > source-level power for each subject. > > > 1) DICS, but not eLORETA, returns extremely large results at certain > voxels. These extrema dominate the grand averages. In each subject, these > voxels are always at the edge of the cortex, near the skull. The voxel > locations are not exactly the same across subjects, but for any given > subject they tend to appear in one of a few locations (i.e. over the right > occipital cortex). The lead fields have the same magnitude (following > normalization) across all voxels. I did notice, however, that voxels at > which extreme values appear tend to have a larger condition number (~12) > than voxels at which abnormal values do not appear in any subject (~2). I > do not know whether this is relevant but I thought it might have some > effect on adaptive but not non-adaptive filters. Since I'm constructing the > forward model using FT templates, I thought someone else might have > encountered this problem before. > > > 2) As I mentioned above, eLORETA does not return such extreme results; > furthermore, when we contrast controls with schizophrenia patients using an > independent samples t-test with cluster control for multiple comparisons we > find significant differences between groups using eLORETA but not DICS. The > raw differences between the grand averages returned by DICS and eLORETA are > similar, but when we run stats using DICS most of the correct p values are > equal to 1 with one or two in the 0.8-0.9 range. I'm looking for converging > evidence between different source analysis methods and it's not clear to me > why DICS and eLORETA return such different results. > > > 3) I thought that voxels are which unusually large values occur in > controls and patients could be throwing off the stats; however, DICS does > not return significant contrasts between control and schizophrenia even > when I mask out the extreme voxels. > > > Thanks in advance for any advice. > > > Best, > > > Alexander > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Mon Aug 15 17:56:31 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Mon, 15 Aug 2016 15:56:31 +0000 Subject: [FieldTrip] Voxel Size Message-ID: Hi All, Sorry for putting up two posts in one day but these are different issues so I didn't want to cram them into one thread. How does FT determine the voxel size used in source analysis? Does it come from the resolution of the grid used to generate the lead fields or are there other factors? If the voxel size varies depending on the source localization parameters, does FT store this information? I'd like to be able to report the voxel size used for out analysis. Thank you, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From evergreenlifeyangying at gmail.com Mon Aug 15 21:21:59 2016 From: evergreenlifeyangying at gmail.com (Ying Yang) Date: Mon, 15 Aug 2016 15:21:59 -0400 Subject: [FieldTrip] Stimulus(trigger) as an output channel in the biosemi2ft? Message-ID: Dear FieldTrip Community, My name is Ying Yang and I am a PhD candidate in the Center for the Neural Basis of Cognition, Carnegie Mellon University. I am trying to do real-time EEG acquisition with our Biosemi system. I am used to EEG processing/analysis in python, and would like use the "mne-python" package with the FieldTrip acquisition tool "biosemi2ft". In some initial tests on our Windows 64 bit platform, I ran in cmd biosemi2ft config.txt outputfile - 1972 and used the client object in FieldTrip.py. It seemed to work well. However, it would be really convenient if the recorded data also included the stimulus channel (the trigger channel or "status" channel). I know I can get some info about the trigger events with FieldTrip.Client.getEvents(), but it is more convenient to actually have the trigger channel as one of the channels in the data. >From the limited documentation on http://www.fieldtriptoolbox.org/development/realtime/biosemi, I could not figure out whether it was possible to do so. When I ran "biosemi2ft" on our system, the prompt output said there were 280 channels. So I have customized "config.txt" to select all 280 channels, but none of them seemed to be the trigger channel. So I would like to ask the community if it is possible to record the trigger channel. And if yes, how should I specify it in the "config.txt" file. I will appreciate any input or comment. Thank you. Best, Ying -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Tue Aug 16 00:44:17 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Mon, 15 Aug 2016 22:44:17 +0000 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 14 In-Reply-To: References: Message-ID: Johannes, I understand now, at least about the dipole implementation. The rest should come as I work with FieldTrip some more. Thanks for your help, -Jeff Message: 11 Date: Fri, 12 Aug 2016 17:09:29 -0600 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 Message-ID: <41C233E2-F2D6-46A0-A9F3-0A317F1A82CD at googlemail.com> Content-Type: text/plain; charset=utf-8 I see. Your misunderstanding is that the dipoles are ?represented? through hexahedrons (and that you need to implement this ;-)). The idea that is usually used to derive FEM for EEG is to stick to the model of a dipole and to represent this dipole through the FEM basis functions. One method to do this (the ?Venant approach?) is already implemented in fieldtrip. The way this representation is achieved is described in the papers I mentioned. If you do not want to use a different approach here, no further work on your side is needed. What you refer to as a ?source model? is what I would call ?source space? (since ?source model? can be easily mixed up?). The source space can be defined just as you would do it for spheres and BEM in fieldtrip. To apply FEM, you have to indicate to fieldtrip to generate a hexahedral head model and ?simbio? as method of forward computation. Best, Johannes > Am 12.08.2016 um 16:53 schrieb K Jeffrey Eriksen : > > Johannes, > > I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. > > In my naive view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. > > I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. > > Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. > > Thanks, > -Jeff ************* From eriksenj at ohsu.edu Tue Aug 16 02:05:29 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Tue, 16 Aug 2016 00:05:29 +0000 Subject: [FieldTrip] importing Brainstorm head and source models and leftfields Message-ID: Hi, I am trying to do some forward and inverse simulations using a 3-shell BEM, and would prefer to import my model from Brainstorm where I have already created it. I can find one example of importing the cortical mesh from Brainstorm using ft_read_headshape with the 'matlab' format, but I cannot find anything on how to import the Brainstorm BEM head model or leadfield. Please point me to any further information on this topic, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Tue Aug 16 07:20:06 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Tue, 16 Aug 2016 05:20:06 +0000 Subject: [FieldTrip] importing Brainstorm head and source models and leftfields In-Reply-To: References: Message-ID: Hi Jeff, Probably this is not yet implemented. Since it is all matlab-based it should be pretty straightforward, once you know how the headmodel is represented in the Brainstorm .mat file. Once you have figured this out, it probably takes just a few lines of code in ft_read_headshape. If you have an updated version of this function, you can easily contribute it to the code-base for everyone’s use through git. How this can be done, is shown here: http://www.fieldtriptoolbox.org/development/git Best, Jan-Mathijs On 16 Aug 2016, at 02:05, K Jeffrey Eriksen > wrote: Hi, I am trying to do some forward and inverse simulations using a 3-shell BEM, and would prefer to import my model from Brainstorm where I have already created it. I can find one example of importing the cortical mesh from Brainstorm using ft_read_headshape with the ‘matlab’ format, but I cannot find anything on how to import the Brainstorm BEM head model or leadfield. Please point me to any further information on this topic, -Jeff _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Tue Aug 16 13:44:13 2016 From: julian.keil at gmail.com (Julian Keil) Date: Tue, 16 Aug 2016 13:44:13 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI In-Reply-To: References: Message-ID: <5B3236ED-05F6-41F3-9942-126116A25F9B@gmail.com> Hi Gabriel, have you tried using a grid with the exact same dimensions as the MRI, i.e.: %% Set the start and End of the x,y,z axis vox1 = mri.transform*[mri.dim,1]'; % start vox1 = vox1(1:3)/10; % convert to mm vox2 = mri.transform*[1,1,1,1]'; %end vox2 = vox2(1:3)/10; % convert to mm %% Choose the Minima vox_min = min([vox1,vox2]')'; vox_max = max([vox1,vox2]')'; %% Set the spacing vox_delta = abs(mri.transform*[1,1,1,1]'-mri.transform*[2,2,2,1]'); vox_delta = vox_delta(1:3)/10; % convert to mm RES = vox_delta(1); and then use: cfg.grid.xgrid = vox_min(1):RES:vox_max(1); cfg.grid.ygrid = vox_min(2):RES:vox_max(2); cfg.grid.zgrid = vox_min(3):RES:vox_max(3); Good luck, Julian Am 15.08.2016 um 17:46 schrieb gab dippel: > Dear Fieldtrippers, > > my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. > > So the goal is to compute the virtual channels of a certain atlas region let say the SMA. > As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. > > Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: > 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) > --> So here I construct an MRI based grid > > load standard_mri.mat > cfg = []; > cfg.mri = mri; > template_grid = ft_prepare_sourcemodel(cfg); > > this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. > > 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) > --> this is obsolete in my case i guess > > 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) > --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': > cfg = []; > cfg.grid.xgrid = -90:1:90; > cfg.grid.ygrid = -108:1:108; > cfg.grid.zgrid = -90:1:90; > cfg.grid.unit = 'mm'; > cfg.grid.tight = 'yes'; > cfg.mri = mri; > high_res_grid_mm = ft_prepare_sourcemodel(cfg) > > > 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) > --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. > > 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. > --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. > > I would appreciate any feedback and ideas on this issue. > > Kind regards, > > Gabriel > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From marco.rotonda at gmail.com Wed Aug 17 08:32:29 2016 From: marco.rotonda at gmail.com (Marco Rotonda) Date: Wed, 17 Aug 2016 08:32:29 +0200 Subject: [FieldTrip] FFT and filtering Message-ID: Hi Fieldtrippers, I had a quite simple question, even though I was not so sure how to respond. Let suppose I have an EEG raw signal and I'm interested on the mean amplitude of some bands (delta, theta, etc.). The signal is continuous so I take chunks of data (let say one second). Let suppose the signal is clean (no artifacts). Should I have to filter the signal before doing the FFT or I can just do the FFT of the signal and take the mean of the bands I'm interested on? Take care Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: From Gabriel.Dippel at uniklinikum-dresden.de Mon Aug 15 15:44:06 2016 From: Gabriel.Dippel at uniklinikum-dresden.de (Dippel, Gabriel) Date: Mon, 15 Aug 2016 13:44:06 +0000 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: <5C7F3323D8D9804D90AF6A7ED2611DE362F3D1E9@G06EDBN1.med.tu-dresden.de> Dear Fieldtrippers, my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. So the goal is to compute the virtual channels of a certain atlas region let say the SMA. As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) --> So here I construct an MRI based grid 
 load standard_mri.mat cfg = []; cfg.mri = mri; template_grid = ft_prepare_sourcemodel(cfg); this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) --> this is obsolete in my case i guess 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': cfg = []; cfg.grid.xgrid = -90:1:90; cfg.grid.ygrid = -108:1:108; cfg.grid.zgrid = -90:1:90; cfg.grid.unit = 'mm'; cfg.grid.tight = 'yes'; cfg.mri = mri; high_res_grid_mm = ft_prepare_sourcemodel(cfg) 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. I would appreciate any feedback and ideas on this issue. Kind regards, Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From ankanb06 at gmail.com Wed Aug 17 16:33:29 2016 From: ankanb06 at gmail.com (Ankan Biswas) Date: Wed, 17 Aug 2016 20:03:29 +0530 Subject: [FieldTrip] FFT and filtering In-Reply-To: References: Message-ID: *Hello Marco,* I think depending upon the sampling rate, you have set in the recording equipment, you may have a anti-aliasing filter. And as you don't know what are the frequency components in your signal before doing a fft, you may do a fft on the raw data which will give you the frequency components and then take the mean of the amplitude of the frequencies of the band you are interested in. Please correct *fieldtripers* if I am wrong. Thanks, Ankan On Wed, Aug 17, 2016 at 12:02 PM, Marco Rotonda wrote: > Hi Fieldtrippers, > I had a quite simple question, even though I was not so sure how to > respond. > Let suppose I have an EEG raw signal and I'm interested on the mean > amplitude of some bands (delta, theta, etc.). > The signal is continuous so I take chunks of data (let say one second). > Let suppose the signal is clean (no artifacts). > Should I have to filter the signal before doing the FFT or I can just do > the FFT of the signal and take the mean of the bands I'm interested on? > > Take care > > Marco > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Wed Aug 17 17:11:56 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Wed, 17 Aug 2016 15:11:56 +0000 Subject: [FieldTrip] Wavelet and time-frequency plot Message-ID: Hello All, I am trying to apply wavelet on my signal to see HFOs in time-frequency plot. The sampling rate of my signal is 30K. I will get an error: " Error using fft Out of memory. Type HELP MEMORY for your options. " here is what I wrote according to http://www.fieldtriptoolbox.org/reference/ft_freqanalysis: [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_freqanalysis - FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type "help ft_freqanalysis". FT_FREQANALYSIS performs ... cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; %cfg.channel = 'chan 4'; cfg.toi = (1:size(eeg.eeg_data,2))/Fs; % cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); Do you have any idea? is it realted to my sampling rate? Thanks! Bahar -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Wed Aug 17 17:24:25 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 17 Aug 2016 17:24:25 +0200 Subject: [FieldTrip] valid workaround for nonparametric stats on cortical surface data? Message-ID: Hello Fieldtrip community, ft_statistics_montecarlo fails when it is called through ft_sourcestatistics with cortical surface (as opposed to a 3D volumetric grid) source data. To avoid this limitation, I can change my source level time series avg.mom into a sensor data structure (my electrodes are simply 'virtual' then), provide the source level neighborhood structure, and run ft_timelockstatistics on my 'virtual sensor' data set. As far as I can tell, this effectively gives source level statistics, just through the wrong function, so to speak. Since I am reading that ft_statistics_montecarlo might behave differently depending on which function is calling it.... FT_STATISTICS_MONTECARLO should not be called directly, instead you should call the function that is associated with the type of data on which you want to perform the test. % Use as % stat = ft_timelockstatistics(cfg, data1, data2, data3, ...) % stat = ft_freqstatistics (cfg, data1, data2, data3, ...) % stat = ft_sourcestatistics (cfg, data1, data2, data3, ...) ...I wanted to know whether there are some additional things to be aware of when using ft_timelockstatistics on source level virtual electrode time series. Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From V.Peter at westernsydney.edu.au Thu Aug 18 05:10:11 2016 From: V.Peter at westernsydney.edu.au (Varghese Peter) Date: Thu, 18 Aug 2016 03:10:11 +0000 Subject: [FieldTrip] Issues with trial by trial bad channel rejection Message-ID: <617B8E9395E43D47B7479C8FB3185E755320908C@hall.AD.UWS.EDU.AU> Dear fieldtrip community, I have 128 channel EEG data collected from young infants in an ERP paradigm. Since the EEG data from young infants are noisier than adults, I tried to implement a trial by trial bad channel correction. If a trial has more than 20 bad channels, reject the trial altogether and if the number of bad channels are less than 20, interpolate the bad channels. I have implemented this using the following script. It seems to work, but when I load the file after this step, it takes a long time to load it (up to 20 minutes) and all subsequent processing takes very long time. Is there a way to fix this? Thank you, Varghese indx=1; BadChannelCriterion=100; AllTrialsBadChannelLabels={}; datr={}; TrialNos=[]; for loop =1:length(I09_ADSStd_epochs2.trial), AllTrialsBadchannelIndex = find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion); SingleTrialBadChannelLabels= I09_ADSStd_epochs2.label(AllTrialsBadchannelIndex ); AllTrialsBadChannelLabels= [AllTrialsBadChannelLabels; SingleTrialBadChannelLabels]; if length(find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion))<20, BadchannelIndex = find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion); BadchannelLabels=I09_ADSStd_epochs2.label(BadchannelIndex); cfg = []; cfg.layout= lay; cfg.badchannel = BadchannelLabels; cfg.method = 'spline'; cfg.neighbours = EEG_neighbours; cfg.trials = loop; datr{indx} = ft_channelrepair(cfg,I09_ADSStd_epochs2); TrialNos(indx)=loop; indx=indx+1; end end cfg = []; I09_ADSStd_epochs_clean = ft_appenddata(cfg, datr{:}); -------------- next part -------------- An HTML attachment was scrubbed... URL: From k.kessler at aston.ac.uk Fri Aug 19 12:39:33 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Fri, 19 Aug 2016 10:39:33 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham’s focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Professor Klaus Kessler Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From pooneh.baniasad at gmail.com Sun Aug 21 11:40:43 2016 From: pooneh.baniasad at gmail.com (pooneh baniasad) Date: Sun, 21 Aug 2016 14:10:43 +0430 Subject: [FieldTrip] The compartment nesting cannot be determined Message-ID: Dear FieldTrip community, I'm Pouneh baniasad and I'm working with FieldTrip due to my thesis. I've just read the conversation with this title in the FieldTrip listing mail but it didn't answer completely. I segmented the "Subject01.mri" into four slices as {'gray','csf','skull','scalp'}. After preparing mesh when I wanted to use ft_prepare_headmodel i got this error: "The compartment nesting cannot be determined". Furthermore I use BEM method for calculating. My nesting matrix and numboundries are as follows: numboundaries = 4 nesting = [0, 0, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1; 0, 0, 0, 0] ​I know the nesting matrix is not correct but don't have any idea what should i do. -- Bests Pouneh Baniasad -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Mon Aug 22 17:24:29 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Mon, 22 Aug 2016 15:24:29 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter Message-ID: Dear Fieldtrip Users, I am trying to compute non-parametric granger causality between several ROIs in source-space. I am using the following code to obtain the fourier-spectra of my sensor-level data. cfg = []; cfg.output = 'fourier'; cfg.method = 'mtmfft'; cfg.taper = 'dpss'; cfg.tapsmofrq = 4; cfg.keeptrials = 'yes'; cfg.pad = 1; cfg.padtype = 'zero'; freq = ft_freqanalysis(cfg, data_fix); I was wondering how to project the sensor level fourier-data into source space using the spatial filters computed when calling ft_sourceanalysis? I.e. how to multiply the freq*filter? I am little unsure how the fourierspctrm is represented and how this will feed into ft_connectivity analysis? Many thanks, Robert Seymour (PhD Student, Aston Brain Centre) -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Mon Aug 22 21:50:26 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Mon, 22 Aug 2016 19:50:26 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter In-Reply-To: References: Message-ID: <250771CD-30C7-451D-B7C7-EDE9C622FEEB@donders.ru.nl> Hi Robert, In principle it’s OK, and computationally efficient, to (left)-multiply the spatial filter with the fourier coefficients (in a for-loop across frequencies, or something like that), to get the source-level fourier representation. Practically, you would need to do something like: nchan = numel(freq.label); nfreq = numel(freq.freq); nrpttap = size(freq.fourierspctrm,1); fourier_source = filter*reshape(permute(freq.fourierspctrm,[2 3 1]), [nchan nfreq*nrpttap])); fourier_source = reshape(fourier_source, [nfreq nrpttap]); Now you have a nfreq*nrpttap matrix that represents per tapered data segment the fourierspctrm. From this representation, you would want to create the source pair-wise cross-spectral density that can be subjected to the non-parametric factorization code to compute Granger causality. That is, it’s more or less OK if you know what you’re doing, but can become tricky in terms of correct data administration/bookkeeping. Otherwise, and perhaps more straightforwardly, I’d recommend to do a time-domain source reconstruction (create a set of ‘virtual channels’, there’s are some examples in the wiki’s tutorials how to do it), and then use ft_freqanalysis and ft_connectivityanalysis on the virtual channel data. Best wishes, Jan-Mathijs On 22 Aug 2016, at 17:24, Seymour, Robert (Research Student) > wrote: Dear Fieldtrip Users, I am trying to compute non-parametric granger causality between several ROIs in source-space. I am using the following code to obtain the fourier-spectra of my sensor-level data. cfg = []; cfg.output = 'fourier'; cfg.method = 'mtmfft'; cfg.taper = 'dpss'; cfg.tapsmofrq = 4; cfg.keeptrials = 'yes'; cfg.pad = 1; cfg.padtype = 'zero'; freq = ft_freqanalysis(cfg, data_fix); I was wondering how to project the sensor level fourier-data into source space using the spatial filters computed when calling ft_sourceanalysis? I.e. how to multiply the freq*filter? I am little unsure how the fourierspctrm is represented and how this will feed into ft_connectivity analysis? Many thanks, Robert Seymour (PhD Student, Aston Brain Centre) _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruil3 at student.unimelb.edu.au Tue Aug 23 08:49:57 2016 From: ruil3 at student.unimelb.edu.au (Rui Li) Date: Tue, 23 Aug 2016 16:49:57 +1000 Subject: [FieldTrip] A Problem using cfg.channel = {'MEG'} and ft_preprocessing Message-ID: Dear fieldtrip users, I downloaded the fieldtrip toolbox: fieldtrip-20160820; cfg = []; cfg.dataset = dataset; cfg.channel = {'MEG'}; data = ft_preprocessing(cfg); The 'label' field in data is an empty cell, which leads to the mistakes in the following processing. I am wondering do you found the same problem? Is this a bug? Regards, Rui. -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Tue Aug 23 11:10:35 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Tue, 23 Aug 2016 09:10:35 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter Message-ID: Thanks Jan-Mathijs, I'll try that. I've actually implemented your second suggestion (averaging over virtual electrodes and then calculating fourier/CSD) - do you think there would be any major difference between the two approaches? Cheers, Rob -------------- next part -------------- An HTML attachment was scrubbed... URL: From k.kessler at aston.ac.uk Tue Aug 23 11:59:10 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Tue, 23 Aug 2016 09:59:10 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham's focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Klaus Kessler (Professor of Cognitive Neuroscience) Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From haristz at umn.edu Wed Aug 24 04:05:56 2016 From: haristz at umn.edu (Haris Tzagarakis) Date: Tue, 23 Aug 2016 21:05:56 -0500 Subject: [FieldTrip] cluster statistics on dynamic ROI Message-ID: <57BD0104.1020204@umn.edu> Dear Fieldtripers, I have a question about cluster-based statistics at the source level using an ROI. The option cfg.roi exists in ft_sourceanalysis but requires the use of atlas anatomic labels. My case is slightly different in that I have an ROI defined dymamically by a prior source level analysis and I want to evaluate source level statistics only within the voxels of that ROI for a different parameter. I ended up creating volumes with the appropriate dimensions and setting all the volume array values for the parameter I want to test to NaN except for the voxels of the ROI. I also set up the "inside" field to contain the index values of the ROI voxels only. This seems to work when using cfg.correctm = 'cluster' (which is what I want) but was wondering if anyone can see a potential problem that I might be missing? With Best Wishes Haris -- Charidimos [Haris] Tzagarakis MD, PhD, MRCPsych University of Minnesota Dept of Neuroscience office: Brain Sciences Center Minneapolis VA Medical Center Tel:612-467-1363 From k.kessler at aston.ac.uk Wed Aug 24 15:11:53 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Wed, 24 Aug 2016 13:11:53 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: <52122e491dc744b2ba985d9d8fe45306@EXPRD03.hosting.ru.nl> Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham’s focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Klaus Kessler (Professor of Cognitive Neuroscience) Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From joseluisblues at gmail.com Wed Aug 24 18:04:07 2016 From: joseluisblues at gmail.com (Jose) Date: Wed, 24 Aug 2016 18:04:07 +0200 Subject: [FieldTrip] on spectral analysis of MEG data Message-ID: dear Fieldtrip community, I'm performing analysis of CTF MEG data. I have two conditions of interest: A and B, and I have performed spectral decomposition with the wavelet method to obtain the power (frequencies from 6 to 50 Hz). I have some questions regarding my analysis: 1. As a first approach I wanted to do analysis at the sensor level and then to move at the source level. This is a rather exploratory analysis. I have noted oscillatory activity when analysing ERFs, so I decided to perform spectral analysis but I don't have any a priori hypothesis about any frequency or sensor. I'm using a cluster-based permutation (CBP) test to evaluate significance, but I'm not sure how to do a multi-sensor analysis. Since I have computed the power from frequencies ranging from 6 to 50 Hz, I could perform a CBP test for each frequency, but this would become a multiple comparison problem isn't? Otherwise what I have see in some publications is to average across sensors, and do a permutation test similar to what is done in single-sensor analysis, 2. I have performed spectral analysis of my data for magnetometers and gradiometers. I was wondering if I should expect the same results for both magnetometers and gradiometers. Since the activity of the planar gradient do not cover the same sensors than the magnetometers I wouldn't expect it. However, perhaps the effects should fall within the same frequency boundaries? 3. I was wondering why in the "Within subjects experiments" example of the tutorial "Cluster-based permutation tests on time-frequency data" ( http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) the cfg.alpha is set to 0.025. Since the data are planar gradients, thus positive values, one would need to perform a one-side test, and thus an alpha of 0.05? Maybe in this case the data was baseline corrected and thus one would then have positive and negative values, might that be the case? As a general question, if I'm working with planar gradient data, I should need differentially set my alpha value regarding if is baseline-corrected or not, is that correct? 4. I have seen some publications that include an additional correction to the analysis after performing a permutation test. For instance, Busch et al (J Neurosc 2009) use a resampling test and the FDR method to test significance of differences in power in the Fz channel. The general question is when one can apply only a resampling/permutation test, and when one have to include a correction like FDR? Thanks in advance, Jose -------------- next part -------------- An HTML attachment was scrubbed... URL: From nugenta at mail.nih.gov Wed Aug 24 18:11:00 2016 From: nugenta at mail.nih.gov (Nugent, Allison C. (NIH/NIMH) [E]) Date: Wed, 24 Aug 2016 16:11:00 +0000 Subject: [FieldTrip] NIH MEG Workshop Message-ID: Reminder! A call for abstracts is currently open! We are soliciting abstracts based on the four themes for discussion below, as well as for a general scientific session. Visit http://megworkshop.nih.gov for more details. The abstract deadline has been extended to September 15st. At this meeting, we plan to address the following four themes: 1. What does MEG add to the field of neuroscience above and beyond other existing techniques? 2. How can we support the evolution of MEG acquisition and methods, through both software and hardware? 3. How can we develop and support infrastructure to share data and facilitate big science? 4. How could an MEG-North America consortium work to address these issues? Keynote Speakers: Sylvain Baillet, PhD, Director, MEG Core McGill University, McConnell Brain Imaging Center Dimitrios Pantazis, PhD, Director of MEG Lab, Martinos Imaging Center Timothy P. Roberts, PhD, Vice Chair of Research, Department of Radiology, The Children's Hospital of Philadelphia Julia M. Stephen, PhD, Director, MEG/EEG Core, The Mind Research Network For more details, visit http://megworkshop.nih.gov Registration to this NIH sponsored event is free of charge. We hope to see you in Bethesda in November! Dr. Richard Coppola, Director, NIMH MEG Core Dr. Allison C Nugent, Director of Neuroimaging Research, Experimental Therapeutics and Pathophysiology Branch, NIMH Register Now at Eventbrite! Allison Nugent, PhD Director of Neuroimaging Research Experimental Therapeutics and Pathophysiology Branch NIMH/NIH/DHHS Ph 301-451-8863 -------------- next part -------------- An HTML attachment was scrubbed... URL: From russgport at gmail.com Wed Aug 24 18:45:49 2016 From: russgport at gmail.com (Russell Port) Date: Wed, 24 Aug 2016 12:45:49 -0400 Subject: [FieldTrip] NIH MEG Workshop In-Reply-To: References: Message-ID: Will you pay for me to go to this? Sent from my iPhone > On Aug 24, 2016, at 12:11 PM, Nugent, Allison C. (NIH/NIMH) [E] wrote: > > Reminder! > > A call for abstracts is currently open! We are soliciting abstracts based on the four themes for discussion below, as well as for a general scientific session. Visit http://megworkshop.nih.gov for more details. The abstract deadline has been extended to September 15st. > > At this meeting, we plan to address the following four themes: > > 1. What does MEG add to the field of neuroscience above and beyond other existing techniques? > 2. How can we support the evolution of MEG acquisition and methods, through both software and hardware? > 3. How can we develop and support infrastructure to share data and facilitate big science? > 4. How could an MEG-North America consortium work to address these issues? > > Keynote Speakers: > > Sylvain Baillet, PhD, Director, MEG Core McGill University, McConnell Brain Imaging Center > Dimitrios Pantazis, PhD, Director of MEG Lab, Martinos Imaging Center > Timothy P. Roberts, PhD, Vice Chair of Research, Department of Radiology, The Children’s Hospital of Philadelphia > Julia M. Stephen, PhD, Director, MEG/EEG Core, The Mind Research Network > > For more details, visit http://megworkshop.nih.gov > > Registration to this NIH sponsored event is free of charge. > > We hope to see you in Bethesda in November! > > Dr. Richard Coppola, Director, NIMH MEG Core > Dr. Allison C Nugent, Director of Neuroimaging Research, Experimental Therapeutics and Pathophysiology Branch, NIMH > > Register Now at Eventbrite! > > > Allison Nugent, PhD > Director of Neuroimaging Research > Experimental Therapeutics and Pathophysiology Branch > NIMH/NIH/DHHS > Ph 301-451-8863 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 26 01:49:14 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Thu, 25 Aug 2016 23:49:14 +0000 Subject: [FieldTrip] errors while trying to run beamformer tutorial Message-ID: I am trying to learn how to apply the LCMV beamformer to EEG data. To that end I am starting to go through this tutorial: http://www.fieldtriptoolbox.org/tutorial/beamformer_lcmv?s[]=lcmv I downloaded the data from this link: The ft_definetrial and ft_preprocessing functions require the original MEG dataset, which is available from ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/tutorial/SubjectSEF.zip. Then I tried this code: % find the interesting segments of data cfg = []; cfg.dataset = 'SubjectSEF.ds'; cfg.trialdef.eventtype = 'Blue'; cfg.trialdef.prestim = .1; % .1 sec prior to trigger cfg.trialdef.poststim = .2; % .2 sec following trigger cfg.continuous = 'yes'; cfg = ft_definetrial(cfg); and got this output: Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In dataset2files (line 42) In ft_checkconfig (line 557) In ft_definetrial (line 131) In fieldtrip_test_lcmv (line 13) Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' Error using ft_read_header (line 2248) unsupported header format "unknown" Error in ft_trialfun_general (line 78) hdr = ft_read_header(cfg.headerfile, 'headerformat', cfg.headerformat); Error in ft_definetrial (line 177) [trl, event] = feval(cfg.trialfun, cfg); Error in fieldtrip_test_lcmv (line 13) cfg = ft_definetrial(cfg); So I am totally lost here. Any suggestions? Thanks, -Jeff Eriksen -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 26 07:36:49 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 26 Aug 2016 05:36:49 +0000 Subject: [FieldTrip] errors while trying to run beamformer tutorial In-Reply-To: References: Message-ID: <931E197F-6020-4237-90ED-67E105B06151@donders.ru.nl> Hi Jeff, I assume that you have unzipped the data, and have the data (i.e. the ‘SubjectSEF.ds’) in directoryX. You need to specify the full path to the data in cfg.dataset (or your current working directory should be directoryX), i.e. cfg.dataset = ‘directoryX/SubjectSEF.ds’; Hope this helps, Jan-Mathijs On 26 Aug 2016, at 01:49, K Jeffrey Eriksen > wrote: I am trying to learn how to apply the LCMV beamformer to EEG data. To that end I am starting to go through this tutorial: http://www.fieldtriptoolbox.org/tutorial/beamformer_lcmv?s[]=lcmv I downloaded the data from this link: The ft_definetrial and ft_preprocessing functions require the original MEG dataset, which is available from ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/tutorial/SubjectSEF.zip. Then I tried this code: % find the interesting segments of data cfg = []; cfg.dataset = 'SubjectSEF.ds'; cfg.trialdef.eventtype = 'Blue'; cfg.trialdef.prestim = .1; % .1 sec prior to trigger cfg.trialdef.poststim = .2; % .2 sec following trigger cfg.continuous = 'yes'; cfg = ft_definetrial(cfg); and got this output: Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In dataset2files (line 42) In ft_checkconfig (line 557) In ft_definetrial (line 131) In fieldtrip_test_lcmv (line 13) Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' Error using ft_read_header (line 2248) unsupported header format "unknown" Error in ft_trialfun_general (line 78) hdr = ft_read_header(cfg.headerfile, 'headerformat', cfg.headerformat); Error in ft_definetrial (line 177) [trl, event] = feval(cfg.trialfun, cfg); Error in fieldtrip_test_lcmv (line 13) cfg = ft_definetrial(cfg); So I am totally lost here. Any suggestions? Thanks, -Jeff Eriksen _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From christine.blume at sbg.ac.at Fri Aug 26 15:09:06 2016 From: christine.blume at sbg.ac.at (Blume Christine) Date: Fri, 26 Aug 2016 13:09:06 +0000 Subject: [FieldTrip] ft_clusterplot with 3D clusters from ft_freqstatistics Message-ID: Dear community, Following TF analysis I am using ft_freqstatistics for a cluster-based permutation test. Subsequently, I would like to review significant clusters using ft_clusterplot. That works very well as long as my input to ft_freqstatistics is only 2D (channels x frequencies). However, when I include time, the call to ft_clusterplot results in an error message telling me that either time or frequency needs to be a singleton dimension. Unfortunately, I do not find anything in the FT documentation on this issue. Is there a recommendable way to use ft_clusterplot with 3D clusters, i.e. channel x freq x time clusters? Best, Christine -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 26 23:54:09 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 26 Aug 2016 21:54:09 +0000 Subject: [FieldTrip] Localizing sources using beamformer techniques web tutorial Message-ID: Jan-Mathijs, Your path suggestion got me going, thanks. I then encountered some other errors as I went further along in the tutorial. The one that stopped me was the last listed below, #5. I do not know if I have the folders and files set up right, so have included a screenshot of how they appear on my computer. In particular it seems that SubjectSEF.ds appears to be a folder at some times, and a file at others. -Jeff 1. cfg = ft_definetrial(cfg); -> Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' reading the events from 'E:\Staff\Jeff\Jeff_Matlab\FieldTrip_KJE\data\SubjectSEF\SubjectSEF.ds\SubjectSEF.res4' found 7826 events created 204 trials the call to "ft_definetrial" took 8 seconds 2. cfg.neighbours = ft_prepare_neighbours(cfg, timelock); -> clicking on sensor did NOT show its label 3. timelock_planar = ft_megplanar(cfg, timelock); -> the input is timelock data with 274 channels and 360 timebins Warning: the trial definition in the configuration is inconsistent with the actual data > In ft_warning (line 184) In fixsampleinfo (line 68) In ft_datatype_raw (line 175) In ft_checkdata (line 362) In ft_megplanar (line 98) In fieldtrip_test_lcmv (line 49) Warning: reconstructing sampleinfo by assuming that the trials are consecutive segments of a continuous recording > In ft_warning (line 184) In fixsampleinfo (line 79) In ft_datatype_raw (line 175) In ft_checkdata (line 362) In ft_megplanar (line 98) In fieldtrip_test_lcmv (line 49) the call to "ft_selectdata" took 0 seconds average number of neighbours is 7.35 minimum distance between neighbours is 2.00 cm maximum distance between gradiometers is 4.41 cm Warning: copying input chanunit to montage > In ft_apply_montage (line 120) In ft_megplanar (line 325) In fieldtrip_test_lcmv (line 49) the call to "ft_megplanar" took 2 seconds 4. vol = ft_prepare_headmodel(cfg, seg); -> Warning: please specify cfg.method='projectmesh', 'iso2mesh' or 'isosurface' > In ft_prepare_mesh (line 138) In ft_prepare_headmodel (line 348) In fieldtrip_test_lcmv (line 80) Warning: using 'projectmesh' as default > In ft_prepare_mesh (line 139) In ft_prepare_headmodel (line 348) In fieldtrip_test_lcmv (line 80) triangulating the outer boundary of compartment 1 (brain) with 3000 vertices the call to "ft_prepare_mesh" took 4 seconds the call to "ft_prepare_headmodel" took 4 seconds 5. hdr = ft_read_header('SubjectSEF.ds'); -> Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In ft_read_header (line 159) In fieldtrip_test_lcmv (line 84) Error using ft_read_header (line 2248) unsupported header format "unknown" Error in fieldtrip_test_lcmv (line 84) hdr = ft_read_header('SubjectSEF.ds'); Message: 2 Date: Fri, 26 Aug 2016 05:36:49 +0000 From: "Schoffelen, J.M. (Jan Mathijs)" To: FieldTrip discussion list Subject: Re: [FieldTrip] errors while trying to run beamformer tutorial Message-ID: <931E197F-6020-4237-90ED-67E105B06151 at donders.ru.nl> Content-Type: text/plain; charset="utf-8" Hi Jeff, I assume that you have unzipped the data, and have the data (i.e. the ?SubjectSEF.ds?) in directoryX. You need to specify the full path to the data in cfg.dataset (or your current working directory should be directoryX), i.e. cfg.dataset = ?directoryX/SubjectSEF.ds?; Hope this helps, Jan-Mathijs -------------- next part -------------- A non-text attachment was scrubbed... Name: FT_data_folder.JPG Type: image/jpeg Size: 36806 bytes Desc: FT_data_folder.JPG URL: From dippel.g at gmail.com Mon Aug 29 13:03:50 2016 From: dippel.g at gmail.com (Gabriel Dippel) Date: Mon, 29 Aug 2016 13:03:50 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: Dear Julian, thanks for your help! With some minor changes it finally worked out with the following code: vox1 = mri_cm.transform*[mri_cm.dim,1]'; % start vox1 = vox1(1:3)*10; % convert to mm vox2 = mri_cm.transform*[1,1,1,1]'; %end vox2 = vox2(1:3)*10; % convert to mm % Choose the Minima vox_min = min([vox1,vox2]')'; vox_max = max([vox1,vox2]')'; % Set the spacing vox_delta = abs(mri_cm.transform*[1,1,1,1]'-mri_cm.transform*[2,2,2,1]'); vox_delta = vox_delta(1:3)*10; % convert to mm RES = vox_delta(1); cfg = []; %cfg.inwardshift = -0.5; cfg.grid.xgrid = vox_min(1):RES:vox_max(1)+1; cfg.grid.ygrid = vox_min(2):RES:vox_max(2)+1; cfg.grid.zgrid = vox_min(3):RES:vox_max(3)+1; cfg.grid.tight = 'no'; template_grid_mm = ft_prepare_sourcemodel(cfg, vol_mm); Cheers Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From markus.gschwind at gmail.com Mon Aug 29 16:54:00 2016 From: markus.gschwind at gmail.com (Markus Gschwind) Date: Mon, 29 Aug 2016 16:54:00 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? Message-ID: Dear EEGers, We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). We came across the Zebris system http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php Is there anyone who has experience with this? Thank you in advance, Best, Markus -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Mon Aug 29 17:02:47 2016 From: julian.keil at gmail.com (Julian Keil) Date: Mon, 29 Aug 2016 17:02:47 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: Message-ID: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Dear Markus, we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. I'd say it takes no more than 10 minutes per subject. Let me know if you need more info, Julian Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > Dear EEGers, > > We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). > > We came across the Zebris system > http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php > > Is there anyone who has experience with this? > > Thank you in advance, > Best, > Markus > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From markus.gschwind at gmail.com Mon Aug 29 21:57:21 2016 From: markus.gschwind at gmail.com (Markus Gschwind) Date: Mon, 29 Aug 2016 21:57:21 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: Hi Julain, Thanks for that input. With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? Thanks in advance! Best, Markus 2016-08-29 17:02 GMT+02:00 Julian Keil : > Dear Markus, > > we use the Polhemus Patriot together with the BrainStrom toolbox for our > 128-channel EEG caps. > Once you get it set up and all quirks worked out (e.g. using a > serial-to-USB converter instead of just the USB-connection), it works quite > fast and without problems. > I'd say it takes no more than 10 minutes per subject. > > Let me know if you need more info, > > Julian > > Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > > Dear EEGers, > > We would like to get in contact with people having experience with > electrode positioning systems,which can be used in a reasonable amount of > time (especially with patients), and on high-density caps (we use EGI 256 > channels). > > We came across the Zebris system > http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php > > Is there anyone who has experience with this? > > Thank you in advance, > Best, > Markus > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorn at artinis.com Tue Aug 30 09:02:09 2016 From: jorn at artinis.com (=?utf-8?Q?J=C3=B6rn_M._Horschig?=) Date: Tue, 30 Aug 2016 09:02:09 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: <004901d2028c$6d3c96d0$47b5c470$@artinis.com> Hi Markus, The fastest digitization method I saw up to date is this one: http://www.brainproducts.com/productdetails.php?id=60 - I hope no one from my company sees this mail ;) However it only works with the BrainProducts Acticap and is quite pricy. Commercially, there are two types of product available. One type are devices similar to Zebris, that would be e.g. xensor from ANT, EEG Pinpoint from Localite and BrainProduct should also have one. They are usually in the price range of around 15k€ and imho a big overkill if you are just interested in localizing the electrodes. They all work with using an (infrared) camera to track the position of a pin pointing device. Their actual use for realtime neuronavigation with TMS, but they can be utilized also for stationary, one-time tracking of electrode positions. A cheaper option are the Polhemus devices, where the Patriot is the cheapest one (but still with a relatively good accuracy) of 1.5mm RMS at a sampling rate of 60Hz (yes, we also sell these with our devices, that’s why I know). Polhemus works with creating an electromagnetic field and measuring the position of a sensor within this field. The disadvantage with the Polhemus devices is that there is no proprietary software for electrode digitization. We built our own integration in our software, which is possible because Polhemus makes an SDK available (but we are a NIRS company, so no option for you). There are also some Matlab codes flying around the world wide web for EEG digitization. All in all, they are however not extremely user friendly and/or stable (imho, but I might have high standards). Despite the differences in the technique (camera vs. electromagnetic field), price and software, both require the same amount of manual labour: ticking each electrode manually and continuing to the next one. Only the BrainProducts solution mentioned above works differently. There are several other ideas and papers out there, but nothing that is commercially available in a package. Btw, I just googled, EGI has a similar system as ANT, Localite and Brain Products: https://www.egi.com/clinical-division/clinical-division-clinical-products/ges-400-series I have no experience with this and never saw it in action. But, all companies should be willing to come over to give you a demo of their device (we would, but again, wrong modality). So, just drop them a mail stating your problem (and available budget!) and they will contact you and most likely suggest a demo (otherwise, ask them). I hope this helps! Best, Jörn -- Jörn M. Horschig, PhD, Software Engineer & Project Leader NeuroGuard XS Artinis Medical Systems | +31 481 350 980 From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Markus Gschwind Sent: Monday, August 29, 2016 21:57 To: FieldTrip discussion list Subject: Re: [FieldTrip] Best EEG electrode positioning system? Hi Julain, Thanks for that input. With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? Thanks in advance! Best, Markus 2016-08-29 17:02 GMT+02:00 Julian Keil >: Dear Markus, we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. I'd say it takes no more than 10 minutes per subject. Let me know if you need more info, Julian Am 29.08.2016 um 16:54 schrieb Markus Gschwind: Dear EEGers, We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). We came across the Zebris system http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php Is there anyone who has experience with this? Thank you in advance, Best, Markus _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Tue Aug 30 11:26:58 2016 From: julian.keil at gmail.com (Julian Keil) Date: Tue, 30 Aug 2016 11:26:58 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: Hi Markus, in our setup, we mount the source on a tripod that is positioned behind the subject. We then attach the reference sensor to the forehead (this corrects for movements of the subject) and mark the single electrodes with the stylus. Thus, the head of the subject does not need to be fixed, as long as the source is not moved. I'm not sure what is included in the 2800 $ but here's what we use: * Polhemus Patriot * 1x Stylus (Sensor 1) * 1x Reference (Sensor 2) * 1x Source * Serial Cable Additionally we use: * Serial-to-USB Converter * BrainStorm Toolbox for Matlab (Free after registration from: http://neuroimage.usc.edu/brainstorm/) The Polhemus Software (I think it's included) can be useful for basic troubleshooting, such as checking if there is a connection to the PC, but is not needed otherwise. Cheers, Julian Am 29.08.2016 um 21:57 schrieb Markus Gschwind: > Hi Julain, > > Thanks for that input. > > With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? > > On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? > > Thanks in advance! > Best, Markus > > > > > > 2016-08-29 17:02 GMT+02:00 Julian Keil : > Dear Markus, > > we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. > Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. > I'd say it takes no more than 10 minutes per subject. > > Let me know if you need more info, > > Julian > > Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > >> Dear EEGers, >> >> We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). >> >> We came across the Zebris system >> http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php >> >> Is there anyone who has experience with this? >> >> Thank you in advance, >> Best, >> Markus >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From andrejakosticln at gmail.com Tue Aug 30 13:37:34 2016 From: andrejakosticln at gmail.com (=?UTF-8?Q?Andreja_Kosti=C4=87?=) Date: Tue, 30 Aug 2016 13:37:34 +0200 Subject: [FieldTrip] Which units are used for the "dippos" argument in ft_compute_leadfield and friends? Message-ID: Hello everyone! Background: I'm using ft_dipolesimulation to generate a simulated EEG from dipoles in specific locations inside of a brain. I'm using a BEM volume conduction model made with dipoli. Since I want specific locations inside of the brain, I need a way to specify where they actually are. Problem: Going through the ft_dipolesimulation, I was unable to find an explanation about which units I'm supposed to use. I do see that the position argument is passed on to ft_compute_leadfield. Going through the ft_compute_leadfield, I see that, in my specific case, the position will be passed onto eeg_leadfieldb, which then passes it on to inf_medium_leadfield which does the actual calculation. However, when I was reading inf_medium_leadfield, I couldn't figure out which units are being used there. Since ft_compute_leadfield seems to be commonly used function, I was wondering if anyone could tell me which measurement units are used for the dippos argument in it. All the best, Andreja Kostić -------------- next part -------------- An HTML attachment was scrubbed... URL: From marco.rotonda at gmail.com Wed Aug 31 22:35:45 2016 From: marco.rotonda at gmail.com (Marco Rotonda) Date: Wed, 31 Aug 2016 22:35:45 +0200 Subject: [FieldTrip] Strange plots with ft_clusterplot Message-ID: Hi there, I'm trying to plot some data but I have some strange behaviour not from ft_clusterplot, but from ft_topoplotTFR. I ran the code on matlab 2015b and 2016a, fiedtrip version of 30/08 and 01/06 I mean it seems that the configuration options of ft_clusterplot are taken fine, while the options of ft_topoplotTFR (like the colormap!) is not. Seems like a problem of Axes. I've exaggerated a bit the configuration to have a better idea. Here is the code: cfg = []; cfg.alpha = 0.05; cfg.parameter = 'stat'; % cfg.interactive = 'yes'; cfg.highlightcolorpos =[255 255 255]; cfg.layout = 'easycapM11.mat'; % cfg.maskparameter = 1; cfg.colorbar = 'yes'; cfg.zlim = [-9 18]; cfg.shading = 'interp'; cfg.gridscale = 300; cfg.contournum = 10; cfg.colormap = gray(10); cfg.markersymbol = '.'; cfg.markersize = 12; cfg.markercolor = [0 0.69 0.94]; cfg.subplotsize = [1 1]; cfg.marker = 'on'; cfg.highlight = 'on'; ft_clusterplot(cfg, statdelta); Here the console log: >> plot_cluster the input is freq data with 30 channels, 1 frequencybins and no timebins Warning: The field cfg.highlight is forbidden, it will be removed from your configuration > In ft_checkconfig (line 208) In ft_clusterplot (line 82) In plot_cluster (line 20) reading layout from file easycapM11.mat the call to "ft_prepare_layout" took 0 seconds There are 6 clusters smaller than alpha (0.05) Negative cluster: 1, pvalue: 0.00019996 (*), f = 2.4414 to 2.4414 Negative cluster: 2, pvalue: 0.00079984 (*), f = 2.4414 to 2.4414 Negative cluster: 3, pvalue: 0.0091982 (*), f = 2.4414 to 2.4414 Negative cluster: 4, pvalue: 0.015797 (x), f = 2.4414 to 2.4414 Negative cluster: 5, pvalue: 0.017596 (x), f = 2.4414 to 2.4414 Negative cluster: 6, pvalue: 0.04819 (x), f = 2.4414 to 2.4414 making subplot 1 from 1 the call to "ft_clusterplot" took 2 seconds >> Here the result: [image: Immagine incorporata 1] Any Idea? Thanks in advance Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 1.png Type: image/png Size: 69210 bytes Desc: not available URL: From pooneh.baniasad at gmail.com Mon Aug 1 10:17:08 2016 From: pooneh.baniasad at gmail.com (pooneh baniasad) Date: Mon, 1 Aug 2016 12:47:08 +0430 Subject: [FieldTrip] Generating EEG & Source model function Message-ID: Dear FieldTrip community, ​ ​I'm trying to generate EEG signal without using raw datas. I used the 'Subject01.mri' as my anatomical model, the BEM method for preparing a headmodel and 'standard_1020.elc' for aligning electrodes. For a source model I loaded template grid (cortex_20484.surf.gii). Now my questions are how can I set dipole's location (in other words, my grid's resolution)? How can I allocate a source model (sin, cos, ...) to each dipole? Is there any function in Fieldtrip doing that? or I have to writing the code by myself. After having the source model for each dipole and calculating leadfield matrix what should I do for plotting the EEG signal? -- Bests Pouneh Baniasad -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrejakosticln at gmail.com Mon Aug 1 15:41:17 2016 From: andrejakosticln at gmail.com (=?UTF-8?Q?Andreja_Kosti=C4=87?=) Date: Mon, 1 Aug 2016 15:41:17 +0200 Subject: [FieldTrip] Generating EEG & Source model function In-Reply-To: References: Message-ID: Hello Pouneh Baniasad, I had a similar issue some time ago, and found my solution within Fieldtrip, so I might be able to offer a bit of advice. There is a function for in Fieldtrip that will (partially) allow you to simulate dipoles. It's called ft_dipolesimulation.m. Unfortunately, in its current state, it only allows you to simulate 1 dipole. It does have quite a bit potential, however, since the function seems to be originally intended to work with multiple dipoles, but in its current implementation, it will not actually cycle through multiple dipoles and will crash if you give it more than 1. The function will allow you to set frequency, phase, amplitude, sample rate, orientation vector etc. for the dipoles but I didn't test how that works for more than one dipole, since I used externally generated data as my dipole waveforms. With only a couple of extra lines of code (basically just 1 extra for loop around the part that does lead-field calculation), it can be edited to go through a matrix of dipole coordinates and orientations. I'm currently on vacation, so it might take some time for me to dig up modifications I did for it to go through multiple dipoles, but it it took me maybe 10 minutes to fix in total, so it's really easy. I think that the coordinates that you need to give for each dipole are voxel positions from the MRI. There's also a bug near the end of the function, at the place where ft_senstype is called. It will set to MEG in both cases, so that needs fixing as well. Later on, when you get the EEG, you can plot it like this, for example: %View the EEG cfg=[]; cfg.viewmode='vertical'; ft_databrowser(cfg,data_from_ft_dipolesimulation); All the best, Andreja Kostić 2016-08-01 10:17 GMT+02:00 pooneh baniasad : > Dear FieldTrip community, > ​ > ​I'm trying to generate EEG signal without using raw datas. > I used the 'Subject01.mri' as my anatomical model, the BEM method for > preparing a headmodel and 'standard_1020.elc' for aligning electrodes. > For a source model I loaded template grid (cortex_20484.surf.gii). > Now my questions are how can I set dipole's location (in other words, my > grid's resolution)? > How can I allocate a source model (sin, cos, ...) to each dipole? Is there > any function in Fieldtrip doing that? or I have to writing the code by > myself. > After having the source model for each dipole and calculating leadfield > matrix what should I do for plotting the EEG signal? > > > -- > Bests > > Pouneh Baniasad > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From tmadsen at emory.edu Mon Aug 1 17:03:40 2016 From: tmadsen at emory.edu (Teresa Madsen) Date: Mon, 1 Aug 2016 11:03:40 -0400 Subject: [FieldTrip] queries_related to_error In-Reply-To: References: Message-ID: Maybe you accidentally deleted the "utilities" folder? I would try updating to the latest version of FieldTrip. On Sun, Jul 31, 2016 at 6:22 AM, Laxmi Shaw wrote: > Dear Fieldtrip users, > > Suddenly i got one error while compiling any fieldtrip function based > code.Please need your help to remove this error. I have attach the screen > shot of that matlab program. > [image: Inline image 1] > Your helps always been appreciated. > > > Regards > -- > Laxmi Shaw > Research Scholar(PhD) > IIT Kharagpur > West Bengal > Ph no-08388837821 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- Teresa E. Madsen, PhD Division of Behavioral Neuroscience and Psychiatric Disorders Yerkes National Primate Research Center Emory University Rainnie Lab, NSB 5233 954 Gatewood Rd. NE Atlanta, GA 30329 (770) 296-9119 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 103003 bytes Desc: not available URL: From roycox.roycox at gmail.com Mon Aug 1 17:33:59 2016 From: roycox.roycox at gmail.com (Roy Cox) Date: Mon, 1 Aug 2016 11:33:59 -0400 Subject: [FieldTrip] Fwd: postdoc and research assistant position available in Center for Sleep and Cognition In-Reply-To: References: Message-ID: hello all, A postdoc position and RA position are now available in the Center for Sleep and Cognition (PI: Robert Stickgold). Feel free to forward these ads to anyone that may be interested. Best, Roy Cox ------------------------------------------------ *Postdoctoral position in Stickgold lab* Applications are invited for a full-time postdoctoral position at the Center for Sleep and Cognition (sleepandcognition.org ), PI Robert Stickgold, The position is for two years, with possible extension contingent on funding. The lab is at Beth Israel Deaconess Medical Center / Harvard Medical School, in Boston. Research in the lab is focused on the role of sleep in memory consolidation, with current projects investigating emotional memory, memory integration, the algorithms of memory prioritization/selection for consolidation, and the mechanistic role of neural oscillations in these processes. Approaches include targeted memory reactivation, time-frequency analyses of learning- and sleep-associated oscillatory activity, and computational modeling. The lab is also interested in deficits in these processes associated with sleep disorders as well as a range of psychiatric and neurological disorders. A current study, in collaboration with Dara Manoach and Matcheri Keshavan, investigates memory consolidation deficits in patients with schizophrenia. Facilities include two fully equipped sleep rooms for measuring high-density EEG/PSG and several units for behavioral testing. Access to several clinical populations is possible. A PhD in psychology or neuroscience (or a related discipline) and a strong research background are required. The following are beneficial: experience with EEG measurements/analyses, experience running behavioral experiments, programming skills, and strong statistical and quantitative skills. Please send your CV and a brief statement of research interest to Elaine Parr: mparr at bidmc.harvard.edu. Applications will be reviewed until the position is filled. Start date is flexible. *Research assistant position in Stickgold lab* The Center for Sleep and Cognition at Beth Israel Deaconess Medical Center is seeking a college graduate with strong organizational and interpersonal skills as a full time research assistant for projects investigating sleep and memory consolidation. If hired, you will be responsible for screening subjects for participation in experimental studies, enrolling subjects into these studies, administering cognitive tests, and recording the overnight sleep of subjects. This includes actively monitoring subjects’ sleep in the sleep laboratory. You will be expected to work closely with the Principal Investigator, lab mates, and collaborators on all aspects of the project. Training in recording sleep EEGs, behavioral test administration, and data analysis will be provided. Administrative duties will include helping to maintain accurate records, and assist with grant applications, human subject applications, and publications. Some computer programming experience is an asset, as is a high level of comfort with novel computer applications and environments. A bachelor’s degree and prior research experience are required. A background in psychology, statistics, and neuroscience, as well as a prior mentored research project would be preferred. You must be mature and responsible, with excellent oral and written communication skills. You must be able to work independently in a fast-paced environment, juggle and prioritize multiple tasks, feel comfortable working with clinical and non-clinical study populations, and seek assistance when appropriate. This is an excellent research opportunity for someone bound for graduate school in psychology, cognitive neuroscience, or medicine. Position is available immediately. A two-year commitment is required. Please send a resume, (unofficial) transcript, writing sample, and contact information for three references to Elaine Parr: mparr at bidmc.harvard.edu. -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.vanEs at donders.ru.nl Tue Aug 2 13:25:02 2016 From: M.vanEs at donders.ru.nl (Es, M.W.J. van (Mats)) Date: Tue, 2 Aug 2016 11:25:02 +0000 Subject: [FieldTrip] sourcestatistics spm_bwlabel issue Message-ID: <3FC79061C73BEF44A3BEDA5DFC0ADBDF4ECD563F@exprd01.hosting.ru.nl> Hi FieldTrippers, After doing DICS source analysis, I get an error with source statistics: Error using spm_bwlabel spm_bwlabel: CONN must be 6, 18 or 26 Error in clusterstat (line 184) [posclusobs, posnum] = spm_bwlabel(tmp, 2*numdims); Error in ft_statistics_montecarlo (line 347) [stat, cfg] = clusterstat(cfg, statrand, statobs); Error in ft_sourcestatistics (line 205) [stat, cfg] = statmethod(cfg, dat, design); Error in source_analysis (line 143) stat = ft_sourcestatistics(cfg, sourceAct, sourceBl); I uploaded the data here (https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0)https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0https://www.dropbox.com/s/67tocpl685ytf4e/source.mat?dl=0 and this is the code that I am executing: cfg = []; cfg.method = 'montecarlo'; cfg.statistic = 'ft_statfun_depsamplesT'; cfg.parameter = 'pow'; cfg.correctm = 'cluster'; cfg.clusteralpha = 0.05; % this is the treshold for clustering, not the % statistical test of the cluster cfg.clusterstatistic = 'maxsum'; cfg.numrandomization = 1000; cfg.alpha = 0.05; % note that this only implies single-sided testing cfg.tail = 0; cfg.clustertail = 0; cfg.uvar = 1; % row of design matrix that contains unit variable (in this case: trials) cfg.ivar = 2; % row of design matrix that contains independent variable (the conditions) cfg.dim = [2400 1 1]; design = [1:length(dataAct.trial), 1:length(dataBl.trial); ones(1,length(dataAct.trial)), ones(1,length(dataBl.trial))*2]; cfg.design = design; stat = ft_sourcestatistics(cfg, sourceAct, sourceBl); Any help would be appreciated! Best, Mats -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Thu Aug 4 20:25:38 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Thu, 4 Aug 2016 18:25:38 +0000 Subject: [FieldTrip] Constrain Source solution space Message-ID: Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From RICHARDS at mailbox.sc.edu Fri Aug 5 15:51:34 2016 From: RICHARDS at mailbox.sc.edu (RICHARDS, JOHN) Date: Fri, 5 Aug 2016 13:51:34 +0000 Subject: [FieldTrip] constrain source solution space Message-ID: https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/MediaObjects/10548_2016_505_MOESM3_ESM.docx 1--prepare a grid, for the source volume 2-prepare a head volume 3-prepare electrode (or meg) scalp locations These three elements are used for a lead field. LF and other elements are used w EEG in ft_sourceanalysis. There are several tutorials on FT site to do this. John -----Original Message----- From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of fieldtrip-request at science.ru.nl Sent: Friday, August 5, 2016 6:00 AM To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 69, Issue 4 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. Constrain Source solution space (Nakhnikian, Alexander) ---------------------------------------------------------------------- Message: 1 Date: Thu, 4 Aug 2016 18:25:38 +0000 From: "Nakhnikian, Alexander" To: "fieldtrip at science.ru.nl" Subject: [FieldTrip] Constrain Source solution space Message-ID: Content-Type: text/plain; charset="iso-8859-1" Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 69, Issue 4 **************************************** From Alexander_Nakhnikian at hms.harvard.edu Fri Aug 5 18:07:12 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Fri, 5 Aug 2016 16:07:12 +0000 Subject: [FieldTrip] constrain source solution space In-Reply-To: References: Message-ID: Hi John, Thank you for your feedback. I'm not sure, however, I understand your suggestion. Is the idea to exclude the white matter from the head model? If so, aren't we discarding an important part of the volume conductor model? Furthermore, if I'm correctly interpreting the FAQ page I provided, it should be possible to apply a tissue mask after we've completed the 3 steps you listed since ft_sourceanalysis and ft_prepare_leadfield are both called after we have the grid, head volume, and sensor locations. Thanks, Alexander ________________________________ From: RICHARDS, JOHN Sent: Friday, August 5, 2016 9:51:34 AM To: fieldtrip at science.ru.nl; Nakhnikian, Alexander Subject: constrain source solution space https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/MediaObjects/10548_2016_505_MOESM3_ESM.docx 1--prepare a grid, for the source volume 2-prepare a head volume 3-prepare electrode (or meg) scalp locations These three elements are used for a lead field. LF and other elements are used w EEG in ft_sourceanalysis. There are several tutorials on FT site to do this. John -----Original Message----- From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of fieldtrip-request at science.ru.nl Sent: Friday, August 5, 2016 6:00 AM To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 69, Issue 4 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. Constrain Source solution space (Nakhnikian, Alexander) ---------------------------------------------------------------------- Message: 1 Date: Thu, 4 Aug 2016 18:25:38 +0000 From: "Nakhnikian, Alexander" To: "fieldtrip at science.ru.nl" Subject: [FieldTrip] Constrain Source solution space Message-ID: Content-Type: text/plain; charset="iso-8859-1" Hello All, I'm trying to constrain my source space to gray matter and I found suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter [http://www.fieldtriptoolbox.org/_media/logo-share.png] faq:can_i_restrict_the_source_reconstruction_to_the_grey ... www.fieldtriptoolbox.org Yes, there are two strategies you can use. You can either make a regular 3D grid spanning the whole brain in which only grid locations in grey matter are considered ... The problem is that I cannot figure out how to actually do this. For example, I don't see options in ft_sourceanalysis for inputing segmented mir with the tissue types of interest, now for giving the program an anatomic mask. Any feedback would be greatly appreciated. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 69, Issue 4 **************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Fri Aug 5 18:25:34 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Fri, 5 Aug 2016 16:25:34 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol Message-ID: Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich -------------- next part -------------- An HTML attachment was scrubbed... URL: From xiew1202 at gmail.com Fri Aug 5 19:02:07 2016 From: xiew1202 at gmail.com (Xie Wanze) Date: Fri, 5 Aug 2016 13:02:07 -0400 Subject: [FieldTrip] constrain source solution space In-Reply-To: References: Message-ID: Alexander, In John's step 1 (creating the grid, source volume), you exclude the WM because they WM are fibers not neurons, i.e., they are not generating the activity. In step 2 (creating the head model), you don't exclude the WM. Instead, you do segmentation of the head/brain, so WM, GM, and OM(CSF) are separated. So you are not discarding or losing an "important part of the volume conductor model". Wanze 2016-08-05 12:07 GMT-04:00 Nakhnikian, Alexander < Alexander_Nakhnikian at hms.harvard.edu>: > Hi John, > > > Thank you for your feedback. I'm not sure, however, I understand your > suggestion. Is the idea to exclude the white matter from the head model? If > so, aren't we discarding an important part of the volume conductor model? > Furthermore, if I'm correctly interpreting the FAQ page I provided, it > should be possible to apply a tissue mask after we've completed the 3 steps > you listed since ft_sourceanalysis and ft_prepare_leadfield are both called > after we have the grid, head volume, and sensor locations. > > > Thanks, > > > Alexander > ------------------------------ > *From:* RICHARDS, JOHN > *Sent:* Friday, August 5, 2016 9:51:34 AM > *To:* fieldtrip at science.ru.nl; Nakhnikian, Alexander > *Subject:* constrain source solution space > > https://static-content.springer.com/esm/art%3A10.1007%2Fs10548-016-0505-3/ > MediaObjects/10548_2016_505_MOESM3_ESM.docx > > 1--prepare a grid, for the source volume > 2-prepare a head volume > 3-prepare electrode (or meg) scalp locations > > These three elements are used for a lead field. > > LF and other elements are used w EEG in ft_sourceanalysis. > > There are several tutorials on FT site to do this. > > John > -----Original Message----- > From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces@ > science.ru.nl ] On Behalf Of > fieldtrip-request at science.ru.nl > Sent: Friday, August 5, 2016 6:00 AM > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 69, Issue 4 > > 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. Constrain Source solution space (Nakhnikian, Alexander) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 4 Aug 2016 18:25:38 +0000 > From: "Nakhnikian, Alexander" > To: "fieldtrip at science.ru.nl" > Subject: [FieldTrip] Constrain Source solution space > Message-ID: > namprd07.prod.outlook.com> > > Content-Type: text/plain; charset="iso-8859-1" > > Hello All, > > > I'm trying to constrain my source space to gray matter and I found > suggestions for how to do this on the FAQ: http://www.fieldtriptoolbox. > org/faq/can_i_restrict_the_source_reconstruction_to_the_grey_matter > > [http://www.fieldtriptoolbox.org/_media/logo-share.png]< > http://www.fieldtriptoolbox.org/faq/can_i_restrict_the_ > source_reconstruction_to_the_grey_matter> > > faq:can_i_restrict_the_source_reconstruction_to_the_grey ... fieldtriptoolbox.org/faq/can_i_restrict_the_source_ > reconstruction_to_the_grey_matter> > www.fieldtriptoolbox.org > Yes, there are two strategies you can use. You can either make a regular > 3D grid spanning the whole brain in which only grid locations in grey > matter are considered ... > > > > > The problem is that I cannot figure out how to actually do this. For > example, I don't see options in ft_sourceanalysis for inputing segmented > mir with the tissue types of interest, now for giving the program an > anatomic mask. Any feedback would be greatly appreciated. > > > Best, > > > Alexander > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: attachments/20160804/48cc4c8e/attachment-0001.html> > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 69, Issue 4 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From xkshu at outlook.com Sun Aug 7 14:37:29 2016 From: xkshu at outlook.com (shu xiaokang) Date: Sun, 7 Aug 2016 12:37:29 +0000 Subject: [FieldTrip] fieldtrip for Mac Message-ID: Hi, I have met a problem when I was using fieldtrip to plot a topography with my macbook. Detailly, the colors of topographies drawn (using ft_topoplotTFR) with macbook are different from that drawn with windows (as attached figures). Actually, the pictures drawn with macbook are really ugly. Anyone know how to solve the problem? Shu[cid:6982C939-293A-42AA-8724-7439D84214AA][cid:2912BE42-6DE2-41B8-A818-5B88C95A997C] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Mac.png Type: image/png Size: 167415 bytes Desc: Mac.png URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Win.png Type: image/png Size: 333207 bytes Desc: Win.png URL: From tiago.lopes56 at yahoo.com Mon Aug 8 04:39:17 2016 From: tiago.lopes56 at yahoo.com (tiago lopes) Date: Mon, 8 Aug 2016 02:39:17 +0000 (UTC) Subject: [FieldTrip] calculate ERD / ERS References: <2107718987.18605392.1470623957848.JavaMail.yahoo.ref@mail.yahoo.com> Message-ID: <2107718987.18605392.1470623957848.JavaMail.yahoo@mail.yahoo.com> Hi,i am using the toolbox fieldtrip to calculate ERD / ERS in different groups. However, i do not know if I should use a relative or absolute power density in function cfg.baselinetype. I am using the following script, cfg                                 = [ ];cfg.method                     = 'wavelet';cfg.width                        = 7cfg.output                        = 'pow'cfg.foi                           =4:0.2:30;cfg.toi                           = -.68:0.01:1.5;cfg.keeptrials                ='no';cfg.baseline                    =[-0.4 -0.1];cfg.baselinetype            ='relative';         (I do not know if I should use a relative or absolute.)TFRtot                          = ft_freqanalysis(cfg, date)TFRtotal                       = ft_freqbaseline(cfg, TFRtot); Can anyone help me with this problem please? Federal University of Bahia, BrazilProgram in Medicine and Health Att. Tiago Lopes -------------- next part -------------- An HTML attachment was scrubbed... URL: From ayelet.landau at gmail.com Mon Aug 8 09:18:34 2016 From: ayelet.landau at gmail.com (Ayelet Landau) Date: Mon, 8 Aug 2016 10:18:34 +0300 Subject: [FieldTrip] Postdoc/PhD positions - Cognitive Neuroscience @ the Hebrew University of Jersusalem Message-ID: *Post Doc and PhD positions at the Brain Attention and Time Lab, at the Hebrew University of Jerusalem, Israel* Full-time post doc and PhD positions are available in the Brain Attention and Time Lab of Dr. Ayelet N. Landau at the Hebrew University of Jerusalem. Initial appointment will be for one year with the option to renew annually up to 4 years. Preferred starting date: October 2016 The lab’s core research areas include the guidance of attention and temporal processing and their underlying neural mechanisms. As cognitive neuroscientists we try to construe models of cognition and examine them using both in perception and in physiology. The positions are part of two externally funded projects focused on: (1) Fluctuations in attention and rhythmic attentional sampling. (2) Neural mechanisms of interval timing. Both research programs examine the role of brain rhythms in cognition. In the lab, we measure perception in different modalities (tactile, visual and auditory) together with non-invasive physiology (MEG/EEG) and eye-tracking. You can read about the research and the lab here. We are seeking a highly qualified post doc with a doctorate in a relevant field (e.g., Psychology, Neuroscience, and Cognitive Science) and shared interests in the core research areas described above. The researcher, ideally, should have extensive experience with EEG/MEG methodology and neural oscillations measurement. Experience with other techniques - such as fMRI, computational modeling, etc. - is also welcome but not required. In addition, we are looking for strong candidates for a funded PhD studentship. The Hebrew University offers several training opportunities in different departments. The successful candidate will be competitive for one of the flagship programs (psychology, cognitive science or neuroscience) and will have demonstrated experience in research from their post-bac or BA education (as research assistants or honors students). Knowledge of programming is an advantage. For both positions, a passion and a commitment to science, strong social skills, trouble shooting skills and fast learning abilities are a requirement. Interested candidates should send a CV, a brief statement of research interests, and the names and contact details of two academic references to ayelet.landau at huji.ac.il preferably by September 15th. Applications will be considered until the positions are filled. I look forward to hearing from you! Ayelet -- Ayelet N. Landau, PhD *Senior Lecturer* *Department of Psychology & Department of Cognitive SciencesThe Hebrew University of JerusalemJerusalem 91905Israel* -- Ayelet N. Landau, PhD *Senior Lecturer* *Department of Psychology & Department of Cognitive SciencesThe Hebrew University of JerusalemJerusalem 91905Israel* -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Mon Aug 8 11:36:41 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Mon, 08 Aug 2016 11:36:41 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> Message-ID: <10097d8526f9118870bfd95571e9cdd6@inserm.fr> Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: From anna.wieczorek.taraday at gmail.com Mon Aug 8 11:44:19 2016 From: anna.wieczorek.taraday at gmail.com (Anna Wieczorek-Taraday) Date: Mon, 8 Aug 2016 11:44:19 +0200 Subject: [FieldTrip] fieldtrip for Mac In-Reply-To: References: Message-ID: Hi Shu, If I understood correctly, you would you topoplot to be 'blue-yellow-red' instead of being 'blue-green'? If that is the case, you should specify the colormap in configuration structure when drawing figure (probably your default colormap on MacBook is set to 'parula' and the one on Win is 'jet'). try this: cfg.colormap = 'jet' and here you can find some more info about colormaps in Matlab: http://nl.mathworks.com/help/matlab/ref/colormap.html Good luck, Anna 2016-08-07 14:37 GMT+02:00 shu xiaokang : > Hi, > > I have met a problem when I was using fieldtrip to plot a topography with > my macbook. Detailly, the colors of topographies drawn (using > ft_topoplotTFR) with macbook are different from that drawn with windows > (as attached figures). Actually, the pictures drawn with macbook are really > ugly. Anyone know how to solve the problem? > > Shu > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Win.png Type: image/png Size: 333207 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Mac.png Type: image/png Size: 167415 bytes Desc: not available URL: From daniel.haehnke at tum.de Mon Aug 8 11:51:08 2016 From: daniel.haehnke at tum.de (=?utf-8?B?SMOkaG5rZSwgRGFuaWVs?=) Date: Mon, 8 Aug 2016 09:51:08 +0000 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <10097d8526f9118870bfd95571e9cdd6@inserm.fr> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> Message-ID: <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> Dear Laetitia, I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? Best, Daniel -- Daniel Hähnke PhD student Technische Universität München Institute of Neuroscience Translational NeuroCognition Laboratory Biedersteiner Straße 29, Bau 601 80802 Munich Germany Email: daniel.haehnke at tum.de Phone: +49 89 4140 3356 On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From xkshu at outlook.com Mon Aug 8 12:19:56 2016 From: xkshu at outlook.com (shu xiaokang) Date: Mon, 8 Aug 2016 10:19:56 +0000 Subject: [FieldTrip] fieldtrip for Mac In-Reply-To: References: Message-ID: Hi, Anna Thanks very much! It really works to add the code ‘cfg.colormap=‘jet’’, the default colormap on my mac has been set to ‘parula’. Shu 在 2016年8月8日,下午5:44,Anna Wieczorek-Taraday > 写道: Hi Shu, If I understood correctly, you would you topoplot to be 'blue-yellow-red' instead of being 'blue-green'? If that is the case, you should specify the colormap in configuration structure when drawing figure (probably your default colormap on MacBook is set to 'parula' and the one on Win is 'jet'). try this: cfg.colormap = 'jet' and here you can find some more info about colormaps in Matlab: http://nl.mathworks.com/help/matlab/ref/colormap.html Good luck, Anna 2016-08-07 14:37 GMT+02:00 shu xiaokang >: Hi, I have met a problem when I was using fieldtrip to plot a topography with my macbook. Detailly, the colors of topographies drawn (using ft_topoplotTFR) with macbook are different from that drawn with windows (as attached figures). Actually, the pictures drawn with macbook are really ugly. Anyone know how to solve the problem? Shu _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruil3 at student.unimelb.edu.au Tue Aug 9 08:34:18 2016 From: ruil3 at student.unimelb.edu.au (Rui Li) Date: Tue, 9 Aug 2016 16:34:18 +1000 Subject: [FieldTrip] Data Frequency Range for SAM(g2) Message-ID: Dear FieldTrippers, Currently, I am trying to reconstruct the source space using SAM(fg2) from MEG data of epilepsy patients. I read the paper "Kirsch_et_l+2006+Clinical_Neurophysiology+Automated_localization_of_magnetoencephalographic_interictal_spikes_by_adaptive_spatial_filtering" as the reference. However, it is a little confusing that the frequency range used to operate SAM(g2) was 20 - 70Hz. Does anybody have the idea why this frequency range was used? Are there any pieces of literature recommended for this issue? Regards, Rui. -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Tue Aug 9 19:19:32 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Tue, 9 Aug 2016 17:19:32 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol In-Reply-To: References: Message-ID: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Pomper, Ulrich Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Wed Aug 10 11:01:51 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Wed, 10 Aug 2016 11:01:51 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> Message-ID: <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> Hi Daniel, Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : Operation terminated by user during ft_checkdata>fixcsd (line 1072) In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1170) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 416) data = ft_checkdata(data, 'cmbrepresentation', 'full'); Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? Thanks a lot for your help. Best, Laetitia On 08-08-2016 11:51, Hähnke wrote: > Dear Laetitia, > > I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? > > Best, > > Daniel > > -- > Daniel Hähnke > PhD student > > Technische Universität München > Institute of Neuroscience > Translational NeuroCognition Laboratory > Biedersteiner Straße 29, Bau 601 > 80802 Munich > Germany > > Email: daniel.haehnke at tum.de > Phone: +49 89 4140 3356 > >> On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: >> >> Hello fieldtrippers, >> first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! >> >> I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended [1]. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >>> cfg=[]; >>> cfg.method='granger'; >>> granger=ft_connectivityanalysis(cfg, freq); >> to compute the granger causality. >> However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : >> >> Operation terminated by user during ft_checkdata>fixcsd (line 1255) >> >> In ft_checkdata (line 797) >> data = fixcsd(data, cmbrepresentation, channelcmb); >> >> In ft_checkdata>fixcsd (line 1351) >> data = ft_checkdata(data, 'cmbrepresentation', 'full'); >> >> In ft_checkdata (line 797) >> data = fixcsd(data, cmbrepresentation, channelcmb); >> >> In ft_connectivityanalysis (line 392) >> data = ft_checkdata(data, 'cmbrepresentation', 'full'); >> >> I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. >> >> Thanks a lot for your help. >> >> Regards, >> >> Laetitia Lalla >> PhD student in INMED, Marseille, France _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip Links: ------ [1] http://www.fieldtriptoolbox.org/tutorial/connectivityextended -------------- next part -------------- An HTML attachment was scrubbed... URL: From daniel.haehnke at tum.de Wed Aug 10 11:49:46 2016 From: daniel.haehnke at tum.de (=?utf-8?B?SMOkaG5rZSwgRGFuaWVs?=) Date: Wed, 10 Aug 2016 09:49:46 +0000 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> Message-ID: <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> Hi Laetitia, could you provide the code that you used for the calculation of your input structure ‘freq’? When I had a similar looking issue it was because I used a trial-resolved structure, whereas GC calculation seems to require trial-averaged data. Best, Daniel On 10.08.2016, at 11:01, laetitia.lalla at inserm.fr wrote: Hi Daniel, Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : Operation terminated by user during ft_checkdata>fixcsd (line 1072) In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1170) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 595) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 416) data = ft_checkdata(data, 'cmbrepresentation', 'full'); Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? Thanks a lot for your help. Best, Laetitia On 08-08-2016 11:51, Hähnke wrote: Dear Laetitia, I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? Best, Daniel -- Daniel Hähnke PhD student Technische Universität München Institute of Neuroscience Translational NeuroCognition Laboratory Biedersteiner Straße 29, Bau 601 80802 Munich Germany Email: daniel.haehnke at tum.de Phone: +49 89 4140 3356 On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: Hello fieldtrippers, first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >cfg=[]; >cfg.method='granger'; >granger=ft_connectivityanalysis(cfg, freq); to compute the granger causality. However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : Operation terminated by user during ft_checkdata>fixcsd (line 1255) In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_checkdata>fixcsd (line 1351) data = ft_checkdata(data, 'cmbrepresentation', 'full'); In ft_checkdata (line 797) data = fixcsd(data, cmbrepresentation, channelcmb); In ft_connectivityanalysis (line 392) data = ft_checkdata(data, 'cmbrepresentation', 'full'); I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. Thanks a lot for your help. Regards, Laetitia Lalla PhD student in INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Wed Aug 10 12:01:52 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Wed, 10 Aug 2016 10:01:52 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol References: <3D66B259-F956-4001-9AD3-1247F36D5E7C@gmail.com> Message-ID: <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> Dear Bumper, It may be helpful to provide the list with some example code + data, should anybody be keen to look into this. Best, Jan-Mathijs On 09 Aug 2016, at 19:19, Pomper, Ulrich > wrote: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Pomper, Ulrich > Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From u.pomper at ucl.ac.uk Wed Aug 10 12:44:06 2016 From: u.pomper at ucl.ac.uk (Pomper, Ulrich) Date: Wed, 10 Aug 2016 10:44:06 +0000 Subject: [FieldTrip] mtmfft vs. mtmconvol In-Reply-To: <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> References: <3D66B259-F956-4001-9AD3-1247F36D5E7C@gmail.com>, <16D6A584-4D02-4098-8B2F-2186F5696F34@donders.ru.nl> Message-ID: Dear all, Below please find some code which illustrates the issue I'm having. Example data can be found here: https://www.dropbox.com/s/5bgpawph49vkgoo/data_fft_vs_conv.mat?dl=0 The code results in a plot of the PSD, showing how both mtmfft and mtmconvol yield (more or less) similar results, but only after the results from mtmfft are multiplied by 10. Again, I'd be grateful for any clarification on why this might be! Cheers, Ulrich %%%%%%%%%%%%% MTMFFT code %%%%%%%%%%%%%%%%%%%%%%%%% cfg = []; cfg.continuous = 'no'; cfg.channel = {'all', '-VEOG', '-HEOG'} cfg.output = 'pow'; cfg.method = 'mtmfft'; cfg.foi = 1:0.5:30; cfg.taper = 'hanning'; cfg.tapsmofrq = 2 +(0*(cfg.foi)); cfg.keeptapers = 'no'; cfg.keeptrials = 'no'; cfg.pad = 5; freq_fft = ft_freqanalysis(cfg, data); %%%%%%%%%%%%% MTMCONVOL code %%%%%%%%%%%%%%%%%%%%%%%%% taplen = 695; cfg = []; cfg.continuous = 'no'; cfg.channel = {'all', '-VEOG', '-HEOG'} cfg.output = 'pow'; cfg.method = 'mtmconvol'; cfg.foi = 1:0.5:30; cfg.toi = 0.25; cfg.taper = 'hanning'; cfg.tapsmofrq = 2 +(0*(cfg.foi)); cfg.t_ftimwin = ones(length(cfg.foi),1).* (taplen /1000); % cfg.keeptapers = 'no'; cfg.keeptrials = 'no'; cfg.pad = 5; freq_conv = ft_freqanalysis(cfg, data); %%%%%%%%%% plot the two different results for comparison %%%%%%%%%%%%%%%%% CH1_mean_fft = freq_fft.powspctrm(1,:); CH1_mean_conv = freq_conv.powspctrm(1,:); % mtmfft data multiplied by 10, which puts them in a similar order of magnitude as the results from mtmconvol CH1_mean_fft10 = freq_fft.powspctrm(1,:) * 10; figure; plot(CH1_mean_conv); hold on; plot(CH1_mean_fft10); hold on; plot(CH1_mean_fft); ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Schoffelen, J.M. (Jan Mathijs) Sent: 10 August 2016 11:01 To: FieldTrip discussion list Subject: Re: [FieldTrip] mtmfft vs. mtmconvol Dear Bumper, It may be helpful to provide the list with some example code + data, should anybody be keen to look into this. Best, Jan-Mathijs On 09 Aug 2016, at 19:19, Pomper, Ulrich > wrote: bump.... Has anybody encountered this issue before? Any suggestion would be highly appreciated! Many Thanks! ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Pomper, Ulrich > Sent: 05 August 2016 17:25 To: fieldtrip at science.ru.nl Subject: [FieldTrip] mtmfft vs. mtmconvol Dear all, I have a question regarding different results I get from spectral analysis using mtmfft versus mtmconvol. In short, the spectral power across frequencies is very similar for both methods, but for some reason my results are an order of magnitude larger when using mtmconvol. In other words, the power spectral density plots for both methods are highly overlapping, but only after I multiply the results of mtmfft by 10. Is there any evident reason for this? Are the two methods just outputting different units/ scales? (I ran both using almost identical settings. For mtmconvol I used a single timepoint at the center of my data period, with a taper length identical to the length of the data period used in mtmfft. All other parameters are the same). Cheers, Ulrich _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Wed Aug 10 16:29:09 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Wed, 10 Aug 2016 16:29:09 +0200 Subject: [FieldTrip] Compute Time-Frequency Granger Causality with ft_connectivityanalysis In-Reply-To: <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> References: <646F174E-105D-4A5B-961D-62AAED16862A@uni-konstanz.de> <10097d8526f9118870bfd95571e9cdd6@inserm.fr> <56B383AC-8D4B-44CE-B8A3-241CD2343F09@tum.de> <29976653b0dd1a4c01c03ef8eb13263d@inserm.fr> <13803E26-62B0-4EEB-A2B7-FCFACDA8C706@tum.de> Message-ID: Hello ! Sure, this is the code that I use after the preprocessing : %------------------------------------------------------------------------------- cfg = []; cfg.method = 'mtmconvol'; cfg.output = 'powandcsd'; cfg.channel = data.label; cfg.channelcmb = {'Str' 'Ctx'}; cfg.taper = 'dpss'; cfg.foi = 0.5:100; cfg.tapsmofrq = 1.5*ones(1, length(cfg.foi)); cfg.t_ftimwin = 2*ones(1, length(cfg.foi)); cfg.toi = data.time{1,1}; cfg.keeptrials = 'no'; freq = ft_freqanalysis(cfg, data); % cfg=[]; % cfg.method='coh'; % coh=ft_connectivityanalysis(cfg, freq); cfg=[]; cfg.method='granger'; granger=ft_connectivityanalysis(cfg, freq); %------------------------------------------------------------------------------ I succesfully compute the Time-Frequency Map of the coherence (this was to check), but it won't work for the Granger causality... Thanks a lot for your help ! Best, Laetitia On 10-08-2016 11:49, Hähnke wrote: > Hi Laetitia, > > could you provide the code that you used for the calculation of your input structure 'freq'? > > When I had a similar looking issue it was because I used a trial-resolved structure, whereas GC calculation seems to require trial-averaged data. > > Best, Daniel > > On 10.08.2016, at 11:01, laetitia.lalla at inserm.fr wrote: > > Hi Daniel, > Thanks a lot for your answer. I was using a version from last September. I downloaded the most recent version "fieldtrip-20160809" this morning and I still have the same issue... When I call ft_connectivity analysis, this message is displayed : "the call to "ft_selectdata" took 0 seconds and required the additional allocation of an estimated ... MB" and then Matlab stays stuck... I terminate it myself and the error is still the same : > > Operation terminated by user during ft_checkdata>fixcsd (line 1072) > In ft_checkdata (line 595) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_checkdata>fixcsd (line 1170) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > In ft_checkdata (line 595) > data = fixcsd(data, cmbrepresentation, channelcmb); > In ft_connectivityanalysis (line 416) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > Has anyone else encountered issues when trying to plot a Time-Frequency Map of the Granger causality with ft_connectivityanalysis ? > > Thanks a lot for your help. > > Best, > > Laetitia > > On 08-08-2016 11:51, Hähnke wrote: Dear Laetitia, > > I think I had this issue before and it was caused by a bug in the fieldtrip version I was using. What version are you using? > > Best, > > Daniel > > -- > Daniel Hähnke > PhD student > > Technische Universität München > Institute of Neuroscience > Translational NeuroCognition Laboratory > Biedersteiner Straße 29, Bau 601 > 80802 Munich > Germany > > Email: daniel.haehnke at tum.de > Phone: +49 89 4140 3356 > > On 08.08.2016, at 11:36, laetitia.lalla at inserm.fr wrote: > > Hello fieldtrippers, > first of all, thanks a lot for this collaborative mailing list. It helped me a lot in the past and i hope you will be able to help me today ! > > I succesfully implemented the spectral granger causality thanks to this FieldTrip tutorial : http://www.fieldtriptoolbox.org/tutorial/connectivityextended [1]. Now I'd like to compute a Time-Frequency Map of my granger causality. Hence, I used ft_freqanalysis with cfg.method = 'mtmconvol' and cfg.output = 'powandcsd' and the minimal code >> cfg=[]; >> cfg.method='granger'; >> granger=ft_connectivityanalysis(cfg, freq); > to compute the granger causality. > However, when I run this code, Matlab bugs and stays "busy" for a while until I terminate it, with the following error message : > > Operation terminated by user during ft_checkdata>fixcsd (line 1255) > > In ft_checkdata (line 797) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_checkdata>fixcsd (line 1351) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > In ft_checkdata (line 797) > data = fixcsd(data, cmbrepresentation, channelcmb); > > In ft_connectivityanalysis (line 392) > data = ft_checkdata(data, 'cmbrepresentation', 'full'); > > I can see in the help of the function checkdata the following : "cmbrepresentation = sparse, full (applies to covariance and cross-spectral density)". But I don't really understand what "cmbrepresentation" do ... Maybe someone who had a similar problem in the past can help me ? I think I'm missing some optional arguments that I should add. > > Thanks a lot for your help. > > Regards, > > Laetitia Lalla > PhD student in INMED, Marseille, France _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip Links: ------ [1] http://www.fieldtriptoolbox.org/tutorial/connectivityextended -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 17:42:29 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 15:42:29 +0000 Subject: [FieldTrip] reading .mat in fieldtrip Message-ID: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 17:42:30 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 15:42:30 +0000 Subject: [FieldTrip] reformat .mat data - example script Message-ID: Hi Did you solve your problem with reading .mat in field trip? I have the same problem do you have any idea? -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 18:33:03 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 09:33:03 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) : > Hi All, > > > > I have a “.mat” file which contais: <8x10350000 double> and sampling rate. > > How should I import this data to field trip? By using [data] = > ft_preprocessing( cfg); > > I am getting an error that the data should be in the format of raw or > raw + comp. > > > > Any idea? > > > > Thanks! > > > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 18:44:49 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 16:44:49 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 18:59:12 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 09:59:12 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: You could try to make one long trial, and take it from there. Load that matrix stored in your mat file (type 'help load'), and then data.trial{1,1} = matrix; data.time{1,1} = 1:size(matrix,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; .. data.label{8,1} = 'chan 8'; See that page, and/or type 'help ft_datatype_raw'. When your data is in raw format, you can process it with ft_preprocessing (e.g. to filter) or ft_redefinetrial (to create trials). Hope that gets you on your way, Arjen 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) : > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = > ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: > > Hi Bahareh, > > To get you started, see this page: > http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat > > It describes what fieldtrip expects your raw data to look like. > > Arjen > > 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: > >> Hi All, >> >> >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling >> rate. >> >> How should I import this data to field trip? By using [data] = >> ft_preprocessing( cfg); >> >> I am getting an error that the data should be in the format of raw or >> raw + comp. >> >> >> >> Any idea? >> >> >> >> Thanks! >> >> >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 19:15:51 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 17:15:51 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> I tried all these options before. The problem with ft_preprossecing is with cfg.dataset: I gave it my data's file name and path but the error is related to header and it says "unsupported header format"! And to use ft_predefintrial I need to creat Cfg apart of data that I do not have have anything at this time to include in Cfg. Thanks for your help! Bahar On Aug 11, 2016, at 12:00 PM, Arjen Stolk > wrote: You could try to make one long trial, and take it from there. Load that matrix stored in your mat file (type 'help load'), and then data.trial{1,1} = matrix; data.time{1,1} = 1:size(matrix,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; .. data.label{8,1} = 'chan 8'; See that page, and/or type 'help ft_datatype_raw'. When your data is in raw format, you can process it with ft_preprocessing (e.g. to filter) or ft_redefinetrial (to create trials). Hope that gets you on your way, Arjen 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) >: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 19:27:00 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 10:27:00 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> References: <8C0E6534-6D40-47F6-899D-20A65BFA0DD0@memphis.edu> Message-ID: You will no longer need to specify cfg.dataset once the data is already read into the matlab environment. Try, for instance, cfg = []; cfg.demean = 'yes'; preproc = ft_preprocessing(cfg, data); 2016-08-11 10:15 GMT-07:00 Bahareh Elahian (belahian) : > I tried all these options before. > > The problem with ft_preprossecing is with cfg.dataset: I gave it my data's > file name and path but the error is related to header and it says > "unsupported header format"! > And to use ft_predefintrial I need to creat Cfg apart of data that I do > not have have anything at this time to include in Cfg. > > Thanks for your help! > > Bahar > > > On Aug 11, 2016, at 12:00 PM, Arjen Stolk wrote: > > You could try to make one long trial, and take it from there. Load that > matrix stored in your mat file (type 'help load'), and then > > data.trial{1,1} = matrix; > data.time{1,1} = 1:size(matrix,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > .. > data.label{8,1} = 'chan 8'; > > See that page, and/or type 'help ft_datatype_raw'. When your data is in > raw format, you can process it with ft_preprocessing (e.g. to filter) or > ft_redefinetrial (to create trials). > > Hope that gets you on your way, > Arjen > > > > > 2016-08-11 9:44 GMT-07:00 Bahareh Elahian (belahian) >: > >> Thanks for the answer, >> >> I have had a look on this page before and I tried to follow the steps. >> The problem is ;I do not have any cfg to define cfg.trl and use newdata >> = ft_redefinetrial(cfg,data); >> >> Any other idea? >> >> >> >> On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: >> >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) < >> belahian at memphis.edu>: >> >>> Hi All, >>> >>> >>> >>> I have a “.mat” file which contais: <8x10350000 double> and sampling >>> rate. >>> >>> How should I import this data to field trip? By using [data] = >>> ft_preprocessing( cfg); >>> >>> I am getting an error that the data should be in the format of raw or >>> raw + comp. >>> >>> >>> >>> Any idea? >>> >>> >>> >>> Thanks! >>> >>> >>> >>> >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From toni.rbaena at gmail.com Thu Aug 11 20:47:18 2016 From: toni.rbaena at gmail.com (Antonio Rodriguez) Date: Thu, 11 Aug 2016 20:47:18 +0200 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" < belahian at memphis.edu> escribió: > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = > ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: > > Hi Bahareh, > > To get you started, see this page: > http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat > > It describes what fieldtrip expects your raw data to look like. > > Arjen > > 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: > >> Hi All, >> >> >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling >> rate. >> >> How should I import this data to field trip? By using [data] = >> ft_preprocessing( cfg); >> >> I am getting an error that the data should be in the format of raw or >> raw + comp. >> >> >> >> Any idea? >> >> >> >> Thanks! >> >> >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 21:00:52 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 19:00:52 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Antonio Rodriguez Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribi?: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 21:23:30 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 19:23:30 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , , Message-ID: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Bahareh Elahian (belahian) Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Antonio Rodriguez Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribi?: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a ".mat" file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From K.Vogt at donders.ru.nl Thu Aug 11 23:05:55 2016 From: K.Vogt at donders.ru.nl (Katharina Vogt) Date: Thu, 11 Aug 2016 22:05:55 +0100 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: <9D133336-632C-4227-9076-710E03043F9F@donders.ru.nl> Hi Bahareh, I had the same issue before too. I also created the needed structure and then used ft_redefinetrial. Not optimal, but it did the job!! However, I asked Robert Oostenveld to add my file format and he did. I might have to add that I work at the same Uni as he does and I was able to do it in person. I guess you can at least ask. Best, Katharina > On 11 Aug 2016, at 20:23, Bahareh Elahian (belahian) wrote: > > I did something and it works but it is not correct . > I specified cfg.trl = data.trial{1,1} > > cfg = []; > cfg.bpfilter = 'yes'; > cfg.demean = 'yes'; > data.trial{1,1} = eeg.eeg_data; > cfg.trl = data.trial{1,1}; > data.time{1,1} = 1:size(eeg.eeg_data,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > data.label{3,1} = 'chan 3'; > data.label{4,1} = 'chan 4'; > data.label{5,1} = 'chan 5'; > data.label{6,1} = 'chan 6'; > data.label{7,1} = 'chan 7'; > data.label{8,1} = 'chan 8'; > data.fsample = eeg.samp_rate; > newdata = ft_redefinetrial(cfg,data); > > the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. > > > From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > > Sent: Thursday, August 11, 2016 2:00:52 PM > To: FieldTrip discussion list > Subject: Re: [FieldTrip] reading .mat in fieldtrip > > Thanks but none of the options works. > The error is : > you should specify at least one configuration option. > > Even cfg.demean = 'yes'; is not enough. > > From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > > Sent: Thursday, August 11, 2016 1:47:18 PM > To: FieldTrip discussion list > Subject: Re: [FieldTrip] reading .mat in fieldtrip > > Hi. > You can create an empty cfg structure, and fill with data : > cfg =[]; > newdata = ft_redefinetrial(cfg,data); > > El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: > Thanks for the answer, > > I have had a look on this page before and I tried to follow the steps. > The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); > > Any other idea? > > > > On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: > >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: >> Hi All, >> >> I have a “.mat” file which contais: <8x10350000 double> and sampling rate. >> How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); >> I am getting an error that the data should be in the format of raw or raw + comp. >> >> Any idea? >> >> Thanks! >> >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.stolk8 at gmail.com Thu Aug 11 23:25:13 2016 From: a.stolk8 at gmail.com (Arjen Stolk) Date: Thu, 11 Aug 2016 14:25:13 -0700 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: Message-ID: Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) : > I did something and it works but it is not correct . > > I specified cfg.trl = data.trial{1,1} > > > cfg = []; > cfg.bpfilter = 'yes'; > cfg.demean = 'yes'; > data.trial{1,1} = eeg.eeg_data; > cfg.trl = data.trial{1,1}; > data.time{1,1} = 1:size(eeg.eeg_data,2); > data.label{1,1} = 'chan 1'; > data.label{2,1} = 'chan 2'; > data.label{3,1} = 'chan 3'; > data.label{4,1} = 'chan 4'; > data.label{5,1} = 'chan 5'; > data.label{6,1} = 'chan 6'; > data.label{7,1} = 'chan 7'; > data.label{8,1} = 'chan 8'; > data.fsample = eeg.samp_rate; > newdata = ft_redefinetrial(cfg,data); > > the newdata.time and newdata.trial are <1*8 cell > . some of the cells > are empty and one is NAN. > > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > *Sent:* Thursday, August 11, 2016 2:00:52 PM > > *To:* FieldTrip discussion list > *Subject:* Re: [FieldTrip] reading .mat in fieldtrip > > > Thanks but none of the options works. > > The error is : > > you should specify at least one configuration option. > > > Even cfg.demean = 'yes'; is not enough. > > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > *Sent:* Thursday, August 11, 2016 1:47:18 PM > *To:* FieldTrip discussion list > *Subject:* Re: [FieldTrip] reading .mat in fieldtrip > > > Hi. > > You can create an empty cfg structure, and fill with data : > > cfg =[]; > newdata = ft_redefinetrial(cfg,data); > > El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" < > belahian at memphis.edu> escribió: > >> Thanks for the answer, >> >> I have had a look on this page before and I tried to follow the steps. >> The problem is ;I do not have any cfg to define cfg.trl and use newdata >> = ft_redefinetrial(cfg,data); >> >> Any other idea? >> >> >> >> On Aug 11, 2016, at 11:36 AM, Arjen Stolk wrote: >> >> Hi Bahareh, >> >> To get you started, see this page: >> http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat >> >> It describes what fieldtrip expects your raw data to look like. >> >> Arjen >> >> 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) < >> belahian at memphis.edu>: >> >>> Hi All, >>> >>> >>> >>> I have a “.mat” file which contais: <8x10350000 double> and sampling >>> rate. >>> >>> How should I import this data to field trip? By using [data] = >>> ft_preprocessing( cfg); >>> >>> I am getting an error that the data should be in the format of raw or >>> raw + comp. >>> >>> >>> >>> Any idea? >>> >>> >>> >>> Thanks! >>> >>> >>> >>> >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 23:32:18 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 21:32:18 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: That was a good point. The problem is I do not want to specify any trial for my configuration. As I mentioned before if I leave cfg =[]; if gives me an error. ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Arjen Stolk Sent: Thursday, August 11, 2016 4:25:13 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) >: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a “.mat” file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Thu Aug 11 23:38:33 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Thu, 11 Aug 2016 21:38:33 +0000 Subject: [FieldTrip] reading .mat in fieldtrip In-Reply-To: References: , Message-ID: Thanks all, The problem is fixed: Here is the answer : cfg = []; cfg.demean = 'yes'; % base correction data.trial{1,1} = eeg.eeg_data; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; [data1] = ft_preprocessing (cfg, data); _____ Bahar ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Arjen Stolk Sent: Thursday, August 11, 2016 4:25 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Bahareh, according to http://www.fieldtriptoolbox.org/reference/ft_redefinetrial (or 'help ft_redefinetrial') cfg.trl should be [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_redefinetrial – FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type “help ft_redefinetrial”. FT_REDEFINETRIAL allows you to ... [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_redefinetrial – FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type “help ft_redefinetrial”. FT_REDEFINETRIAL allows you to ... cfg.trl = Nx3 matrix with the trial definition, For example, according to the page mentioned earlier (I suggest you actually read it this time: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat) cfg.trl = [1 100 -10; 101 200 -10; 201 300 -10]; In contrast, you specified data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; It's my guess that eeg.eeg_data is that 8x10350000 matrix you imported, meaning your cfg.trl specification is off (it should be Nx3). 2016-08-11 12:23 GMT-07:00 Bahareh Elahian (belahian) >: I did something and it works but it is not correct . I specified cfg.trl = data.trial{1,1} cfg = []; cfg.bpfilter = 'yes'; cfg.demean = 'yes'; data.trial{1,1} = eeg.eeg_data; cfg.trl = data.trial{1,1}; data.time{1,1} = 1:size(eeg.eeg_data,2); data.label{1,1} = 'chan 1'; data.label{2,1} = 'chan 2'; data.label{3,1} = 'chan 3'; data.label{4,1} = 'chan 4'; data.label{5,1} = 'chan 5'; data.label{6,1} = 'chan 6'; data.label{7,1} = 'chan 7'; data.label{8,1} = 'chan 8'; data.fsample = eeg.samp_rate; newdata = ft_redefinetrial(cfg,data); the newdata.time and newdata.trial are <1*8 cell > . some of the cells are empty and one is NAN. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Bahareh Elahian (belahian) > Sent: Thursday, August 11, 2016 2:00:52 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Thanks but none of the options works. The error is : you should specify at least one configuration option. Even cfg.demean = 'yes'; is not enough. ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Antonio Rodriguez > Sent: Thursday, August 11, 2016 1:47:18 PM To: FieldTrip discussion list Subject: Re: [FieldTrip] reading .mat in fieldtrip Hi. You can create an empty cfg structure, and fill with data : cfg =[]; newdata = ft_redefinetrial(cfg,data); El 11 ago. 2016 7:11 p. m., "Bahareh Elahian (belahian)" > escribió: Thanks for the answer, I have had a look on this page before and I tried to follow the steps. The problem is ;I do not have any cfg to define cfg.trl and use newdata = ft_redefinetrial(cfg,data); Any other idea? On Aug 11, 2016, at 11:36 AM, Arjen Stolk > wrote: Hi Bahareh, To get you started, see this page: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat It describes what fieldtrip expects your raw data to look like. Arjen 2016-08-11 8:42 GMT-07:00 Bahareh Elahian (belahian) >: Hi All, I have a “.mat” file which contais: <8x10350000 double> and sampling rate. How should I import this data to field trip? By using [data] = ft_preprocessing( cfg); I am getting an error that the data should be in the format of raw or raw + comp. Any idea? Thanks! _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 12 02:19:48 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 00:19:48 +0000 Subject: [FieldTrip] FEM in FieldTrip Message-ID: Hello, I would like to implement subject-specific FEM head/dipole models in FieldTrip. Searching the FieldTrip site has not given me enough information, and some of the simbio links are broken. Can someone please inform me as to the state of the FEM code in FieldTrip, and where I can find the documentation? I can find the simbio folder with about 25 files, but no documentation. Thanks, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 12 02:52:43 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 00:52:43 +0000 Subject: [FieldTrip] how do embed a dipole model in a FEM head model? Message-ID: Please ignore my previous request for FEM documentation, as I finally found this: http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. Please advise how to create a source model in this case. Thanks, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorw01 at gmail.com Fri Aug 12 03:47:00 2016 From: j.vorw01 at gmail.com (Johannes Vorwerk) Date: Thu, 11 Aug 2016 19:47:00 -0600 Subject: [FieldTrip] how do embed a dipole model in a FEM head model? In-Reply-To: References: Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54@googlemail.com> Hi Jeff, I am not sure if we have the same understanding of a „source model“, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ¨ J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267–278. C. H. Wolters, H. Kostler, C. M ¨ oller, J. H ¨ ardtlein, and A. Anwander ¨ , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189–192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. I hope this helps. Best, Johannes > Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : > > Please ignore my previous request for FEM documentation, as I finally found this: > > http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio > > Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. > > Please advise how to create a source model in this case. > > Thanks, > -Jeff > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From rhancock at email.arizona.edu Fri Aug 12 05:44:04 2016 From: rhancock at email.arizona.edu (Roeland Hancock) Date: Thu, 11 Aug 2016 20:44:04 -0700 Subject: [FieldTrip] Postdoctoral and Research Associate Positions at Haskins Laboratories Message-ID: Please see the below announcements for two research associate positions and one postdoctoral position at Haskins Laboratories — successful applicants for all positions will work on NIH funded projects focused on the neurobiology of reading development and reading disability. *Job Announcement, July 2016: Postdoctoral Fellow* Haskins Laboratories, 300 George Street, Suite 900, New Haven CT 06511 Qualified individuals are invited to apply for a full-time Postdoctoral Fellow position in the Haskins Imaging Lab (http://www.haskins.yale.edu/hil/) at Haskins Laboratories. This position is supported by a new 5-year NIH grant on the cognitive neuroscience of language and reading development in children ages 6-12. Specifically, this project will use Magnetic Resonance Spectroscopy (MRS) alongside fMRI, EEG, and behavioral techniques to understand typical and atypical language development. The successful candidate will report to Project Co-Investigators Dr. Kenneth Pugh and Dr. Fumiko Hoeft, work closely with Director of Neuroimaging Research Dr. Einar Mencl and the Director of EEG research Dr. Nicole Landi, and be responsible for coordination of multimodal imaging, data analysis, journal article reporting, and supervision of Research Associates. The successful candidate will join a team of researchers investigating the neural bases of speech, language and reading using data from fMRI, EEG/ERP, fNIRS, ultrasound, EMG and behavioral data from typical individuals, and individuals with language disorders. This candidate will have the opportunity to work on several projects on this grant, and to collaborate with researchers at Haskins, University of Connecticut and Yale University. *Minimum Qualifications* • Ph.D. in Psychology, Cognitive Science, Neuroscience, Communication Disorders, Linguistics, or related field • Significant research in cognitive neuroscience of language • Excellent interpersonal skills • Excellent verbal and written communication skills *Preferred Qualifications* • Experience with fMRI/sMRI, MRS, EEG data collection and analysis • Experience with experimental presentation software such as E-Prime or PsychoPy • Experience working with children • Data analysis and manipulation skills (e.g., Matlab, R, Python) The initial appointment will be for one year, renewable after the first year. Interested applicants should contact Tammy Ursini, Administrative Coordinator (ursini at haskins.yale.edu) with cover letter, resume, copy of (unofficial) transcripts, and the names of three potential references. Please note “Job Posting 5016”, in the subject line of your email. This position will remain open until filled, with an anticipated start date in fall 2016. Compensation is commensurate with skills and experience. Haskins Laboratories (www.haskins.yale.edu) is a private, non-profit research institute with a primary focus on speech, language, reading, and their biological basis. Haskins has long-standing, formal affiliations with the University of Connecticut and Yale University. Haskins Laboratories is an Equal Opportunity Employer. ------------------------------ *Job Announcement, July 2016: Research Associate (2)* Haskins Laboratories, 300 George Street, Suite 900, New Haven CT 06511 Project Director: Dr. Kenneth Pugh Qualified individuals are invited to apply for two full-time Research Associate positions at Haskins Laboratories. The successful candidates will join a team of researchers investigating the cognitive and neural bases of reading and language development using behavioral and neuroimaging data (fMRI, EEG and NIRS) in typically developing and language impaired children and adolescents. We are accepting applications for two related positions: 1) *Behavioral testing and coordination*. This position will involve hands on collection of behavioral and neuroimaging data, including standardized assessments, with young children and adolescents. Applicants for this position must have experience working with young children. 2) *Neuroimaging analysis and management*. This position will involve both routine data manipulation and organization of neuroimaging data (MRI/fMRI, EEG, fNIRS), as well as assisting with development of new analysis strategies. Specific requirements for this position include strong computing skills (scripting, data management) and data analysis skills. Requirements include: • BA or BS in Psychology, Cognitive Science, Computer Science or related field Additional relevant skills include: • Experience with human research • Experience administering standardized assessments • Experience with neuroimaging • Experience with experimental presentation software packages (e.g., E-PRIME, Presentation, PsychoPy) • Experience with statistical analysis (e.g., SPSS, R, Matlab) • Experience with data management software (e.g., FileMaker, Access, RedCap) Interested applicants should contact Tammy Ursini, Administrative Coordinator (ursini at haskins.yale.edu ) with cover letter, resume, copy of (unofficial) transcripts, and the names of three potential references. Please note “Job Posting 5015”, in the subject line of your email and also indicate which of the two positions you are interested in. These positions will remain open until filled, with an anticipated start date of September, 2016. Compensation is commensurate with skills and experience. Haskins Laboratories (www.haskins.yale.edu) is a private, non-profit research institute with a primary focus on speech, language, reading, and their biological basis. Haskins has long-standing, formal affiliations with the University of Connecticut and Yale University. Haskins Laboratories is an Equal Opportunity Employer. Roeland Hancock, PhD Postdoctoral Researcher Department of Psychiatry UCSF Weill Institute for Neurosciences University of California, San Francisco 401 Parnassus Avenue San Francisco, CA 94143 brainLENS.org -------------- next part -------------- An HTML attachment was scrubbed... URL: From Adham.Elshahabi at med.uni-tuebingen.de Fri Aug 12 10:06:44 2016 From: Adham.Elshahabi at med.uni-tuebingen.de (Adham Elshahabi) Date: Fri, 12 Aug 2016 10:06:44 +0200 Subject: [FieldTrip] =?utf-8?q?Postdoc_Position_in_T=C3=BCbingen=2C_German?= =?utf-8?q?y?= Message-ID: <57AD9FB4020000EF0001D6FA@vslgwd5> Dear Fieldtrip community, please find attached a job offer for 1 Postdoc positon in Tübingen for simultaneous PET/fMRI/EEG in small animals. For mor information, please contact Hans directly: hans.wehrl at med.uni-tuebingen.de Best regards, Adham Elshahabi University Hospital Tübingen MEG Center http://meg.medizin.uni-tuebingen.de -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: PostDoc_PETMREEG_Tuebingen.pdf Type: application/pdf Size: 231850 bytes Desc: Acrobat URL: From brungio at gmail.com Fri Aug 12 13:52:47 2016 From: brungio at gmail.com (Bruno L. Giordano) Date: Fri, 12 Aug 2016 12:52:47 +0100 Subject: [FieldTrip] Optimizing leadfield computation Message-ID: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Hi, I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? Thank you, Bruno -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bruno L. Giordano, PhD Institute of Neuroscience and Psychology 58 Hillhead Street, University of Glasgow Glasgow, G12 8QB, Scotland T +44 (0) 141 330 5484 Www: http://www.brunolgiordano.net Email charter: http://www.emailcharter.org/ From jan.schoffelen at donders.ru.nl Fri Aug 12 14:16:17 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 12:16:17 +0000 Subject: [FieldTrip] Optimizing leadfield computation In-Reply-To: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> References: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Message-ID: Hi Bruno, I don’t know about the low-level details of the computation in meg_forward, but I’d take your word on that it allows for multiple positions simultaneously. With respect to the leadfield calculation as such, we typically recommend to pre-compute them once (and store them for later use), and input a source-model with these pre-computed leadfields in ft_sourceanalysis. This typically works if you keep the signal subspace for which you computed your leadfields consistent with the signal subspace of the sensor-data. We are aware that apart from this FT's beamformer code is relatively slow (even with precomputed leadfields), but at some point in the past we decided to go for code clarity and correctness, rather than to go for computational speed. Doing all computations vectorized will make the code quite opaque (and moreover is not really straightforward if one would like to stay flexible with respect to location specific dimensions of vector leadfields (e.g. regional sources). Given all other steps in typical data processing pipelines, the beamformer step is usually not the time limiting one. Best, Jan-Mathijs > On 12 Aug 2016, at 13:52, Bruno L. Giordano wrote: > > Hi, > > I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). > > It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? > > Thank you, > > Bruno > > > -- > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > Bruno L. Giordano, PhD > Institute of Neuroscience and Psychology > 58 Hillhead Street, University of Glasgow > Glasgow, G12 8QB, Scotland > T +44 (0) 141 330 5484 > Www: http://www.brunolgiordano.net > Email charter: http://www.emailcharter.org/ > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip From brungio at gmail.com Fri Aug 12 15:10:00 2016 From: brungio at gmail.com (Bruno L. Giordano) Date: Fri, 12 Aug 2016 14:10:00 +0100 Subject: [FieldTrip] Optimizing leadfield computation In-Reply-To: References: <900bddfb-8ad3-40e7-3d4b-60604b404201@gmail.com> Message-ID: <1b80e222-21e2-ef03-9e4b-36481b9b7a74@gmail.com> Hi Jan-Mathijs, thanks. I will check what I can do then. Leadfield computation becomes quite lengthy when one has a large number of blocks for a large number of participants, and would like to have finer than usual grids ;-) And yes, I compute them only once. I understand the philosophy of the development team, it makes perfect sense. Indeed, optimized code can be at times not very transparent. However, the most important aspect of the optimization would simply require replacing loops through the dipoles with mtimesx-based matrix multiplications. If you guys are interested, I can send the functions I have written, so that you can see how they operate. Cheers, Bruno On 12/08/2016 13:16, Schoffelen, J.M. (Jan Mathijs) wrote: > Hi Bruno, > > I don’t know about the low-level details of the computation in meg_forward, but I’d take your word on that it allows for multiple positions simultaneously. > > With respect to the leadfield calculation as such, we typically recommend to pre-compute them once (and store them for later use), and input a source-model with these pre-computed leadfields in ft_sourceanalysis. This typically works if you keep the signal subspace for which you computed your leadfields consistent with the signal subspace of the sensor-data. > > We are aware that apart from this FT's beamformer code is relatively slow (even with precomputed leadfields), but at some point in the past we decided to go for code clarity and correctness, rather than to go for computational speed. Doing all computations vectorized will make the code quite opaque (and moreover is not really straightforward if one would like to stay flexible with respect to location specific dimensions of vector leadfields (e.g. regional sources). Given all other steps in typical data processing pipelines, the beamformer step is usually not the time limiting one. > > Best, > Jan-Mathijs > >> On 12 Aug 2016, at 13:52, Bruno L. Giordano wrote: >> >> Hi, >> >> I wonder whether the leadfield computation (singleshell) can be made faster by avoiding loops through the dipoles (e.g., avoiding dipole loops makes the beamformer >20 times faster). >> >> It seems like the most time consuming part of the leadfield computation is meg_forward.m Am I correct in concluding that this function accepts multiple dipoles in input? >> >> Thank you, >> >> Bruno >> >> >> -- >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> Bruno L. Giordano, PhD >> Institute of Neuroscience and Psychology >> 58 Hillhead Street, University of Glasgow >> Glasgow, G12 8QB, Scotland >> T +44 (0) 141 330 5484 >> Www: http://www.brunolgiordano.net >> Email charter: http://www.emailcharter.org/ >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bruno L. Giordano, PhD Institute of Neuroscience and Psychology 58 Hillhead Street, University of Glasgow Glasgow, G12 8QB, Scotland T +44 (0) 141 330 5484 Www: http://www.brunolgiordano.net Email charter: http://www.emailcharter.org/ From belahian at memphis.edu Fri Aug 12 16:51:32 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 14:51:32 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis Message-ID: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 17:08:20 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 15:08:20 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: Message-ID: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Fri Aug 12 17:15:54 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 15:15:54 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> References: , <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of Schoffelen, J.M. (Jan Mathijs) Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 17:59:13 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 15:59:13 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: It is correct as far as the data.fsample is consistent with this (which I suspect it isn’t). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Fri Aug 12 18:09:22 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Fri, 12 Aug 2016 16:09:22 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> , Message-ID: Thanks for suggestions. The data.fsample is 30K. I want to see HFOs in time- frequency plot. Wavelet is one solution of that. The error which I am getting is coming from padding and I do not know where should I fix it. What should I do if I do not want any padding? Bahar On Aug 12, 2016, at 11:04 AM, Schoffelen, J.M. (Jan Mathijs) > wrote: It is correct as far as the data.fsample is consistent with this (which I suspect it isn't). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis - FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 12 18:32:42 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 12 Aug 2016 16:32:42 +0000 Subject: [FieldTrip] Wavelet- Time frequency analysis In-Reply-To: References: <42CF7DF8-9A75-4B8D-9C02-B8E0DD9DFB81@donders.ru.nl> Message-ID: If your sampling rate is 30K, then your time axis should be something like (1:size(data.trial{1},1))./data.fsample; rather than 1:some-number On 12 Aug 2016, at 18:09, Bahareh Elahian (belahian) > wrote: Thanks for suggestions. The data.fsample is 30K. I want to see HFOs in time- frequency plot. Wavelet is one solution of that. The error which I am getting is coming from padding and I do not know where should I fix it. What should I do if I do not want any padding? Bahar On Aug 12, 2016, at 11:04 AM, Schoffelen, J.M. (Jan Mathijs) > wrote: It is correct as far as the data.fsample is consistent with this (which I suspect it isn’t). If you are interested in HFO, why not bandpassfilter your data and do a Hilbert transform? Best, Jan-Mathijs On 12 Aug 2016, at 17:15, Bahareh Elahian (belahian) > wrote: Thanks for the answer, They are the same actually my cfg.toi is my data.time. I specified them the same as each other . was it right? ________________________________ From: fieldtrip-bounces at science.ru.nl > on behalf of Schoffelen, J.M. (Jan Mathijs) > Sent: Friday, August 12, 2016 10:08:20 AM To: FieldTrip discussion list Subject: Re: [FieldTrip] Wavelet- Time frequency analysis Note that the units of the time points specified in cfg.toi should coincide with the units in the time axis of the data, i.e. data.time. JM On 12 Aug 2016, at 16:51, Bahareh Elahian (belahian) > wrote: Hi All, I am trying to apply wavelet on my signal to see HFOs. According to http://www.fieldtriptoolbox.org/tutorial/timefrequencyanalysis I wrote the following lines but I will get an error that: "the padding that you specified is shorter than the data". As far as I understood 'maxperlen' is the default. Any other idea for padding or solving this problem? [https://www.bing.com/th?id=OVP.V249f2fff057aa7a9c87ce8b67ec6c972&pid=Api] tutorial:timefrequencyanalysis – FieldTrip www.fieldtriptoolbox.org cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; cfg.channel = 'chan 4'; cfg.toi = 1:size(eeg.eeg_data,2); cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); data1 is my data which I get by applying ft_preprocessing. _________________________________________________ Bahar _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Sat Aug 13 00:53:09 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 12 Aug 2016 22:53:09 +0000 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 In-Reply-To: References: Message-ID: Johannes, I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. In my naïve view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. Thanks, -Jeff Message: 3 Date: Thu, 11 Aug 2016 19:47:00 -0600 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] how do embed a dipole model in a FEM head model? Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54 at googlemail.com> Content-Type: text/plain; charset="utf-8" Hi Jeff, I am not sure if we have the same understanding of a ?source model?, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ? J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267?278. C. H. Wolters, H. Kostler, C. M ? oller, J. H ? ardtlein, and A. Anwander ? , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189?192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. I hope this helps. Best, Johannes > Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : > > Please ignore my previous request for FEM documentation, as I finally found this: > > http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio > mbio> > > Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. > > Please advise how to create a source model in this case. > > Thanks, > -Jeff > From j.vorw01 at gmail.com Sat Aug 13 01:09:29 2016 From: j.vorw01 at gmail.com (Johannes Vorwerk) Date: Fri, 12 Aug 2016 17:09:29 -0600 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 In-Reply-To: References: Message-ID: <41C233E2-F2D6-46A0-A9F3-0A317F1A82CD@googlemail.com> I see. Your missunderstanding is that the dipoles are „represented“ through hexaedrons (and that you need to implement this ;-)). The idea that is usually used to derive FEM for EEG is to stick to the model of a dipole and to represent this dipole through the FEM basis functions. One method to do this (the „Venant approach“) is already implemented in fieldtrip. The way this representation is achieved is described in the papers I mentioned. If you do not want to use a different approach here, no further work on your side is needed. What you refer to as a „source model“ is what I would call „source space“ (since „source model“ can be easily mixed up…). The source space can be defined just as you would do it for spheres and BEM in fieldtrip. To apply FEM, you have to indicate to fieldtrip to generate a hexahedral head model and „simbio“ as method of forward computation. Best, Johannes > Am 12.08.2016 um 16:53 schrieb K Jeffrey Eriksen : > > Johannes, > > I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. > > In my naïve view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. > > I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. > > Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. > > Thanks, > -Jeff > > Message: 3 > Date: Thu, 11 Aug 2016 19:47:00 -0600 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] how do embed a dipole model in a FEM head > model? > Message-ID: <768BFCED-6404-466B-AFC9-F12C3F15FD54 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Jeff, > > I am not sure if we have the same understanding of a ?source model?, but in the terminology that is familiar to me there is no need to explicitly define a source model. As source model a current dipole is chosen and by standard the Venant appraoch is implemented to model the current dipole, see for example > > H. Buchner, G. Knoll, M. Fuchs, A. Rienacker, R. Beckmann, M. Wagner, J. Silny, and ? J. Pesch, Inverse localization of electric dipole current sources in finite element models of the human head, Electroencephalography and Clinical Neurophysiology, 102 (1997), pp. 267?278. > C. H. Wolters, H. Kostler, C. M ? oller, J. H ? ardtlein, and A. Anwander ? , Numerical approaches for dipole modeling in finite element method based source analysis., International Congress Series, 1300 (June 2007), pp. 189?192. ISBN-13:978-0-444-52885-8, http://dx.doi.org/10.1016/j.ics.2007.02.014. > J. Vorwerk, M. Clerc, M. Burger, and C. H. Wolters, Comparison of boundary element and finite element approaches to the EEG forward problem., Biomedizinische Technik. Biomedical engineering, 57 (2012). > > or http://www.sci.utah.edu/~wolters/PaperWolters/2016/Vorwerk_Dissertation_2016.pdf where you can also find a basic explanation of the FieldTrip-SimBio pipeline. > > I hope this helps. > > Best, > Johannes > >> Am 11.08.2016 um 18:52 schrieb K Jeffrey Eriksen : >> >> Please ignore my previous request for FEM documentation, as I finally found this: >> >> http://www.fieldtriptoolbox.org/tutorial/headmodel_eeg_fem?s[]=simbio >> > mbio> >> >> Reading through the above tutorial, there is no mention of how to define a source model to match an FEM head model. I cannot find this using what I consider as reasonable search terms. >> >> Please advise how to create a source model in this case. >> >> Thanks, >> -Jeff >> > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip From c.monroy at donders.ru.nl Mon Aug 15 15:34:41 2016 From: c.monroy at donders.ru.nl (Monroy, C.D. (Claire)) Date: Mon, 15 Aug 2016 13:34:41 +0000 Subject: [FieldTrip] ft_singleplotER Message-ID: <88359EE60C7B4649B4765DEE86343C614F106DF3@exprd01.hosting.ru.nl> Hi! Has anyone ever tried to plot shaded error bars around the ERP waveforms when using ft_singleplotER? If so, could someone share with me how they did this? Claire Monroy PhD student Baby Research Center Donders Institute for Brain, Cognition and Behaviour, Centre for Cognition Room B.01.18 Phone: +31 (0) 24 36 55977 Email: c.monroy at donders.ru.nl -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Mon Aug 15 16:18:15 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Mon, 15 Aug 2016 14:18:15 +0000 Subject: [FieldTrip] Odd behavior in DICS Message-ID: Hello All, I'm getting strange results from DICS applied to EEG data. I'm wondering if anyone else has run into these issues and/or can suggest a solution. I don't have individual sMRI so I'm using the standard BEM and MRI that come with FT. I constructed the lead fields as follows. First, I constrain the dipoles of interest to the cortical mantle using the AAL atlas. I then compute the lead fields using ft_prepare_leadfields; I don't have a baseline for these data so the lead fields are normalized. I feed the precomputed lead fields and data into ft_sourceanalysis to find the source-level power for each subject. 1) DICS, but not eLORETA, returns extremely large results at certain voxels. These extrema dominate the grand averages. In each subject, these voxels are always at the edge of the cortex, near the skull. The voxel locations are not exactly the same across subjects, but for any given subject they tend to appear in one of a few locations (i.e. over the right occipital cortex). The lead fields have the same magnitude (following normalization) across all voxels. I did notice, however, that voxels at which extreme values appear tend to have a larger condition number (~12) than voxels at which abnormal values do not appear in any subject (~2). I do not know whether this is relevant but I thought it might have some effect on adaptive but not non-adaptive filters. Since I'm constructing the forward model using FT templates, I thought someone else might have encountered this problem before. 2) As I mentioned above, eLORETA does not return such extreme results; furthermore, when we contrast controls with schizophrenia patients using an independent samples t-test with cluster control for multiple comparisons we find significant differences between groups using eLORETA but not DICS. The raw differences between the grand averages returned by DICS and eLORETA are similar, but when we run stats using DICS most of the correct p values are equal to 1 with one or two in the 0.8-0.9 range. I'm looking for converging evidence between different source analysis methods and it's not clear to me why DICS and eLORETA return such different results. 3) I thought that voxels are which unusually large values occur in controls and patients could be throwing off the stats; however, DICS does not return significant contrasts between control and schizophrenia even when I mask out the extreme voxels. Thanks in advance for any advice. Best, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From dippel.g at gmail.com Mon Aug 15 17:46:30 2016 From: dippel.g at gmail.com (gab dippel) Date: Mon, 15 Aug 2016 17:46:30 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: Dear Fieldtrippers, my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. So the goal is to compute the virtual channels of a certain atlas region let say the SMA. As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) --> So here I construct an MRI based grid 
 load standard_mri.mat cfg = []; cfg.mri = mri; template_grid = ft_prepare_sourcemodel(cfg); this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) --> this is obsolete in my case i guess 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': cfg = []; cfg.grid.xgrid = -90:1:90; cfg.grid.ygrid = -108:1:108; cfg.grid.zgrid = -90:1:90; cfg.grid.unit = 'mm'; cfg.grid.tight = 'yes'; cfg.mri = mri; high_res_grid_mm = ft_prepare_sourcemodel(cfg) 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. I would appreciate any feedback and ideas on this issue. Kind regards, Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From azeez.adebimpe5 at gmail.com Mon Aug 15 17:50:18 2016 From: azeez.adebimpe5 at gmail.com (Azeez Adebimpe) Date: Mon, 15 Aug 2016 11:50:18 -0400 Subject: [FieldTrip] Odd behavior in DICS In-Reply-To: References: Message-ID: Hi Alexander, DICS also works similarly to eLORETA but you need to remove bias after you compute the source. 1. Estimate the noise from the data with cfg.dics.projectnoise='yes'; the default is no, so you need to set it while computing source. 2. Divide the pow by noise estimate Sourcedb=source; Sourcedb.avg.pow=sourcedb.avg.pow./sourcedb.avg.noise; 3. plot the Sourcedb.avg.pow; to see hope it help, Best, Azeez On Mon, Aug 15, 2016 at 10:18 AM, Nakhnikian, Alexander < Alexander_Nakhnikian at hms.harvard.edu> wrote: > Hello All, > > > I'm getting strange results from DICS applied to EEG data. I'm wondering > if anyone else has run into these issues and/or can suggest a solution. > > > I don't have individual sMRI so I'm using the standard BEM and MRI that > come with FT. I constructed the lead fields as follows. First, I constrain > the dipoles of interest to the cortical mantle using the AAL atlas. I then > compute the lead fields using ft_prepare_leadfields; I don't have a > baseline for these data so the lead fields are normalized. I feed the > precomputed lead fields and data into ft_sourceanalysis to find the > source-level power for each subject. > > > 1) DICS, but not eLORETA, returns extremely large results at certain > voxels. These extrema dominate the grand averages. In each subject, these > voxels are always at the edge of the cortex, near the skull. The voxel > locations are not exactly the same across subjects, but for any given > subject they tend to appear in one of a few locations (i.e. over the right > occipital cortex). The lead fields have the same magnitude (following > normalization) across all voxels. I did notice, however, that voxels at > which extreme values appear tend to have a larger condition number (~12) > than voxels at which abnormal values do not appear in any subject (~2). I > do not know whether this is relevant but I thought it might have some > effect on adaptive but not non-adaptive filters. Since I'm constructing the > forward model using FT templates, I thought someone else might have > encountered this problem before. > > > 2) As I mentioned above, eLORETA does not return such extreme results; > furthermore, when we contrast controls with schizophrenia patients using an > independent samples t-test with cluster control for multiple comparisons we > find significant differences between groups using eLORETA but not DICS. The > raw differences between the grand averages returned by DICS and eLORETA are > similar, but when we run stats using DICS most of the correct p values are > equal to 1 with one or two in the 0.8-0.9 range. I'm looking for converging > evidence between different source analysis methods and it's not clear to me > why DICS and eLORETA return such different results. > > > 3) I thought that voxels are which unusually large values occur in > controls and patients could be throwing off the stats; however, DICS does > not return significant contrasts between control and schizophrenia even > when I mask out the extreme voxels. > > > Thanks in advance for any advice. > > > Best, > > > Alexander > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Alexander_Nakhnikian at hms.harvard.edu Mon Aug 15 17:56:31 2016 From: Alexander_Nakhnikian at hms.harvard.edu (Nakhnikian, Alexander) Date: Mon, 15 Aug 2016 15:56:31 +0000 Subject: [FieldTrip] Voxel Size Message-ID: Hi All, Sorry for putting up two posts in one day but these are different issues so I didn't want to cram them into one thread. How does FT determine the voxel size used in source analysis? Does it come from the resolution of the grid used to generate the lead fields or are there other factors? If the voxel size varies depending on the source localization parameters, does FT store this information? I'd like to be able to report the voxel size used for out analysis. Thank you, Alexander -------------- next part -------------- An HTML attachment was scrubbed... URL: From evergreenlifeyangying at gmail.com Mon Aug 15 21:21:59 2016 From: evergreenlifeyangying at gmail.com (Ying Yang) Date: Mon, 15 Aug 2016 15:21:59 -0400 Subject: [FieldTrip] Stimulus(trigger) as an output channel in the biosemi2ft? Message-ID: Dear FieldTrip Community, My name is Ying Yang and I am a PhD candidate in the Center for the Neural Basis of Cognition, Carnegie Mellon University. I am trying to do real-time EEG acquisition with our Biosemi system. I am used to EEG processing/analysis in python, and would like use the "mne-python" package with the FieldTrip acquisition tool "biosemi2ft". In some initial tests on our Windows 64 bit platform, I ran in cmd biosemi2ft config.txt outputfile - 1972 and used the client object in FieldTrip.py. It seemed to work well. However, it would be really convenient if the recorded data also included the stimulus channel (the trigger channel or "status" channel). I know I can get some info about the trigger events with FieldTrip.Client.getEvents(), but it is more convenient to actually have the trigger channel as one of the channels in the data. >From the limited documentation on http://www.fieldtriptoolbox.org/development/realtime/biosemi, I could not figure out whether it was possible to do so. When I ran "biosemi2ft" on our system, the prompt output said there were 280 channels. So I have customized "config.txt" to select all 280 channels, but none of them seemed to be the trigger channel. So I would like to ask the community if it is possible to record the trigger channel. And if yes, how should I specify it in the "config.txt" file. I will appreciate any input or comment. Thank you. Best, Ying -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Tue Aug 16 00:44:17 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Mon, 15 Aug 2016 22:44:17 +0000 Subject: [FieldTrip] fieldtrip Digest, Vol 69, Issue 14 In-Reply-To: References: Message-ID: Johannes, I understand now, at least about the dipole implementation. The rest should come as I work with FieldTrip some more. Thanks for your help, -Jeff Message: 11 Date: Fri, 12 Aug 2016 17:09:29 -0600 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] fieldtrip Digest, Vol 69, Issue 13 Message-ID: <41C233E2-F2D6-46A0-A9F3-0A317F1A82CD at googlemail.com> Content-Type: text/plain; charset=utf-8 I see. Your misunderstanding is that the dipoles are ?represented? through hexahedrons (and that you need to implement this ;-)). The idea that is usually used to derive FEM for EEG is to stick to the model of a dipole and to represent this dipole through the FEM basis functions. One method to do this (the ?Venant approach?) is already implemented in fieldtrip. The way this representation is achieved is described in the papers I mentioned. If you do not want to use a different approach here, no further work on your side is needed. What you refer to as a ?source model? is what I would call ?source space? (since ?source model? can be easily mixed up?). The source space can be defined just as you would do it for spheres and BEM in fieldtrip. To apply FEM, you have to indicate to fieldtrip to generate a hexahedral head model and ?simbio? as method of forward computation. Best, Johannes > Am 12.08.2016 um 16:53 schrieb K Jeffrey Eriksen : > > Johannes, > > I an unfamiliar with the derivation you mention (Venant approach) and will read the papers you list here to try to understand it. > > In my naive view based on thinking about the spherical and BEM cases, the head model is simply a set of 3-4 nested volumes, and in the central volume one implements dipoles at particular locations, which can generally be located anywhere inside the innermost volume. In FEM the entire head volume is hexagons, and I see that FieldTrip/simbio uses a modified (distorted or warped) cubic voxel model for the hexagons. I would presume the simplest idea would be to equate particular gray matter (GM) hexagons with individual dipoles, and perhaps this is what the Venant approach does. > > I just do not know how to specify particular GM voxels to use as my set of dipoles. How do I address them since they have been distorted from their original cubic voxel shape? Maybe this will be more clear as I read these papers and do some more work with FieldTrip. > > Oh, I guess to me a "source model" is the set of generator locations and orientations. For spheres and BEM these could be point dipoles(1 or 3 per position) or perhaps 2D patches. For FEM these would be tetrahedrons or hexagons with 1 or 3 dipoles at each element used. > > Thanks, > -Jeff ************* From eriksenj at ohsu.edu Tue Aug 16 02:05:29 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Tue, 16 Aug 2016 00:05:29 +0000 Subject: [FieldTrip] importing Brainstorm head and source models and leftfields Message-ID: Hi, I am trying to do some forward and inverse simulations using a 3-shell BEM, and would prefer to import my model from Brainstorm where I have already created it. I can find one example of importing the cortical mesh from Brainstorm using ft_read_headshape with the 'matlab' format, but I cannot find anything on how to import the Brainstorm BEM head model or leadfield. Please point me to any further information on this topic, -Jeff -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Tue Aug 16 07:20:06 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Tue, 16 Aug 2016 05:20:06 +0000 Subject: [FieldTrip] importing Brainstorm head and source models and leftfields In-Reply-To: References: Message-ID: Hi Jeff, Probably this is not yet implemented. Since it is all matlab-based it should be pretty straightforward, once you know how the headmodel is represented in the Brainstorm .mat file. Once you have figured this out, it probably takes just a few lines of code in ft_read_headshape. If you have an updated version of this function, you can easily contribute it to the code-base for everyone’s use through git. How this can be done, is shown here: http://www.fieldtriptoolbox.org/development/git Best, Jan-Mathijs On 16 Aug 2016, at 02:05, K Jeffrey Eriksen > wrote: Hi, I am trying to do some forward and inverse simulations using a 3-shell BEM, and would prefer to import my model from Brainstorm where I have already created it. I can find one example of importing the cortical mesh from Brainstorm using ft_read_headshape with the ‘matlab’ format, but I cannot find anything on how to import the Brainstorm BEM head model or leadfield. Please point me to any further information on this topic, -Jeff _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Tue Aug 16 13:44:13 2016 From: julian.keil at gmail.com (Julian Keil) Date: Tue, 16 Aug 2016 13:44:13 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI In-Reply-To: References: Message-ID: <5B3236ED-05F6-41F3-9942-126116A25F9B@gmail.com> Hi Gabriel, have you tried using a grid with the exact same dimensions as the MRI, i.e.: %% Set the start and End of the x,y,z axis vox1 = mri.transform*[mri.dim,1]'; % start vox1 = vox1(1:3)/10; % convert to mm vox2 = mri.transform*[1,1,1,1]'; %end vox2 = vox2(1:3)/10; % convert to mm %% Choose the Minima vox_min = min([vox1,vox2]')'; vox_max = max([vox1,vox2]')'; %% Set the spacing vox_delta = abs(mri.transform*[1,1,1,1]'-mri.transform*[2,2,2,1]'); vox_delta = vox_delta(1:3)/10; % convert to mm RES = vox_delta(1); and then use: cfg.grid.xgrid = vox_min(1):RES:vox_max(1); cfg.grid.ygrid = vox_min(2):RES:vox_max(2); cfg.grid.zgrid = vox_min(3):RES:vox_max(3); Good luck, Julian Am 15.08.2016 um 17:46 schrieb gab dippel: > Dear Fieldtrippers, > > my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. > > So the goal is to compute the virtual channels of a certain atlas region let say the SMA. > As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. > > Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: > 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) > --> So here I construct an MRI based grid > > load standard_mri.mat > cfg = []; > cfg.mri = mri; > template_grid = ft_prepare_sourcemodel(cfg); > > this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. > > 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) > --> this is obsolete in my case i guess > > 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) > --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': > cfg = []; > cfg.grid.xgrid = -90:1:90; > cfg.grid.ygrid = -108:1:108; > cfg.grid.zgrid = -90:1:90; > cfg.grid.unit = 'mm'; > cfg.grid.tight = 'yes'; > cfg.mri = mri; > high_res_grid_mm = ft_prepare_sourcemodel(cfg) > > > 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) > --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. > > 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. > --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. > > I would appreciate any feedback and ideas on this issue. > > Kind regards, > > Gabriel > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From marco.rotonda at gmail.com Wed Aug 17 08:32:29 2016 From: marco.rotonda at gmail.com (Marco Rotonda) Date: Wed, 17 Aug 2016 08:32:29 +0200 Subject: [FieldTrip] FFT and filtering Message-ID: Hi Fieldtrippers, I had a quite simple question, even though I was not so sure how to respond. Let suppose I have an EEG raw signal and I'm interested on the mean amplitude of some bands (delta, theta, etc.). The signal is continuous so I take chunks of data (let say one second). Let suppose the signal is clean (no artifacts). Should I have to filter the signal before doing the FFT or I can just do the FFT of the signal and take the mean of the bands I'm interested on? Take care Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: From Gabriel.Dippel at uniklinikum-dresden.de Mon Aug 15 15:44:06 2016 From: Gabriel.Dippel at uniklinikum-dresden.de (Dippel, Gabriel) Date: Mon, 15 Aug 2016 13:44:06 +0000 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: <5C7F3323D8D9804D90AF6A7ED2611DE362F3D1E9@G06EDBN1.med.tu-dresden.de> Dear Fieldtrippers, my current question(s) has previously been answered here by Julian Keil: https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html yet I appear to face a conceptual problems in my understanding. So the goal is to compute the virtual channels of a certain atlas region let say the SMA. As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: 1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel) --> So here I construct an MRI based grid 
 load standard_mri.mat cfg = []; cfg.mri = mri; template_grid = ft_prepare_sourcemodel(cfg); this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain. 2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial) --> this is obsolete in my case i guess 3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel) --> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid': cfg = []; cfg.grid.xgrid = -90:1:90; cfg.grid.ygrid = -108:1:108; cfg.grid.zgrid = -90:1:90; cfg.grid.unit = 'mm'; cfg.grid.tight = 'yes'; cfg.mri = mri; high_res_grid_mm = ft_prepare_sourcemodel(cfg) 4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup) --> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels. 5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4. --> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here. I would appreciate any feedback and ideas on this issue. Kind regards, Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From ankanb06 at gmail.com Wed Aug 17 16:33:29 2016 From: ankanb06 at gmail.com (Ankan Biswas) Date: Wed, 17 Aug 2016 20:03:29 +0530 Subject: [FieldTrip] FFT and filtering In-Reply-To: References: Message-ID: *Hello Marco,* I think depending upon the sampling rate, you have set in the recording equipment, you may have a anti-aliasing filter. And as you don't know what are the frequency components in your signal before doing a fft, you may do a fft on the raw data which will give you the frequency components and then take the mean of the amplitude of the frequencies of the band you are interested in. Please correct *fieldtripers* if I am wrong. Thanks, Ankan On Wed, Aug 17, 2016 at 12:02 PM, Marco Rotonda wrote: > Hi Fieldtrippers, > I had a quite simple question, even though I was not so sure how to > respond. > Let suppose I have an EEG raw signal and I'm interested on the mean > amplitude of some bands (delta, theta, etc.). > The signal is continuous so I take chunks of data (let say one second). > Let suppose the signal is clean (no artifacts). > Should I have to filter the signal before doing the FFT or I can just do > the FFT of the signal and take the mean of the bands I'm interested on? > > Take care > > Marco > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From belahian at memphis.edu Wed Aug 17 17:11:56 2016 From: belahian at memphis.edu (Bahareh Elahian (belahian)) Date: Wed, 17 Aug 2016 15:11:56 +0000 Subject: [FieldTrip] Wavelet and time-frequency plot Message-ID: Hello All, I am trying to apply wavelet on my signal to see HFOs in time-frequency plot. The sampling rate of my signal is 30K. I will get an error: " Error using fft Out of memory. Type HELP MEMORY for your options. " here is what I wrote according to http://www.fieldtriptoolbox.org/reference/ft_freqanalysis: [http://www.fieldtriptoolbox.org/_media/logo-share.png] reference:ft_freqanalysis - FieldTrip www.fieldtriptoolbox.org Note that this reference documentation is identical to the help that is displayed in MATLAB when you type "help ft_freqanalysis". FT_FREQANALYSIS performs ... cfg= []; cfg.pad = 'maxperlen'; cfg.method = 'wavelet'; cfg.output = 'pow'; %cfg.channel = 'chan 4'; cfg.toi = (1:size(eeg.eeg_data,2))/Fs; % cfg.foilim = [80 500]; [freq] = ft_freqanalysis(cfg, data1); Do you have any idea? is it realted to my sampling rate? Thanks! Bahar -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Wed Aug 17 17:24:25 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 17 Aug 2016 17:24:25 +0200 Subject: [FieldTrip] valid workaround for nonparametric stats on cortical surface data? Message-ID: Hello Fieldtrip community, ft_statistics_montecarlo fails when it is called through ft_sourcestatistics with cortical surface (as opposed to a 3D volumetric grid) source data. To avoid this limitation, I can change my source level time series avg.mom into a sensor data structure (my electrodes are simply 'virtual' then), provide the source level neighborhood structure, and run ft_timelockstatistics on my 'virtual sensor' data set. As far as I can tell, this effectively gives source level statistics, just through the wrong function, so to speak. Since I am reading that ft_statistics_montecarlo might behave differently depending on which function is calling it.... FT_STATISTICS_MONTECARLO should not be called directly, instead you should call the function that is associated with the type of data on which you want to perform the test. % Use as % stat = ft_timelockstatistics(cfg, data1, data2, data3, ...) % stat = ft_freqstatistics (cfg, data1, data2, data3, ...) % stat = ft_sourcestatistics (cfg, data1, data2, data3, ...) ...I wanted to know whether there are some additional things to be aware of when using ft_timelockstatistics on source level virtual electrode time series. Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From V.Peter at westernsydney.edu.au Thu Aug 18 05:10:11 2016 From: V.Peter at westernsydney.edu.au (Varghese Peter) Date: Thu, 18 Aug 2016 03:10:11 +0000 Subject: [FieldTrip] Issues with trial by trial bad channel rejection Message-ID: <617B8E9395E43D47B7479C8FB3185E755320908C@hall.AD.UWS.EDU.AU> Dear fieldtrip community, I have 128 channel EEG data collected from young infants in an ERP paradigm. Since the EEG data from young infants are noisier than adults, I tried to implement a trial by trial bad channel correction. If a trial has more than 20 bad channels, reject the trial altogether and if the number of bad channels are less than 20, interpolate the bad channels. I have implemented this using the following script. It seems to work, but when I load the file after this step, it takes a long time to load it (up to 20 minutes) and all subsequent processing takes very long time. Is there a way to fix this? Thank you, Varghese indx=1; BadChannelCriterion=100; AllTrialsBadChannelLabels={}; datr={}; TrialNos=[]; for loop =1:length(I09_ADSStd_epochs2.trial), AllTrialsBadchannelIndex = find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion); SingleTrialBadChannelLabels= I09_ADSStd_epochs2.label(AllTrialsBadchannelIndex ); AllTrialsBadChannelLabels= [AllTrialsBadChannelLabels; SingleTrialBadChannelLabels]; if length(find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion))<20, BadchannelIndex = find(max(abs(I09_ADSStd_epochs2.trial{loop}),[],2)>BadChannelCriterion); BadchannelLabels=I09_ADSStd_epochs2.label(BadchannelIndex); cfg = []; cfg.layout= lay; cfg.badchannel = BadchannelLabels; cfg.method = 'spline'; cfg.neighbours = EEG_neighbours; cfg.trials = loop; datr{indx} = ft_channelrepair(cfg,I09_ADSStd_epochs2); TrialNos(indx)=loop; indx=indx+1; end end cfg = []; I09_ADSStd_epochs_clean = ft_appenddata(cfg, datr{:}); -------------- next part -------------- An HTML attachment was scrubbed... URL: From k.kessler at aston.ac.uk Fri Aug 19 12:39:33 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Fri, 19 Aug 2016 10:39:33 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham’s focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Professor Klaus Kessler Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From pooneh.baniasad at gmail.com Sun Aug 21 11:40:43 2016 From: pooneh.baniasad at gmail.com (pooneh baniasad) Date: Sun, 21 Aug 2016 14:10:43 +0430 Subject: [FieldTrip] The compartment nesting cannot be determined Message-ID: Dear FieldTrip community, I'm Pouneh baniasad and I'm working with FieldTrip due to my thesis. I've just read the conversation with this title in the FieldTrip listing mail but it didn't answer completely. I segmented the "Subject01.mri" into four slices as {'gray','csf','skull','scalp'}. After preparing mesh when I wanted to use ft_prepare_headmodel i got this error: "The compartment nesting cannot be determined". Furthermore I use BEM method for calculating. My nesting matrix and numboundries are as follows: numboundaries = 4 nesting = [0, 0, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1; 0, 0, 0, 0] ​I know the nesting matrix is not correct but don't have any idea what should i do. -- Bests Pouneh Baniasad -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Mon Aug 22 17:24:29 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Mon, 22 Aug 2016 15:24:29 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter Message-ID: Dear Fieldtrip Users, I am trying to compute non-parametric granger causality between several ROIs in source-space. I am using the following code to obtain the fourier-spectra of my sensor-level data. cfg = []; cfg.output = 'fourier'; cfg.method = 'mtmfft'; cfg.taper = 'dpss'; cfg.tapsmofrq = 4; cfg.keeptrials = 'yes'; cfg.pad = 1; cfg.padtype = 'zero'; freq = ft_freqanalysis(cfg, data_fix); I was wondering how to project the sensor level fourier-data into source space using the spatial filters computed when calling ft_sourceanalysis? I.e. how to multiply the freq*filter? I am little unsure how the fourierspctrm is represented and how this will feed into ft_connectivity analysis? Many thanks, Robert Seymour (PhD Student, Aston Brain Centre) -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Mon Aug 22 21:50:26 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Mon, 22 Aug 2016 19:50:26 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter In-Reply-To: References: Message-ID: <250771CD-30C7-451D-B7C7-EDE9C622FEEB@donders.ru.nl> Hi Robert, In principle it’s OK, and computationally efficient, to (left)-multiply the spatial filter with the fourier coefficients (in a for-loop across frequencies, or something like that), to get the source-level fourier representation. Practically, you would need to do something like: nchan = numel(freq.label); nfreq = numel(freq.freq); nrpttap = size(freq.fourierspctrm,1); fourier_source = filter*reshape(permute(freq.fourierspctrm,[2 3 1]), [nchan nfreq*nrpttap])); fourier_source = reshape(fourier_source, [nfreq nrpttap]); Now you have a nfreq*nrpttap matrix that represents per tapered data segment the fourierspctrm. From this representation, you would want to create the source pair-wise cross-spectral density that can be subjected to the non-parametric factorization code to compute Granger causality. That is, it’s more or less OK if you know what you’re doing, but can become tricky in terms of correct data administration/bookkeeping. Otherwise, and perhaps more straightforwardly, I’d recommend to do a time-domain source reconstruction (create a set of ‘virtual channels’, there’s are some examples in the wiki’s tutorials how to do it), and then use ft_freqanalysis and ft_connectivityanalysis on the virtual channel data. Best wishes, Jan-Mathijs On 22 Aug 2016, at 17:24, Seymour, Robert (Research Student) > wrote: Dear Fieldtrip Users, I am trying to compute non-parametric granger causality between several ROIs in source-space. I am using the following code to obtain the fourier-spectra of my sensor-level data. cfg = []; cfg.output = 'fourier'; cfg.method = 'mtmfft'; cfg.taper = 'dpss'; cfg.tapsmofrq = 4; cfg.keeptrials = 'yes'; cfg.pad = 1; cfg.padtype = 'zero'; freq = ft_freqanalysis(cfg, data_fix); I was wondering how to project the sensor level fourier-data into source space using the spatial filters computed when calling ft_sourceanalysis? I.e. how to multiply the freq*filter? I am little unsure how the fourierspctrm is represented and how this will feed into ft_connectivity analysis? Many thanks, Robert Seymour (PhD Student, Aston Brain Centre) _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruil3 at student.unimelb.edu.au Tue Aug 23 08:49:57 2016 From: ruil3 at student.unimelb.edu.au (Rui Li) Date: Tue, 23 Aug 2016 16:49:57 +1000 Subject: [FieldTrip] A Problem using cfg.channel = {'MEG'} and ft_preprocessing Message-ID: Dear fieldtrip users, I downloaded the fieldtrip toolbox: fieldtrip-20160820; cfg = []; cfg.dataset = dataset; cfg.channel = {'MEG'}; data = ft_preprocessing(cfg); The 'label' field in data is an empty cell, which leads to the mistakes in the following processing. I am wondering do you found the same problem? Is this a bug? Regards, Rui. -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Tue Aug 23 11:10:35 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Tue, 23 Aug 2016 09:10:35 +0000 Subject: [FieldTrip] Non-Parametric Granger Causality - Freq * Spatial Filter Message-ID: Thanks Jan-Mathijs, I'll try that. I've actually implemented your second suggestion (averaging over virtual electrodes and then calculating fourier/CSD) - do you think there would be any major difference between the two approaches? Cheers, Rob -------------- next part -------------- An HTML attachment was scrubbed... URL: From k.kessler at aston.ac.uk Tue Aug 23 11:59:10 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Tue, 23 Aug 2016 09:59:10 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham's focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Klaus Kessler (Professor of Cognitive Neuroscience) Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From haristz at umn.edu Wed Aug 24 04:05:56 2016 From: haristz at umn.edu (Haris Tzagarakis) Date: Tue, 23 Aug 2016 21:05:56 -0500 Subject: [FieldTrip] cluster statistics on dynamic ROI Message-ID: <57BD0104.1020204@umn.edu> Dear Fieldtripers, I have a question about cluster-based statistics at the source level using an ROI. The option cfg.roi exists in ft_sourceanalysis but requires the use of atlas anatomic labels. My case is slightly different in that I have an ROI defined dymamically by a prior source level analysis and I want to evaluate source level statistics only within the voxels of that ROI for a different parameter. I ended up creating volumes with the appropriate dimensions and setting all the volume array values for the parameter I want to test to NaN except for the voxels of the ROI. I also set up the "inside" field to contain the index values of the ROI voxels only. This seems to work when using cfg.correctm = 'cluster' (which is what I want) but was wondering if anyone can see a potential problem that I might be missing? With Best Wishes Haris -- Charidimos [Haris] Tzagarakis MD, PhD, MRCPsych University of Minnesota Dept of Neuroscience office: Brain Sciences Center Minneapolis VA Medical Center Tel:612-467-1363 From k.kessler at aston.ac.uk Wed Aug 24 15:11:53 2016 From: k.kessler at aston.ac.uk (Kessler, Klaus) Date: Wed, 24 Aug 2016 13:11:53 +0000 Subject: [FieldTrip] PhD on decision making with EEG in VR Message-ID: <52122e491dc744b2ba985d9d8fe45306@EXPRD03.hosting.ru.nl> Dear Fieldtrippers We would be grateful if you could disseminate the following PhD opportunity to suitable candidates. More info can be found on the Aston University website (https://jobs.aston.ac.uk/Vacancy.aspx?ref=R160328) or please contact me directly if you'd like to know more. Cheers Klaus Applications are invited from ambitious, self-motivated candidates to work on a PhD research project on decision making under stress. The project will be conducted as a collaboration between Aston University, the University of Nottingham, and the Tactical Training Centre of Cleveland & Durham Police. The aim is to use Electroencephalography (EEG) recordings in Virtual Reality (VR) environments to understand the neural mechanisms that differentiate good decisions from bad decisions in stressful scenarios. Nottingham’s focus will be on the physics of EEG data collection and analysis, while VR setups will be generated and tested with EEG at the new Aston Laboratories for Immersive Virtual Environments (ALIVE). The PhD will be primarily based at Aston and the project will involve (and include funds for) travelling between Aston, Nottingham, and Durham. Applicants must have a minimum of an Upper Second Class Honours degree in a related subject (e.g. physics, neuroscience, mathematics, computer science, engineering or psychology). Due to the nature of the project the successful candidate should also have excellent programming skills, strong mathematical ability and a good understanding of experimental science. Klaus Kessler (Professor of Cognitive Neuroscience) Aston Brain Centre School of Life and Health Sciences Aston University Aston Triangle Birmingham, B4 7ET Phone: +44 (0)121 204 3187 -------------- next part -------------- An HTML attachment was scrubbed... URL: From joseluisblues at gmail.com Wed Aug 24 18:04:07 2016 From: joseluisblues at gmail.com (Jose) Date: Wed, 24 Aug 2016 18:04:07 +0200 Subject: [FieldTrip] on spectral analysis of MEG data Message-ID: dear Fieldtrip community, I'm performing analysis of CTF MEG data. I have two conditions of interest: A and B, and I have performed spectral decomposition with the wavelet method to obtain the power (frequencies from 6 to 50 Hz). I have some questions regarding my analysis: 1. As a first approach I wanted to do analysis at the sensor level and then to move at the source level. This is a rather exploratory analysis. I have noted oscillatory activity when analysing ERFs, so I decided to perform spectral analysis but I don't have any a priori hypothesis about any frequency or sensor. I'm using a cluster-based permutation (CBP) test to evaluate significance, but I'm not sure how to do a multi-sensor analysis. Since I have computed the power from frequencies ranging from 6 to 50 Hz, I could perform a CBP test for each frequency, but this would become a multiple comparison problem isn't? Otherwise what I have see in some publications is to average across sensors, and do a permutation test similar to what is done in single-sensor analysis, 2. I have performed spectral analysis of my data for magnetometers and gradiometers. I was wondering if I should expect the same results for both magnetometers and gradiometers. Since the activity of the planar gradient do not cover the same sensors than the magnetometers I wouldn't expect it. However, perhaps the effects should fall within the same frequency boundaries? 3. I was wondering why in the "Within subjects experiments" example of the tutorial "Cluster-based permutation tests on time-frequency data" ( http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) the cfg.alpha is set to 0.025. Since the data are planar gradients, thus positive values, one would need to perform a one-side test, and thus an alpha of 0.05? Maybe in this case the data was baseline corrected and thus one would then have positive and negative values, might that be the case? As a general question, if I'm working with planar gradient data, I should need differentially set my alpha value regarding if is baseline-corrected or not, is that correct? 4. I have seen some publications that include an additional correction to the analysis after performing a permutation test. For instance, Busch et al (J Neurosc 2009) use a resampling test and the FDR method to test significance of differences in power in the Fz channel. The general question is when one can apply only a resampling/permutation test, and when one have to include a correction like FDR? Thanks in advance, Jose -------------- next part -------------- An HTML attachment was scrubbed... URL: From nugenta at mail.nih.gov Wed Aug 24 18:11:00 2016 From: nugenta at mail.nih.gov (Nugent, Allison C. (NIH/NIMH) [E]) Date: Wed, 24 Aug 2016 16:11:00 +0000 Subject: [FieldTrip] NIH MEG Workshop Message-ID: Reminder! A call for abstracts is currently open! We are soliciting abstracts based on the four themes for discussion below, as well as for a general scientific session. Visit http://megworkshop.nih.gov for more details. The abstract deadline has been extended to September 15st. At this meeting, we plan to address the following four themes: 1. What does MEG add to the field of neuroscience above and beyond other existing techniques? 2. How can we support the evolution of MEG acquisition and methods, through both software and hardware? 3. How can we develop and support infrastructure to share data and facilitate big science? 4. How could an MEG-North America consortium work to address these issues? Keynote Speakers: Sylvain Baillet, PhD, Director, MEG Core McGill University, McConnell Brain Imaging Center Dimitrios Pantazis, PhD, Director of MEG Lab, Martinos Imaging Center Timothy P. Roberts, PhD, Vice Chair of Research, Department of Radiology, The Children's Hospital of Philadelphia Julia M. Stephen, PhD, Director, MEG/EEG Core, The Mind Research Network For more details, visit http://megworkshop.nih.gov Registration to this NIH sponsored event is free of charge. We hope to see you in Bethesda in November! Dr. Richard Coppola, Director, NIMH MEG Core Dr. Allison C Nugent, Director of Neuroimaging Research, Experimental Therapeutics and Pathophysiology Branch, NIMH Register Now at Eventbrite! Allison Nugent, PhD Director of Neuroimaging Research Experimental Therapeutics and Pathophysiology Branch NIMH/NIH/DHHS Ph 301-451-8863 -------------- next part -------------- An HTML attachment was scrubbed... URL: From russgport at gmail.com Wed Aug 24 18:45:49 2016 From: russgport at gmail.com (Russell Port) Date: Wed, 24 Aug 2016 12:45:49 -0400 Subject: [FieldTrip] NIH MEG Workshop In-Reply-To: References: Message-ID: Will you pay for me to go to this? Sent from my iPhone > On Aug 24, 2016, at 12:11 PM, Nugent, Allison C. (NIH/NIMH) [E] wrote: > > Reminder! > > A call for abstracts is currently open! We are soliciting abstracts based on the four themes for discussion below, as well as for a general scientific session. Visit http://megworkshop.nih.gov for more details. The abstract deadline has been extended to September 15st. > > At this meeting, we plan to address the following four themes: > > 1. What does MEG add to the field of neuroscience above and beyond other existing techniques? > 2. How can we support the evolution of MEG acquisition and methods, through both software and hardware? > 3. How can we develop and support infrastructure to share data and facilitate big science? > 4. How could an MEG-North America consortium work to address these issues? > > Keynote Speakers: > > Sylvain Baillet, PhD, Director, MEG Core McGill University, McConnell Brain Imaging Center > Dimitrios Pantazis, PhD, Director of MEG Lab, Martinos Imaging Center > Timothy P. Roberts, PhD, Vice Chair of Research, Department of Radiology, The Children’s Hospital of Philadelphia > Julia M. Stephen, PhD, Director, MEG/EEG Core, The Mind Research Network > > For more details, visit http://megworkshop.nih.gov > > Registration to this NIH sponsored event is free of charge. > > We hope to see you in Bethesda in November! > > Dr. Richard Coppola, Director, NIMH MEG Core > Dr. Allison C Nugent, Director of Neuroimaging Research, Experimental Therapeutics and Pathophysiology Branch, NIMH > > Register Now at Eventbrite! > > > Allison Nugent, PhD > Director of Neuroimaging Research > Experimental Therapeutics and Pathophysiology Branch > NIMH/NIH/DHHS > Ph 301-451-8863 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 26 01:49:14 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Thu, 25 Aug 2016 23:49:14 +0000 Subject: [FieldTrip] errors while trying to run beamformer tutorial Message-ID: I am trying to learn how to apply the LCMV beamformer to EEG data. To that end I am starting to go through this tutorial: http://www.fieldtriptoolbox.org/tutorial/beamformer_lcmv?s[]=lcmv I downloaded the data from this link: The ft_definetrial and ft_preprocessing functions require the original MEG dataset, which is available from ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/tutorial/SubjectSEF.zip. Then I tried this code: % find the interesting segments of data cfg = []; cfg.dataset = 'SubjectSEF.ds'; cfg.trialdef.eventtype = 'Blue'; cfg.trialdef.prestim = .1; % .1 sec prior to trigger cfg.trialdef.poststim = .2; % .2 sec following trigger cfg.continuous = 'yes'; cfg = ft_definetrial(cfg); and got this output: Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In dataset2files (line 42) In ft_checkconfig (line 557) In ft_definetrial (line 131) In fieldtrip_test_lcmv (line 13) Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' Error using ft_read_header (line 2248) unsupported header format "unknown" Error in ft_trialfun_general (line 78) hdr = ft_read_header(cfg.headerfile, 'headerformat', cfg.headerformat); Error in ft_definetrial (line 177) [trl, event] = feval(cfg.trialfun, cfg); Error in fieldtrip_test_lcmv (line 13) cfg = ft_definetrial(cfg); So I am totally lost here. Any suggestions? Thanks, -Jeff Eriksen -------------- next part -------------- An HTML attachment was scrubbed... URL: From jan.schoffelen at donders.ru.nl Fri Aug 26 07:36:49 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Fri, 26 Aug 2016 05:36:49 +0000 Subject: [FieldTrip] errors while trying to run beamformer tutorial In-Reply-To: References: Message-ID: <931E197F-6020-4237-90ED-67E105B06151@donders.ru.nl> Hi Jeff, I assume that you have unzipped the data, and have the data (i.e. the ‘SubjectSEF.ds’) in directoryX. You need to specify the full path to the data in cfg.dataset (or your current working directory should be directoryX), i.e. cfg.dataset = ‘directoryX/SubjectSEF.ds’; Hope this helps, Jan-Mathijs On 26 Aug 2016, at 01:49, K Jeffrey Eriksen > wrote: I am trying to learn how to apply the LCMV beamformer to EEG data. To that end I am starting to go through this tutorial: http://www.fieldtriptoolbox.org/tutorial/beamformer_lcmv?s[]=lcmv I downloaded the data from this link: The ft_definetrial and ft_preprocessing functions require the original MEG dataset, which is available from ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/tutorial/SubjectSEF.zip. Then I tried this code: % find the interesting segments of data cfg = []; cfg.dataset = 'SubjectSEF.ds'; cfg.trialdef.eventtype = 'Blue'; cfg.trialdef.prestim = .1; % .1 sec prior to trigger cfg.trialdef.poststim = .2; % .2 sec following trigger cfg.continuous = 'yes'; cfg = ft_definetrial(cfg); and got this output: Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In dataset2files (line 42) In ft_checkconfig (line 557) In ft_definetrial (line 131) In fieldtrip_test_lcmv (line 13) Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' Error using ft_read_header (line 2248) unsupported header format "unknown" Error in ft_trialfun_general (line 78) hdr = ft_read_header(cfg.headerfile, 'headerformat', cfg.headerformat); Error in ft_definetrial (line 177) [trl, event] = feval(cfg.trialfun, cfg); Error in fieldtrip_test_lcmv (line 13) cfg = ft_definetrial(cfg); So I am totally lost here. Any suggestions? Thanks, -Jeff Eriksen _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From christine.blume at sbg.ac.at Fri Aug 26 15:09:06 2016 From: christine.blume at sbg.ac.at (Blume Christine) Date: Fri, 26 Aug 2016 13:09:06 +0000 Subject: [FieldTrip] ft_clusterplot with 3D clusters from ft_freqstatistics Message-ID: Dear community, Following TF analysis I am using ft_freqstatistics for a cluster-based permutation test. Subsequently, I would like to review significant clusters using ft_clusterplot. That works very well as long as my input to ft_freqstatistics is only 2D (channels x frequencies). However, when I include time, the call to ft_clusterplot results in an error message telling me that either time or frequency needs to be a singleton dimension. Unfortunately, I do not find anything in the FT documentation on this issue. Is there a recommendable way to use ft_clusterplot with 3D clusters, i.e. channel x freq x time clusters? Best, Christine -------------- next part -------------- An HTML attachment was scrubbed... URL: From eriksenj at ohsu.edu Fri Aug 26 23:54:09 2016 From: eriksenj at ohsu.edu (K Jeffrey Eriksen) Date: Fri, 26 Aug 2016 21:54:09 +0000 Subject: [FieldTrip] Localizing sources using beamformer techniques web tutorial Message-ID: Jan-Mathijs, Your path suggestion got me going, thanks. I then encountered some other errors as I went further along in the tutorial. The one that stopped me was the last listed below, #5. I do not know if I have the folders and files set up right, so have included a screenshot of how they appear on my computer. In particular it seems that SubjectSEF.ds appears to be a folder at some times, and a file at others. -Jeff 1. cfg = ft_definetrial(cfg); -> Warning: no trialfun was specified, using ft_trialfun_general > In ft_definetrial (line 138) In fieldtrip_test_lcmv (line 13) evaluating trialfunction 'ft_trialfun_general' reading the events from 'E:\Staff\Jeff\Jeff_Matlab\FieldTrip_KJE\data\SubjectSEF\SubjectSEF.ds\SubjectSEF.res4' found 7826 events created 204 trials the call to "ft_definetrial" took 8 seconds 2. cfg.neighbours = ft_prepare_neighbours(cfg, timelock); -> clicking on sensor did NOT show its label 3. timelock_planar = ft_megplanar(cfg, timelock); -> the input is timelock data with 274 channels and 360 timebins Warning: the trial definition in the configuration is inconsistent with the actual data > In ft_warning (line 184) In fixsampleinfo (line 68) In ft_datatype_raw (line 175) In ft_checkdata (line 362) In ft_megplanar (line 98) In fieldtrip_test_lcmv (line 49) Warning: reconstructing sampleinfo by assuming that the trials are consecutive segments of a continuous recording > In ft_warning (line 184) In fixsampleinfo (line 79) In ft_datatype_raw (line 175) In ft_checkdata (line 362) In ft_megplanar (line 98) In fieldtrip_test_lcmv (line 49) the call to "ft_selectdata" took 0 seconds average number of neighbours is 7.35 minimum distance between neighbours is 2.00 cm maximum distance between gradiometers is 4.41 cm Warning: copying input chanunit to montage > In ft_apply_montage (line 120) In ft_megplanar (line 325) In fieldtrip_test_lcmv (line 49) the call to "ft_megplanar" took 2 seconds 4. vol = ft_prepare_headmodel(cfg, seg); -> Warning: please specify cfg.method='projectmesh', 'iso2mesh' or 'isosurface' > In ft_prepare_mesh (line 138) In ft_prepare_headmodel (line 348) In fieldtrip_test_lcmv (line 80) Warning: using 'projectmesh' as default > In ft_prepare_mesh (line 139) In ft_prepare_headmodel (line 348) In fieldtrip_test_lcmv (line 80) triangulating the outer boundary of compartment 1 (brain) with 3000 vertices the call to "ft_prepare_mesh" took 4 seconds the call to "ft_prepare_headmodel" took 4 seconds 5. hdr = ft_read_header('SubjectSEF.ds'); -> Warning: could not determine filetype of SubjectSEF.ds > In ft_filetype (line 1294) In ft_read_header (line 159) In fieldtrip_test_lcmv (line 84) Error using ft_read_header (line 2248) unsupported header format "unknown" Error in fieldtrip_test_lcmv (line 84) hdr = ft_read_header('SubjectSEF.ds'); Message: 2 Date: Fri, 26 Aug 2016 05:36:49 +0000 From: "Schoffelen, J.M. (Jan Mathijs)" To: FieldTrip discussion list Subject: Re: [FieldTrip] errors while trying to run beamformer tutorial Message-ID: <931E197F-6020-4237-90ED-67E105B06151 at donders.ru.nl> Content-Type: text/plain; charset="utf-8" Hi Jeff, I assume that you have unzipped the data, and have the data (i.e. the ?SubjectSEF.ds?) in directoryX. You need to specify the full path to the data in cfg.dataset (or your current working directory should be directoryX), i.e. cfg.dataset = ?directoryX/SubjectSEF.ds?; Hope this helps, Jan-Mathijs -------------- next part -------------- A non-text attachment was scrubbed... Name: FT_data_folder.JPG Type: image/jpeg Size: 36806 bytes Desc: FT_data_folder.JPG URL: From dippel.g at gmail.com Mon Aug 29 13:03:50 2016 From: dippel.g at gmail.com (Gabriel Dippel) Date: Mon, 29 Aug 2016 13:03:50 +0200 Subject: [FieldTrip] Extracting virtual EEG channel from a atlas based ROI Message-ID: Dear Julian, thanks for your help! With some minor changes it finally worked out with the following code: vox1 = mri_cm.transform*[mri_cm.dim,1]'; % start vox1 = vox1(1:3)*10; % convert to mm vox2 = mri_cm.transform*[1,1,1,1]'; %end vox2 = vox2(1:3)*10; % convert to mm % Choose the Minima vox_min = min([vox1,vox2]')'; vox_max = max([vox1,vox2]')'; % Set the spacing vox_delta = abs(mri_cm.transform*[1,1,1,1]'-mri_cm.transform*[2,2,2,1]'); vox_delta = vox_delta(1:3)*10; % convert to mm RES = vox_delta(1); cfg = []; %cfg.inwardshift = -0.5; cfg.grid.xgrid = vox_min(1):RES:vox_max(1)+1; cfg.grid.ygrid = vox_min(2):RES:vox_max(2)+1; cfg.grid.zgrid = vox_min(3):RES:vox_max(3)+1; cfg.grid.tight = 'no'; template_grid_mm = ft_prepare_sourcemodel(cfg, vol_mm); Cheers Gabriel -------------- next part -------------- An HTML attachment was scrubbed... URL: From markus.gschwind at gmail.com Mon Aug 29 16:54:00 2016 From: markus.gschwind at gmail.com (Markus Gschwind) Date: Mon, 29 Aug 2016 16:54:00 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? Message-ID: Dear EEGers, We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). We came across the Zebris system http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php Is there anyone who has experience with this? Thank you in advance, Best, Markus -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Mon Aug 29 17:02:47 2016 From: julian.keil at gmail.com (Julian Keil) Date: Mon, 29 Aug 2016 17:02:47 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: Message-ID: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Dear Markus, we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. I'd say it takes no more than 10 minutes per subject. Let me know if you need more info, Julian Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > Dear EEGers, > > We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). > > We came across the Zebris system > http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php > > Is there anyone who has experience with this? > > Thank you in advance, > Best, > Markus > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From markus.gschwind at gmail.com Mon Aug 29 21:57:21 2016 From: markus.gschwind at gmail.com (Markus Gschwind) Date: Mon, 29 Aug 2016 21:57:21 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: Hi Julain, Thanks for that input. With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? Thanks in advance! Best, Markus 2016-08-29 17:02 GMT+02:00 Julian Keil : > Dear Markus, > > we use the Polhemus Patriot together with the BrainStrom toolbox for our > 128-channel EEG caps. > Once you get it set up and all quirks worked out (e.g. using a > serial-to-USB converter instead of just the USB-connection), it works quite > fast and without problems. > I'd say it takes no more than 10 minutes per subject. > > Let me know if you need more info, > > Julian > > Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > > Dear EEGers, > > We would like to get in contact with people having experience with > electrode positioning systems,which can be used in a reasonable amount of > time (especially with patients), and on high-density caps (we use EGI 256 > channels). > > We came across the Zebris system > http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php > > Is there anyone who has experience with this? > > Thank you in advance, > Best, > Markus > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorn at artinis.com Tue Aug 30 09:02:09 2016 From: jorn at artinis.com (=?utf-8?Q?J=C3=B6rn_M._Horschig?=) Date: Tue, 30 Aug 2016 09:02:09 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: <004901d2028c$6d3c96d0$47b5c470$@artinis.com> Hi Markus, The fastest digitization method I saw up to date is this one: http://www.brainproducts.com/productdetails.php?id=60 - I hope no one from my company sees this mail ;) However it only works with the BrainProducts Acticap and is quite pricy. Commercially, there are two types of product available. One type are devices similar to Zebris, that would be e.g. xensor from ANT, EEG Pinpoint from Localite and BrainProduct should also have one. They are usually in the price range of around 15k€ and imho a big overkill if you are just interested in localizing the electrodes. They all work with using an (infrared) camera to track the position of a pin pointing device. Their actual use for realtime neuronavigation with TMS, but they can be utilized also for stationary, one-time tracking of electrode positions. A cheaper option are the Polhemus devices, where the Patriot is the cheapest one (but still with a relatively good accuracy) of 1.5mm RMS at a sampling rate of 60Hz (yes, we also sell these with our devices, that’s why I know). Polhemus works with creating an electromagnetic field and measuring the position of a sensor within this field. The disadvantage with the Polhemus devices is that there is no proprietary software for electrode digitization. We built our own integration in our software, which is possible because Polhemus makes an SDK available (but we are a NIRS company, so no option for you). There are also some Matlab codes flying around the world wide web for EEG digitization. All in all, they are however not extremely user friendly and/or stable (imho, but I might have high standards). Despite the differences in the technique (camera vs. electromagnetic field), price and software, both require the same amount of manual labour: ticking each electrode manually and continuing to the next one. Only the BrainProducts solution mentioned above works differently. There are several other ideas and papers out there, but nothing that is commercially available in a package. Btw, I just googled, EGI has a similar system as ANT, Localite and Brain Products: https://www.egi.com/clinical-division/clinical-division-clinical-products/ges-400-series I have no experience with this and never saw it in action. But, all companies should be willing to come over to give you a demo of their device (we would, but again, wrong modality). So, just drop them a mail stating your problem (and available budget!) and they will contact you and most likely suggest a demo (otherwise, ask them). I hope this helps! Best, Jörn -- Jörn M. Horschig, PhD, Software Engineer & Project Leader NeuroGuard XS Artinis Medical Systems | +31 481 350 980 From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Markus Gschwind Sent: Monday, August 29, 2016 21:57 To: FieldTrip discussion list Subject: Re: [FieldTrip] Best EEG electrode positioning system? Hi Julain, Thanks for that input. With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? Thanks in advance! Best, Markus 2016-08-29 17:02 GMT+02:00 Julian Keil >: Dear Markus, we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. I'd say it takes no more than 10 minutes per subject. Let me know if you need more info, Julian Am 29.08.2016 um 16:54 schrieb Markus Gschwind: Dear EEGers, We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). We came across the Zebris system http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php Is there anyone who has experience with this? Thank you in advance, Best, Markus _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From julian.keil at gmail.com Tue Aug 30 11:26:58 2016 From: julian.keil at gmail.com (Julian Keil) Date: Tue, 30 Aug 2016 11:26:58 +0200 Subject: [FieldTrip] Best EEG electrode positioning system? In-Reply-To: References: <0F482706-9463-459A-A705-90580642DFCD@gmail.com> Message-ID: Hi Markus, in our setup, we mount the source on a tripod that is positioned behind the subject. We then attach the reference sensor to the forehead (this corrects for movements of the subject) and mark the single electrodes with the stylus. Thus, the head of the subject does not need to be fixed, as long as the source is not moved. I'm not sure what is included in the 2800 $ but here's what we use: * Polhemus Patriot * 1x Stylus (Sensor 1) * 1x Reference (Sensor 2) * 1x Source * Serial Cable Additionally we use: * Serial-to-USB Converter * BrainStorm Toolbox for Matlab (Free after registration from: http://neuroimage.usc.edu/brainstorm/) The Polhemus Software (I think it's included) can be useful for basic troubleshooting, such as checking if there is a connection to the PC, but is not needed otherwise. Cheers, Julian Am 29.08.2016 um 21:57 schrieb Markus Gschwind: > Hi Julain, > > Thanks for that input. > > With the Polhemus Patriot you install the subject in a chair, with the head fixed, and check manually the position of all the electrodes with a sensor, right? > > On their website it says 2.800 USD for the patriot. Is this all we would need or is there more to buy with it? Is there any proprietary software to buy? > > Thanks in advance! > Best, Markus > > > > > > 2016-08-29 17:02 GMT+02:00 Julian Keil : > Dear Markus, > > we use the Polhemus Patriot together with the BrainStrom toolbox for our 128-channel EEG caps. > Once you get it set up and all quirks worked out (e.g. using a serial-to-USB converter instead of just the USB-connection), it works quite fast and without problems. > I'd say it takes no more than 10 minutes per subject. > > Let me know if you need more info, > > Julian > > Am 29.08.2016 um 16:54 schrieb Markus Gschwind: > >> Dear EEGers, >> >> We would like to get in contact with people having experience with electrode positioning systems,which can be used in a reasonable amount of time (especially with patients), and on high-density caps (we use EGI 256 channels). >> >> We came across the Zebris system >> http://www.zebris.de/english/medizin/medizin-elektroden-positionierung.php >> >> Is there anyone who has experience with this? >> >> Thank you in advance, >> Best, >> Markus >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > https://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From andrejakosticln at gmail.com Tue Aug 30 13:37:34 2016 From: andrejakosticln at gmail.com (=?UTF-8?Q?Andreja_Kosti=C4=87?=) Date: Tue, 30 Aug 2016 13:37:34 +0200 Subject: [FieldTrip] Which units are used for the "dippos" argument in ft_compute_leadfield and friends? Message-ID: Hello everyone! Background: I'm using ft_dipolesimulation to generate a simulated EEG from dipoles in specific locations inside of a brain. I'm using a BEM volume conduction model made with dipoli. Since I want specific locations inside of the brain, I need a way to specify where they actually are. Problem: Going through the ft_dipolesimulation, I was unable to find an explanation about which units I'm supposed to use. I do see that the position argument is passed on to ft_compute_leadfield. Going through the ft_compute_leadfield, I see that, in my specific case, the position will be passed onto eeg_leadfieldb, which then passes it on to inf_medium_leadfield which does the actual calculation. However, when I was reading inf_medium_leadfield, I couldn't figure out which units are being used there. Since ft_compute_leadfield seems to be commonly used function, I was wondering if anyone could tell me which measurement units are used for the dippos argument in it. All the best, Andreja Kostić -------------- next part -------------- An HTML attachment was scrubbed... URL: From marco.rotonda at gmail.com Wed Aug 31 22:35:45 2016 From: marco.rotonda at gmail.com (Marco Rotonda) Date: Wed, 31 Aug 2016 22:35:45 +0200 Subject: [FieldTrip] Strange plots with ft_clusterplot Message-ID: Hi there, I'm trying to plot some data but I have some strange behaviour not from ft_clusterplot, but from ft_topoplotTFR. I ran the code on matlab 2015b and 2016a, fiedtrip version of 30/08 and 01/06 I mean it seems that the configuration options of ft_clusterplot are taken fine, while the options of ft_topoplotTFR (like the colormap!) is not. Seems like a problem of Axes. I've exaggerated a bit the configuration to have a better idea. Here is the code: cfg = []; cfg.alpha = 0.05; cfg.parameter = 'stat'; % cfg.interactive = 'yes'; cfg.highlightcolorpos =[255 255 255]; cfg.layout = 'easycapM11.mat'; % cfg.maskparameter = 1; cfg.colorbar = 'yes'; cfg.zlim = [-9 18]; cfg.shading = 'interp'; cfg.gridscale = 300; cfg.contournum = 10; cfg.colormap = gray(10); cfg.markersymbol = '.'; cfg.markersize = 12; cfg.markercolor = [0 0.69 0.94]; cfg.subplotsize = [1 1]; cfg.marker = 'on'; cfg.highlight = 'on'; ft_clusterplot(cfg, statdelta); Here the console log: >> plot_cluster the input is freq data with 30 channels, 1 frequencybins and no timebins Warning: The field cfg.highlight is forbidden, it will be removed from your configuration > In ft_checkconfig (line 208) In ft_clusterplot (line 82) In plot_cluster (line 20) reading layout from file easycapM11.mat the call to "ft_prepare_layout" took 0 seconds There are 6 clusters smaller than alpha (0.05) Negative cluster: 1, pvalue: 0.00019996 (*), f = 2.4414 to 2.4414 Negative cluster: 2, pvalue: 0.00079984 (*), f = 2.4414 to 2.4414 Negative cluster: 3, pvalue: 0.0091982 (*), f = 2.4414 to 2.4414 Negative cluster: 4, pvalue: 0.015797 (x), f = 2.4414 to 2.4414 Negative cluster: 5, pvalue: 0.017596 (x), f = 2.4414 to 2.4414 Negative cluster: 6, pvalue: 0.04819 (x), f = 2.4414 to 2.4414 making subplot 1 from 1 the call to "ft_clusterplot" took 2 seconds >> Here the result: [image: Immagine incorporata 1] Any Idea? Thanks in advance Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 1.png Type: image/png Size: 69210 bytes Desc: not available URL: