@@ -383,7 +383,6 @@ def get_fixed_effcts(subj_id, subj_masks, contrasts, effect_size_path_dict_list,
383
383
384
384
### Create the fixed effect workflow
385
385
386
-
387
386
``` {code-cell} ipython3
388
387
# initiate the fixed effect GLM workflow
389
388
wf_fixed_effect = Workflow(
@@ -482,7 +481,7 @@ def secondlevel_estimation(firstlevel_stats_list, design_matrix, firstlevel_cont
482
481
stat_maps_dict = dict.fromkeys(firstlevel_contrast[0][0].keys())
483
482
for index, (contrast_id, contrast_val) in enumerate(firstlevel_contrast[0][0].items()):
484
483
print(' Contrast % 2i out of %i: %s' % (
485
- index + 1, len(firstlevel_contrast[0]), contrast_id))
484
+ index + 1, len(firstlevel_contrast[0][0] ), contrast_id))
486
485
second_level_input = [nib.load(stats_dict[contrast_id]) for stats_dict in firstlevel_stats_list]
487
486
second_level_model = SecondLevelModel()
488
487
second_level_model = second_level_model.fit(second_level_input, design_matrix=design_matrix)
@@ -692,7 +691,7 @@ def nonparametric_test(firstlevel_stats_list, smoothing_fwhm, design_matrix, fir
692
691
plot_contrast_dict = dict.fromkeys(firstlevel_contrast[0][0].keys())
693
692
for index, (contrast_id, contrast_val) in enumerate(firstlevel_contrast[0][0].items()):
694
693
print(' Contrast % 2i out of %i: %s' % (
695
- index + 1, len(firstlevel_contrast[0]), contrast_id))
694
+ index + 1, len(firstlevel_contrast[0][0] ), contrast_id))
696
695
# here we set threshold as none to do voxel-level FWER-correction.
697
696
second_level_input = [nib.load(stats_dict[contrast_id]) for stats_dict in firstlevel_stats_list]
698
697
neg_log_pvals_permuted_ols_unmasked = \
@@ -808,7 +807,7 @@ print(results)
808
807
809
808
## Let's Plot!
810
809
811
- We only use 5 subjects, so it's reasonable the following plots have nothing survived from testing.
810
+ We only use 2 subjects, so it's reasonable the following plots have nothing survived from testing.
812
811
813
812
+++
814
813
0 commit comments