nmf.equal: Testing Equality of NMF Models The function 'nmf.equal' tests...

Description Usage Arguments Details Methods (by class) Methods (by generic)

Description

Testing Equality of NMF Models

The function nmf.equal tests if two NMF models are the same, i.e. they contain – almost – identical data: same basis and coefficient matrices, as well as same extra parameters.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
nmf.equal(x, y, ...)

## S4 method for signature 'NMF,NMF'
nmf.equal(x, y, identical = TRUE, ...)

## S4 method for signature 'list,list'
nmf.equal(x, y, ..., all = FALSE, vector = FALSE)

## S4 method for signature 'list,missing'
nmf.equal(x, y, ...)

Arguments

x

an NMF model or an object that is associated with an NMF model, e.g. the result from a fit with nmf.

y

an NMF model or an object that is associated with an NMF model, e.g. the result from a fit with nmf.

...

extra arguments to allow extension, and passed to subsequent calls

identical

a logical that indicates if the comparison should be made using the function identical (TRUE) or all.equal (FALSE). See description for method nmf.equal,NMF,NMF.

all

a logical that indicates if all fits should be compared separately or only the best fits

vector

a logical, only used when all=TRUE, that indicates if all fits must be equal for x and y to be declared equal, or if one wants to return the result of each comparison in a vector.

Details

nmf.equal compares two NMF models, and return TRUE iff they are identical acording to the function identical when identical=TRUE, or equal up to some tolerance acording to the function all.equal. This means that all data contained in the objects are compared, which includes at least the basis and coefficient matrices, as well as the extra parameters stored in slot ‘misc’.

If extra arguments are specified in ..., then the comparison is performed using all.equal, irrespective of the value of argument identical.

Methods (by class)

Methods (by generic)


renozao/NMF documentation built on June 14, 2020, 9:35 p.m.