You are reading an old version of the documentation (v3.0.2). For the latest version see https://matplotlib.org/stable/
Version 3.0.2
matplotlib
Fork me on GitHub

matplotlib.axis.YTick.set_contains

YTick.set_contains(picker)

Replace the contains test used by this artist. The new picker should be a callable function which determines whether the artist is hit by the mouse event:

hit, props = picker(artist, mouseevent)

If the mouse event is over the artist, return hit = True and props is a dictionary of properties you want returned with the contains test.

Parameters:
picker : callable