n_of_u_chars: Unicode Character Counts

Description

Compute the number of Unicode characters (code points) in sequences or ranges of Unicode characters.

Usage

1

Arguments

x

a vector of Unicode characters, character ranges, or character sequences.

Value

An integer vector with the numbers of Unicode characters specified by the elements of x.

Examples

1
2
3
4
5
6
7
## How many code points are assigned to the Latin and Cyrillic scripts?
x <- u_scripts(c("Latn", "Cyrl"))
## Numbers in the respective ranges:
n <- lapply(x, n_of_u_chars)
n
## Total number:
sapply(n, sum)

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.