read_chla_daily: Read daily chlorphyll-a

read_chla_dailyR Documentation

Read daily chlorphyll-a

Description

Data is read as daily files in a way consistent with other read functions that can be used by extract(). (readchla for example cannot be used this way as it returns a mean value for the period asked for).

Usage

read_chla_daily(
  date,
  time.resolution = "daily",
  xylim = NULL,
  lon180 = TRUE,
  varname = c("chlor_a"),
  setNA = TRUE,
  latest = TRUE,
  returnfiles = FALSE,
  ...,
  inputfiles = NULL
)

read_chla_weekly(
  date,
  xylim = NULL,
  lon180 = TRUE,
  varname = c("chlor_a"),
  setNA = TRUE,
  latest = TRUE,
  returnfiles = FALSE,
  ...,
  inputfiles = NULL
)

read_chla_monthly(
  date,
  xylim = NULL,
  lon180 = TRUE,
  varname = c("chlor_a"),
  setNA = TRUE,
  latest = TRUE,
  returnfiles = FALSE,
  ...,
  inputfiles = NULL
)

Arguments

date

date or dates of data to read,

time.resolution

time resoution data to read, daily or monthly

xylim

spatial extents to crop from source data, can be anything accepted by extent, see Details

lon180

defaults to TRUE, to "rotate" Pacific view 0, 360 data to Atlantic view -180, 180

varname

variable to return from the data files, default is "sst" or "anom", "err", "ice"

setNA

mask out land values (only applies to monthly time.resolution)

latest

if TRUE (and date not supplied) return the latest time available

returnfiles

ignore options and just return the file names and dates

...

passed in to brick, primarily for filename

inputfiles

input the files data base to speed up initialization

Details

This function will read from the entire era available to SeaWiFS, MODISA, and VIIRS.

To read from particular eras use the output of ocfiles() for inputfiles argument.

Value

raster object

Examples

read_chla_daily(latest = FALSE) ## we should see SeaWiFS
read_chla_daily() ## we should see MODISA (or VIIRS)

AustralianAntarcticDivision/raadtools documentation built on Nov. 14, 2024, 4:27 p.m.