%.% {matchr} | R Documentation |
Compose Functions
Description
Combine two functions into a single function so that the rhs
is called on the arguments first,
then the lhs
.
Usage
lhs %.% rhs
Arguments
lhs |
function to be called second |
rhs |
function to be called first |
Value
a composed function
Examples
sq_log <- round %.% sqrt %.% log
Match(
10:20,
i %fn% (sq_log(i) > 2) ->
"big",
. ->
"small"
)
[Package matchr version 0.1.0 Index]