This functions estimate a likelihood map for each stationary period based on twilight data. The functions performs the following steps:
Perform a calibration on the known stationary period. See below for details
Compute a likelihood map for each twilight using the calibration.
Combine the likelihood maps of all twilights belonging to the same stationary periods with a log-linear pooling. See GeoPressureManual | Probability aggregation for more information on probability aggregation using log-linear pooling.
Usage
geolight_map(
tag,
twl_calib_adjust = 1.4,
twl_llp = function(n) log(n)/n,
compute_known = FALSE,
quiet = FALSE
)
Arguments
- tag
a GeoPressureR
tag
object.- twl_calib_adjust
smoothing parameter for the kernel density (see
stats::kernel()
).- twl_llp
log-linear pooling aggregation weight.
- compute_known
logical defining if the map(s) for known stationary period should be estimated based on twilight or hard defined by the known location
stap$known_l**
- quiet
logical to hide messages about the progress
Calibration
Calibration requires to have a known position for a least one stationary periods. Use
tag_set_map()
to define the known position.
Instead of calibrating the twilight errors in terms of duration, we directly model the zenith
angle error. We use a kernel distribution to fit the zenith angle during the known stationary
period(s). The twl_calib_adjust
parameter allows to manually adjust how smooth you want the
fit of the zenith angle to be. Because the zenith angle error model is fitted with data from the
calibration site only, and we are using it for all locations of the bird’s journey, it is safer
to assume a broader/smoother distribution.
See also
Other geolight:
twilight_create()
,
twilight_label_read()
,
twilight_label_write()
Examples
withr::with_dir(system.file("extdata", package = "GeoPressureR"), {
# Read geolocator data and build twilight
tag <- tag_create("18LX", quiet = TRUE) |>
tag_label(quiet = TRUE) |>
tag_set_map(
extent = c(-16, 23, 0, 50),
scale = 10,
known = data.frame(
stap_id = 1,
known_lon = 17.05,
known_lat = 48.9
)
)
# Compute the twilight
tag <- twilight_create(tag) |> twilight_label_read()
# Compute likelihood map
tag <- geolight_map(tag, quiet = TRUE)
})
plot(tag, type = "map_light")