mapReduce: Map reduce code to help with processing of chunks

Description Usage Arguments Value Examples

Description

Map reduce code to help with processing of chunks

Usage

1
mapReduce(nameInput, chunkSize, totalSize, data)

Arguments

nameInput

if data is coming from Alteryx, name of the input data is coming from

chunkSize

maximal size of chunk

totalSize

total size of data

data

dataframe outside of Alterx, not dataframe if inside Alteryx

Value

function taking two function arguments - a map function and a reduce function and applying them as expected

Examples

1
2
3
4
5
6
7
8
9
## Not run: 
   mapReduce(NULL, 15, 100,
     data.frame(x = 1:100)
   )(sum, function(x){sum(unlist(x))})
   mapReduce(NULL, 15, 100,
     data.frame(x = 1:100)
   )(function(x) {sum(x^2)}, function(x) {sum(unlist(x))})

## End(Not run)

alteryx/AlteryxSim documentation built on May 10, 2019, 10:26 a.m.