This function extracts CMIP5 data from grids that have been downloaded and stored locally. Files are saved as a netCDF file in CF conventions at *DAILY* resolution. Note: At this point in time, variables that are only available at a native monthly resolution will be repeated to give a pseudo-daily record (and can get dealt with in the downscaling workflow). These files are ready to be used in the general PEcAn workflow or fed into the downscaling workflow.

extract.local.CMIP5(outfolder, in.path, start_date, end_date, site_id,
  lat.in, lon.in, model, scenario, ensemble_member = "r1i1p1",
  date.origin = NULL, no.leap = NULL, overwrite = FALSE,
  verbose = FALSE, ...)

Arguments

outfolder

- directory where output files will be stored

in.path

- path to the raw full grids

start_date

- first day for which you want to extract met (yyyy-mm-dd)

end_date

- last day for which you want to extract met (yyyy-mm-dd)

site_id

name to associate with extracted files

lat.in

site latitude in decimal degrees

lon.in

site longitude in decimal degrees

model

which GCM to extract data from

scenario

which experiment to pull (p1000, historical, ...)

ensemble_member

which CMIP5 experiment ensemble member

date.origin

(optional) specify the date of origin for timestamps in the files being read. If NULL defaults to 1850 for historical simulations (except MPI-ESM-P) and 850 for p1000 simulations (plus MPI-ESM-P historical). Format: YYYY-MM-DD

no.leap

(optional, logical) if you know your GCM of interest is missing leap year, you can specify it here. otherwise the code will automatically determine if leap year is missing and if it should be added in.

overwrite

logical. Download a fresh version even if a local file with the same name already exists?

verbose

logical. to control printing of debug info

...

Other arguments, currently ignored

Details

Extract NLDAS from local download Extract NLDAS meteorology for a poimt from a local download of the full grid