vld_term {term}R Documentation

Validate Term or Term Record

Description

Validates the elements of a term or term_rcrd vector. Use chk_s3_class() to check if an object is a term or term_rcrd.

Usage

vld_term(x, validate = "complete")

vld_term_rcrd(x, validate = "complete")

Arguments

x

The object.

validate

A string specifying the level of the validation. The possible values in order of increasing strictness are 'class', 'valid', 'consistent' and 'complete'.

Details

Internal validity of a term can be checked on three levels:

Missing values are ignored as are duplicates and order.

Value

A flag indicating whether the condition was met.

Functions

See Also

chk_term()

Other valid: valid_term()

Other valid: valid_term()

Examples

# vld_term
vld_term(c("x[2]", "x[1]"))
vld_term(term("x[2]", "x[1]"))

# vld_term_rcrd
vld_term_rcrd(c("x[2]", "x[1]"))
vld_term_rcrd(term_rcrd("x[2]", "x[1]"))

[Package term version 0.3.5 Index]