File Exchange

image thumbnail

Segment images interactively, and generate MATLAB code

version (434 KB) by Brett Shoelson
An interactive app and function for segmenting images.


Updated 01 Sep 2016

View License

Interactive UI for segmenting images. Explore different approaches, then export segmentation mask and reproduction code.
Supports all tunable parameters for EDGE detection, THRESHOLDING (including MULTITHRESH/IMQUANTIZE), HOUGH (line and circle detection), regional and extended minima and maxima, and COLOR thresholding.
PLEASE NOTE: From R2014b forward, this is intended as a REPLACEMENT for SegmentTool. This version will not work prior to R2014b, but SegmentTool will not work in R2014b.

Comments, suggestions appreciated!

Comments and Ratings (15)

Sam Lim

Kiarash Ahi

Guojin Feng

Convenient app. Recommended.

The code doesn't print out on my pc for some reason?
Also is there a way of automatically applying this to a three dimensional matrix that has 124 slices?

Can you send me an image and a snippet of code that recreates the failure? I am able to import and work with both double and uint16 images.

Great app but i have a question. Why it is not functional when i Import a grayscale Image ( double or uint16) ?

thank you

I'm a little confused, Dominic. The current version of segmentImage (on this page) includes a call to audioread(), but not to wavread(). Where are you encountering that message?


As a workaround, I created a new "wavread.m" with the audioread script inside. This way, I'm able to start it again.


I can't get it to start on Matlab R2016b. "wavread" has been replaced by "audioread" in R2015b, so the app won't start anymore.


Yuan Chao


Ahmed Ayoub


Updated license

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

Discover Live Editor

Create scripts with code, output, and formatted text in a single executable document.

Learn About Live Editor