varname {wakefield} | R Documentation |
Add Internal Name to Vector
Description
Adds the class variable
and an internal
attributes(x)[["varname"]]
attribute to a vector.
Usage
varname(x, name)
Arguments
x |
A vector to add a |
name |
A name to assign to |
Value
Returns a vector of the class variable
with a
attributes(x)[["varname"]]
assigned.
Examples
varname(1:10, "A")
attributes(varname(1:10, "A"))
sum(varname(1:10, "A"))
varname(LETTERS, "Caps")
attributes(varname(LETTERS, "Caps"))
paste(varname(LETTERS, "Caps"), collapse="")
[Package wakefield version 0.3.6 Index]