if (stri_install_check(silent=TRUE))
stri_count_charclass(c("stRRRingi", "STrrrINGI", "123"),
c("\\p{Ll}", "\\p{Lu}", "\\p{Zs}"))
if (stri_install_check(silent=TRUE))
stri_count_charclass("\t\n", "\\p{WHITE_SPACE}") # white space - binary property
if (stri_install_check(silent=TRUE))
stri_count_charclass("\t\n", "\\p{Z}") # whitespace - general category (note the difference)
Run the code above in your browser using DataLab