class_docstr: A path editor.
  
  Press 't' to toggle vertex markers on and off.  When vertex markers are on,
  they can be dragged with the mouse.
class_docstr_tok: ["A","path","editor",".","Press","'t","'","to","toggle","vertex","markers","on","and","off",".","When","vertex","markers","are","on",",","they","can","be","dragged","with","the","mouse","."]
docstr: Return the index of the point closest to the event position or *None*
  if no point is within ``self.epsilon`` to the event position.
docstr_tok: ["Return","the","index","of","the","point","closest","to","the","event","position","or","*","None","*","if","no","point","is","within","``","self.epsilon","``","to","the","event","position","."]
code: def get_ind_under_point(self, event):
      """
      Return the index of the point closest to the event position or *None*
      if no point is within ``self.epsilon`` to the event position.
      """
      xy = self.pathpatch.get_path().vertices
      xyt = self.pathpatch.get_transform().transform(
          xy
      )  # to display coords
      xt, yt = xyt[:, 0], xyt[:, 1]
      d = np.sqrt((xt - event.x) ** 2 + (yt - event.y) ** 2)
      ind = d.argmin()
      return ind if d[ind] < self.epsilon else None
  
file_path: matplotlib/galleries/examples/event_handling/path_editor.py
imports: import matplotlib.pyplot
  import numpy
  from matplotlib.backend_bases import MouseButton
  from matplotlib.patches import PathPatch
  from matplotlib.path import Path
label_desc: Use image node_id 2 for calling the PathInteractor obj's underlying member method code with example usage: obj.get_ind_under_point(event) and returns: unknown