read_vol
read_vol(filename, index=0)Read a 3D neuroimaging volume from file.
Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| filename | str or Path | Path to the neuroimaging file | required |
| index | int | For 4D files, which 3D volume to extract (0-based) Default is 0 (first volume) | 0 |
Returns
| Name | Type | Description |
|---|---|---|
| DenseNeuroVol | The loaded 3D volume |
Notes
Unlike R which uses 1-based indexing, Python uses 0-based indexing for the volume index parameter.