Skip to content

Latest commit

 

History

History
36 lines (24 loc) · 792 Bytes

README.md

File metadata and controls

36 lines (24 loc) · 792 Bytes

zstd

R-CMD-check

Fast, lossless compression using the Zstandard algorithm

Installation

# Install the development version from GitHub:
## install.packages("devtools")
devtools::install_github("sbearrows/zstd")

Example

Simple data compression example:

library(zstd)
# simple compression and decompression
input <- readBin("input", what = 'raw', n = file.size("input"))
output <- compression(input, level = 10)
original <- decompression(output)

# streamable compression
stream_compression("input", "output.zst", level = 10)

# streamable decompression
stream_decompression("output.zst", "original")