Extract monthly weather from CF file for input to RothC
Source:R/met2model.RothC.R
met2model.RothC.RdInput files need to be named `<in.path>/<in.prefix>.YYYY.nc`
Arguments
- in.path
path on disk where CF files live
- in.prefix
prefix for each file
- outfolder
location where model specific output is written.
- start_date, end_date
When to start and end output. Specify as exact dates, but output will be padded to whole months.
- overwrite
logical: replace output files if they already exist?
Details
Output files are named `<outfolder>/<in.prefix>.YY-mm.YY-mm.dat` with one line per month and columns for temperature, rainfall, and evaporation.
Note that the created file contains only weather data and not any of the soil or management data needed for RothC's single combined input file. See `write.config.RothC()` for assembly into a model-ready RothC_input.dat`.