bind_to_function

0th

Percentile

Encloses argument in a function's environment

This function takes a function f and a series of named arguments, and returns a closure of f which will only rely on one single argument 'param'. This is used to reduce the number of arguments passed around to likelihood or movement functions. This functionality is used internally when creating closures of custom moves in bind_moves.

Usage
bind_to_function(f, ...)
Arguments
f

The function to which arguments are bound.

...

Named arguments to bind to the function's environment.

References

Initial code comes from the partially_apply function in the 'rodeint' package (/github.com/richfitz/rodeint/).

Aliases
  • bind_to_function
Documentation reproduced from package outbreaker2, version 1.0.1, License: MIT + file LICENSE

Community examples

Looks like there are no examples yet.