diff --git a/src/main/resources/doc/ij1macro/functions_extd.html b/src/main/resources/doc/ij1macro/functions_extd.html index efff78f6c..b99760226 100644 --- a/src/main/resources/doc/ij1macro/functions_extd.html +++ b/src/main/resources/doc/ij1macro/functions_extd.html @@ -15,7 +15,7 @@ All commands inside an else block are executed if the expression in the earlier if block is false. -filelist = getFileList(directory)
for (i = 0; i < lengthOf(filelist); i++) {
if (endsWith(filelist[i], ".tif")) {
open(directory + File.separator + filelist[i]);
}
}
+directory = getDirectory("Choose input directory");
filelist = getFileList(directory);
for (i = 0; i < lengthOf(filelist); i++) {
if (endsWith(filelist[i], ".tif")) {
open(directory + File.separator + filelist[i]);
}
}
A for loop which opens all files ending with ".tif" in a folder. @@ -23,11 +23,11 @@ A for loop which loops over slices in a stack. -n = roiManager('count');
for (i = 0; i < n; i++) {
roiManager('select', i);
// process roi here
}
+n = roiManager("count");
for (i = 0; i < n; i++) {
roiManager("select", i);
// process roi here
}
A for loop which loops over ROIs in the ROI Manager. -for (i = 0; i < nResults(); i++) {
v = getResult('Area', i);
setResult('myColumn', i, v);
}
updateResults();
+for (i = 0; i < nResults(); i++) {
v = getResult("Area", i);
setResult("myColumn", i, v);
}
updateResults();
A for loop which loops over results in the Results Table.