cloud_s3_upload | R Documentation |
Uploads a local file from the project's directory to its corresponding location within the project's S3 root folder.
cloud_s3_upload(file, root = NULL)
file |
Path to a file relative to project folder root. Can contain only letters, digits, '-', '_', '.', spaces and '/' symbols. |
root |
S3 path of the project root. This serves as the reference point
for all relative paths. When left as |
Invisibly returns NULL
after successfully uploading the file.
# create a toy csv file
dir.create("toy_data")
write.csv(mtcars, "toy_data/mtcars.csv")
# uploads toy_data/mtcars.csv to 'data' subfolder of project's S3 folder
cloud_s3_upload("toy_data/mtcars.csv")
# clean up
unlink("toy_data", recursive = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.