Learn R Programming

ohvbd (version 1.0.0)

fetch_vd: Fetch VecDyn dataset/s by ID

Description

Retrieve VecDyn dataset/s specified by their dataset ID.

Usage

fetch_vd(ids, rate = 5, connections = 2, basereq = vb_basereq())

Value

A list of httr2 response objects, as an ohvbd.responses object.

Arguments

ids

a numeric ID or numeric vector of ids (preferably in an ohvbd.ids object) indicating the particular dataset/s to download.

rate

maximum number of calls to the API per second.

connections

number of simultaneous connections to the server at once. Maximum 8. Do not enable unless you really need to as this hits the server significantly harder than usual.

basereq

an httr2 request object, as generated by vb_basereq(). If NA, uses the default request.

Author

Francis Windram

Examples

Run this code
if (FALSE) { # interactive()
fetch_vd(54)

fetch_vd(c(423,424,425))

ohvbd.ids(c(423,424,425), "vd") |>
  fetch() # Calls fetch_vd()
}

Run the code above in your browser using DataLab