【发布时间】:2013-09-01 19:16:36
【问题描述】:
是否有其他版本可以使每个字符串的第一个字母大写并且对于 flac perl 也使用 FALSE?
name<-"hallo"
gsub("(^[[:alpha:]])", "\\U\\1", name, perl=TRUE)
【问题讨论】:
-
总是一个字吗?这可能会有所帮助 - How to convert a vector of strings to Title Case。查看@mnel 的回答
-
toupper中的示例可能有用,例如.simpleCap -
@Henrik 将每个单词都大写。
-
@zx8754 我看不到 perl flac FALSE 的解决方案
-
@SimonO101,也许我误解了克劳斯所说的“每个字符串”。