| names2 | R Documentation |
A simple wrapper around base::names().
Returns a character vector even if no names attribute is set.
Values NA and "" are treated as missing and replaced with the value provided in missing_val.
names2(x, missing_val = NA_character_)
x |
( |
missing_val |
( |
(character(length(x))).
x = 1:3
names(x)
names2(x)
names(x)[1:2] = letters[1:2]
names(x)
names2(x, missing_val = "")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.