Posted by
Romain Guiet on
Feb 27, 2015; 7:24am
URL: http://imagej.273.s1.nabble.com/make-a-polyline-tp5011797.html
Dear All,
I’m facing a “stupid’’ issue in macro language and I guess I’m missing something without finding what -_-'
Here you’ll find a montage image:
https://dl.dropboxusercontent.com/u/22602328/imageJ/polylineIssue.jpgas an example of each step:
1 2 3
4 5 6
1-I have a segmented particle
2-That I skeletonize
3-Make points from mask
4-Then create a polyline using
getSelectionCoordinates(xpoints, ypoints);
makeSelection("polyline", xpoints, ypoints);
5 and 6 are just magnification to more clearly see the issue : a “zigzag” line instead of a “simpler” one.
In the next step I will measure pixel intensities on another image using this line and the getProfile() function…
(I’m interested in the shape of this profile, not the absolute values ;) )
Any simple idea ? or do I need to write a function findClosestNeighbour to apply, between step 3 and 4, on my points before creating the polyline.
Thanks in advance for any input,
Cheers,
Romain
---------------------------------------------------------------
Dr. Romain Guiet
Bioimaging and Optics Platform (PT-BIOP)
Ecole Polytechnique Fédérale de Lausanne (EPFL)
Faculty of Life Sciences
Station 19, AI 0140
CH-1015 Lausanne
Phone: [+4121 69] 39629
http://biop.epfl.ch/---------------------------------------------------------------
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html