Here is a macro that runs Analyze>Tools>Analyze Line Graph and saves
the results in the users home directory. The trick that makes it work
is enabling the "Auto-close" and "List Values" options in the
Edit>Options>Profile Plot Options.
run("Profile Plot Options...",
"width=450 height=200 auto-close list interpolate draw");
run("Analyze Line Graph");
selectWindow("Plot Values");
values = getInfo();
run("Close");
f = File.open(getDirectory("home")+"results.txt");
print(f, values);
-wayne
On May 25, 2007, at 3:07 PM, David Judd wrote:
> Hi,
>
> I'm trying to create a macro that will call Analyze Line Graph.
> This works
> fine up to a point, but I can't figure out how to save the results.
> Specifically, run("Analyze Line Graph"); works fine, bringing up a
> window
> with three buttons - List, Save, and Copy. However, there doesn't
> seem to
> be a macro command that will allow me to press any of those
> buttons, or by
> any other method access the text data I've just taken from the image.
>
> Anybody have a fix?
>
> Thanks!
>
> -David