-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
Changing the way the string of the path is handled lets the macro run on newer ImageJ versions after 1.5.2 (tested on 1.5.4)
Line 5 should have brackets around the path which will looks like:
run("Image Sequence...", "open=[" + path + "] sort use");
Making the updated thing:
// Takes unscaled data and scales it to a 10um space. Also converts to 8-bit.
paths = newArray("E:\\DeSousa_cleared_brains\\5B\\488\\15-29-24_5B_488_UltraII_C00_xyz-Table Z0000.ome.tif");
for (i=0; i<paths.length; i++) {
path = paths[i];
run("Image Sequence...", "open=[" + path + "] sort use");
run("Scale...", "x=0.40625 y=0.40625 z=0.3 interpolation=Bilinear average process create");
run("8-bit");
parent = File.getParent(path);
dir = File.getParent(parent) + File.separator + File.getName(parent) + "_scaled";
File.makeDirectory(dir);
name = "10um";
saveAs("Tiff", dir+File.separator+name);
}
Metadata
Metadata
Assignees
Labels
No labels