get_history: Get Entity history

Description Usage Arguments Value Examples

View source: R/Entity-functions.R

Description

Get the history data of a given Entity. If a Container object is given then this will return a list of data.tables or NULL if an Entity in the Container doesn't have any history data.

Usage

1
2
3
4
5
6
7
get_history(x, ...)

## S3 method for class 'Container'
get_history(x, ...)

## S3 method for class 'Entity'
get_history(x, ...)

Arguments

x

An R6 object that belongs to one of these classes: Entity, Population and World.

...

(not being used) dots

Value

a list of data.table or NULL.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
create_toy_world()

add_history(world$get("Individual"),
  ids = 1:100,
  event = "test_event1",
  time = 1
)

get_history(world)
get_history(world$get("Individual"))

dymium-org/dymiumCore documentation built on July 18, 2021, 5:10 p.m.