The magrittr package provides operators for chaining R expressions with forward pipes. Do not use this tag for questions which merely contain a pipe operator. Use this tag for questions asking specifically about the behavior of the %>%, %<>%, %$%, or %T>% operators or the convenience functions provided by the package.
To archive its humble aims, magrittr provides a new “pipe”-like operator for r, %>%
, with which you may pipe a value forward into an expression or function call; something along the lines of x %>% f
, rather than f(x)
. This is not an unknown feature elsewhere; a prime example is the |>
operator used extensively in f# (to say the least) and indeed this – along with Unix pipes – served as a motivation for developing the magrittr package.
In order to get better answers always use this tag together with r.
Development version of magrittr is hosted on GitHub.