I have an image with white of various intensities, thicknesses, lengths and shapes on it. I am interested in finding the total displacement from the beginning to the end of each track. I have manually drawn on each track using the line tool to create regions of interest.
Is it now possible to find the total displacement from the beginning of each track , not the total length of the track. It might have already been done before. Can someone please point me to any solutions.
(the image is attached)
Hi Bilal, you could use in a macro the command:
Then take the first and last elements of the arrays
ypoints to calculate the displacement.
Hope this helps,
Thanks for response.
I am a novice to Macro writing. Can I just paste this into new Macro and run it.
“Is it now possible to find the total displacement from the beginning of each track , not the total length of the track.”
Do you want the trajectory with its different positions (x, y)?
You don’t want the length.
Is this the image you want to get?
Use the PlugIn “Ridge Detection”.
Could write me the steps I need to follow.
Know your basics, know your math.
Use the Pythagorean theorem on points
xpoints,ypoints and xpoints[xpoints.length-1],ypoints[ypoints.length-1], which is the macro language notation of the first and last elements of the ROI as @RoccoDAntuono already pointed out.
The following Error was obtained obtained:
|Error:||Unrecognized command: “Enhance Local Contrast” in line 3:|
|run ( “Enhance Local Contrast” , “blocksize=127 histogram=256 maximum=3” <)> ;|
This is the filter: “enhance local contrast”.
I use ImageJ (version 1.52u) and not FIJI.
Thanks Mathew for your help.