code: def _get_markers(marks, order, bins):
          
  
          if callable(marks):
              markers = [x for x in order if marks(x)]
          elif isinstance(marks, list):
              markers = [order[x] for x in marks]
          elif isinstance(marks, tuple):
              markers = marks
          else:
              nth_mark = np.ceil(len(order) / marks).astype(int)
              markers = order[::nth_mark]
  
          return np.array([bins[x][1] for x in markers])
docs: Helper function to get marker positions depending on mark type.