strTail | R Documentation |
Function that returns the last n characters from (vector of) character string(s).
strTail( string, n_char=1)
string |
Character string or vector of character strings. |
n_char |
Number of characters to take from the tail (starting at the last character) of the string (or vector of strings). Defaults to 1. |
Typical use of the function is return just the last few characters of a character string.
Function returns a character string (vector) consisting of the last n_char of the character string (vector of character strings).
Damian W. Betebenner dbetebenner@nciea.org
strTail(state.name, 2) ### Last two characters of each state name
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.