Skip to contents

Add one or more Event objects to a Snapshot.

Usage

add_event(snapshot, event)

Arguments

snapshot

A Snapshot object.

event

An Event object created with create_event(), or a list of such objects.

Value

The updated Snapshot object, returned invisibly.

Examples

if (FALSE) { # \dontrun{
evt <- create_event(
  name = "Breakfast",
  template = "Meal: Standard (Human)"
)
snapshot <- load_snapshot("Midazolam") |>
  add_event(evt)

snapshot <- load_snapshot("Midazolam") |>
  add_event(list(evt, evt))
} # }