csv_to_fst: Convert CSV Files to FST Format

View source: R/misc_functions.R

csv_to_fstR Documentation

Convert CSV Files to FST Format

Description

This function converts one or more CSV files to the FST file format. It reads each CSV file using data.table::fread and writes it as an FST file using fst::write_fst. Optionally, the original CSV file(s) can be deleted.

Usage

csv_to_fst(csv_files, compression = 100L, delete_csv = FALSE)

Arguments

csv_files

A character vector of file paths to CSV files.

compression

An integer specifying the compression level for the FST file. Default is 100L.

delete_csv

Logical. If TRUE, deletes the original CSV file(s) after conversion. Default is FALSE.

Value

Invisibly returns NULL.

Examples

## Not run: 
csv_to_fst(c("data.csv"), compression = 100L, delete_csv = TRUE)

## End(Not run)

ChristK/CKutils documentation built on April 11, 2025, 10:11 p.m.