mne_nirs.statistics.run_glm#
- mne_nirs.statistics.run_glm(raw, design_matrix, noise_model='ar1', bins=0, n_jobs=1, verbose=0)[source]#
GLM fit for an MNE structure containing fNIRS data.
This is a wrapper function for nilearn.stats.first_level_model.run_glm.
- Parameters:
- rawinstance of Raw
The haemoglobin data.
- design_matrixas specified in Nilearn
The design matrix as generated by mne_nirs.make_first_level_design_matrix. See example
9.5.5. Examples of design matrices
at https://nilearn.github.io/auto_examples/index.html for details on how to specify design matrices.- noise_model{‘ar1’, ‘ols’, ‘arN’, ‘auto’}, optional
The temporal variance model. Defaults to first order auto regressive model ‘ar1’. The AR model can be set to any integer value by modifying the value of N. E.g. use ar5 for a fifth order model. If the string auto is provided a model with order 4 times the sample rate will be used.
- binsint, optional
Maximum number of discrete bins for the AR coef histogram/clustering. By default the value is 0, which will set the number of bins to the number of channels, effectively estimating the AR model for each channel.
- n_jobsint, optional
The number of CPUs to use to do the computation. -1 means ‘all CPUs’.
- verboseint, optional
The verbosity level. Default is 0.
- Returns:
- glm_estimatesRegressionResults
RegressionResults class which stores the GLM results.
Examples using mne_nirs.statistics.run_glm
#
Utilising Anatomical Information