Hi I am trying to convert a macro I have working in GUI to headless. The overview of my project is that I open a directory do some processing and anlyze particles saving the ROIs to be applied to a corresponding Image from a second a directory. I then take measurements of the ROIs obtained from the first Image on the second and process through the directories. Based on a similar post "Results tables not found " in Headless Mode I have switched from using ROIs to Overlays in order to avoid the call to GUI. I am now getting the results of only the last measurement not all the complied ROIs as this proceeds through. I can see that the individual values are obtained by using a “print” command I can see them on the terminal window. The results I save somehow are only from the last ROI.
A condensed Version of code This is all within a loop that goes through all the files in a directory
//Open file from dir and processes
run(“Analyze Particles…”, “size=4000-Infinity,show=Overlay”);
//Open file from dir with corresponding string ID to Image being processed from dir and threshold
}}//Close file loop
Because I can see the results on the terminal window I think that what is happening is that the GUI holds the "results in a table that you can extract is there a way to cumulatively add data to the same table in headless? I can find this http://javadoc.imagej.net/ImageJ1/ij/measure/ResultsTable.html which I think will help me… I think I shoudl eb able to create a results able and then add values but my coding skill level isn’t quite strong enough to translate this into my macro. I worte my macro in ImageJ language not JAVA and I’m not really sure how I can access these avaialble Java classes. Reading through the forum I can see where people use the commands IJ.renameResults(); for example but I get an error of an undefined identifier when I try to run the command without the IJ. in from and an unrecognized IJ function when I add it. "IJ.ResultsTable(“Phenotype.csv”); Can someone help?