NMFSeed is a constructor method that instantiate NMFSeed-class objects.

Description

NMFSeed is a constructor method that instantiate NMFSeed-class objects.

NMF seeding methods are registered via the function setNMFSeed, which stores them as NMFSeed-class objects in a dedicated registry.

removeNMFSeed removes an NMF seeding method from the registry.

Usage

NMFSeed(key, method, ...)

setNMFSeed(..., overwrite = isLoadingNamespace(), verbose = TRUE)

removeNMFSeed(name, ...)

Arguments

key
access key as a single character string
method
specification of the seeding method, as a function that takes at least the following arguments:
  1. objectuninitialised/empty NMF model, i.e. that it has 0 rows and columns, but has already the rank requested in the call to nmf or seed.
  2. xtarget matrix
  3. ...extra arguments
...
arguments passed to NMFSeed and used to initialise slots in the NMFSeed-class object, or to pkgreg_remove.
name
name of the seeding method.
overwrite
logical that indicates if any existing NMF method with the same name should be overwritten (TRUE) or not (FALSE), in which case an error is thrown.
verbose
a logical that indicates if information about the registration should be printed (TRUE) or not (FALSE).

Methods

  1. NMFSeedsignature(key = "character"): Default method simply calls new with the same arguments.

  2. NMFSeedsignature(key = "NMFSeed"): Creates an NMFSeed based on a template object (Constructor-Copy), in particular it uses the same name.