Download Video From Databrary.
Usage
download_video(
asset_id = 1,
session_id = 9807,
file_name = tempfile(paste0(session_id, "_", asset_id, "_"), fileext = ".mp4"),
target_dir = tempdir(),
vb = options::opt("vb"),
rq = NULL
)
Arguments
- asset_id
Asset id for target file.
- session_id
Slot/session number where target file is stored.
- file_name
Name for downloaded file.
- target_dir
Directory to save the downloaded file.
Default is a temporary directory given by a call to tempdir()
.
- vb
Show verbose messages. (Defaults to FALSE
, overwritable using option 'databraryr.vb' or environment variable 'R_DATABRARYR_VB')
- rq
An httr2
request object.
Value
Full file name to the asset.
Examples
# \donttest{
if (FALSE) { # \dontrun{
download_video() # Download's 'numbers' file from volume 1.
download_video(asset_id = 11643, session_id = 9825, file_name = "rdk.mp4")
#' # Downloads a display with a random dot kinematogram (RDK).
} # }
# }