Description Usage Arguments Details Value Author(s) Examples
View source: R/util_get_numbers.R
Extracts numbers from a vector of character strings.
1 |
x |
Character string or vector. |
This function uses the regular expression pattern "\\(?[0-9]+"
to extract numbers from a vector of character strings.
Note that decimal numbers (e.g., 3.5
)
Returns a numeric vector.
Ivan Jacob Agaloos Pesigan
1 2 3 4 5 | x <- c(
"fkj;lakjfajkfak73875kllkj75487",
"jhgtfiusdf639jhdajkhdf7356.4763"
)
util_get_numbers(x)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.