optCluster (version 1.2.0)

optCluster-class: Class "optCluster"

Description

The class "optCluster" contains the dataset, clustering results, validation measures, ranked lists of clustering algorithms, ordered lists of validation scores, and final rank aggregation results from the function optCluster.

Arguments

Objects from the Class

The function optCluster creates objects of the class "optCluster".

Slots

inputData:

Object of class "matrix" containing the original dataset.

clVal:

Object of class "'>clValid" containing the clustering results and validation measures from the internal clValid function.

ranksWeights:

Object of class "list" containing the ordered ranks of clustering algorithms and the ordered validation scores for each measure.

rankAgg:

Object of class "raggr" containing the rank aggregation results from the internal RankAggreg function.

Methods

optAssign

signature(object = "optCluster"): Returns the cluster assignment corresponding to the optimal clustering algorithm and number of clusters.

getDataset

signature(object = "optCluster"): Returns the original dataset as an object of class "matrix".

getClValid

signature(object = "optCluster"): Returns an object of class "'>clValid".

methodRanks

signature(object = "optCluster"): Returns the ranked lists of clustering algorithms for each validation measure.

scoreRanks

signature(object = "optCluster"): Returns the ordered lists of scores for each validation measure.

getRankAggreg

signature(object = "optCluster"): Returns an object of class "raggr".

topMethod

signature(object = "optCluster"): Returns the name of the optimal clustering algorithm and number of clusters.

measureNames

signature(object = "optCluster"): Returns the names of the validation measures used.

methodNames

signature(object = "optCluster"): Returns the names of the clustering algorithms used.

clusterResults

signature(object = "optCluster"): Returns an object of the class corresponding to the selected clustering method for each number of cluster in the analysis. If provided k, the object and clustering assignment for the corresponding method and number of clusters is returned.

Additional arguments:

method = methodNames(object)
The clustering algorithm to extract. The selection of only one algorithm is allowed.
k = NULL
The number of clusters to extract. The selection of only one number of clusters is allowed.

valScores

signature(object = "optCluster"): Returns the scores from the selected validation measure(s).

Additional arguments:

measures = measureNames(object)
The validation measure(s) to extract.

optimalScores

signature(object = "optCluster"): Returns the optimal score for each validation measure as well as the corresponding clustering algorithm and number of clusters.

print

signature(x = "optCluster"): Print method for class "optCluster".

show

signature(object = "optCluster"): Same as print.

summary

signature(object = "optCluster"): Summary method for class "optCluster".

References

Brock, G., Pihur, V., Datta, S. and Datta, S. (2008). clValid: An R Package for Cluster Validation. Journal of Statistical Software 25(4), http://www.jstatsoft.org/v25/i04.

Datta, S. and Datta, S. (2003). Comparisons and validation of statistical clustering techniques for microarray gene expression data. Bioinformatics 19(4): 459-466.

Pihur, V., Datta, S. and Datta, S. (2007). Weighted rank aggregation of cluster validation measures: A Mounte Carlo cross-entropy approach. Bioinformatics 23(13): 1607-1615.

Pihur, V., Datta, S. and Datta, S. (2009). RankAggreg, an R package for weighted rank aggregation. BMC Bioinformatics, 10:62, http://www.biomedcentral.com/1471-2105/10/62.

Sekula, M. (2015). optCluster : An R package for Determining the Optimal Clustering Algorithm and Optimal Number of Clusters. Electronic Theses and Dissertations. Paper 2147. http://ir.library.louisville.edu/etd/2147

See Also

For details on the function optCluster see optCluster.

For a description of the clValid function, including all available arguments that can be passed to it, see clValid in the clValid package. For a desciption of the class "clValid" including all available methods see clValid-class.

For a description of the RankAggreg function, including all available arguments that can be passed to it, see RankAggreg in the RankAggreg package.

Examples

Run this code
# NOT RUN {
	
	## This example may take a few minutes to compute
	
# }
# NOT RUN {
	## Obtain Dataset	
	data(arabid)	
	
	## Normalize Data with Respect to Library Size	
	obj <- t(t(arabid)/colSums(arabid))
	
	## Analysis of Normalized Data using Internal and Stability Measures
	norm1 <- optCluster(obj, 2:4, clMethods = "all")

	## View results
	norm1
	topMethod(norm1)
	summary(norm1)
	optimalScores(norm1)
	optAssign(norm1)
	
	## Extract cluster results for kmeans and all numbers of clusters
	clusterResults(norm1, method = "kmeans")
	## Extract cluster results for kmeans and 3 clusters only
	clusterResults(norm1, method = "kmeans", k = 3)
	
	## Extract all validation scores
	valScores(norm1)
	## Extract validations scores for APN and ADM only
	valScores(norm1, measures = c("APN", "ADM"))
	
	## Extract additional information from slots
	methodNames(norm1)
	measureNames(norm1)
	methodRanks(norm1)
	scoreRanks(norm1)
	
# }
# NOT RUN {
# }

Run the code above in your browser using DataCamp Workspace