Waterfall-class {GenVisR} | R Documentation |
An S4 class for the waterfall plot object, under development!!!
Waterfall(input, labelColumn = NULL, samples = NULL, coverage = NULL, mutation = NULL, genes = NULL, mutationHierarchy = NULL, recurrence = NULL, geneOrder = NULL, geneMax = NULL, sampleOrder = NULL, plotA = c("frequency", "burden", NULL), plotATally = c("simple", "complex"), plotALayers = NULL, plotB = c("proportion", "frequency", NULL), plotBTally = c("simple", "complex"), plotBLayers = NULL, gridOverlay = FALSE, drop = TRUE, labelSize = 5, labelAngle = 0, sampleNames = TRUE, clinical = NULL, sectionHeights = NULL, sectionWidths = NULL, verbose = FALSE, plotCLayers = NULL)
input |
Object of class MutationAnnotationFormat, or GMS. |
labelColumn |
Character vector specifying a column name from which to extract labels for cells. |
samples |
Character vector specifying samples to plot. If not NULL all samples in "input" not specified with this parameter are removed. |
coverage |
Integer specifying the size in base pairs of the genome covered by sequence data from which mutations could be called. Required for the mutation burden sub-plot (see details and vignette). Optionally a named vector of integers corresponding to each sample can be supplied for more accurate calculations. |
mutation |
Character vector specifying mutations to keep, if defined mutations not supplied are removed from the main plot. |
genes |
Character vector of genes to keep |
mutationHierarchy |
Data.table object with rows specifying the order of mutations from most to least deleterious and column names "mutation" and "color". Used to change the default colors and/or to give priority to a mutation for the same gene/sample (see details and vignette). |
recurrence |
Numeric value between 0 and 1 specifying a mutation recurrence cutoff. Genes which do not have mutations in the proportion of samples defined are removed. |
geneOrder |
Character vector specifying the order in which to plot genes. |
geneMax |
Integer specifying the maximum number of genes to be plotted. Genes kept will be choosen based on the reccurence of mutations in samples. Unless geneOrder is specified. |
sampleOrder |
Character vector specifying the order in which to plot samples. |
plotA |
String specifying the type of plot for the top sub-plot, one of "burden", "frequency", or NULL for a mutation burden (requires coverage to be specified), frequency of mutations, or no plot respectively. |
plotATally |
String specifying one of "simple" or "complex" for a simplified or complex tally of mutations respectively. |
plotALayers |
list of ggplot2 layers to be passed to the plot. |
plotB |
String specifying the type of plot for the left sub-plot, one of "proportion", "frequency", or NULL for a plot of gene proportions frequencies , or no plot respectively. |
plotBTally |
String specifying one of "simple" or "complex" for a simplified or complex tally of genes respectively. |
plotBLayers |
list of ggplot2 layers to be passed to the plot. |
gridOverlay |
Boolean specifying if a grid should be overlayed on the waterfall plot. |
drop |
Boolean specifying if mutations not in the main plot should be dropped from the legend. If FALSE the legend will be based on mutations in the data before any subsets occur. |
labelSize |
Integer specifying the size of label text |
labelAngle |
Numeric value specifying the angle of label text |
sampleNames |
Boolean specifying if samples should be labeled on the plot. |
clinical |
Object of class Clinical, used for adding a clinical data subplot. |
sectionHeights |
Numeric vector specifying relative heights of each plot section, should sum to one. Expects a value for each section. |
sectionWidths |
Numeric vector specifying relative heights of each plot section, should sum to one. Expects a value for each section. |
verbose |
Boolean specifying if status messages should be reported |
plotCLayers |
list of ggplot2 layers to be passed to the plot. |
PlotA
gtable object for the top sub-plot.
PlotB
gtable object for the left sub-plot.
PlotC
gtable object for the main plot.
PlotD
gtable object for the bottom sub-plot.
Grob
gtable object for the arranged plot.
primaryData
data.table object storing the primary data, should have column names sample, gene, mutation, label.
simpleMutationCounts
data.table object storing simplified mutation counts, should have column names sample, mutation, Freq, mutationBurden
complexMutationCounts
data.table object storing mutation counts per mutation type should have column names sample, mutation, Freq, mutationBurden.
geneData
data.table object storing gene counts, should have column names gene, mutation, count.
ClinicalData
data.table object stroring the data used to plot the clinical sub-plot.
mutationHierarchy
data.table object storing the hierarchy of mutation type in order of most to least important and the mapping of mutation type to color. Should have column names mutation, color, and label.