Shape Information Extraction

Hello,
I was wondering if there was a way to extract polygon information for each individual detection object. I have poked around a bit and have not been able to find anything. The closest I have come is the ‘Add Shape Features’ option in the Analyze->Calculate Features menu.

I am running v0.2.0-m2.

Thank you in advance!

Nick

Can you define this more precisely?
Thanks,
Pete

Yea, no problem. Thanks for your help! I’m hoping to extract a pixel-coordinate representation of the polygon that is the detection object.

Thanks,
Nick

Using this script, I found getPolygonPoints(), which might be a starting… point. You would probably run into problems with anything more complicated than a basic polygon though.

getSelectedObjects().each{println it.getROI().getPolygonPoints()}

If your detection object is a cell… you would probably need to be careful about pulling out the getNucleusROI() versus the exterior cell ROI.

*All coordinates are in pixels, I believe, not um or anything like that.

2 Likes

Thank you very much! I will take a look.

Nick

In case you haven’t seen it, Pete’s post might be even more useful as it creates a CSV file directly.