plot.edecob {edecob}R Documentation

Plot Event Data

Description

Generates a ggplot2 visualizing the data and event if any detected.

Usage

## S3 method for class 'edecob'
plot(x, ...)

Arguments

x

The output of the edecob function for one subject. It is an object of class edecob containing the data and the event information.

...

Other arguments like title, xlab, or ylab. If the plot should be returned, write output = TRUE.

Details

The data points are plotted on the x-axis with the time point on the y-axis. The data from the learning period are gray. The baseline period is outlined by two vertical blue lines. The smoother is plotted in orange. The confidence bound is the blue area. If an event is detected, a red triangle will mark the detection day.

If the parameter output = TRUE is given to the function, the function will output the ggplot. The plot can then be manipulated using the usual functions from the ggplot2 package.

Value

None. If output = TRUE was written in function call, a ggplot object that visualizes the data will be returned. The returned plot will not contain the the text at the bottom.


[Package edecob version 1.2.2 Index]