Description Usage Arguments Value Examples
View source: R/plotTrajRibbon.R
A ribbon with confidence interval for the mean is plotted around the group mean. Optionally an additional curve is plotted, e.g. a stimulation time course.
1 2 3 4 5 |
dt.arg |
Data table in long format with mean time series and upper and lower bound for the CI |
x.arg |
String with column name of x-axis data (default: Metadata_RealTime) |
y.arg |
String with column name of y-axis data (default: Mean) |
group.arg |
String with column name of the grouping variable for trajectories (default: Metadata_Well). |
col.arg |
Vector with string elements with colour palette for time series curves (default: NULL). |
dt.stim.arg |
Data table with stimulation time series (default: NULL). |
stim.x.arg |
String with column name of x-axis of dt.stim.arg. |
stim.y.arg |
String with column name of y-axis of dt.stim.arg. |
xlab.arg |
String with x-axis label |
ylab.arg |
String with y-axis label |
plotlab.arg |
String with plot title |
ggplot2 plot object
1 2 3 4 5 6 7 8 9 10 | require(tca)
# generate synthetic time series
dt = genTraj()
# clculate 90% CI
dt.aggr = calcTrajCI(in.dt = dt, in.col.meas = 'objNuc_Intensity_MeanIntensity_imErkCor', in.col.by = 'Metadata_Site', in.type = 'normal', conf.int = 0.9)
# plot each group in a separate facet; add population mean
plotTrajRibbon(dt.arg = dt.aggr, x.arg = 'Metadata_RealTime', y.arg = 'Mean')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.