Label the unconnected shapes in a binary image in relation to their
size.
function call:
[out_img1]=vsg('LabelByVol',in_img1);
Arguments:
in_img1
- input image, a DICOM image which is binary, i.e. with values 0 or 255;
Description:
out_img1
– a DICOM image. The input image is processed such that each connected
region is given an individual label. These labels are then re-ordered
such that the largest blob will have the lowest label and the smallest
blob, the highest label. The output image is an image of these labels;
Example:
[filename, chosenDirectory] = uigetfile('*.dcm',
'Pick an M-file');
filePath = [chosenDirectory filename];
stackOfImages=vsg('DICOMRead',filePath);
%4D array of data
[out_img1]=vsg('Threshold',stackOfImages,500);
[out_img1]=vsg('LabelByVol',out_img1);
Notes:
1. For
2. Dicom images
require XMedCon software (version xmedcon-0.10.5-1-win32).
3. DICOM data must
be in a separate folder.