ropensci-archive / bomrang

:warning: ARCHIVED :warning: Australian government Bureau of Meteorology (BOM) data client for R
Other
109 stars 26 forks source link

Should get_precis_forecast be explicit in returning data.table brackets? #109

Closed KyleHaynes closed 4 years ago

KyleHaynes commented 4 years ago

Should the get_precis_forecast be explicit in returning dt[] to avoid confusion to non data.table users? E.g. as detailed in the following S/O post: https://stackoverflow.com/a/33196350/2449656

f <- get_precis_forecast(state = "QLD")

# Print output ...
f
# Nothing is returned/printed. Whaaaat?

# Try again ...
f
     index product_id state         town       aac       lat      lon elev    start_time_local end_time_local utc_offset       
  1:     0   IDQ11295   QLD     Brisbane QLD_PT001 -27.48080 153.0389  8.1 2020-01-05 05:00:00     2020-01-06      10:00       
  2:     1   IDQ11295   QLD     Brisbane QLD_PT001 -27.48080 153.0389  8.1 2020-01-06 00:00:00     2020-01-07      10:00       
  3:     2   IDQ11295   QLD     Brisbane QLD_PT001 -27.48080 153.0389  8.1 2020-01-07 00:00:00     2020-01-08      10:00       
  4:     3   IDQ11295   QLD     Brisbane QLD_PT001 -27.48080 153.0389  8.1 2020-01-08 00:00:00     2020-01-09      10:00 
...
adamhsparks commented 4 years ago

Thanks, I'd noted, but thought it was my local installation and didn't follow it much further.

This applies to get_ag_bulletin() and get_coastal_forecast() as well.