digitize plot figures

Hello! I've used Igor for a long time now, but never once played around the image processing capabilities.
Now I'm at a point where I need to summarize data and compare to what I have, which involves collecting information from journal articles and digitizing the data read from plots. This is really tedious, and I'm checking into ways of automating this by collecting images of the plots and importing them to igor and after processing, ending up with ordered pairs of data in two waves for further analysis. I know there are concerns with sampling that I'm glossing over, but does anyone know of straightforward ways of doing this, and/or some pseudocode?

Best regards, Tim
Type this in any Procedure window, and click compile:
#include <IgorThief>

Adds a GUI for manually tracing a graphic file to retrieve the values displayed in a graph. The GUI is invoked from the Data->Packages->Igor Thief menu.

For a demo of this, open the Trace Graph example experiment using the File->Example Experiments->Techniques->Trace Graph menu.

--Jim Prouty
Software Engineer, WaveMetrics, Inc.
If you look for a more automagical way of doing this, i.e., a function extracting the data instead of you manually clicking around, you may want to look into the tracer project by tony. Go to the projects tab on this site and search for 'tracer'. If you additionally take the time to color the trace you want to extract (if it is not already in the paper, this can be done with programs like gimp in seconds), then the function works like a breeze.
Hmmm... If you cut out the center data part from the image with your favorite image editing software and then load that image into igor and ... I guess then you are almost there already. The image will be loaded as 3-layer RGB wave. You then only need a formula to convert R,G, and B values to one data value (or you could generate a lookup table for a rainbow color table, assuming the rainbow colors built into Igor are the same as in the image). Finally scale the axes accordingly and you are done. No need to read individual data points from the image. A more sophisticated approach would be to first grab the colors from the color scale (along a line between two cursors for example) and then extract the colors from within a defined rectangle.
Wow, that makes things super easy. Reminds me, that I should look into the Igor blog more often.
With the attached example graph one could even write a fully automated function after selecting an appropriate color wave. Just cut the image data (remove all columns and rows up until the point where there are no more white points) and do the color to data transformation via lookup. This gets more complicated if there is a graph border or the graph would be slightly tilted (scanned data etc.). I guess still the fastest way (if you don't do such tasks very often and could benefit from automation) is to use a graphics prog to prepare the bare data and color scale before diving into igor.

I use IgorThief often and have colleagues asking for similar tools -- why not add a shortcut it to the Analysis -> Packages menu?

IgorThief isn't our package, so we don't control it. Only our own packages go in those menus, because we need to know that they exist in the installation.

Surely IgorThief is included in the installation?

Unlike other WM packages where the packages submenu does the insertinclude for the package, after which most packages will add a main menu item, IgorThief does the reverse: after it has been included, it adds an item to the Data -> Packages submenu!

Older versions of some of my packages also did this, but now I try to avoid messing with the packages submenus in an way that's inconsistent with WMMenus.ipf.

For my own installations I have something like this in a 'Default Includes' file:

menu "Load Waves", hideable
    submenu "Packages" 
        "-"
        "Load Horiba NGS Files...", /Q, Execute/P/Q/Z "INSERTINCLUDE \"NGSloader\"";Execute/P/Q/Z "COMPILEPROCEDURES ";Execute/P/Q/Z "NGSloader#NGSloader()"
        "Load WiRE Files...", /Q, Execute/P/Q/Z "INSERTINCLUDE \"WiRE loader\"";Execute/P/Q/Z "COMPILEPROCEDURES ";Execute/P/Q/Z "WireLoader#loadWiRE()"
        "Load, Display and Scale Image...", /Q, Execute/P/Q/Z "INSERTINCLUDE \"ImageScaleGUI\"";Execute/P/Q/Z "COMPILEPROCEDURES ";Execute/P/Q/Z "ImageScaleGUI#LoadAndScaleImage()"
        "Load Bruker OPUS Files...", /Q, Execute/P/Q/Z "INSERTINCLUDE \"OPUSLoader\"";Execute/P/Q/Z "COMPILEPROCEDURES ";Execute/P/Q/Z "OpusLoader#LoadOpusGUI()"
    end
end

In this way, my own packages are added 'below the line'. After they have been included they add an item to the parent menu.