In Matlab, load the volume from the NIfTY file using the builtin function 'niftiread' (https://www.mathworks.com/help/images/ref/niftiread.html), then use the 'MajorAxisLength' property from the 'regioprops' Matlab function (https://www.mathworks.com/help/images/ref/regionprops.html) to measure the maximum length of the object of interest.