Re: Selective batch processing within a folder using macro
Posted by Krs5 on Oct 13, 2016; 1:57pm URL: http://imagej.273.s1.nabble.com/Selective-batch-processing-within-a-folder-using-macro-tp5017364p5017367.html
Dear Ritu
You could use something like:
dir1 = getDirectory("Select Directory with files");
list = getFileList(dir1);
Dialog.create("Select files")
Dialog.addNumber("Select the first image to analyse:", 1);
Dialog.addNumber("Select the last image to analyse", list.length);
Dialog.show()
start = Dialog.getNumber();
end = Dialog.getNumber();
for (i=(start - 1); i<end; i++){
Here goes your analysis code
}
This works only when there are only image files in the directory and there are no subdirectories. Otherwise you have somehow correct for those...
-----Original Message-----
From: ImageJ Interest Group [mailto:[hidden email]] On Behalf Of rituroych
Sent: 13 October 2016 13:46
To: [hidden email] Subject: Selective batch processing within a folder using macro
Dear All,
I have written a macro to process all the files in a folder.
The folder contains around 100 images, but I would like to choose a certain number of files at a time for batch processing using the macro and not the entire folder. Please suggest a method to do so.