Amherst-Statistics / ValleyBikes-obsolete

Repository for the Valley Bikes data project
Other
0 stars 0 forks source link

Spec interface for function to read the trip data for a day #12

Open elachtara opened 4 years ago

elachtara commented 4 years ago

from the external website into some specified directory

shukryzablah commented 4 years ago

Reinstall the package and see the fetch_dates function. It requires a start date and an end date and downloads to a specified directory. There is no error checking right now.

ValleyBikes::fetch_dates("2018-07-01", "2018-07-05", output_dir = "~/Downloads")

and it returns list of paths invisibly.

nicholasjhorton commented 4 years ago

This looks good.

@shukry Might you be willing to add an example of usage to the fetch_dates() function? I'm thinking that you would spec "." as the output_dir=.

shukryzablah commented 4 years ago

Added a simple example to the function's documentation accessible at ?fetch_dates and changed the default directory to the present directory.

The function still doesn't handle dates that have no data inside the specified date range, e.g. "2016-01-01" - "2016-01-01". What should the behavior be?