https://fr.mathworks.com/help/images/ref/imerase.html
imerase - Remove image pixels within rectangular region of interest - MATLAB
This MATLAB function remove pixels of image I within the rectangular region defined by rect and returns the image with the erased region, Ierased.
remove imageof interestpixelswithinrectangular