Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

apply

Apply Function


Description

Apply a function to the rows or columns of an fts object

Usage

column.apply(x, FUN, ...)
row.apply(x, FUN, ...)

Arguments

x

An Fts object

FUN

function to be applied

...

further arguments to function

Value

an Fts object or vector depending on the fuction type

Author(s)

Whit Armstrong

Examples

x <- fts(index=seq(from=Sys.Date(),by="months",length.out=24),data=1:24)
y <- fts(index=seq(from=Sys.Date(),by="months",length.out=24),data=1:24)

z <- cbind(x,y)

## returns vector
z.col.sum <- column.apply(z,sum)

## returns fts
z.row.sum <- row.apply(z,sum)

fts

R Interface to 'tslib' (a Time Series Library in C++)

v0.9.9.2
GPL-3
Authors
Whit Armstrong <armstrong.whit@gmail.com>
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.