Determine whether an object is a user-defined format
The is.format function can be used to determine if an object is a
user-defined format of class "fmt".
is.format(x)
x |
A user-defined format of class "fmt". |
The is.format function returns TRUE if the object passed is a
user-defined format. User-defined formats are defined using the value
function. See the value
function help for further details.
A logical value or TRUE or FALSE.
# Define format
fmt1 <- value(condition(x == "A", "Label A"),
condition(x == "B", "Label B"),
condition(TRUE, "Other"))
# Check for format
is.format(fmt1)
is.format("A")Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.