bicenter.wt: Double Weighted Centring

Description Usage Arguments Value Author(s) Examples

Description

This function creates a doubly centred matrix.

Usage

1
bicenter.wt(X, row.wt = rep(1, nrow(X)), col.wt = rep(1, ncol(X)))

Arguments

X

a matrix with n rows and p columns

row.wt

a vector of positive or null weights of length n

col.wt

a vector of positive or null weights of length p

Value

returns a doubly centred matrix

Author(s)

Daniel Chessel

Examples

1
2
3
4
5
w <- matrix(1:6, 3, 2)
bicenter.wt(w, c(0.2,0.6,0.2), c(0.3,0.7))

w <- matrix(1:20, 5, 4)
sum(bicenter.wt(w, runif(5), runif(4))^2)

ade4 documentation built on May 29, 2017, 2:05 p.m.

Search within the ade4 package
Search all R packages, documentation and source code