-
Notifications
You must be signed in to change notification settings - Fork 17
How to add a new city
mark padgham edited this page Oct 12, 2017
·
7 revisions
Adding new cities to the package currently requires the following steps:
- Modify all necessary
src/
files and write the appropriate routine inbikedata-files.R
. - Add city to
R/utils.R/convert_city_names
. - Add entry to
R/database-stats.R/bike_demographic_data
. - Update
R/storebikedata.R/get_bike_cities
and../get_flist_city
. - Add entry to
R/bikedata-files.R/get_bike_files
. - Potentially change
R/data-time-functions.R/convert_dates_to_filenames
. - Potentially add city-specific function to
R/stations.R
- Put new data in test data (can be done later)
Test data are created with this script:
bike_write_test_data (tempdir ())
bikedb <- file.path (getwd (), "testdb.sqlite")│
store_bikedata (data_dir = tempdir (), bikedb = bikedb)
index_bikedata_db (bikedb = bikedb)
Then the bikedb
is moved manually to /inst/data
.