download_resource: Download an HDX resource

Description Usage Arguments Value Examples

View source: R/resource.R

Description

Download an HDX resource into a specific folder

Usage

1
2
3
4
5
6
7
8
download_resource(
  resource,
  folder = NULL,
  filename = NULL,
  quiet = FALSE,
  force = FALSE,
  ...
)

Arguments

resource

Resource, an HDX resource

folder

character, path of the directory where you will store the data

filename

(character), name of the file you will download

quiet

(logical), no progress bar from download (default = FALSE)

force

(logical) force download (default = FALSE)

...

extra paramaters

Value

Resource

Examples

1
2
3
4
5
6
## Not run: 
#Setting the config to use HDX default server
 res <- read_resource("98aa1742-b5d3-40c3-94c6-01e31ded6e84")
 download_resource(res, folder = "/tmp")

## End(Not run)

dickoa/rhdx documentation built on Oct. 13, 2021, 8:36 p.m.