chunk.bit: Chunk bit vectors

Description Usage Arguments Value Author(s) See Also Examples

View source: R/ffbit.R

Description

chunking method for ffdf objects automatically considering RAM requirements from recordsize as calculated from sum(.rambytes[vmode])

Usage

1
2
## S3 method for class 'bit'
chunk(x, RECORDBYTES = .rambytes["logical"], BATCHBYTES = getOption("ffbatchbytes"), ...)

Arguments

x

bit

RECORDBYTES

optional integer scalar representing the bytes needed to process a single element of the bit vector

BATCHBYTES

integer scalar limiting the number of bytes to be processed in one chunk, default from getOption("ffbatchbytes"), see also .rambytes

...

further arguments passed to chunk

Value

A list with ri indexes each representing one chunk

Author(s)

Jens Oehlschl<c3><a4>gel

See Also

chunk, bit

Examples

1
2
3
4
5
6
7
  n <- 1000
  x <- bit(n)
  ceiling(n / (300 %/% sum(.rambytes["logical"])))
  chunk(x, BATCHBYTES=300)
  ceiling((n/2) / (100 %/% sum(.rambytes["logical"])))
  chunk(x, from=1, to = n/2, BATCHBYTES=100)
  rm(x, n)

kindlychung/ff documentation built on May 20, 2019, 9:58 a.m.