Skip to content

Commit fccf509

Browse files
authored
[FIX] allow analysis to have null points when converting from nimads to dataset (#808)
allow analysis to have null points
1 parent c1e8c31 commit fccf509

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

nimare/io.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ def _analysis_to_dict(study, analysis):
5555
"title": study.name,
5656
},
5757
"coords": {
58-
"space": analysis.points[0].space,
59-
"x": [p.x for p in analysis.points],
60-
"y": [p.y for p in analysis.points],
61-
"z": [p.z for p in analysis.points],
58+
"space": analysis.points[0].space if analysis.points else "UNKNOWN",
59+
"x": [p.x for p in analysis.points] or [None],
60+
"y": [p.y for p in analysis.points] or [None],
61+
"z": [p.z for p in analysis.points] or [None],
6262
},
6363
}
6464
sample_size = study.metadata.get("sample_size")

0 commit comments

Comments
 (0)