MATLAB: How to superimpose a RGB image over gray image with background to be transparent

image processingMATLAB

I have a RGB image with only black and white colour pixels.I want to overlay it on a grayscale image with only white colour pixel visible and black colour become transparent?
Related Question