| listDataElementAccess | R Documentation |
This is the generic behind ' to modify the behaviour of '
listDataElementAccess(X, .body, .env)
X |
the list on which to operate |
.body |
an expression, which is either a single name, in which case a the correponding '$'-operator is applied to the list, or a full expression, in which '.' takes the role of the selected element. |
.env |
the environment the .body expression shall be evaluated in |
a list from the results of body evaluated in .env, with . standing in for the elements of X, or if .body is a name with .$name evaluted.
L = list(list(name = "a", val = 1), list(name = "b", val = 2))
# a bare name applies the corresponding `$` accessor to each element
listDataElementAccess(L, quote(name), environment())
# a full expression uses `.` for each list element
listDataElementAccess(L, quote(.$val * 10), environment())
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.