isd_parse: Parse NOAA ISD/ISH data files

View source: R/isd_parser.R

isd_parseR Documentation

Parse NOAA ISD/ISH data files

Description

Parse NOAA ISD/ISH data files

Usage

isd_parse(
  path,
  additional = TRUE,
  parallel = FALSE,
  cores = getOption("cl.cores", 2),
  progress = FALSE
)

Arguments

path

(character) file path. required

additional

(logical) include additional and remarks data sections in output. Default: TRUE

parallel

(logical). do processing in parallel. Default: FALSE

cores

(integer) number of cores to use: Default: 2. We look in your option "cl.cores", but use default value if not found.

progress

(logical) print progress - ignored if parallel=TRUE. The default is FALSE because printing progress adds a small bit of time, so if processing time is important, then keep as FALSE

Value

A tibble (data.frame)

References

ftp://ftp.ncdc.noaa.gov/pub/data/noaa

See Also

isd_parse_line

Examples

path <- system.file('extdata/104270-99999-1928.gz', package = "isdparser")

(res <- isd_parse(path))

# with progress
(res2 <- isd_parse(path, progress = TRUE))

# only control + mandatory sections
(res <- isd_parse(path, additional = FALSE))

## Not run: 
# in parallel
(out <- isd_parse(path, parallel = TRUE))

## End(Not run)

ropensci/isdparser documentation built on Sept. 12, 2022, 8:01 a.m.