Summary
The voxelwise reducers do no NaN handling across subjects. If any included
subject is NaN at a voxel, the group estimate at that voxel is NaN (no
listwise/pairwise deletion). When a subject's map is entirely NaN, the whole
group map is NaN. This is silent — no warning, no error, just an all-NaN output.
Reproduce
32 subjects, one contrast whose first-level map is all-NaN for 5 subjects
(here: a parametric-modulation coefficient that was unestimable for subjects with
constant ratings):
maps <- data.frame(file = beta_files, subject = subs, contrast = "vividness")
g <- gds_from_nifti_maps(maps)
fit <- one_sample(g, col_data = data.frame(row.names = subs)) |> compute()
t <- assays(fit)[["t_coef:(Intercept)"]]
sum(is.finite(t) & t != 0) # 0 -> entire group t-map is NaN
The same poisoning affects per-voxel NaNs for the OLS reducer and the
reduce(method = "random"/"fixed") meta reducers. Workaround: drop all-NaN
subjects before fitting (only rescues the whole-subject case, not scattered
per-voxel NaNs).
Requests
- Per-voxel availability handling: estimate from the finite subjects at each
voxel (reduced n/df), as standard second-level fMRI tools do.
- At minimum, warn when subjects/voxels are dropped (or when a voxel has
<2 finite observations), instead of silently emitting NaN.
- A summary of effective-n per voxel (or per fit) would make this auditable.
Env
fmrigds 0.1.0.9000, R 4.5.0.
Summary
The voxelwise reducers do no NaN handling across subjects. If any included
subject is
NaNat a voxel, the group estimate at that voxel isNaN(nolistwise/pairwise deletion). When a subject's map is entirely
NaN, the wholegroup map is
NaN. This is silent — no warning, no error, just an all-NaN output.Reproduce
32 subjects, one contrast whose first-level map is all-
NaNfor 5 subjects(here: a parametric-modulation coefficient that was unestimable for subjects with
constant ratings):
The same poisoning affects per-voxel NaNs for the OLS reducer and the
reduce(method = "random"/"fixed")meta reducers. Workaround: drop all-NaNsubjects before fitting (only rescues the whole-subject case, not scattered
per-voxel NaNs).
Requests
voxel (reduced n/df), as standard second-level fMRI tools do.
<2 finite observations), instead of silently emitting NaN.
Env
fmrigds 0.1.0.9000, R 4.5.0.