box_read will download a file specified by file_id, and
attempt to read it into memory as an R object. This can be useful, for
example, to read in a .csv file as a data.frame.
Converting a file to an R object is by default handled by
rio's import function. The only
modification of it's behavior is that json files are not neccesarily
coerced to data.frames, but can used to store list data, too.
In addtion, more specific read functions are provided:
box_read(file_id, type = NULL, version_id = NULL, version_no = NULL, read_fun = rio::import, fread = FALSE, ...)
box_read_csv(file_id, ...)
box_read_tsv(file_id, ...)
box_read_json(file_id, ...)
box_read_excel(file_id, ...)version_id of
the desired filebox_dl for saving files to disk,
box_save for working with R workspaces, and
box_source for working with R code.