Enforces API limits client-side where the API limits unique queries to 30 per 60 seconds as found and reported by @camwur in Issue 57. This can be adjusted in future releases of nasapower if the POWER API changes as has been indicated is possible.
(Re)enables vcr for better unit testing.
More comprehensive unit tests.
Adds support for new NASA POWER API v2.0, which includes new hourly data and other major changes to the API and available data. See https://power.larc.nasa.gov/ for fully detailed changes to the data.
Drops support for the deprecated NASA POWER API V1.0. Previous versions of nasapower are no longer functional.
Adds new function,
query_parameters() to fetch information from the API on individual and all available community/temporal API combination parameters.
SSE community, replaced with
global option for geographic coverage as passed along through the
latlon argument of
Directly parse data from API response rather than downloading data to disk and importing.
get_power()arguments are changed:
temporal_averageargument has been superseded by
temporal_apito align with the terminology used in the POWER API. The
temporal_averageargument will still work, however, a message will be given if a user still uses
temporal_averageto alert the user of the change and ask them to update their scripts.
-99.00value rather than the proper
NAfor missing data. Thanks to Fernando Miguez, https://github.com/femiguez, for the assistance in isolating the issue.
Due to the removal of the CRAN package APSIM from CRAN, the removal of the
create_met() function has been implemented sooner than expected to keep nasapower on CRAN.
Correct any missing or redirecting URLs
Following a UNIX-like philosophy, this release removes functionality to write APSIM .met and DSSAT ICASA files to disk. nasapower now will only fetch the appropriate data and return a
tibble() object in-session, please use apsimx or the POWER web API data access viewer, https://power.larc.nasa.gov/data-access-viewer/, for fetching and/or writing .met or .icasa files, respectively. Note that
create_icasa() ideally should have been deprecated, but the server was not responding properly when queried for some time before the current release of nasapower so the function has been removed.
Add ability to
get_power() to accept a user-provided
site_elevation parameter that is passed to the API. When this is used it will return a corrected atmospheric pressure value adjusted to the elevation provided.
Use newest values from POWER team to validate user inputs for API requests, see https://github.com/ropensci/nasapower/issues/48 for more.
Replace raster with terra for examples of converting to spatial data in vignettes
Use vcr for enhanced testing
Refactor the internal handling of temporary files to allow for more efficient use of the future package
Corrects bug when querying the SB or SSE communities resulting in an error
Corrects example in vignette when creating a .met file
Fix issues reported at https://cloud.r-project.org//web/checks/check_results_nasapower.html with failing tests. These tests should be skipped on CRAN but were not.
Fixes bug where missing values in POWER data were not properly replaced with
tibble and metFile outputs
Fixes bug in documentation for
create_icasa() where the parameter for
file_out was misidentified as just
Fixes bug where .met files were not created properly including where “radn” and “rain” col headers were reversed
Warning: Must pass a scalar integer as 'nrow' argument to 'new_tibble()'.
Fixes bug where “CLIMATE” could not be requested for a single point
GLOBALvalues are requested. This is now specified in
lonlatin conjunction with
temporal_average = CLIMATOLOGY.
nasapoweruntil the POWER team can properly address how pre-query validation should be performed
Flesh out examples using
naspower data with
raster to create spatial objects for systems with low-RAM where the functionality may not work as expected
Standardise formatting of vignette subheadings
Spell check vignette
Updates documentation examples
Provides nicer method of printing data in R console
Updates tests for better coverage and removes non-functional tests
dplyr as an Import
Provides access to all three communities, AG, SSE and and SB, not just AG
Uses new ‘POWER’ ‘API’ to download new 1/2 x 1/2 degree data
get_power() to get weather data and optionally metadata as well
create_met() to create ‘APSIM’ met objects from ‘POWER’ data
create_icasa() to create a text file of weather data for use in ‘DSSAT’ crop modelling
Internally, replaces httr package with crul
get_regionfunctions are deprecated in favour of
get_power(). The new POWER interface allows for the specification of single points or regional areas. Global coverage may be queried for Climatology. See the help for
?get_power()for more details.
Fix bug where lon/lat values were improperly assigned internally due to row names not being ordered correctly in
Fix bug reports link in DESCRIPTION file
Correct vignette where it had said, “both of which will which will download”
Correct documentation for
get_region(), which incorrectly stated that it downloaded data for a 1 x 1 degree cell
Optimise arguments used in
utils::read.table() to ingest weather data in the
get_region() functions more quickly
NEWS now formatted more nicely for easier reading
Add statement about possible performance and memory usage when using
get_region() in the vignette
Add an example of converting the data frame to a spatial object using raster to create a
Specify in documentation that a range of days to years can be specified for download
get_region()with multiple dates. https://github.com/ropensci/nasapower/issues/1
.onLoad(), removed from zzz.R
Tidied up startup message
Clean up vignette
Build vignette faster
Remove DATE from DESCRIPTION
Add new functionality to download regions in addition to single cells
Add static documentation website, https://docs.ropensci.org/nasapower/
Add startup message