node_events | R Documentation |
In many countries, individual-based livestock data are collected to enable contact tracing during disease outbreaks. However, the livestock databases are not always structured in such a way that relevant information for disease spread simulations is easily retrieved. The aim of this function is to facilitate cleaning livestock event data and prepare it for usage in SimInf.
node_events(x, time = NULL, target = NULL, age = NULL)
## S4 method for signature 'SimInf_indiv_events'
node_events(x, time = NULL, target = NULL, age = NULL)
x |
an individual events object of class
|
time |
All events that occur after ‘time’ are
included. Default is |
target |
The SimInf model ('SEIR', 'SIR', 'SIS', 'SISe3',
'SISe3_sp', 'SISe', or 'SISe_sp') to target the events and u0
for. The default, |
age |
Integer vector with break points in days for the ageing events. |
The individual-based events will be aggregated on node-level. The
select
value is determined by the event type and age
category. If there is only one age category, i.e.,
age=NULL
, then select=1
for the enter events, and
select=2
for all other events. If there are two age
categories, then select=1
for the enter events in the first
age category, and select=2
for the enter events in the
second age category. Similarly, select=3
for all other
events in the first age category, and select=4
for all
other events in the first second category. With three age
categories, it works similarly with select=1,2,3
for the
enter events in each age category, respectively. And
select=4,5,6
for all other events.
a data.frame
with the columns event
,
time
, node
, dest
, n
,
proportion
, select
, and shift
.
individual_events
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.