View source: R/heatmap_pattern_marker_regions.R
heatmapPatternMarkers | R Documentation |
Function to make a heatmap of the accessibility of the most differentially accessible regions as discovered by CoGAPS.
heatmapPatternMarkers(
cgaps_result,
atac_data,
celltypes,
numregions = 50,
colColors = NULL,
rowColors = NULL,
patterns = NULL,
order = TRUE,
...
)
cgaps_result |
CogapsResult object from CoGAPS run |
atac_data |
a numeric matrix of the ATAC data input to CoGAPS |
celltypes |
a list or factor of celltypes corresponding to the positions of those cells in the atac_data matrix |
numregions |
number of chromosomal regions/peaks to plot for each CoGAPS pattern. Default is 50. Plotting very large numbers of regions can cause significant slowdown in runtime |
colColors |
column-wise colors for distinguishing celltypes. If NULL, will be generated randomly |
rowColors |
row-wise colors for distinguishing patterns. If NULL will be generated randomly |
patterns |
which patterns should be plotted, if NULL all will be plotted |
order |
option whether to sort the data by celltype before plotting, TRUE by default |
... |
additional arguments to the heatmap.2 function |
heatmap of the accessibility for numregions for each pattern
If you get the error: "Error in plot.new() : figure margins too large" while using this function in RStudio just make the plotting pane in Rstudio larger and run the code again; this error only means the legend is being cut off in any case, the main plot will still appear correctly
data("schepCogapsResult")
data(schepCellTypes)
data("subsetSchepData")
heatmapPatternMarkers(schepCogapsResult, atac_data = subsetSchepData,
celltypes = schepCellTypes, numregions = 50)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.