ropensci/stats19

Should `dl_stats19` have default type as `acc` like `get_stats19`

layik opened this issue · 1 comments

layik commented
stats19::dl_stats19(2018)
#> More than one file found, selecting the first.
#> Files identified: dftRoadSafetyData_Vehicles_2018.csv
#>    http://data.dft.gov.uk.s3.amazonaws.com/road-accidents-safety-data/dftRoadSafetyData_Vehicles_2018.csv
#> Attempt downloading from:
#> Data saved at /var/folders/z7/l4z5fwqs2ksfv22ghh2n9smh0000gp/T//RtmpFltSNF/dftRoadSafetyData_Vehicles_2018.csv
d = stats19::get_stats19(2018)
#> Files identified: dftRoadSafetyData_Accidents_2018.csv
#>    http://data.dft.gov.uk.s3.amazonaws.com/road-accidents-safety-data/dftRoadSafetyData_Accidents_2018.csv
#> Attempt downloading from:
#> Data saved at /var/folders/z7/l4z5fwqs2ksfv22ghh2n9smh0000gp/T//RtmpFltSNF/dftRoadSafetyData_Accidents_2018.csv
#> Reading in:
#> /var/folders/z7/l4z5fwqs2ksfv22ghh2n9smh0000gp/T//RtmpFltSNF/dftRoadSafetyData_Accidents_2018.csv
#> date and time columns present, creating formatted datetime column

Created on 2020-12-04 by the reprex package (v0.3.0)

The issue is not specifying "type" in dl_stats19 here

stats19/R/dl.R

Line 36 in 2ef7fab

type = NULL,

Any issues you can see with this change? PR will follow for test.

layik commented

In fact, in the not so great docs of the function, it was meant to be so will send the PR.