plot.yaConsensus {yaConsensus}R Documentation

Plot the consensus dissimilarity matrix and provide the consensus clustering.

Description

This function processes the ouput of yaConsensus and acts as a wrapper to the pheatmap function.

Usage

## S3 method for class 'yaConsensus'
plot(x, G = 2, annotation = NULL, annotation.colorCode = NULL, 
     matching_clustering = NULL, consensus_colors = NULL,...)

Arguments

x

an object coming from yaConsensus().

G

an integer value indicating the number of clusters required for the consensus clustering. Default is 2.

annotation

a data frame where the variables are annotations (as labels) of samples. The row-names have to match the names of the samples.

annotation.colorCode

a string named list of color names. The names have to be values stored in the annotation data-frame.

matching_clustering

a string value matching one of the annotation valiables in the annotation data-frame. The function tries to match at best the color coding of the selected variable in the data-frame.

consensus_colors

a list of color provided to annotate the consensus clustering. If provided, the matching_clustering is overrided.

...

parameters compatible with pheatmap function.

Details

In the slot 'statistics', the function returns the same statistics of yaConsensus().

Value

A named list with the following slots:

annotation

a data frame. It is the same given in input, with 'consensus' and 'consensus.col' more variables.

ann_colors

a named list of colors associated with each variable in the annotation data-frame.

hclust

an object of hclust clust. It's the result of the hclust() applied to the consensus dissimilarity with the complete linkage.

statistics

see Note

Note

In case an 'annotation' is provided, with summary(), additional statistics are provided.

The variable specified as given in summary(..., given = "some clustering") is assumed as a theoretical clustering, while the consensus clustering is the empirical one. The entropy accuracy, precision, and average (Risso and Pagnotta, 2021) are computed with the former assumptions. summary() itself returns all the statistics. "some clustering" has to be one of the column of the annotation data.frame.

Author(s)

Stefano M. Pagnotta

References

Risso and Pagnotta (2021) - Per-sample standardization and asymmetric winsorization lead to accurate clustering of RNA-seq expression profiles - Bioinformatics, btab091, <DOI: 10.1093/bioinformatics/btab091>

See Also

pheatmap, yaConsensus

Examples

# see the examples in yaConsensus help.

[Package yaConsensus version 1.0 Index]