Try using this function:
;Method can be 1, 2, or 3. Experiment on which works best Function MeshRadius#(mesh, method = 1) w# = MeshWidth(mesh) / 2 h# = MeshHeight(mesh) / 2 d# = MeshDepth(mesh) / 2 If method = 1 Then rad# = (w+h+d)/3.0 If method = 2 Then rad# = w If h > rad Then rad = h If d > rad Then rad = d End If If method = 3 Then rad# = Sqr(w*w + h*h + d*d) Return rad# End Function