File Exchange

image thumbnail


version (7.9 KB) by Jordi Palacin
To create a new plot from a scanned image file


Updated 22 Feb 2011

View Version History

View License

This function opens an image file containing a plot. Then the origin, maximum X and Y axis, and data points can be manually and automatically selected to obtain a new vectorial plot (the animated screenshot shows the menus included).

Using Image Processing Toolbox to open idexed and gray images (functions ind2rgb, gray2rgb).

More functions at

Cite As

Jordi Palacin (2021). ReversePlot (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (14)

chou fly

It is nice and helpful, thanks

Abhishek Sharma

Nice and simple code.

Guillaume Adamczak

Nice software but logscaling is not working in R2015b


Great code!

David Abraham

Just tried it out and it works simply and well. I like software that doesn't require any reading of manuals, and the results are great. Thanks!

Enrico Segre

Bug "Delete an area of the curve...:
I think all is needed to correct it is to change line 420 with
rbbox %(no arguments)

Enrico Segre

Comparing with GRABIT

-Zooming the figure is not possible in reverseplot;
-reverseplot doesn't mark the datapoints manually pointed at, while marking them one by one, only at the end;
-reverseplot does not offer to delete the last point erroneously pointed (could e.g. be bound to Backspace)

-GRABIT misses the automatic curve detection;

Besides, I just realized that in reverseplot "Delete an area of the curve..." has a bug (the selection rectangle is misplaced)

Anyway, both pieces of software are nice and useful.

Enrico Segre

I see no reason why png should not be supported. To that extent, it is sufficient to change lines 84-90 with:

[filename, pathname] = uigetfile( ...
{'*.jpg;*.jpeg;*.gif;*.bmp;*.tif;*.png','All suported formats'
'*.jpg;*.jpeg','JPEG (*.jpg;*.jpeg)'; ...
'*.gif','Gif (*.gif)'; '*.png','PNG (*.png)'; ...
'*.bmp','Bitmap (*.bmp)'; ...
'*.tif','TIFF (*.tif)'}, ...
'Open scanned image...');

Enrico Segre

Coooooool. I've found a basic bug, though. In function loaddata, lines 98-100,
info = imfinfo([lower(pathname) lower(filename)]);
[a,map] = imread([lower(pathname) lower(filename)]);
is plainly wrong on a case-sensitive OS like unix, and files with uppercase pathnames won't load. Removing all lower() solves the problem.


Really useful for me.....

sono fera

I wonder if it's could work on a plot-with-marker like seismic plot.

Dick Beresford

A very neat bit of code that provides a useful function. Deals with log as well as linear axes. Would be even more useful if it could return the coordinates as data values in the MATLAB workspace.


This is super handy

Alberto Zin

Really useful !

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

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!