Description Usage Arguments Value Examples
This function is used to get the attribute as a character instead of an expression (e.g. attribute = Length) or an extract to the node (e.g. attribute = node$Length). It is used in a special context where we know the attribute will always be used to reference a node (i.e. data masking).
1 | attribute_as_name(attribute)
|
attribute |
a quoted expression |
The attribute as a character
1 2 3 4 5 6 7 8 9 | ## Not run:
attribute_as_name(rlang::expr(Length))
attribute_as_name(rlang::expr(node$Length))
attribute_as_name(rlang::expr("Length"))
test = "Length"
attribute_as_name(rlang::expr(test))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.