getRandom: Generate initial random start

Description Usage Arguments Details Value References See Also Examples

View source: R/main.R

Description

Generate an initial random start for the Additive Profile Clustering algorithm (see adproclus).

Usage

1
getRandom(data, centers)

Arguments

data

Object-by-variable data matrix of class matrix or data.frame.

centers

either the number of clusters k, or a matrix of initial (distinct) cluster centres.

Details

getRandom generates an random initial binary membership matrix A by drawing entries from a Bernoulli Distribution with π = 0.5. A corresponding initial profile matrix P is subsequently estimated conditionally upon A (for details, see Depril et al., 2008, and Wilderjans et al., 2010).

For programming simplicity, this function provides the option to pass a matrix of initial cluster centers to the centers argument. In this case, the matrix is dismissed, the number of clusters k is set to nrow(centers) and a new profile matrix is returned, based on a randomly generated membership matrix. For generating an initial start based on a specific set of initial cluster centers, see getRational.

Warning: This function does not obtain an ADPRCOLUS model. To perform aditive profile clustering, see adproclus.

Value

getRandom returns a list with the following components:

type

A character string denoting the type of start ('Random Start')

A

A randomly generated initial Membership matrix

P

The corresponding initial Profile matrix

References

Wilderjans, T. F., Ceulemans, E., Van Mechelen, I., & Depril, D. (2010). ADPROCLUS: a graphical user interface for fitting additive profile clustering models to object by variable data matrices. Behavior Research Methods, 43(1), 56-65.

Depril, D., Van Mechelen, I., & Mirkin, B. (2008). Algorithms for additive clustering of rectangular data tables. Computational Statistics and Data Analysis, 52, 4923-4938.

See Also

getRational for generating rational starts and adproclus for details about membership and profile matrices.

Examples

1
getRandom(ADPROCLUS::CGdata, 3)

JRBCH/ADPROCLUS documentation built on Oct. 30, 2019, 7:33 p.m.