Re: Measuring distance between two points
Posted by
simon andrews (BI) on
URL: http://imagej.273.s1.nabble.com/Measuring-distance-between-two-points-tp3683081p3683085.html
> -----Original Message-----
> From: ImageJ Interest Group [mailto:
[hidden email]] On
> Behalf Of Liliana de Jesus Duarte Ferreira
> Sent: 20 June 2008 16:08
> To:
[hidden email]
> Subject: Measuring distance between two points
>
> Dear all
>
> Can anyone tell me how to measure the distance between two
> spots that are in different sections of the same stack?
It's just an extension of Pythagoras' theorem to do this in 3D.
ie
sqrt((x1-x2)**2 + (y1-y2)**2 + (z1-z2)**2)
You'll need to watch out that the distance between adjacent pixels in
the same stack probably won't be the same as the distance between the
same pixel in adjacent stacks so convert to real distances as early as
possible to keep things simple.
It may well be overkill for your case, but I wrote a plugin to this a
while back. It requires fairly clean images and needs Java3D to be
installed, but it might be worth a look.
http://www.bioinformatics.bbsrc.ac.uk/projects/stackmeasure/Simon.