gastropy.neuro.fmri.compute_plv_map

gastropy.neuro.fmri.compute_plv_map#

gastropy.neuro.fmri.compute_plv_map(egg_phase, bold_phases, vol_shape=None, mask_indices=None, artifact_mask=None)[source]#

Compute a voxelwise PLV map between EGG and BOLD phases.

Parameters:
  • egg_phase (array_like, shape (n_timepoints,)) – Gastric phase per volume (from phase_per_volume + apply_volume_cuts).

  • bold_phases (array_like, shape (n_voxels, n_timepoints)) – BOLD phase per volume for each voxel (from bold_voxelwise_phases).

  • vol_shape (tuple of int, optional) – 3D volume dimensions (e.g., (97, 115, 97)). If provided along with mask_indices, returns a 3D volume.

  • mask_indices (array_like, optional) – Boolean mask or integer indices mapping voxels back to the 3D volume. Required if vol_shape is provided.

  • artifact_mask (array_like of bool, shape (n_timepoints,), optional) – Boolean mask where True = clean volume, False = artifact. Artifact volumes are excluded from the PLV computation.

Returns:

plv – PLV values. Shape is (n_voxels,) if vol_shape is None, otherwise vol_shape.

Return type:

np.ndarray