Description Usage Arguments Details Note Author(s) See Also Examples
View source: R/apc_plot_data.R
The plot shows where the data matrix is sparse.
1 2 3 4 5 6 | apc.plot.data.sparsity(apc.data.list,
data.type="a",swap.axes=FALSE,
apc.index=NULL,
sparsity.limits=c(1,2),
cex=NULL,pch=15,
main.outer=NULL)
|
apc.data.list |
List. See |
data.type |
Optional. Character. "r"/"d"/"m" if sums are computed for responses/dose/all. "r" is default. |
swap.axes |
Optional. Logical. If true swap axes in plot. Default is FALSE unless data.format="CL" |
apc.index |
Optional. List. See |
sparsity.limits |
Optional. vector with two values in increasing order. Default is c(1,2). The sparsity plot is a heat map with three colours: black if the observation is smaller than first index (default 1), grey if the observation is smaller than the second index (default 2) and otherwise white. |
cex |
Optional |
pch |
Optional. vector with two values. Either integers specifying a symbol or characters.
See |
main.outer |
Optional. Character. Main title for plot, to be shown in outer margin. Default is NULL, in which case a title is generated internally. |
The default values is used to highlight where a matrix of counts has values of zero and one. Estimation can be very noise in those areas.
Note that the axes for plots grow from bottom left while axes for matrices grow from top left. The exception is when data.format="CL", in which case both grow from top left.
Bent Nielsen <bent.nielsen@nuffield.ox.ac.uk> 25 Apr 2015 updated 27 Apr 2015
The example below uses asbestos data, see data.asbestos
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | #####################
# EXAMPLE with artificial data
# generate a 3x4 matrix in "AP" data.format with the numbers 1..12
m.data <- matrix(data=seq(length.out=12),nrow=3,ncol=4)
m.data
data.list <- apc.data.list(m.data,"AP")
apc.plot.data.sparsity(data.list)
#####################
# EXAMPLE with Japanese breast cancer data
# get data list, then make sparsity plots.
data.list <- data.asbestos()
apc.plot.data.sparsity(data.list)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.