normalize_function_list: Normalize a List of Functions

Description Usage Arguments Value Examples

View source: R/function_list.r

Description

Takes a list of functions and function names (or a vector of function names) and names it. Requires all entries with functions to be named and adds names to functions that were specified as names.

Usage

1

Arguments

funs

Valid list or vector of function names and/or functions.

Value

Named list or character vector of functions.

Examples

1
2
3
4
normalize_function_list(c(value = 'mean'))
normalize_function_list(c('median', n = 'length'))
normalize_function_list(list('median', n = length))
normalize_function_list(list(Sum = sum, Custom = function(x) sum(nchar(as.character(x)))))

flying-sheep/ggplot.multistats documentation built on Dec. 9, 2019, 4:19 p.m.