Ejemplo n.º 1
0
 def _check_quantiles(self, val):
     """
     Validate the quantiles passed in. Returns the np array if valid.
     """
     if len(val) != 3 or not is_monotonic(val) or not np.all(val < 1):
         raise YellowbrickValueError(
             "quantiles must be a sequence of three "
             "monotonically increasing values less than 1")
     return np.asarray(val)
Ejemplo n.º 2
0
 def _check_quantiles(self, val):
     """
     Validate the quantiles passed in. Returns the np array if valid.
     """
     if len(val) != 3 or not is_monotonic(val) or not np.all(val < 1):
         raise YellowbrickValueError(
             "quantiles must be a sequence of three "
             "monotonically increasing values less than 1"
         )
     return np.asarray(val)