Case Conversion

Often during data transformations strings have to be converted from one case to the other. These simple transformations could be achieved by tolower() and toupper() functions. The casefolding() function could also be used as a wrapper to the two functions.

toupper('string manipulation') # Converting text to upper case.
## [1] "STRING MANIPULATION"
tolower('STRING MANIPULATION') # Converting text to lower case.
## [1] "string manipulation"
casefold('string manipulation', upper=TRUE) # Usage of the casefold function.
## [1] "STRING MANIPULATION"