Posted by
Jeremy Adler on
Jan 04, 2016; 9:48am
URL: http://imagej.273.s1.nabble.com/Distance-from-fixed-object-to-threshold-particle-in-a-stack-tp5015307p5015314.html
I am not completely clear about what you are after but
The shortest distance of every pixel from a base binary object are generated using
Distance Map
from Process/Binary
for distance less than 255 pixels
or from Plugins/Process
Exact Signed Euclidean Distance Transform (3D)
then from your stack you need to find the location (x,y) of each object using Analyze/Analze Particles and use this position to read its distance to the object
which can be done using
getPixel(x,y)
from the Distance mapped image
if the base object is a single pixel the forget the distance map and just use the formula for a right angled triangle to find the straightline distance
for the location of the object use the centre of mass option in Analyze/Set Measurements
There are at least two possible complications to consider
1) if you have more than one particle in each image of your stack
2) if there are obstructions in the route to the base object, like lakes that you cannot cross.
-----Original Message-----
From: ImageJ Interest Group [mailto:
[hidden email]] On Behalf Of burt46
Sent: den 3 januari 2016 00:42
To:
[hidden email]
Subject: Distance from fixed object to threshold particle in a stack
Hi,
I am trying to calculate the distance from a fixed object to particles in a stack sequence that have a certain threshold once processed. The nearest i have seen, based on other forum posts, was one entitled "plot profile in a stack" (
http://imagej.1557.x6.nabble.com/plot-profile-in-a-stack-td3695085.html<
http://imagej.1557.x6.nabble.com/plot-profile-in-a-stack-td3695085.html> ) whereby a line can generate slices then export to a text file. This is what im looking for, but it only limits the analysis based on particles on top of the line. Think of this scenario, on a football pitch, if i draw a line through the goal line on one side, then have a stack of aerial images of the entire pitch, i want to calculate the distance a particular player is from the goal line as he runs around the pitch (i.e. each stack image).
Any ideas how this can be done, or at least determine the distance of the closest particle to the fixed position?
Many thanks
--
View this message in context:
http://imagej.1557.x6.nabble.com/Distance-from-fixed-object-to-threshold-particle-in-a-stack-tp5015307.htmlSent from the ImageJ mailing list archive at Nabble.com.
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html