PairwiseMatrix-class: Pairwise Similarity/Distance Matrix

PairwiseMatrix-classR Documentation

Pairwise Similarity/Distance Matrix

Description

Represents a pairwise similarity or distance matrix.

Usage

as.PairwiseMatrix(x, ...)

## S4 method for signature 'matrix'
as.PairwiseMatrix(x, ...)

## S4 method for signature 'PairwiseMatrix'
as.matrix(x, ...)

Arguments

x

an R object.

...

additional arguments to be passed to methods.

Details

If the elements being compared are from the same set, the matrix may be symmetric if the comparator is symmetric. In this case, entries in the upper triangle and/or along the diagonal may not be stored in memory, since they are redundant.

Functions

  • as.PairwiseMatrix: Convert an R object x to a PairwiseMatrix.

  • as.PairwiseMatrix,matrix-method: Convert an ordinary matrix x to a PairwiseMatrix.

  • as.matrix,PairwiseMatrix-method: Convert a PairwiseMatrix x to an ordinary matrix.

Slots

.Data

entries of the matrix in column-major order. Entries in the upper triangle and/or on the diagonal may be omitted.

Dim

integer vector of length 2. The dimensions of the matrix.

Diag

logical indicating whether the diagonal entries are stored in .Data.


comparator documentation built on March 18, 2022, 6:15 p.m.