View source: R/plot.functions.R
| timeplot | R Documentation |
Plot raw responses over time by treatment or class
timeplot(network, level = "treatment", plotby = "arm", link = "identity", ...)
network |
An object of class |
level |
A string indicating whether nodes/facets should represent |
plotby |
A character object that can take either |
link |
Can take either |
... |
Arguments to be sent to |
Plots can be faceted by either treatment (level="treatment") or class
(level="class") to investigate similarity of treatment responses within classes/agents.
Points represent observed responses and lines connect between observations within the
same study and arm.
The function returns an object of class(c("gg", "ggplot"). Characteristics
of the object can therefore be amended as with other plots generated by ggplot().
# Make network
goutnet <- mb.network(goutSUA_CFB)
# Use timeplot to plot responses grouped by treatment
timeplot(goutnet)
# Use timeplot ot plot resposes grouped by class
timeplot(goutnet, level="class")
# Plot matrix of relative effects
timeplot(goutnet, level="class", plotby="rel")
# Plot using Standardised Mean Differences
copdnet <- mb.network(copd)
timeplot(copdnet, plotby="rel", link="smd")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.