get.split.filename.cmip5: Splits up a CMIP5 filename

Description Usage Arguments Details Value References Examples

View source: R/helpers.r

Description

Splits up a CMIP5 filename into its component parts.

Usage

1

Arguments

cmip5.file

The filename to be split.

Details

As the CMIP5 conventions define the format of filenames, quite a bit of data can be extracted from the filename alone. This function makes that process easier by splitting up the given CMIP5 filename, returning a named vector consisting of the variable, time resolution, model, emissions scenario, run, time range, and time start and end.

Value

A vector containing the variable (var), time resolution (tres), model (model), emissions scenario (emissions), run (run), time range (trange), time start (tstart) and time end (tend) for the file.

References

https://pcmdi.llnl.gov/mips/cmip5/docs/CMIP5_output_metadata_requirements.pdf?id=28

Examples

1
2
3
## Split up filename into component bits
split.bits <- get.split.filename.cmip5(
                "pr/pr_day_MRI-CGCM3_historical_r1i1p1_18500101-20051231.nc")

ncdf4.helpers documentation built on Oct. 15, 2021, 5:19 p.m.