tail_t: Terminal Subperiod

Description Usage Arguments Methods (by class) Note See Also Examples

View source: R/head_t_tail_t.R

Description

Return a subperiod time series with the terminal part, where the length is specified in terms of the temporal length.

Usage

1
2
3
4
tail_t(x, ...)

## S3 method for class 'uts'
tail_t(x, width, ...)

Arguments

x

a time series object.

...

further arguments passed to or from methods.

width

a duration object, specifying the temporal width of the terminal subperiod time series.

Methods (by class)

Note

For an evenly spaced time series, the methods tail() and tail_t() essentially work the same. For unevenly spaced time series, however, they are quite different. The subperiod window of the former is determined by the observation values, while for the latter it is determined by the observation times.

See Also

head, head_t, tail, window for other methods that extract a subperiod time series.

Examples

1
2
tail_t(ex_uts(), ddays(1))
tail_t(ex_uts(), ddays(0))  # leaves only the last observation

andreas50/uts documentation built on April 8, 2021, 10:03 a.m.