Skip to content
Snippets Groups Projects
Commit 215aaa77 authored by Paul McCarthy's avatar Paul McCarthy
Browse files

A couple of bugfixes - cluster parsing routine had wrong data types, and

cluster panel was trying to load ztats for contrast -1 when no cluster
results.
parent 002b9819
No related branches found
No related tags found
No related merge requests found
......@@ -385,12 +385,12 @@ def loadClusterResults(featdir, settings, contrast):
'Z-MAX X (vox)' : ('zmaxx', int),
'Z-MAX Y (vox)' : ('zmaxy', int),
'Z-MAX Z (vox)' : ('zmaxz', int),
'Z-COG X (vox)' : ('zcogx', float),
'Z-COG Y (vox)' : ('zcogy', float),
'Z-COG Z (vox)' : ('zcogz', float),
'Z-MAX X (mm)' : ('zmaxx', int),
'Z-MAX Y (mm)' : ('zmaxy', int),
'Z-MAX Z (mm)' : ('zmaxz', int),
'Z-COG X (vox)' : ('zcogx', int),
'Z-COG Y (vox)' : ('zcogy', int),
'Z-COG Z (vox)' : ('zcogz', int),
'Z-MAX X (mm)' : ('zmaxx', float),
'Z-MAX Y (mm)' : ('zmaxy', float),
'Z-MAX Z (mm)' : ('zmaxz', float),
'Z-COG X (mm)' : ('zcogx', float),
'Z-COG Y (mm)' : ('zcogy', float),
'Z-COG Z (mm)' : ('zcogz', float),
......@@ -398,9 +398,9 @@ def loadClusterResults(featdir, settings, contrast):
'COPE-MAX X (vox)' : ('copemaxx', int),
'COPE-MAX Y (vox)' : ('copemaxy', int),
'COPE-MAX Z (vox)' : ('copemaxz', int),
'COPE-MAX X (mm)' : ('copemaxx', int),
'COPE-MAX Y (mm)' : ('copemaxy', int),
'COPE-MAX Z (mm)' : ('copemaxz', int),
'COPE-MAX X (mm)' : ('copemaxx', float),
'COPE-MAX Y (mm)' : ('copemaxy', float),
'COPE-MAX Z (mm)' : ('copemaxz', float),
'COPE-MEAN' : ('copemean', float)}
# An error will be raised if the
......
......@@ -477,6 +477,12 @@ class ClusterPanel(fslpanel.FSLEyesPanel):
featImage = self.__featImages[overlay]
contrast = self.__statSelect.GetSelection()
# No cluster results
if contrast < 0:
self.__addZStats .Enable(False)
self.__addClustMask.Enable(False)
return
zstat = featImage.getZStats( contrast)
clustMask = featImage.getClusterMask(contrast)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment