File Exchange

image thumbnail


version (2.22 KB) by Brett Shoelson
Manually mark and count objects in an image.

1 Download

Updated 01 Sep 2016

View License

Sometimes you need to be able to manually count objects or regions in an image. (You may want to validate an automatic count, for instance.) This tool facilitates that task by allowing you to mark objects with cursor clicks. Then you can tally and delete them.
Operates on current image object
Activates and operates on image imgHandle
markPoints(..., task)
task (optional input) may be:
'Clear' (deletes existing marks)
'Count' (returns the count of existing marks)
'Mark' (Default; return to marking task)

Cite As

Brett Shoelson (2020). markPoints (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (3)


It actually works fine. The reason I couldn't make it work was because I was working on a image that had been overlayed with plots. Sorry for the first comment.

Brett Shoelson

Lasse, your feedback isn't very helpful to me. I use this function frequently, and can assure you that it _does_ work. Perhaps you can tell me why you think it's not working, or why it's buggy, and let me take a look?

This file has been downloaded hundreds of times. Is anyone else finding it to be buggy or nonfunctional? If there are bugs to be fixed or improvements to be made, I'd like the opportunity to fix/make them.

Thanks! Brett


Buggy. Slow and counting does not actually work.


Updated license

Added copyright.


MATLAB Release Compatibility
Created with R2011b
Compatible with any release
Platform Compatibility
Windows macOS Linux