Login  Register

adding to Results table zeros out the line above

Posted by jmarks on Jun 26, 2014; 9:24pm
URL: http://imagej.273.s1.nabble.com/adding-to-Results-table-zeros-out-the-line-above-tp5008457.html

Hello All,
Using IJ v1.48v,  I am trying to write custom fields to the Results table, using setResult, using nResults as the current line number.

run("Set Measurements...", "redirect=None decimal=6");
setResult("Membrane area", nResults, MembraneArea );
setResult("FRET area", nResults-1, areaFRET);    // nResults is now increased by 1, so must write to previous line to stay on the same line  as the entry above.
setResult("mean FRET", nResults-1, meanFRET );
setResult("Std Dev", nResults-1, stddevFRET );
setResult("FRET Area percent", nResults-1, FRETperAreaPercent );
normFRET = FRETperAreaPercent  * meanFRET ;
setResult("Normalized FRET", nResults-1, normFRET );
updateResults() ;

Everything works fine on the first pass. For each subsequent loop, the new line gets written to the next line of Results window correctly. The problem is that the results on the line above have all been changed to zeros.

What am I doing wrong?

thanks for any suggestions!

Jeremy D. Marks, PhD, MD, FRCPC
Associate Professor
Departments of Pediatrics and Neurology, and the College
University of Chicago
900 East 57th Street, Room 4130
Chicago, IL 60637



Jeremy D. Marks, PhD, MD, FRCPC
Associate Professor
Departments of Pediatrics and Neurology, and the College
University of Chicago
900 East 57th Street, Room 4130
Chicago, IL 60637


--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html