How can Calculate & Visualize the Center of Mass (COM)?

Hello everyone,

I am currently conducting a research study involving patients with unilateral left-sided breast cancer undergoing radiotherapy. The purpose of my study is to compare Normal Breathing (free breathing) and Deep Inspiration Breath Hold (DIBH) conditions using CT images and image analysis in 3D Slicer version 5.10.0.

In this project, I need to evaluate anatomical displacement and motion-related parameters of the heart and lungs between the two breathing conditions. I would greatly appreciate detailed step-by-step guidance for the following questions.

Question 1:
How can I calculate the Center of Mass (COM) or Centroid of the heart in 3D Slicer version 5.10.0?

I already have segmented heart structures for both breathing conditions. I would like to know the exact workflow step-by-step, including:

Which modules or extensions should be used

How to obtain the centroid coordinates numerically

How to export or save these coordinates

Whether this can be done directly from a segmentation or label map

Any recommended method for accurate COM calculation in Slicer

Question 2:
After obtaining the Center of Mass coordinates for different patients, how can I visualize or display the heart COM inside 3D Slicer?

Specifically, I would like to know:

How to display the COM as a point/marker in 2D and 3D views

Whether fiducial points or markups should be used

How to compare COM locations between Normal Breathing and DIBH

Whether there is a recommended workflow for multiple patients

Figure 1.
Visualization of the heart Center of Mass (COM) in 3D Slicer for a patient with unilateral left-sided breast cancer undergoing radiotherapy planning. This figure is related to Questions 1 and 2 regarding the calculation and visualization of the heart centroid in Normal Breathing and DIBH conditions.

I am a student and still a beginner in working with 3D Slicer software. Therefore, I would highly appreciate very detailed, step-by-step guidance for the following questions. If possible, please explain the workflow in a beginner-friendly manner, including the names of modules, extensions, buttons, and menus that should be used in 3D Slicer version 5.10.0.

Additionally, I noticed that some older tutorials mention extensions such as Plastimatch or QARegistration, but these extensions do not appear in the Extension Manager of Slicer 5.10.0. Therefore, I would appreciate recommendations for alternative workflows that are currently supported in this version.

Thank you very much for your help and guidance.

Yes, you can obtain the centroid coordinates using the Segment Statistics module.

If you already have a segmentation of the heart, you can open Segment Statistics, select the segmentation node and the heart segment, and run the calculation. The module can report the centroid / center of mass coordinates of the segment in Slicer’s coordinate system.

However, if your goal is to compare the center of mass between free breathing and DIBH CT, one additional step is important.

The centroid coordinates are only directly comparable if the two CT volumes are in the same physical coordinate system. If the two CT scans were acquired separately, differences in patient positioning, table position, or image origin may affect the coordinates. In that case, the difference between the two centroids may not represent only the motion of the heart.

So, a possible workflow would be:

  1. Calculate the centroid of the heart segment in the free-breathing CT.

  2. Calculate the centroid of the heart segment in the DIBH CT.

  3. Register the two CT volumes, or otherwise make sure they are in the same coordinate system.

  4. Then compare the two centroid positions, for example by calculating the displacement vector or distance between them.

In short: Segment Statistics can give you the centroid coordinates, but for comparison between two CT scans, you need to make sure both centroids are expressed in the same coordinate system.

Otherwise, you may be measuring differences in scan position rather than true anatomical displacement.