ise_build_eh: Build ISE encounter history

Description Usage Arguments Value Examples

View source: R/ise_build_eh.R

Description

Build ISE encounter history

Usage

1
ise_build_eh(df, deploy, occ, ...)

Arguments

df

df object

deploy

deploy object

occ

occ object

...

optional arguments, including quiet = T to suppress time messages

Value

a data frame with encounter history for instantaneous sampling

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
df <- data.frame(
  cam = c(1,1,2,2,2),
  datetime = as.POSIXct(c("2016-01-02 12:00:00",
                        "2016-01-03 13:12:00",
                        "2016-01-02 12:00:00",
                        "2016-01-02 14:00:00",
                        "2016-01-03 16:53:42"),
                      tz = "GMT"),
  count = c(1, 0, 2, 1, 2)
)
deploy <- data.frame(
  cam = c(1, 2, 2, 2),
  start = as.POSIXct(c("2015-12-01 15:00:00",
                       "2015-12-08 00:00:00", 
                       "2016-01-01 00:00:00", 
                       "2016-01-02 00:00:00"),
                     tz = "GMT"),
  end = as.POSIXct(c("2016-01-05 00:00:00", 
                     "2015-12-19 03:30:00", 
                     "2016-01-01 05:00:00",
                     "2016-01-05 00:00:00"), 
                   tz = "GMT"),
  area = c(300, 200, 200, 450)
)
occ <- build_occ(samp_freq = 3600, 
            samp_length = 10,
            study_start = study_dates[1],
            study_end = study_dates[2])
ise_build_eh(df, deploy, occ, assume0 = T)

annam21/TTE.STE.IS documentation built on Dec. 24, 2021, 8:42 a.m.