blockMeans: Calculate Means in Groups Over a Vector

Description Usage Arguments Value Examples

Description

Caculates the mean every n points in a given vector. If time is used, returns the midpoint of the time vector associated with the mean.

Usage

1
blockMeans <- function(X, time, n = 600)

Arguments

X

A data frame or matrix with columns over which to compute the mean.

time

A vector of the class POSIXct containing the time points for each row in X.

n

The number of rows to compute the mean over.

Value

The data frame of the means of every n points.

Examples

1
blockMeans(y[, 28:32], y$Time, n = 1200)

alphonse/aeRo documentation built on May 11, 2019, 11:21 p.m.