plotDeplogo {DepLogo} | R Documentation |
Plot a dependency logo
Description
Plots a dependency logo
Usage
plotDeplogo(
data,
dep.fun = plotDeparcs,
block.fun = deprects,
summary.fun = logo,
weight.fun = NULL,
chunks = NULL,
chunk.height = 800,
summary.height = 100,
minPercent = 0.03,
threshold = 0.1,
numBestForSorting = 3,
maxNum = 6,
sortByWeights = NULL,
dep.fun.legend = TRUE,
show.dependency.pvals = FALSE,
axis.labels = NULL,
weight.ratio = 5,
partition.by = NULL,
...
)
## S3 method for class 'DLData'
plotDeplogo(
data,
dep.fun = plotDeparcs,
block.fun = deprects,
summary.fun = logo,
weight.fun = NULL,
chunks = NULL,
chunk.height = 800,
summary.height = 100,
minPercent = 0.03,
threshold = 0.1,
numBestForSorting = 3,
maxNum = 6,
sortByWeights = NULL,
dep.fun.legend = TRUE,
show.dependency.pvals = FALSE,
axis.labels = NULL,
weight.ratio = 5,
partition.by = NULL,
...
)
Arguments
data |
the data, currently implemented for DLData objects |
dep.fun |
the function for plotting the representation of dependency values (as computed by getDeps) |
block.fun |
the function for plotting a representation of the individual partitions of the data generated in dependency logos. |
summary.fun |
the function for plotting a representation of the summary plot for (one chunk of) the data |
weight.fun |
the function for plotting a representation of the
|
chunks |
the size of chunks the data is split into. The sum of the chunk sizes must not be greater than the number of data points in data; The default value of NULL corresponds to one chunk containing all data points |
chunk.height |
the (relative) height of the parts of the plot representing each of the chunks, one height for each chunk |
summary.height |
the (relative) height of the block summaries in the plot |
minPercent |
the minimum percentage of the (sub) data set that may constitute its own partition in the dependency logo |
threshold |
the threshold on the dependency value for further splits |
numBestForSorting |
the number of dependencies between position i and all other positions when computing the dependency value of position i |
maxNum |
the maximum number of splits allowed |
sortByWeights |
are partitions sorted by their average weight (descending) |
dep.fun.legend |
if |
show.dependency.pvals |
is |
axis.labels |
labels for the x-axis, vector of the same length as the individual sequences |
weight.ratio |
the factor by which the plotting width for the main plot is larger than for |
partition.by |
specify fixed positions to partition by |
... |
forwarded to the high-level |
Details
The function dep.fun
provided for plotting the representation of
dependencies is currently implemented in plotDeparcs and
plotDepmatrix. Custom implementations must have the same signature as
these functions and create a single plot without using
layout (or similar).
The functions block.fun
and summary.fun
provided for plotting
the representation of individual partitions of the data generated in
dependency logos are currently implemented in deprects,
colorchart, and logo. Custom implementations must have the same
signature as these functions and create a single plot without using
layout (or similar).
The function weight.fun
for plotting a representation of the
weights
values of the sequences within one partition is currently
implemented in subLines and subBoxes. Custom implementations
must have the same signature as these functions and create a single plot
without using layout (or similar).
Value
a list of DLData objects with the partitions created for the dependency logo
Author(s)
Jan Grau <grau@informatik.uni-halle.de>
Examples
# read data and create DLData object
seqs <- read.table(system.file("extdata", "cjun.txt", package = "DepLogo"),
stringsAsFactors = FALSE)
data <- DLData(sequences = seqs[, 1],weights = log1p(seqs[, 2]) )
# plot default dependency logo
plotDeplogo(data)
# refine threshold for clearer picture
plotDeplogo(data, threshold = 0.3)
# customize different parts of the plot
plotDeplogo(data, threshold = 0.3, dep.fun = plotDepmatrix, block.fun = colorchart)
# add plots of the weights
plotDeplogo(data, weight.fun = subBoxes)