ahmatrix: ahmatrix

Description Usage Arguments Value Author(s) Examples

View source: R/ahmatrix.R

Description

Converting a triangular matrix into a square pairwise comparison matrix (PCM) where the diagonal values are equal to 1 and a[i,j] = 1/a[j,i].

Usage

1

Arguments

x

a numeric triangular matrix, where empty elements are specified with NA.

Value

An S4 object including a PCM.

Author(s)

Daryanaz Dargahi

Examples

1
2
3
4
5
6
mat <- matrix(nrow = 3, ncol = 3, data = NA)
mat[1,2] <- 5
mat[1,3] <- 2
mat[2,3] <- 7

res <- ahmatrix(mat)

Prize documentation built on April 28, 2020, 7:48 p.m.