Check whether the class of an object is as expected

.check_class(object, proper_class, mode = "any")

Arguments

object

An object whose class needs checking,

proper_class

A string describing the desired class of object.

mode

Optional. A string describing the desired mode of object. Use only if proper_class is vector. Mode cannot be Date. Use proper_class = "Date" for checking class of Date vector.

Value

TRUE if no error is thrown.