Concatenation of releases at the same date and location, but with different numbers of individuals
Currently, sit
considers these as the same release and deduplicates them. However, the different number of individuals released is ignored and the first value is kept.
library(sit)
releases_raw <- read.csv(
system.file("extdata/releases.csv", package = "sit")
)
## Point releases
p_releases <- releases_raw |>
dplyr::filter(!is.na(lon)) |> # Observations with non-missing coords
sf::st_as_sf( # Convert to spatial
coords = c("lon", "lat"), # Variables with coordinates
crs = 4326 # Code for GPS coordinates
)
p_releases2 <- p_releases |> dplyr::mutate(n = n + 1)
## Should this give 3 or 6 releases?
c(sit_revents(p_releases), sit_revents(p_releases2))
#> id type site_id date colour n geometry
#> 1 1 point 1 2019-11-25 yellow 10000 POINT (16.41472 48.23528)
#> 2 2 point 1 2019-12-01 red 10000 POINT (16.41472 48.23528)
#> 3 3 point 1 2019-12-13 blue 10000 POINT (16.41472 48.23528)
Created on 2023-11-12 with reprex v2.0.2
I'm not sure what behaviour would be more appropriate in this (admittedly corner) case. But ignoring the difference in the numbers of individuals does not seem very robust.