This function digitizes curves in a figure, e.g. an image save form a PDF file, plots and displays the data.
% figure digitizer
% Use: 1. Input image to be digitized, e.g. test.jpg. You can type the
% name of the image in the editable text field, or push "Browse"
% button to browse the file.
% 2. Digitize left x, by pushing "Digi x1," and enter corresponding
% value for x1.
% 3. Similarly for x2, y1, y2.
% 4. Digitize x & y along a curve, press "Return" when done.
% 5. x & y will be plotted and displayed.
% Note: x & y axis can be linear or log
% Tips: How to save a jpg image file from a figure in a PDF file
% 1. open the PDF file using Adobe Reader 7.07 (Free on the WEB)
% 2. select the figure using the Snapshot tool of Adobe Reader
% 3. File -> print
% 4. "Selected graphic" in "print range," "Fit to printer margins"
% for "print scaling."
% 5. select "print to file" ... ...
% I beleive that these codes are also a good example of GUI development
% by Hongxue Cai (email@example.com)