a macro to automatically set up merge channels
Posted by
Hao Wu on
Jul 29, 2014; 6:09pm
URL: http://imagej.273.s1.nabble.com/a-macro-to-automatically-set-up-merge-channels-tp5008941.html
Hello, everyone!
I am trying to have a macro to set up merge channels automatically. The
following one is what I have now. Somehow, image J always let the red
channel out although if I print titlered, it shows the correct selection.
Any help would be really appreciated. Thanks a lot!
Best,
Hao
FileTitle=getInfo("image.filename");
selectWindow(FileTitle+" - C=2");
titleRed = getTitle;
selectWindow(FileTitle+" - C=1");
titleGreen = getTitle;
selectWindow(FileTitle+" - C=0");
titleBlue = getTitle;
//print(titleRed);
//print(titleGreen);
//print(titleBlue);
run("Merge Channels...", "red=titleRed green=titleGreen blue=titleBlue
gray=*None*");
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html