View source: R/makeRiverPlots.R
makepHeatmap | R Documentation |
plots a heatmap
makepHeatmap(
mx,
nCol = 200,
col = "default",
maxVal = "default",
minVal = "default",
label = "",
DEsaturation = log2(10),
reverseGradient = F,
border_color = NA,
cluster_rows = F,
cluster_cols = F,
...
)
mx |
numeric. The matrix to be plotted. |
nCol |
numeric. The number of colours in the gradient. Default 200. |
col |
character. The colour scheme to be used. The default 'default' gives a scale adapted for freqwuencies between 0 and 1, with extra attention to values close to 0. 'sunset' is a easier on the eye, but has less ability to resolve values close to the lowest value. 'DE' is meant for differential expression, and sets 0 to black, with red and blue gradient towards positive and negative values, saturating at the DEsaturation parameter. |
maxVal |
numeric. Only for internal use. Default 'default'. |
minVal |
numeric. Only for internal use. Default 'default'. |
label |
character. The label for the colour scale on the side. Default ”. |
DEsaturation |
numeric. The value where the colour saturates when col='DE'. Default log2(10). |
... |
remaining arguments are passed to base heatmap(...) |
This function is a wrapped pheatmap() function with some changed colours and defaults. Depends on pheatmap package, which is not a superFreq dependency, so need to load that library before using this.
#random matrix to plot, centered around 0. Plot in 'DE' colours.
mx = matrix(rt(400, df=10), nrow=100)
makeHeatmap(mx, col='DE')
#random matrix to plot, between 0 and 1. Plot in default and sunset colours.
mx = matrix(runif(400), nrow=100)
makeHeatmap(mx)
makeHeatmap(mx, col='sunset')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.