switchcase: A Simple and Flexible Switch-Case Construct for the 'R' Language
Provides a switch-case construct for 'R', as it is known from other programming languages. It allows to test multiple, similar conditions in an efficient, easy-to-read manner, so nested if-else constructs can be avoided. The switch-case construct is designed as an 'R' function that allows to return values depending on which condition is met and lets the programmer flexibly decide whether or not to leave the switch-case construct after a case block has been executed.
Documentation:
Downloads:
Linking:
Please use the canonical form
https://CRAN.R-project.org/package=switchcase
to link to this page.