Is anyone familiar with an in-built MATLAB command that can specify locations of where a certain conditions is met? For Example: I have a gradient intensity matrix that lists the intensity of each pixel in an image and I want to find the index locations [x,y] of all pixels with a value greater than a set threshold. I know this can be done in a FOR loop but I was curious if there was an equivalent like how some other coding languages have.
John Williams answered .
2025-11-20
[x, y] = find (matrix > value)