check_valid_y

Functions

check_valid_y(y, order)

Ensure y is a non-empty Pandas series or Numpy array, and raise errors according to conditions of failed check

Module Contents

check_valid_y.check_valid_y(y, order)

Ensure y is a non-empty Pandas series or Numpy array, and raise errors according to conditions of failed check

Parameters:
  • (Any) (y)

  • (Str) (order)

  • Raises

  • TypeError (If y is of an unsupported type)

  • ValueError (If y is an empty Pandas series or Numpy array)

  • Returns

  • None

Examples

>>> check_valid_y(np.empty(0), 'second')