Specifications of flexmodel objects often involves string manipulations with regular expressions, and these functions provide some convenience in this area.

alt_group(x, exact = FALSE, negate = FALSE)

wrap_exact(x)

all_in(x)

any_var(x)

all_except(x)

Arguments

x

character vector to convert into a length-1 character vector representing a regular expression pattern

exact

should the regular expression look for exact matches?

negate

should the regular expression look for stings that do not match?

Value

a regular expression pattern to be used in functions like grep and grepl, but also in add_state_param_sum