Description Usage Arguments Value Examples
If the input is not scalar, then only the first element is returned, with a warning.
1 | use_first(x, indexer = c("[[", "["), .xname = get_name_in_parent(x))
|
x |
Input that should be scalar. |
indexer |
Either double indexing, |
.xname |
Not intended to be used directly. |
If x
is scalar, it is returned unchanged, otherwise
only the first element is returned, with a warning.
1 |
$`use_first(1:5)`
<simpleWarning: Only the first value of 1:5 (= 1) will be used.>
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.