plotCellSimilarity,scRNAseq-method | R Documentation |
This function plots the similarity matrix as a heatmap.
plotCellSimilarity(theObject, colorPalette="default", statePalette="default", clusteringMethod="ward.D2", orderClusters=FALSE, savePlot=FALSE, plotPDF=TRUE, returnPlot=FALSE, width=7, height=6, onefile=FALSE, showRowNames=FALSE, showColnames=FALSE, fontsize=7.5, fontsizeRow=0.03, widthPNG=800, heightPNG=750, silentPlot=FALSE)
theObject |
An Object of class scRNASeq for which the count matrix was normalized (see ?normaliseCountMatrix), tSNE were calculated (see ?generateTSNECoordinates), dbScan was run (see ?runDBSCAN), cells were clustered (see ?clusterCellsInternal), as clusters themselves (see ?calculateClustersSimilarity). |
colorPalette |
A vector of colors for clusters. Default = "default", see details. |
statePalette |
A vector of colors for states or conditions. See details. |
clusteringMethod |
Clustering method passed to hclust() function. See ?hclust for a list of method. Default = "ward.D2" |
orderClusters |
If TRUE, clusters in the similarity matrix of cells will be ordered by name. Default = FALSE. |
savePlot |
If TRUE, the heatmap is saved in the directory defined in theObject (?getOutputDirectory) and in the sub-directory "pictures". |
plotPDF |
If TRUE export heatmap in pdf format, if FALSE export it in png format. Default=TRUE. |
returnPlot |
Boolean indicating if the pHeatmap object should be returned by the function. Default = TRUE. |
width |
Width of the plot in the pdf file. See ?pdf for more details. Default = 7. |
height |
Height of the plot in the pdf file. See ?pdf for more details. Default = 6. |
onefile |
Logical: if TRUE allow multiple figures in one file. If FALSE, generate a file with name containing the page number for each page. Defaults to FALSE. |
showRowNames |
pheatmap parameter. Boolean specifying if row names are displayed. Default=FALSE. |
showColnames |
pheatmap parameter. Boolean specifying if column names are displayed. Default=FALSE. |
fontsize |
pheatmap parameter. Base fontsize for the plot. Default=7.5. |
fontsizeRow |
pheatmap parameter. Fontsize for rownames. Default=0.03. |
widthPNG |
Width of the png. See ?png for details. Default=800. |
heightPNG |
Height of the png. See ?png for details. Default=750. |
silentPlot |
If TRUE, does not plot the heatmap. Default=FALSE. |
colorPalette/statePalette – A vector of colors for clusters/states or 'default' value. If 'default' is selected, the number of clusters is limited to 16. If an error message is thrown, re-run the function with your own color vector.
A pheatmap object of the similarity heatmap if returnPlot is TRUE.
Ilyess RACHEDI, based on code by Polina PAVLOVICH and Nicolas DESCOSTES.
calculateClustersSimilarity plotClusteredTSNE plotCellHeatmap plotGeneExpression plotClustersSimilarity
## Object scr containing the results of previous steps load(system.file("extdata/scrFull.Rdat", package="conclus")) ## Plot the heatmap of the similarity matrix plotCellSimilarity(scr)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.