lecture 5 - GLM Flashcards
the signal intensity of time series
- changes with specific experimental conditions, stimuli, or tasks the subject was performing during the scan to identify brain regions that are involved in particular cognitive processes or responses.
- However, the signal can also be influenced by noise, movement artifacts, and physiological changes unrelated to neural activity (breathing), which requires careful preprocessing and analysis to ensure accurate interpretation.
- so, how much of the signal is explained variance
averaging
- take 2 periods
- overlay and average
- test difference between two values (t-test)
problem with averaging fMRI data (+ solution)
- all types of events are being averaged together
-> cue-related and stimulus-related responses - solution: EPOCH AVERAGING
Instead of averaging the whole time series, take the data 20 seconds after an event (cue or stimulus) and average those epochs.
–> Segmenting the time series data into shorter intervals (“epochs”) around the time of the stimulus or cue and then averaging the data within those epochs.
–> This method allows for the examination of the time-locked response to specific events
(i.e., epoched average of cue-locked response and stimulus-locked response separately)
problem with epoch averaging
it is impossible to unambiguously assign data to overlapping events within epochs
–> if stimuli and cues are presented in quick succession, their related BOLD responses can overlap in time.
–> if data responses fall into multiple epochs, they are ‘counted’ multiple times
GLM/Linear Time-Invariant (LTI) System
- neuronal activity acts as input/impulse
- HRF acts as the impulse response function
- the expected fMRI signal at time t is modeled as the convolution of a canonical response and neural activity
GLM/Linear Time-Invariant (LTI) System - principle of linearity
GLM assumes that the BOLD responses elicited by different events or stimuli within the experiment can simply be added together in a linear way to produce the overall BOLD response
–> BOLD response is directly proportional to the magnitude of the neural activity
convolution
- neural activity * ‘canonical’ response
- shows how the BOLD signal changes over time in response to neural activity induced by the stimulus.
- because we assume that the link between neural firing and BOLD response is an LTI system, we can use convolution with an HRF to model the predicted BOLD response
meat of the GLM analysis
- multiple events of which you’ll be interested in differential responses to these events
- form explicit expectations for different conditions/events/predictors/regressors/explanatory variables
–> here, you assume the HRF shape - see whether the voxel’s response pattern is more similar to predictor (regressor) 1 or 2.
-> This comparison is done by convolving the stimulus timing for each condition with the canonical HRF to create predicted BOLD time-courses, which are then compared to the actual observed time-course of BOLD signals from the voxel.
GLM analysis goal
- to try to explain the measured BOLD signal as a combination of our explanatory variables
- Modeling voxel time courses with a linear combination of hypothetical time-series (regressors).
- Same model for each voxel –> One beta estimate per regressor per voxel
y_i = a_i ⋅ x_1 + b_i ⋅ x_2 + c_i + N(0,σ)
- y_i = observed BOLD response for the ith voxel at a specific time point
–> single voxel - x_1, x_2 = regressors
- a, b, c = scaling factors (beta weights) that specify whether a voxel is e.g., ‘house’ selective or ‘face’ selective
–> Indicate how much each regressor contributes to the observed signal - c = intercept: describes the average signal and has nothing to do with the BOLD signal
- N(0,σ) = normally distributed noise
beta weights (scaling factors)
y-hat_i = β_i,1 ⋅ x_1 + β_i,2 ⋅ x_2 + β_i,3
- allow you to say whether a voxel is a ‘face’ or a ‘house’ voxel
- these are the values you need to multiply with your explanatory variables to best explain the data
- optimal combination of betas gives us the explained signal
- indicates the responsiveness of a voxel to each condition
- y-hat_i = the predicted BOLD response for a single voxel
–> explains a cewrtain portion of the signal’s variance
explained & unexplained variance for
y-hat_i = β_i,1 ⋅ x_1 + β_i,2 ⋅ x_2 + β_i,3
- the optimal combination of betas gives us the modeled/explained signal
- this y-hat_i explains a certain portion of the original signal’s variance.
- the better our model, the higher the ratio of explained variance
GLM analysis
Y = X ⋅ β + ε
- We can perform this analysis across all voxels at the same time ( = fast!)
–> simultaneous solution for multiple voxels.
GLM methods
minimizing squared error
||y = Xβ||^2
y = Xβ + e
β-hat = (X’X)^-1⋅X’y (unbiased estimator)
fMRI Donders’ subtraction method
- to zoom into a specific cognitive process, we often want to vary only a single thing in our experiments
- therefore, we need a control condition to subtract
–> task - control task
contrast vectors
- GLM subtraction method
- used to encode the comparisons between different conditions by assigning weights to the regressors (conditions).
- The weights in the contrast vector sum to zero
- we want to test whether there is a stronger response to X than Y
–> β_x > β_y
–> β_x - β_y > 0
contrast outcomes
- depend on the correlation between regressors
- negative t-statistics are also possible
- ‘stronger activation for β_x than for β_y’
family-wise error rate
- the rate at which false positives occur
- increases with more comparisons, which means you are more likely to claim that there is activation in voxels when there is not.
bonferroni correction
changing (lowering) the alpha level
–> very conservative
α_new = α/v
–> v = number of voxels
bonferroni correction: pro’s and cons
pro: no false positives - you can be confident whenever you find something
con: false negatives - you can be confident you’re throwing away actual findings
the trade-off is that by being so strict to avoid false positives, t
why is the Bonferroni correction too conservative?
it assumes independent tests across voxels
false discovery rate (FDR) correction
approach used in multiple hypothesis testing to control the expected proportion false positives.
adjusts the p-values to ensure that among all positive results (i.e., rejected null hypotheses), the proportion that are false positives is at most q = FDR
- FDR = FP / (FP + TP)
- The acceptability of false discoveries depends on the total number of discoveries.
–> 2 false discoveries out of 4 = bad
–> 2 false discoveries out of 50 = okay (FDR = 2/50 = 0.04)
FDR pro’s and cons
pro’s: sensitive if large amounts of voxels are significant, conservative if all voxels show noise
–> (i.e.,: good when there’s a large number of significant results (it’s sensitive) and even when there’s a lot of noise among the results (it’s not too strict))
cons: more complicated algorithms, outcome depends on distribution of p-values
FDR vs Bonferroni correction
bonferroni is the most conservative and thus will show the least activation compared to FDR correction
deconvolution
- fitting the HRF shape, instead of assuming a fixed HRF shape
- is called deconvolution, since we are interested in finding the impulse response function of the LTI system
–> essentially working backward from the BOLD signal to the neural events that caused it. - we have to describe the shape, which takes more regressors (BASIS FUNCTIONS)
different basis functions for deconvolution
Basis functions are mathematical concepts used to represent any function as a combination of basic functions – used to model the Hemodynamic Response Function (HRF)
- by ones:
finite impulse response (FIR) fitting:
uses separate regressors for each time point after an event to individually capture the response at that specific time, with ‘0’ indicating no response and ‘1’ indicating a response at that particular time point along with the intensity of that response (0.0-1.0). - by frequencies:
Fourier Basis Set & Discrete Cosine Set:
regressors are sine and cosine functions -
Gamma
use gamma shape as backbone and add a regressor of neural activity convolved with the HRFs time derivative
disadvantage of Finite Impulse Response (FIR) fitting
“hard to fit” because it involves many different regressors, which makes the model complex and can lead to overfitting if not managed properly.
Gamma basis functions
- since FIR takes a lot of regressors, we can use the gamma shape as a backbone and add a regressor of neural activity convolved with the HRF’s time derivative
- this allows us to change the timing of the HRF, so that we better capture the subject’s HRF shape
–> flexibility but not too many regressors
Gamma basis function: dispersion derivative
an extra regressor that changes the shape of the HRF more than its timing
we perform a GLM analysis instead of epoched averaging because
- we can leverage our knowledge of the HRF shape to disambiguate responses from consecutive events
- the HRF lasts so long that responses to consecutive events in your analysis will overlap, these overlapping responses need to be teased apart
SSE
quantifies the unexplained signal
GLM is typically two-level hierarchical analysis
- within subject
- single subject, single voxel - across subjects
can be done in stages. the hierarchical model ocmbines stages into one model
GLM
- treats the data as a LINEAR COMBINATION of predictors (model functions) plus noise
- the model functions are assumed to have KNOWN SHAPES but their AMPLITUDES ARE UNKNOWN and need to be estimated
mass univariate approach in GLM
construct a separate model for every voxel
block design
similar groups are grouped together
–> two condition block design is optimal for power
event-related design
events are mixed
rapid presentation in event-related design
standard event-related design has many extraneous processes, leading to activation for the wrong reasons
solution = rapid presentation
- prevents subjects from engaging in spontaneous processes (getting distracted)
- maximizes time on the task’s process of interest
psychological considerations
- stimulus predictability
- time on task
- participant strategy
- temporal precision of psychological manipulations
- unintended psychological activity
basic tradeoffs
- fewer conditions and contrasts: more power, but less generalizability and specificity
- many comparisons, high potential for specificity of inference, but low power