Measure 3D distance of cells to a structure

Hi! I have z-stacks of confocal images that consist of 2 channels. In the first channel I have cell and in the second channel I have a structure with cells. I would like to know if there is any way to measure the distance of cells from the structure. Actually, I am wondering if there is any way to define channel 2 as a volume and afterwards measure the distance of the cells in channel 1 from that volume.

1 Like

Hi @Spyr7,

You can use the new 3D Distances plugin as part of the 3D ImageJ Suite. You will have first to segment the two channels.

The plugin will allow you to choose between center-center distances or border-border distances. You can also measure distances between only the closest objects from one channel or between all objects.

Hope this helps

Best

Thomas

1 Like

Hi @ThomasBoudier,

Thanks for the response. The plugin works fine. However, I have a question regarding the results table of 3D Distances and if the objects could be labeled on the image.

Thanks for your help

Hi @Spyr7,

Sure, what you would like to know ?

Best,

Thomas

Hi @ThomasBoudier,

I would like to know what the columns and the rows of the results table represent and if is it possible to display each object(cell) with its label on an image view.

Best,
Spyr7

Hi @Spyr7,

For the closest analysis, the results table will display :

  • label is the value of the object in the labelled image 1
  • closest_1 is the label of the closest object in image 2
  • distance_1 is the distance to this closest object
  • closest_2 is the label of the second closest object in image 2
  • distance_2 is the distance to this second closest object

Of course if you have only one image, closest object will always be itself and distance will be 0.

For the all analysis, the results table will display all the distances between all pairs of objects. Label A is the label for first image and B is the label for the second image.

Regarding the labelling of objects within the image, are you referring to putting text below the object ? For this you can use the 3DManager, just Add your image to the manager then select an image and use Label.

Hope this helps

Best,

Thomas

1 Like

Hi @ThomasBoudier,
Yes that was really intuitive. Thanks a lot!

Best,
Spyr7

Hi @ThomasBoudier !
I have a quick question: I have two images -

Image 1 with the cells
Image 2 with tissue outline.

I’d like to find the shortest distance between each the center of each cell and the tissue (border).

I’ve tried using the 3D Distances plugin, but I’m not sure if the parameters I’m entering in the tool are correct. I’ve included a screenshot below - can you please let me know if this is correct?

Thank you!!
3DDistancesParameters|284x484

Hi @sk1 ,

Actually if you are measuring all distances, the parameter closest is not used. This parameter closest is used to select the criteria to compute the closests objects (either by center-center distance or border-border distance).

Please note that the plugin will only measure center-center distances or border-border distances, the center-border distance is not yet implemented in this plugin, but is available within the 3D Manager.

For your case, I guess you have one or very few tissue objects and many cells, so you can measure all distances, and you want border-border distances; this border (tissue)-border (cell) distance may eventually be more meaningful than an arbitrary center-border distance.

Hope this helps,

Best,

Thomas

1 Like

Hi @ThomasBoudier ,

Thank you for your help! I have a follow up question: in Image 1 (with the cells), there are four different cells. In Image 2, there is only 1 tissue border. However, when I run the plugin, there is only 1 resulting distance measurement.

Would there be any way to get the distance between the tissue border and each cell?
Thank you!

Hi @sk1,

If you choose all distances and select Image1 with four cells and image2 with one object, you should definitely get 4 result lines. Make sure your images are labelled (each object has a different grey value).

Best,

Thomas

Hi @ThomasBoudier ,

You have been so helpful, thank you so very much!

Unfortunately, the cells in my images are color-coded, so they are not each individually labelled. Is there any way that the plugin can still work if the cells do not each have a different grey value? Or, is there any way in ImageJ to update the grey value of my cells so that they are each individually labelled?

On a tangent, I tried to put the labels under the objects in the image by using the 3D Manager, Adding my image, and selecting Label. However, nothing showed up under the images. Am I doing this correctly?

Once again, thank you!

Hi @sk1,

Humm if your image is not segmented it is quite impossible to do any analysis because the computer has no idea where the objects are. If you are not familiar with segmentation techniques, you can try to post a sample image here so we can help yu with the segmentation.

Best

Thomas