CFtime-package {CFtime} | R Documentation |
CFtime: working with CF Metadata Conventions "time" dimensions
Description
Support for all calendars as specified in the Climate and Forecast (CF) Metadata Conventions for climate and forecasting data. The CF Metadata Conventions is widely used for distributing files with climate observations or projections, including the Coupled Model Intercomparison Project (CMIP) data used by climate change scientists and the Intergovernmental Panel on Climate Change (IPCC). This package specifically allows the user to work with any of the CF-compliant calendars (many of which are not compliant with POSIXt). The CF time coordinate is formally defined in the CF Metadata Conventions document.
Details
This package also supports the creation of a "time" dimension, using class
CFClimatology
, for climatological statistics as defined here.
The package can create a CFTime or CFClimatology instance from scratch or, more commonly, it
can use the dimension attributes and dimension variable values from a netCDF
resource. The package does not actually do any of the reading and the user is
free to use their netCDF package of preference. The recommended package to
use (with any netCDF resources) is ncdfCF.
ncdfCF
will automatically use this package to manage the "time" dimension
of any netCDF resource. As with this package, it reads and interprets the
attributes of the resource to apply the CF Metadata Conventions, supporting
axes, auxiliary coordinate variables, coordinate reference systems, etc.
Alternatively, for more basic netCDF reading and writing, the two main options
are RNetCDF and
ncdf4).
Create, modify, inquire
-
Properties
of theCFTime
instance -
parse_timestamps()
: Parse a vector of character timestamps intoCFTime
elements -
Compare
twoCFTime
instances -
Merge
twoCFTime
instances or append additional time steps to aCFTime
instance -
as_timestamp()
andformat()
: Generate a vector of character orPOSIXct
timestamps from aCFTime
instance -
range()
: Timestamps of the two endpoints in the time series -
is_complete()
: Does theCFTime
instance have a complete time series between endpoints? -
month_days()
: How many days are there in a month using the calendar of theCFTime
instance?
Factors and coverage
-
CFfactor()
andcut()
: Create factors for different time periods -
CFfactor_units()
: How many units of time are there in each factor level? -
CFfactor_coverage()
: How much data is available for each level of the factor?
Filtering and selection
-
slice()
: Logical vector of time steps between two extreme points. -
indexOf()
: Index values in the time series of given timestamps, possibly with fractional part for interpolation.
Author(s)
Maintainer: Patrick Van Laake patrick@vanlaake.net [copyright holder]
See Also
Useful links: