% This code is used to digitize figures that you find in publications, journals, or simply scanned reports or documents by clicking on the desired points using the mouse.
% You can use it to pick [x,y] points by clicking on the original scanned plot.
% To run, simply type:
% and then follow the instructions
% 1- Plots or figures should be of jpg, png, bmp or any other format that is
% acceptable by matlab and in the same directory as these m-files you are using.
% 2- You don't have to select the points in increasing or decreasing
% order. Click wherever you want on the plot. I have written a small code
% to sort the vectors in ascending order
% 3- The [x,y] data points will be saved in GRABBED.mat. Load
% GRABBED.mat and the first column of GRABBED will be your absisca points, the second
% are the ordinates.
% This code is written by
% Nassim Khaled
% June 2007
Important:Change imshow to imagesc for people without Image Processing Toolbox.