Check weights argument

validate_weights(w)

Arguments

w

The weights argument specified by user or the result of calling model.weights on a model frame.

Value

If no error is thrown then w is returned.