| plot.dec.sim | R Documentation |
Available plot types are: true toxicity at each dose level
(type = "s"); a bar plot of the probability of selecting each dose
as the MTD (type = "prob"); a bar plot of the average number of
patients treated at each dose level (type = "np"); and a bar plot
of the average number of DLTs at each dose level (type = "dlt").
Setting type = "all" produces all four plots.
## S3 method for class 'dec.sim'
plot(
x,
pt,
s = 1,
type = c("all", "s", "prob", "np", "dlt"),
label = TRUE,
col = "cornflowerblue",
text.col = "darkblue",
cex = 1,
...
)
x |
An object of class |
pt |
A vector of target toxicity values, one for each scenario. |
s |
The scenario to plot. Defaults to 1. |
type |
Plot type. See the description above. |
label |
Logical; if |
col |
Graphical parameter |
text.col |
Color used for text labels. |
cex |
Graphical parameter |
... |
Arguments passed to plotting functions. |
# generate decision table
dt <- dec.table(0.6,0.4,0.2,0.3,c(3,3,3))
# Simulate trials from test data
test.file <- system.file("extdata", "testS.csv", package = "tsdf")
out <- sl.sim(dt$table, test.file)
plot(out, pt=rep(0.3,2), s=1, type="all")
plot(out, pt=rep(0.3,2), s=2, type="prob")
plot(out, pt=rep(0.3,2), s=1, type="np")
plot(out, pt=rep(0.3,2), s=2, type="dlt")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.