Create axis trough cylinder model

I would like to create (by calculation) an axis in the middle of a cylinder (as seen in the attached file).
axis

Is this something which could be achieved in Slicer?
I thought of performing hole filling in advance and maybe cut the cylinder at the bottom, yet I would like to know if it would be possible to create this axis as I would like to calculate the angle between multiple scans of the same specimen…

Filling the cylinder in Segment Editor is a good idea. You can then use Segment Statistics module to get the position and direction of the cylinder’s long axis.

Thank you!
Can I just choose use any random image data (e.g. from the example data) just to provide RAS coordinates to Segment editor (otherwise it does not work without providing a scalar volume)?
I loaded the MRI head example as scalar volume.

How can I calculate now the angle between the z-axis (this should be the long-axis through the cylinder between those two segments)? (I assume the axes are vectors and represented by the coordinates x y z)

I assume that only the cylinder needs to be depicted without any other structure to make this workflow work?
Bildschirmfoto 2021-07-10 um 10.15.14

If you use the GUI then you can use the Specify geometry button to create an empty labelmap volume automatically. Alternatively, you can create a volume from scratch.