biostat_download_shhs: Download SHHS data

Description Usage Arguments Value Examples

Description

Download SHHS data

Usage

1
2
3
biostat_download_shhs(token = nsrr::nsrr_token(),
  out_dir = system.file("extdata", package = "biostatmethods"),
  overwrite = FALSE)

Arguments

token

Token for 'NSRR' data resource, to pass to

out_dir

Directory to download the file

overwrite

Should the file be overwritten if exists already?

Value

A logical if the data was downloaded

Examples

1
2
3
4
5
6
7
token = nsrr::nsrr_token()
res = biostat_download_shhs(token = "", overwrite = TRUE)
testthat::expect_false(res)
if (!is.null(token)) {
    res = biostat_download_shhs()
    testthat::expect_true(res)
}

muschellij2/biostatmethods documentation built on May 25, 2019, 5:01 a.m.