props = regionprops(binaryImage, grayImage, 'Area', 'Perimeter', 'EulerNumber');
allAreas = [props.Area];
allPerimeters = [props.Perimeter];
allRoundnesses = 4 * pi * allAreas ./ allPerimeters .^ 2;
To get the mean and variance of the boundaries, you have to define what the mean of the boundary is. One way might be to smooth it out until it's really smooth using the function sgolayfilt() in the Signal Processing Toolbox. See attached demo. Then you can use min() to find the closest original point and get the distance between them with sqrt(). Then take the standard deviation of all those distances with std().