Skip to contents

downloads the files described in a selection tibble (typically produced by liss_select()) to a local directory. requires an active session established by liss_login().

Usage

liss_download(
  .hosted = NULL,
  .dir = "liss",
  .modules = NULL,
  .waves = NULL,
  .unzip = TRUE
)

Arguments

.hosted

a tibble with at least columns module, wave, file, and path, as returned by liss_select() or get_hosted_files(). if NULL, calls get_hosted_files() internally.

.dir

character. local directory to save files to. created automatically if it does not exist.

.modules

optional character or integer vector to filter by module.

.waves

optional integer vector to filter by wave number.

.unzip

logical. if TRUE (the default), ZIP files are extracted and the archive is removed.

Value

a tibble of download results with columns file and status (invisibly).

Examples

if (FALSE) { # \dontrun{
liss_login()
selection <- liss_select()
liss_download(selection)
} # }