Skip to content

Commit 6a129b6

Browse files
committed
Fix script.
1 parent e7d8532 commit 6a129b6

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

analysis/plot_fmriprep_anats.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
"""Plot T2* maps from tedana."""
22

3+
import os
34
from glob import glob
45

56
import matplotlib.pyplot as plt
@@ -85,14 +86,17 @@ def plot_surface(name, measure, files):
8586

8687

8788
if __name__ == "__main__":
88-
in_dir = "/cbica/projects/pafin/derivatives/fmriprep"
89+
# Need to run locally because surfplot was failing on CUBIC
90+
in_dir = "/Users/taylor/Desktop/surface/data"
8991

9092
patterns = {
91-
"Cortical Thickness": "sub-*/ses-1/anat/*_space-fsLR_den-91k_thickness.dscalar.nii",
92-
"Sulcal Curvature": "sub-*/ses-1/anat/*_space-fsLR_den-91k_curv.dscalar.nii",
93-
"Sulcal Depth": "sub-*/ses-1/anat/*_space-fsLR_den-91k_sulc.dscalar.nii",
93+
"Cortical Thickness": "*_space-fsLR_den-91k_thickness.dscalar.nii",
94+
"Sulcal Curvature": "*_space-fsLR_den-91k_curv.dscalar.nii",
95+
"Sulcal Depth": "*_space-fsLR_den-91k_sulc.dscalar.nii",
9496
}
9597
for name, pattern in patterns.items():
96-
files = sorted(glob(pattern))
98+
files = sorted(glob(os.path.join(in_dir, pattern)))
99+
files = [f for f in files if "PILOT" not in f]
100+
print(f"{name}: {len(files)}")
97101
for measure in ["Mean", "Standard Deviation"]:
98102
plot_surface(name, measure, files)

0 commit comments

Comments
 (0)