Re: distance between adjacent particles
Posted by Gabriel Landini on May 09, 2007; 10:36pm
URL: http://imagej.273.s1.nabble.com/distance-between-adjacent-particles-tp3699485p3699487.html
On Wednesday 09 May 2007 21:30:10 Michael Schmid wrote:
> > I have an image with many particles, distributed randomly. I'm
> > trying to get the average distance between a particle with all its
> > closest neighbors but not all of the particles on the image.
> > Is there an easy way to do or an existing plugin that allows such
> > measurement?
To do this using brute-force would be quite easy with a macro:
get the coordinates of all the points or centroids in arrays x() and y(),
for each point calculate using pythagoras, the distance to all other points
and keep the shortest one in another array.
Now look at the distribution of shortest distances.
Cheers,
G.