Summing specific pixel values
Show older comments
Hi. I am wanting to find the sum of all the positons xi, yi of an image IM. I thought the following would do it - but it doesn't.
sum(im (xi,yi));
Also, If I want to take this a step further and find the sum of all pixels at locations xi, yi but this time include the surrounding 8 pixels (so its a 3x3 centred on xi,yi), how do I do that?
thanks
Accepted Answer
More Answers (0)
Categories
Find more on Simulink 3D Animation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!