paste2 | R Documentation |
Extends paste
with the ability to remove missing values (NA
).
paste2(..., sep = " ", collapse = NULL, na.rm = FALSE)
... |
Objects converted to character vectors. |
sep |
Character string to seperate the terms. |
collapse |
Character string to separate the results. |
na.rm |
Whether |
http://stackoverflow.com/a/31508774
paste2(c("hello", "goodbye"), NA, NA, "world", NA)
paste2(c("hello", "goodbye"), NA, NA, "world", NA, na.rm = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.