| plot.behavior_stream | R Documentation | 
behavior_stream objectsCreates a graphical representation of a set of simulated behavior streams.
## S3 method for class 'behavior_stream'
plot(
  x,
  session_color = "black",
  episode_color = "blue",
  episode_thickness = 2,
  ...
)
| x | object of class  | 
| session_color | character string indicating the color of the lines that represent session time. Default is black. | 
| episode_color | character string indicating the color of the bars that represent episode durations. Default is blue. | 
| episode_thickness | numeric value indicating the thickness of the bars that represent episode durations. Default is 2. | 
| ... | Further arguments, not used for this method. | 
The plot is created using ggplot from the ggplot2 package, 
which must be installed.
An object of class ggplot.
if (requireNamespace("ggplot2", quietly = TRUE)) {
b_streams <- r_behavior_stream(n = 5, mu = 3, lambda = 10, 
                               F_event = F_exp(), F_interim = F_exp(), 
                               stream_length = 100)
plot(b_streams)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.