Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
R
 
 
man
 
 
 
 
 
 
 
 
 
 

README.md

NERACOOS Crawler

NERACOOS provides OpeNDAP access to data from within R. neracooscrawler package provides basic THREDDS crawling facilties. The idea is to programmatically search the OpeNDAP offerings at NERACOOS.

This package is nearly identical to obpgcrawler but is configured specifically for the NERACOOS offerings. Windows users are able to use the crawler to identify resources, but are unable to use the OpeNDAP services. To circumvent that issue, this package provides utlitiy functions for downloading files to a local drive.

Requirements

R >= 3.0

threddscrawler

Installation

It is easy to install with devtools

library(devtools)
install_github("btupper/neracooscrawler")

Useage

Most users will only use the MODISA_query(). An equivalent MURSST_query() is under development.

# get all of the monthly CHL in a 2 year period
x <- MODISA_query(what = 'within', date_filter = as.POSIXct(c("2008-01-01", "2011-12-31")),
    greplargs = list(pattern="MO_CHL_chlor_a_4km", fixed = TRUE))

head(x, n = 2) ; cat("..............\n\n"); tail(x, n = 2)
# $A20080012008031.L3m_MO_CHL_chlor_a_4km.nc
# Reference Class: "DatasetsRefClass"
#   verbose_mode: FALSE
#   url: http://www.neracoos.org/thredds/catalog/GMRI/SATELLITE/NASA/MODISA_NESHELF/MODISA/L3SMI/2008/001/A20080012008031.L3m_MO_CHL_chlor_a_4km.nc
#   children: dataSize date
#   datasets: NA
# 
# $A20080322008060.L3m_MO_CHL_chlor_a_4km.nc
# Reference Class: "DatasetsRefClass"
#   verbose_mode: FALSE
#   url: http://www.neracoos.org/thredds/catalog/GMRI/SATELLITE/NASA/MODISA_NESHELF/MODISA/L3SMI/2008/032/A20080322008060.L3m_MO_CHL_chlor_a_4km.nc
#   children: dataSize date
#   datasets: NA
# 
# ..............
# 
# $A20113052011334.L3m_MO_CHL_chlor_a_4km.nc
# Reference Class: "DatasetsRefClass"
#   verbose_mode: FALSE
#   url: http://www.neracoos.org/thredds/catalog/GMRI/SATELLITE/NASA/MODISA_NESHELF/MODISA/L3SMI/2011/305/A20113052011334.L3m_MO_CHL_chlor_a_4km.nc
#   children: dataSize date
#   datasets: NA
# 
# $A20113352011365.L3m_MO_CHL_chlor_a_4km.nc
# Reference Class: "DatasetsRefClass"
#   verbose_mode: FALSE
#   url: http://www.neracoos.org/thredds/catalog/GMRI/SATELLITE/NASA/MODISA_NESHELF/MODISA/L3SMI/2011/335/A20113352011365.L3m_MO_CHL_chlor_a_4km.nc
#   children: dataSize date
#   datasets: NA

For Windows users who cannot access OpeNDAP resources, we provide a download function. Taking the example above we can download on or more of these datasets.

ok <- MODISA_download(x[1:3], dest = "/Users/ben/Downloads")
ok
# /Users/ben/Downloads/A20080012008031.L3m_MO_CHL_chlor_a_4km.nc 
#                                                           TRUE 
# /Users/ben/Downloads/A20080322008060.L3m_MO_CHL_chlor_a_4km.nc 
#                                                           TRUE 
# /Users/ben/Downloads/A20080612008091.L3m_MO_CHL_chlor_a_4km.nc 
#                                                           TRUE 

About

A limited THREDDS crawler for programmatically working with NERACOOS thredds server

Resources

License

Releases

No releases published

Packages

No packages published

Languages

You can’t perform that action at this time.