R/reduce_geo_rel.R
reduce_geo_rel.Rd
Reduce data frame to a single spatial reliability within a context
reduce_geo_rel(
df,
dist_col = "rel_metres",
dist_min = 100,
dist_max = 250,
context,
extra_cols = "taxa",
over_ride_na = NULL,
over_ride_metres = NULL
)
Dataframe.
Character. Name of the column containing the spatial reliability.
Numeric. In the same units as dist_col
. The target spatial
reliability that will be filtered on later.
Numeric. In the same units as dist_col
. In some cases,
there is good reason to believe that dist_col
is an under estimate of
spatial reliability. These cases are identified by over_ride_metres
where
those instances have dist_col <= dist_max
. In those cases, dist_col_adj
will contain dist_min
rather than dist_col
. Only needed if
over_ride_metres
is used
Character. column names defining the context.
Character. Extra columns added to context.
Named list. List names must be the same as column names.
Any names in over_ride_na
will be matched to column names in df
and any
values in that list element will be given the value dist_min
. This is mainly
used to prevent filtering data sources that do not have a concept equivalent
to rel_metres
.
Named list. List names must be the same as column
names. Any names in over_ride_metres
will be matched to column names in df
and any values in that list element will be given the value dist_min
.
dataframe with a single rel_metres_adj
value per context.