Skip to content

Instantly share code, notes, and snippets.

@PatrickJS44
PatrickJS44 / split_channels.ijm
Created May 27, 2022 09:03 — forked from romainGuiet/split_channels.ijm
An imagej macro example to process a folder of images, split the channels and save them in an output directory
// ask user to select a folder
dir = getDirectory("Select A folder");
// get the list of files (& folders) in it
fileList = getFileList(dir);
// prepare a folder to output the images
output_dir = dir + File.separator + " output" + File.separator ;
File.makeDirectory(output_dir);
//activate batch mode