Description Usage Arguments Details Value Author(s) Examples
View source: R/SimilarityHeatmap.R
The function SimilarityHeatmap
plots the similarity values
between compounds. The darker the shade, the more similar compounds
are. The option is available to set a cutoff value to highlight the most
similar compounds.
1 2 3 |
Data |
The data of which a heatmap should be drawn. |
type |
The type of data. Data can either be the data itself ("data"), the outcome of a clustering method ("clust'), a distance matrix ("dist") or a similarity matrix ("sim"). |
distmeasure |
If type is "data", a distance measure for the clustering should be specified. |
normalize |
Logical. If type is "data", it can be specified whether the data should be normalized. |
method |
If type is "data" and normalize is TRUE, a method for normalization should be specified.
See |
cutoff |
Optional. If a cutoff value is specified, all values lower are put to zero while all other values are kept. This helps to highlight the most similar compounds. |
percentile |
Logical. The cutoff value can be a percentile. If one want the cutoff value to be the 90th percentile of the data, one should specify cutoff = 0.90 and percentile = TRUE. |
plottype |
Should be one of "pdf","new" or "sweave". If "pdf", a location should be provided in "location" and the figure is saved there. If "new" a new graphic device is opened and if "sweave", the figure is made compatible to appear in a sweave or knitr document, i.e. no new device is opened and the plot appears in the current device or document. |
location |
If plottype is "pdf", a location should be provided in "location" and the figure is saved there. |
If data is of type "clust", the distance matrix is extracted from the result and transformed to a similarity matrix. Possibly a range normalization is performed. If data is of type "dist", it is also transformed to a similarity matrix and cluster is performed on the distances. If data is of type "sim", the data is tranformed to a distance matrix on which clustering is performed. Once the similarity mattrix is obtained, the cutoff value is applied and a heatmap is drawn. If no cutoff value is desired, one can leave the default NULL specification.
A heatmap with the names of the compounds on the right and bottom and a dendrogram of the clustering at the left and top.
Marijke Van Moerbeke
1 2 3 4 5 6 7 8 9 10 11 12 | ## Not run:
data(fingerprintMat)
MCF7_F = Cluster(fingerprintMat,type="data",distmeasure="tanimoto",normalize=FALSE,
method=NULL,clust="agnes",linkage="ward",gap=FALSE,maxK=55)
SimilarityHeatmap(Data=MCF7_F,type="clust",cutoff=0.90,percentile=TRUE)
SimilarityHeatmap(Data=MCF7_F,type="clust",cutoff=0.75,percentile=FALSE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.