recursive_reduce: recursive_reduce

View source: R/ascii_tables.R

recursive_reduceR Documentation

recursive_reduce

Description

Utility function used to replicated purrr::reduce. Recursively applies a function to a list of elements until only 1 element remains

Usage

recursive_reduce(.l, .f)

Arguments

.l

list of values to apply a function to

.f

function to apply to each each element of the list in turn. See details.

Details

This function is essentially performing the following operation:

.l[[1]] <- .f( .l[[1]] , .l[[2]]) ; .l[[1]] <- .f( .l[[1]] , .l[[3]])

gowerc/diffdf documentation built on April 9, 2024, 9:34 p.m.