Get the value or interval of the Neighbourhood Tolerance Parameter of a sr_obs object.

neigh_tol(x)

Arguments

x

A sr_obs object.

Value

A numeric vector of size 1 or 2. Either a constant value for this parameter or a interval with distance values in m.

Details

This function retrieves the values set during creation with sr_obs in absolute terms, performing the convertion from values relative to the diameter of the dataset if necessary. See sr_uq.

Examples

d <- data.frame(lon = 1:3, lat = 1:3, date = 1:3) ## Here, the neighbourhood tolerance parameter is set between ## 2.5 % of the dataset diameter and 1 km. ## Note that the resulting distances are in m, even if the ## original coordinates are geographic. obs <- sr_obs(d, "date", uq = sr_uq(neigh_tol = c(-2.5, 1e4))) neigh_tol(obs)
#> [1] 7842.636 10000.000