ply2erddap: Extract ERDDAP statistics from polygon by year-month

View source: R/calculate_data.R

ply2erddapR Documentation

Extract ERDDAP statistics from polygon by year-month

Description

Extract satellite data in an ERDDAP dataset from national marine sanctuary polygon for a given year and month.

Usage

ply2erddap(sanctuary_code, erddap_id, erddap_fld, year, month, stats)

Arguments

sanctuary_code

The sanctuary code based on prefix to Sanctuary GIS files, e.g. "cinms" for Channel Islands Marine Sanctuary

erddap_id

The dataset ID of ERDDAP dataset (see coastwatch.pfeg.noaa.gov/erddap), e.g. "jplMURSST41mday" for Multi-scale Ultra-high Resolution SST Analysis

erddap_fld

The variable of ERDDAP dataset to extract, e.g. "sst"

year

4-digit year.

month

integer month (1-12).

stats

The statistics to be calculated.

Value

A list of values by statistic.

Examples

## Not run: 
ply2erddap("cinms", "jplMURSST41mday", "sst", year = 2010, month = 6, c("mean", "sd"))

## End(Not run)

marinebon/nms4r documentation built on April 23, 2023, 6:09 p.m.