LoopCircos-class {RPointCloud} | R Documentation |
The LoopCircos
Class
Description
A LoopCircos
object represents a one-dimensional cycle (a
loop, or topogical eequivalent of a circle), along with a set of
features that vary around the loop and can be plotted in a "circos"
plot to help explain why the loop exists. The LoopCircos
class
inherits from the Cycle
class, so you can think of it as
a cycle object with extra information (namely, the explanatory
features).
Usage
LoopCircos(cycle, angles, colors)
angleMeans(view, rips, cycle = NULL, dset, angleWidth = 20, incr = 15)
## S4 method for signature 'LoopCircos'
image(x, na.col = "grey", ...)
Arguments
cycle |
In the |
angles |
A matrix where columns are features, rows are angles,
and the value is the mean expression of that feature in a sector
around that central angle. These are almost always constructed using
the |
colors |
A list of character vectors, each of length two, containing the names or hexadecimal representations of colors used to create a color ramp to display the feature. The list should be the same length as the number of features to be displayed. |
view |
A (layout) matrix with coordinates showing where to plot each point in the feature while computing means in sectors. |
rips |
A Rips |
dset |
The numeric matrix from which Featuers are drawn. |
angleWidth |
A numeric vector of length one; the width (in degrees) of each sector. |
incr |
A numeric vector; the increment (in degeres) between sector centers. |
x |
A |
na.col |
A character string; the color in which to plot missing
( |
... |
The usual set of additional graphical parameters. |
Value
The angleMeans
function computes the mean expression of each
numeric feature in a two-dimensional sector swept out around the
centroid of the support of a cycle. It returns these values as a
matrix, with each row corresponding to the angle (in degrees) around
the centroid of the cycle.
The LoopCircos
function constructs and returns an object of the
LoopCircos
class
The image
method returns (invisibly) the LoopCircos
object that was its first argument.
Slots
angles
:A matrix of angle means.
colors
:A list of color-pairs for displayign features.
Methods
- image(x, ...):
-
Produce a circos plot of a
LoopCircos
object.
Author(s)
Kevin R. Coombes <krc@silicovore.com>
See Also
Examples
data(CLL)
cyc1 <- Cycle(ripdiag, 1, 236, "forestgreen")
V <- cmdscale(daisydist)
poof <- angleMeans(V, ripdiag, cyc1, clinical)
poof[is.na(poof)] <- 0
angle.df <- poof[, c("mutation.status", "CatCD38", "CatB2M", "CatRAI",
"Massive.Splenomegaly", "Hypogammaglobulinemia")]
colorScheme <- list(c(M = "green", U = "magenta"),
c(Hi = "cyan", Lo ="red"),
c(Hi = "blue", Lo = "yellow"),
c(Hi = "#dddddd", Lo = "#111111"),
c(No = "#dddddd", Yes = "brown"),
c(No = "#dddddd", Yes = "purple"))
annote <- LoopCircos(cyc1, angle.df, colorScheme)
image(annote)