Asserts a given expression and throws an error if it returns FALSE

assert(expression, error)

Arguments

expression

R expression to be evaluated

error

message to be displayed when the expression is not fulfilled