Hi Dan,
the ImageJ macro language is very simple (but, thus, very fast,
considering that it is interpreted and not compiled). So there is
essentially one variable type, which can hold numbers, strings or arrays.
If you have an arithmetic expression where a variable contains an array,
in ImageJ macros the array simply evaluates to zero. [Strings evaluate
to the value of the number, e.g. a="2"; b=sqrt(a); results in b=1.4142,
the square root of 2]
For assigning values depending on the position in a stack in
Process>Math>Macro, you can use the 'z' variable (which runs from 0 to
nSlices-1). When asked "Process all images?" run the command on the
whole stack, not the current slice (or, when calling from a macro, add
"stack" to the arguments).
Michael
________________________________________________________________
On 08/03/2017 16:14, Daniel White wrote:
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html