reduc: Reduce a matrix or array

Description Usage Arguments Details Value Note Author(s) See Also Examples

View source: R/reduc.R

Description

Function to reduce a matrix or array with a given clustering vector

Usage

1
reduc(x, clu, lbs = NULL)

Arguments

x

a matrix or a three-dimensional array to be reduced

clu

a vector with the class membership

lbs

(optional) the labels to be used in the reduction

Details

Given a partition, this function serves to reduce either a matrix representing e.g. a partial order structure. However the reduction is also generalized a three-dimensional arrays representing multiple relations.

Value

The reduced matrix or a three-dimensional array.

Note

Use decomp for the reduction of a semigroup object.

Author(s)

Antonio Rivero Ostoic

See Also

cngr, rbox, decomp

Examples

1
2
3
4
5
## scan the multiplication table data
s <- matrix(data=c(1, 1, 1, 3, 3, 3, 3, 3, 3), nrow=3, ncol=3, byrow=TRUE)

## Reduce the multiplication table
reduc(s, clu=c(1,2,2))

multiplex documentation built on May 29, 2017, 8:40 p.m.

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