Some basic questions

90 views
Skip to first unread message

Alireza Karami

unread,
Dec 19, 2021, 10:53:45 AM12/19/21
to GLMdenoise
Dear all

I am new to GLMdenoise. I tried to get familiar with it and find the answer to my questions by quickly reviewing related papers and questions in the group. Sorry if I ask basic questions or questions that have been answered before.
  • My first question is whether GLMdenoise is a standalone package for the 1st level analysis or is it only for creating nuisance regressors to use with other software packages such as SPM?
  • If it is a standalone package for the 1st level analysis, would you please give me a hint on how to get t-maps (beta estimate for each voxel divided by its standard error estimate) of a contrast weights vector?
  • Is it possible to define different stimulus duration (stimdur) for different stimuli?
  • I downloaded the sample dataset from here. Would you please briefly describe how the design matrix should be defined?
  • I found out that there is another package GLMsignle, for a single-trial experiment. My experiment has 32 trials that have presented twice in a run and twelve times in total (the experiment has six runs). Do you recommend using GLMsingle instead of GLMdenoise?

Best regards,

Alireza

Kendrick Kay

unread,
Dec 20, 2021, 3:35:54 PM12/20/21
to Alireza Karami, GLMdenoise
Hi Alireza,

Sorry for the delay.



  • My first question is whether GLMdenoise is a standalone package for the 1st level analysis or is it only for creating nuisance regressors to use with other software packages such as SPM?
It is intended in the former sense, but in theory you could use it in the latter sense.  Certainly, the approach/mindset of the toolbox diverges a bit from SPM (and other packages).  Depending on how you approach it, you may want to consider exactly how error on your beta estimates is handled.  Specifically, the data-driven derivation of the nuisance regressors requires "peeking" at the data.  The general approach laid out in the original paper involves treating "runs" as independent, and suggests a bootstrapping approach in that regard.  Alternatively, you could use a condition-split approach (as described in Kay et al NeuroImage 2019).  Or, if error is going to come from distinct subjects (as opposed to error within subjects), I guess that saves you some headache.


  • If it is a standalone package for the 1st level analysis, would you please give me a hint on how to get t-maps (beta estimate for each voxel divided by its standard error estimate) of a contrast weights vector?
I think the response to the previous point covers this.  You could go with a bootstrapping approach.  Or you could use the 'wantparametric' option to get the OLS estimates of error and do some arithmetic to get the standard t-maps.  (The problem with that approach is that these approaches underestimate the noise level, due to temporally autocorrelated noise, which the field has talked about extensively.)



  • Is it possible to define different stimulus duration (stimdur) for different stimuli?
Not easily...  but perhaps you can shoehorn this in, if you think of multiple "onsets" of a given condition as effectively giving you a long duration.  For example, suppose you have a 32-s long stimulus event.  You could treat this as 16 successive onsets of a 2-s long stimulus.  

Bear in mind that for relatively small discrepancies in stimulus durations (e.g. 2 s vs. 3 s), the resulting timecourses that are predicted by a simple convolution with an impulse response are actually very similar in terms of their shape.  Hence, one could probably get away with assuming a fixed timecourse (HRF) and getting the differences in the resulting BOLD response to bear out in the beta (amplitude) associated with the timecourse.


  • I downloaded the sample dataset from here. Would you please briefly describe how the design matrix should be defined?
The 'design' variable in the .mat file has the design matrix specified in there ?



  • I found out that there is another package GLMsignle, for a single-trial experiment. My experiment has 32 trials that have presented twice in a run and twelve times in total (the experiment has six runs). Do you recommend using GLMsingle instead of GLMdenoise?
Potentially yes.  GLMsingle can thought of as a superset of what GLMdenoise does.  It may also make your ability to compute t-maps easier, since the mindset is to treat each trial as (effectively) independent.  So, once you get single trial estimates, you can post-hoc compute whatever statistical metrics that you like.


Hope this helps,
Kendrick



Alireza Karami

unread,
Jan 1, 2022, 4:56:43 PM1/1/22
to GLMdenoise
Thank you so much for your answers.

I understood how to specify the design matrix. I used the following format, as described on your page, to specify it:
{{C1_1 C2_1 C3_1 ...} {C1_2 C2_2 C3_2 ...} ...}

Regarding variable stimulus duration, I used a fixed stimulus duration (0.5 ms) for all stimulus and button-pressed events. I used to set 0.1 ms for button-pressed. But as you said, for relatively small discrepancies in stimulus durations (e.g., 2 s vs. 3 s), the resulting timecourses predicted by a simple convolution with an impulse response are very similar in terms of their shape; I changed it to 0.5 ms to have a fixed duration for all events.

Best regards,

Alireza

Kendrick Kay

unread,
Jan 6, 2022, 3:40:44 PM1/6/22
to Alireza Karami, GLMdenoise
Thank you so much for your answers.

I understood how to specify the design matrix. I used the following format, as described on your page, to specify it:
{{C1_1 C2_1 C3_1 ...} {C1_2 C2_2 C3_2 ...} ...}

Regarding variable stimulus duration, I used a fixed stimulus duration (0.5 ms) for all stimulus and button-pressed events. I used to set 0.1 ms for button-pressed. But as you said, for relatively small discrepancies in stimulus durations (e.g., 2 s vs. 3 s), the resulting timecourses predicted by a simple convolution with an impulse response are very similar in terms of their shape; I changed it to 0.5 ms to have a fixed duration for all events.


I see. This sounds reasonable.

A small note: 0.5 ms (or 0.1 ms) is very very brief.  At least in the GLMdenoise implementation, the shortest stimulus duration is forced to be 0.1 s (100 ms).  You can see this in:
So, in a sense, specifying 0.5 ms will be "rounded" to 100 ms.

(Or, maybe you meant to type (0.5 s = 500 ms). Even then, the difference in timecourse shape for a 0.1 s stimulus vs. a 0.5 s stimulus is very very small.)


Kendrick

Alireza Karami

unread,
Jan 6, 2022, 3:47:15 PM1/6/22
to GLMdenoise
Thank you so much.
I am sorry. The stimulus duration was 500 ms, not 0.5 ms! It was a typo.

Reply all
Reply to author
Forward
0 new messages