mutate: Make mutations across many functions

View source: R/mutate.R

mutateR Documentation

Make mutations across many functions

Description

Goal here is to input many functions but only make one mutation in one the functions to better isolate the effect of the mutation. See Details.

Usage

mutate(x)

Arguments

x

a list of output from parse_fxns()

Details

use a while loop internally; attempt to mutate each function until we make a successful mutation, and then return the complete set of functions with one function with one mutation

Value

a list of the above

Examples

## Not run: 
foo <- function(x) {
  if (x == 1) x else 5
}
bar <- function(w) {
  if (w == 10) w else 5
}
mutate(list(foo, bar))

## End(Not run)

ropensci/mutant documentation built on Nov. 13, 2024, 8:31 a.m.