Time Parameters of a Time Series Object

DESCRIPTION:

Returns or sets the attribute describing the time domain of a time series.

USAGE:

tspar(x) 
tspar(x) <- value 

REQUIRED ARGUMENTS:

x
a univariate or multivariate time series that is of class "rts", "cts", or "its".

VALUE:

the tspar attribute of x. For regular time series, the tspar attribute is a vector of length three giving the starting time ( start), the time interval ( deltat) between observations, and the frequency of the observations ( frequency). For calendar time series, the tspar is a list of length four giving the starting time ( start), the units ( units) of the interval between observations, a multiplier ( k.units) for the case when there are more than one units of time between observations, and the number of observations in a sampling cycle ( frequency). For an irregular time series, the tspar attribute is a numeric vector or vector of dates giving the sampling times for all observations.

The tspar attribute of a regular ( rts) or irregular ( its) time series may itself have an attribute "units" giving the units in which the interval between observations is measured. The tspar function returns this attribute if it exists.

DETAILS:

To delete the tspar attribute of a time series object x, set its value explicitly to NULL : tspar(x) <- NULL.

The tspar function is generic, although it currently has no methods defined for it. The tspar<- function is generic, and will check correctness if x belongs to one of the time series classes.

SEE ALSO:

, , , , , , , , .

EXAMPLES:

x <- rts( as.factor(letters), start = c(0,5), freq = 7, units = "weeks") 
tspar(x) 
tspar(x) <- c( start = 1, deltat = 1/7, frequency = 7)