Adds a layer with trend lines to a ggplot.
plot_lines.Rd
Adds a layer with trend lines to a ggplot.
Usage
plot_lines(
data_plot_lines,
line_values = c("est_noTrendStart_noComp", "est_noTrendEnd_noComp"),
line_sig = "sig_Trend_CompCrossDiffWithin",
plot_settings = plotsettings_lineplot()
)
Arguments
- data_plot_lines
data.
- line_values
Character vector with two elements. Column names in
plot_dat[["plot_lines"]]
containing the y-values for the plotted lines. Defaults toc("est_noTrendStart_noComp", "est_noTrendEnd_noComp")
. If set toNULL
, no lines will be plotted.- line_sig
Character string of the column name containing significance values for
line_values
. Defaults to"sig_Trend_noComp"
, which will show the significance of the difference between two time points.- plot_settings
Named list constructed with
plotsettings_lineplot()
. Defaults to a list with all settings set to0
. There are several predefined lists with optimized settings for different plots. Seeplotsettings_lineplot()
for an overview.
Details
Wrapper for ggplot2::geom_segment()
.