Learn R Programming

fChange (version 2.1.0)

center: Generic Centering of Data

Description

Center data by removing the mean or median. Defining changes allow for regional centering.

Usage

center(object, changes = NULL, type = "mean", ...)

# S3 method for default center(object, changes = NULL, type = "mean", ...)

# S3 method for data.frame center(object, changes = NULL, type = "mean", ...)

# S3 method for matrix center(object, changes = NULL, type = "mean", ...)

# S3 method for dfts center(object, changes = NULL, type = "mean", ...)

Value

Centered data of the same format as the given data.

Arguments

object

Object for computation of centering.

changes

Change points for centering individual sections.

type

String of mean or median for method of centering.

...

Parameters that may be fed into other versions of centering.

See Also

center.default(), center.data.frame(), center.matrix(), center.dfts()

Examples

Run this code
center(1:10)

Run the code above in your browser using DataLab