- Notifications
You must be signed in to change notification settings - Fork11
R client for the National Phenology Network database API
License
Unknown, MIT licenses found
Licenses found
usa-npn/rnpn
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
rnpn is an R client for interacting with the USA National PhenologyNetwork data web services. These services include access to a rich setof observer-contributed, point-based phenology records as well asgeospatial data products including gridded phenological model andclimatological data.
Documentation is available for the National Phenology NetworkAPIdocumentation,which describes the full set of REST services this package wraps.
There is no need for an API key to grab data from the National PhenologyNetwork but users are required to self identify, on an honor system,against requests that may draw upon larger datasets. For functions thatrequire it, simply populate the request_source parameter with your nameor the name of your institution.
CRAN version
install.packages("rnpn")Development version:
install.packages("devtools")library('devtools')devtools::install_github("usa-npn/rnpn")
library('rnpn')This package has dependencies on both curl and gdal. Some Linux basedsystems may require additional system dependencies for those requiredpackages, and accordingly this package, to install correctly. Forexample, on Ubuntu:
sudoaptinstalllibcurl4-openssl-devsudoaptinstalllibproj-devlibgdal-dev
Many of the functions to search for data require knowing the internalunique identifiers of some of the database entities to filter the datadown efficiently. For example, if you want to search by species, thenyou must know the internal identifier of the species. To get a list ofall available species use the following:
species_list<- npn_species()
Similarly, for phenophases:
phenophases<- npn_phenophases()
There are four main functions for accessing observational data, atvarious levels of aggregation. At the most basic level you can downloadthe raw status and intensity data.
some_data<- npn_download_status_data(request_source='Your Name or Org Here',years= c(2015),species_id= c(35),states= c('AZ','IL'))
Note that through this API, data can only be filtered chronologically byfull calendar years. You can specify any number of years in each APIcall. Also note that request_source is a required parameter and shouldbe populated with your name or the name of the organization yourepresent. All other parameters are optional but it is highlyrecommended that you filter your data search further.
This package wraps around standard WCS endpoints to facilitate thetransfer of raster data. Generally, this package does not focus oninteracting with WMS services, although they are available. To get alist of all available data layers, use the following:
layers<- npn_get_layer_details()
You can then use the name of the layers to select and downloadgeospatial data as a raster.
npn_download_geospatial(coverage_id='si-x:lilac_leaf_ncep_historic',date='2016-12-31',format='geotiff',output_path='./six-test-raster.tiff')
For more details see Vignette VII
Please read and review the vignettes for this package to get furtherinformation about the full scope of functionality available.
This code was developed, in part, as part of the integratedPheno-Synthesis Software Suite(PS3).The authors acknowledge funding for this work through NASA’s AISTprogram (80NSSC17K0582, 80NSSC17K0435, 80NSSC17K0538, and80GSFC18T0003). The University of Arizona and the USA National PhenologyNetwork’s efforts with this package are supported in part by USGeological Survey (G14AC00405, G18AC00135) and the US Fish and WildlifeService (F16AC01075 and F19AC00168).
- Pleasereport any issues orbugs.
- License: MIT
- Get citation information for
rnpnin R doingcitation(package = 'rnpn') - Please note that this package is released with aContributor Code ofConduct. By contributing tothis project, you agree to abide by its terms.
About
R client for the National Phenology Network database API
Topics
Resources
License
Unknown, MIT licenses found
Licenses found
Contributing
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.
Contributors10
Uh oh!
There was an error while loading.Please reload this page.
