FMap: Fast Map

Description Usage Arguments Value Examples

View source: R/functional.R

Description

A thin wrapper around internal mapply, which can be a bit faster than base Map.

Usage

1
FMap(fn, ...)

Arguments

fn

Function to apply

...

Arguments to fn; Vectors or lists.

Value

A list

Examples

1
2
3
4
5
6
require(microbenchmark)
microbenchmark(
mapply(`*`, 1:100, 101:200),
Map(`*`, 1:100, 101:200),
FMap(`*`, 1:100, 101:200),
(1:100)*(101:200))

gschofl/rmisc documentation built on May 17, 2019, 8:54 a.m.