Input is a binary image, and output is another binary image holding the rectangles over the detected blobs. Its not a superimposition of a rectangle over an image.
DRAWBOUNDINGBOX draws the bounding boxes around the blobs in a binary image image is the binary image input supplied by the user. This function extracts the coordinates and dimension values of each blob from stats.BoundingBox structure one by one and draws the rectangle around them. To store an image you can further use IMWRITE function on the output of the function DRAWBOUNDINGBOX. the new image stored will have the rectangles marked over the blobs since it is not a superimposition.
Handy submission, but not very well documented and a little inaccurate. For example, should the inner or the outer boundary of the blobs be drawn? Also, the outline is off by one on the top and left edges: