Function for converting the information stored in the clusterLegend slot into other useful formats.
1 2 3 4
character value, indicating desired type of conversion.
convertClusterLegend pulls out information stored in the
clusterLegend slot of the object and returns it in useful format.
return a list that provides the necessary information to color samples
according to cluster and create a legend for it:
"colorVector" A vector the same length as the number of samples, assigning a color to each cluster of the primaryCluster of the object.
"legendNames" A vector the length of the number of clusters of primaryCluster of the object giving the name of the cluster.
"legendColors" A vector the length of the number of clusters of primaryCluster of the object giving the color of the cluster.
output="aheatmap" a conversion of the clusterLegend to be
in the format requested by
aheatmap. The column 'name'
is used for the names and the column 'color' for the color of the clusters.
"matrixColors" a matrix the
same dimension of
clusterMatrix(object), but with the cluster color
or cluster name instead of the clusterIds, respectively.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.