powered by
Vectorized version of base::switch(): just loops over input and calls base::switch().
base::switch()
switchv(EXPR, ...)
Vector of returned values.
An expression evaluating to a vector of numbers of strings
List of alternatives
switchv(c("horse", "fish", "cat", "bug"), horse="fast", cat="cute", "what?")
Run the code above in your browser using DataLab