I have an image, and would like to modify the image based on a given threshold. The function such as
binary = image > threshold
will create a binary image. What I want is the image pixels will remain the same if it is higher than the threshold. Are there any convenient function to do that?