Description Usage Arguments Examples
This function allows the user to extract a substring of a character string whilst containing the start and stop values from the RHS of the string. The user is also given the option of reversing the extracted string before returning the extracted value.
1 | substrRight(x, start, stop, reverse)
|
x |
a character vector |
start |
integer. The first element to be replaced (counting from the RHS). |
stop |
integer. The last element to be replaced (counting from the RHS). |
reverse |
logical. Reverse the ordering of characters. Defaults to FALSE. |
1 2 3 4 5 | x <- '91726352EXTRACT ME2345'
substrRight(x = x, start = 5, stop = 14)
x <- '15679NODNOL'
substrRight(x = x, start = 1, stop = 6, reverse = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.