save_tmp: save temp to store temporary results

Description Usage Arguments Value Examples

View source: R/save_temp.R

Description

This utility function saves temporary data prep results as fst into a given subfolder of path, i.e. tmp! The function also coerces the sf object to a normal data frame by recovering the lat/lon and dropping the geometry. This allows the tibble to be saved as fst (binary format).

Usage

1
save_tmp(.ds, .prefix, .pth = pth)

Arguments

.ds

processed tibble requiring an (additional) id colum

.prefix

a tag to recall what data subset is processed, e.g. departure side (DEP)

.pth

path to store the temp files while iterating

Value

no return as file will be written out to pth folder the function is chatty (ui_info)

Examples

1
2
3
4
## Not run: 
 save_tmp(rq, .prefix = "DEP")
 
## End(Not run)

rainer-rq-koelle/COVID19airtraffic documentation built on March 26, 2021, 5:18 a.m.