powered by
attr(x, which) = y
A wrapper for attr(x, which) = y.
setAttribute(x, which, value)
Changed object x.
x
[any] Your object.
[character(1)] Name of the attribute to set
character(1)
[ANY] Value for the attribute.
ANY
setAttribute(list(), "foo", 1)
Run the code above in your browser using DataLab