VertexROIBase

class glue.core.roi.VertexROIBase(vx=None, vy=None)[source]

Bases: glue.core.roi.Roi

Parameters:
  • vx (list) – initial x vertices
  • vy (list) – initial y vertices

Methods Summary

add_point(x, y) Add another vertex to the ROI
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.
to_polygon()

Methods Documentation

add_point(x, y)[source]

Add another vertex to the ROI

Parameters:
  • x – The x coordinate
  • y – The y coordinate
defined()[source]
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 threshhold. If present, the vertex closest to (x,y) will only be removed if the distance is less than thresh
replace_last_point(x, y)[source]
reset()[source]

Reset the vertex list.

to_polygon()[source]