clim_locs_prep.Rd
Extract monthly climate values for point locations by RCP, climate model and climate variable.
clim_locs_prep(inputs, in_dir = snapdef()$ar5dir, out_dir = snapdef()$ar5dir_locs_prep, verbose = TRUE, overwrite = FALSE)
inputs | data frame of inputs (one row). See details. |
---|---|
in_dir | input directory, e.g., |
out_dir | output directory, e.g., |
verbose | logical, verbose progress. |
overwrite | logical, overwrite existing files. |
inputs
generally comes from clim_inputs_table. clim_locs_prep
processes data sets referred to by
one row of this data frame at a time. This function generates intermediary temp files used susbsequently by clim_locs
and can be deleted afterward if not needed for other uses where it is convenient to have extracted point location climate data
segmented into files by RCP, model and variable as opposed to by point location.
# NOT RUN { library(dplyr) library(parallel) inputs <- clim_inputs_table() %>% filter(!(model == "ts40" & var %in% c("tasmin", "tasmax"))) mclapply(split(inputs, 1:nrow(inputs)), clim_locs_prep, mc.cores = 32) # }