# NOT RUN {
fi<-antsImageRead( getANTsRData("r16") , 2 )
mask<-getMask( fi )
dilatedBall = morphology( mask, operation="dilate", radius=3, type="binary", shape="ball")
erodedBox = morphology( mask, operation="erode", radius=3, type="binary", shape="box")
openedAnnulus = morphology( mask, operation="open", radius=5, type="binary", shape="annulus", thickness=2)
# }
Run the code above in your browser using DataLab