ag_fetch: Fetch Data Used in Autograder

Description Usage Arguments Value Examples

View source: R/download_data.R

Description

Downloads and loads into R the problem specific data.

Usage

1
2
ag_fetch(problem = NULL, when = c("last-day", "last-week", "last-month",
  "start-day"), from = Sys.Date(), to = Sys.Date(), save_dir = getwd())

Arguments

problem

A string indicating the problem to obtain data for.

when

A string containing either: last-day, last-week, last-month, or 'start-day'. If present, then parameters from and to are ignored.

from

A date in yyyy-mm-dd format that represents the starting time. This parameter is ignored if when is given.

to

A date in yyyy-mm-dd format that represents the end time. This parameter is ignored if when is given.

save_dir

A string indicating the save path to use.

Value

A data.frame containing problem specific data.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
## Download all the data in one file
ag_fetch(problem = "twitter-proj", when = "start-day")

## Download data from the last day
ag_fetch(problem = "twitter-proj", when = "last-day")

## Download data for specific time intervals
ag_fetch(problem = "twitter-proj",
              from = "2016-10-09", to = "2016-10-10")

## End(Not run)

coatless/autograde documentation built on May 13, 2019, 8:45 p.m.