VertexROIBase¶
- class glue.core.roi.VertexROIBase(vx=None, vy=None)[source]¶
Bases:
glue.core.roi.Roi
Methods Summary
add_point
(x, y)Add another vertex to the ROI
defined
()Returns whether or not the subset is properly defined
remove_point
(x, y[, thresh])Remove the vertex closest to a reference (xy) point
replace_last_point
(x, y)reset
()Reset the vertex list.
Returns a tuple of x and y points, approximating the ROI as a polygon.
transformed
([xfunc, yfunc])A transformed version of the ROI
Methods Documentation
- add_point(x, y)[source]¶
Add another vertex to the ROI
- Parameters
x – The x coordinate
y – The y coordinate
- remove_point(x, y, thresh=None)[source]¶
Remove the vertex closest to a reference (xy) point
- Parameters
x – The x coordinate of the reference point
y – The y coordinate of the reference point
thresh – An optional threshold. If present, the vertex closest to (x,y) will only be removed if the distance is less than thresh