Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

compose

Composition of Functions


Description

Composes two or more functions into a single function. The returned function calls all provided functions in reverse order: The return value of the last function servers as input for the next to last function, and so on.

Usage

compose(...)

Arguments

...

(functions)
Functions to compose.

Value

(function()) which calls the functions provided via ... in reverse order.

Examples

f = compose(function(x) x + 1, function(x) x / 2)
f(10)

mlr3misc

Helper Functions for 'mlr3'

v0.10.0
LGPL-3
Authors
Michel Lang [cre, aut] (<https://orcid.org/0000-0001-9754-0393>), Patrick Schratz [aut] (<https://orcid.org/0000-0003-0748-6624>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.