R语言|转换大小写|toupper(),tolower()

## 转换字符串大小写
x <- c("a","b","c","d")
## 转换小写
tolower(x)
## 转换大写
toupper(x)
y <- toupper(x)
# 转换数据框列大小写
A1 <- toupper(antisocial$Allele1)
A2 <- toupper(antisocial$Allele2)
antisocial$Allele1 <- A1
antisocial$Allele2 <- A2

 

posted @ 2021-11-14 21:04  西西与维奥拉  阅读(222)  评论(0)    收藏  举报