formatResponseMap {braidReports} | R Documentation |
Format Response and Error Maps
Description
Format response maps as activity maps using a multicolor gradient or error maps using a bidirectional gradient.
Usage
formatResponseMap(rmap, palette = NULL, cscale = NULL, xl = expression(Conc[A]),
yl = expression(Conc[B]), zl = "Activity")
formatDifferenceMap(rmap, zcenter = NULL, xl = expression(Conc[A]),
yl = expression(Conc[B]), zl = "Diff")
Arguments
rmap |
a |
palette |
a character vector or two or more colors defining the colorscale to be applied to the fill variable in the plot. |
cscale |
a value around which the colorscale applied to the fill variable will be centered. If
|
xl |
The character string or expression used to label the x-axis |
yl |
The character string or expression used to label the y-axis |
zl |
The character string or expression used to label the colorscale representing the response variable |
zcenter |
the value that forms the centerpoint (white) in the bidirectional color scale. If |
Details
These functions are largely convenience functions, taking a response map produced by responseMap
and formatting it with colorscales and axis labels. formatResponseMap
with a multicolor gradient; by
default it uses a modified 'jet' colormap, ranging from dark red to dark green, rather than the traditional
dark blue. We find this function useful for visualizing response surfaces representing variables such as
cytotoxicity, cell viability, enzyme activity, etc. The other formats the response map with a bidirectional
color gradient (using the ggplot2
function scale_fill_gradient2
; we find this format ideal for
visualizing error maps.
Value
A ggplot2
plot object, with the appropriate scales and labels added.
Author(s)
Nathaniel R. Twarog
References
Twarog, N.R., Stewart, E., Vowell Hamill, C., and Shelat, A. BRAID: A Unifying Paradigm for the Analysis of Combined Drug Action. Scientific Reports In Press (2016).
See Also
Examples
data(es8olatmz,package="braidrm")
rmap <- responseMap(act~conc1+conc2,es8olatmz)
formatResponseMap(rmap,xl="Olaparib",yl="TMZ",zl="Survival")
formatDifferenceMap(rmap,zcenter=-1)