My goal is to convert a 3 channel 16-bit RGB image into a single channel 16-bit image of average intensity gray values.
Using the GUI I do:
[Stk] button with red arrow triangle down | Z-project | Average Intensity [OK]
In the MacroRecorder that gives me only :
I believe that is wrong as when running
on a the same image it only applies the gray LUT to the Red channel.
If I do in GUI: Image | Stacks| Z-Project it again only records
There must be more happening in the background when using the Z-Project command.
How can I implement this in my own macro as the MacroRecorder is apparently not helping me?
I also would like a way to influence the options in the ZProjection window.
Is there a better way to achieve my original goal?
My current strategy would be, to split channels; Image | Color | Split Channel then divide each channel by 3 then add them sequentially using Image calculator.
Something like this (but “made generic”
run("Split Channels"); run("Divide...", "value=3"); run("Divide...", "value=3.000000"); run("Divide...", "value=3.000000"); run("Image Calculator..."); imageCalculator("Add create 32-bit", "C1-100xV_0003.tif","C2-100xV_0003.tif"); imageCalculator("Add create 32-bit", "Result of C1-100xV_0003.tif","C3-100xV_0003.tif"); run("Grays"); run("16-bit");
At this time I do not understand that adding the 3 intermediate images gives me an intensity in the 40000s while the Z-project workflow gives me an image AVG_ very close to 64000.
My midterm goal is to create a Rodbard calibration separately for AVG_Gray and the 3 color channels using 15 neutral density filters. At this time I am only working with the white full intensity image.
I have also experimented with
Image | hyperstack |stack to Hyperstack
Image | hyperstack |reduce dimensionality ( but this step seems to not perform any averaging but simply throws away the green and blue channel and only keeps the red.