rtapeLapply: Iterate over tape, gathering results.

Description Usage Arguments Details Value Author(s) Examples

Description

Iterate over tape, gathering results.

Usage

1
rtapeLapply(fNames, FUN, ...)

Arguments

fNames

Name of the tape file to read; if this argument is a vector of several names, function behaves as reading a single tape made of all those tapes joined in a given order.

FUN

Callback function.

...

Additional parameters to FUN.

Details

This function read the tape from the oldest to the newest writes and executes the callback function on each read object. Logically, it is an equivalent to lapply(rtapeAsList(fName),FUN,...), but it is optimized to store only the currently processed object in the memory.

Value

A list containing results of FUN calls.

Author(s)

Miron B. Kursa M.Kursa@icm.edu.pl

Examples

1
2
3
4
5
6
7
8
unlink('tmp.tape')
#Record something on the tape
rtapeAdd('tmp.tape',runif(3))
rtapeAdd('tmp.tape',rnorm(3))

#Print tape contents
rtape_apply('tmp.tape',print)
unlink('tmp.tape')

rtape documentation built on May 2, 2019, 9:18 a.m.

Related to rtapeLapply in rtape...