I have a directory with over 500 tiff files of split channels and stacks.
For each image, there are 4 channels and 5 stacks as individual tiff files (i.e., 20 files per image).
I would like to z project and then get maximum projection for each channel - i.e., for image X, select the 5 images of the same channel, z project, maximum projection, save.
I have been trying to figure out to do this based on the name.
The file names contain the stack (plane) to the left of an “-” and the channel to the right of the “-”
If I try to create a
subStringArray splitting the names with
split( fileName, "-"), it no longer recognizes the channel which is post “-”.
I believe another way of doing it would be to divide the directory into every 20 images as a block; take the first image, and every 4th images thereafter, to 5 images; the same for the second, third and fourth respectively.
Below is an example of a directory. X denotes the first channel of the first image, 5 planes. Y denotes the same for the second image.