Description Usage Arguments Value Examples
False detections are defined as single detections within a predefined time
interval (usually 24h). They can be identified among all the detections of
the whole acoustic array or individually (providing the receiver
argument), in which case the the detections of each single acoustic receiver
are considered independently.
1 | falseDetect(tag.id, time.stamp, rec.id = NULL, time.int = 24)
|
tag.id |
vector with the ID codes of tagged individuals. |
time.stamp |
vector with the date and time of each detection in
|
rec.id |
vector with the ID codes of the receivers for each detection. Optional argument, if provided, the fuction will also identify the false detections within each receiver. |
time.int |
time interval (in hours) that define false detections. It is set to 24h by default, as it is the most commonly used value. |
The function returns a data.frame with one or two logical vectors
indicating if each detection has been identified as good (TRUE
) or
false (FALSE
), taking into account the whole detection
array
(first column) or each receiver
separately (optional
second column, only if receiver
is provided).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | # Create a random dataset
set.seed(900)
time.stamp <- Sys.time() + c(1:24, 70:71, 200, 300:320, 500, 701:720) * 3600
tag.id <- factor(sample(c("i1", "i2"), length(time.stamp), replace = TRUE))
rec.id <- factor(sample(c("r1", "r2"), length(time.stamp), replace = TRUE))
# False detections for the whole receiver array
f1 <- falseDetect(tag.id, time.stamp)
plot(time.stamp, tag.id, pch = (1:2)[rec.id])
points(time.stamp[!f1], tag.id[!f1], col = 2, cex = 2)
# False detections within individual receivers
f2 <- falseDetect(tag.id, time.stamp, rec.id)
plot(time.stamp, tag.id, pch = (1:2)[rec.id])
points(time.stamp[!f2$receiver], tag.id[!f2$receiver], col = 4, cex = 2.4)
points(time.stamp[!f2$array], tag.id[!f2$array], col = 2, cex = 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.