File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
examples/01_DataOperations Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 7979import numpy as np
8080
8181high = data [np .where (data .X ['PainLevel' ]== 3 )[0 ]]
82- high .mean ().threshold (threshold = '95 %' ).plot ()
82+ high .mean ().threshold (lower = '2.5%' , upper = '97.5 %' ).plot ()
8383
8484#########################################################################
8585# We might be interested in creating a binary mask from this threshold.
8686
87- mask = high .mean ().threshold (threshold = '95 %' ,binarize = True )
88- mask .plot ()
87+ mask_b = high .mean ().threshold (lower = '2.5%' , upper = '97.5 %' ,binarize = True )
88+ mask_b .plot ()
8989
9090#########################################################################
9191# We might also want to create separate images from each contiguous ROI.
9292
93- region = high .mean ().threshold (threshold = '95 %' ).regions ()
93+ region = high .mean ().threshold (lower = '2.5%' , upper = '97.5 %' ).regions ()
9494region .plot ()
9595
You can’t perform that action at this time.
0 commit comments