The toupper()
function in R converts a string to uppercase.
The following figure shows a visual representation of the toupper()
function.
toupper(string)
As a parameter, the toupper()
function requires a string that is to be converted to uppercase.
The toupper()
function returns a string that is converted to uppercase.
The code below shows how the toupper()
function works.
#Stringa <- toupper("educative");print(paste0("toupper('educative'): ", a))#String with numberb <- toupper("educative09");print(paste0("toupper('educative09'): ", b))