user_classify: Add user specified classification of territory areas

View source: R/user_classify.R

user_classifyR Documentation

Add user specified classification of territory areas

Description

Opportunity to add a new column 'user_class' which enables the user to confirm or reject the automated assessment of territory areas.

Usage

user_classify(
  territory_poly,
  territory = NULL,
  possible = NULL,
  activity = NULL
)

Arguments

territory_poly

a territory polygon generated with beavertools::estimate_territories()

territory

numeric vector containing the ID numbers for areas to be reclassified as 'Territory'. e.g. c(10, 28)

possible

numeric vector containing the ID numbers for areas to be reclassified as 'Possible'

activity

numeric vector containing the ID numbers for areas to be reclassified as 'Activity'

Value

territory_poly is returned with the an additional column 'user_class'

Examples

# Here we filter the filter the built in 2019-2020 ROBT feeding sign data `RivOtter_FeedSigns`
# Then pipe this 'sf' object to forage_density.
ROBT_201920 <- RivOtter_FeedSigns %>%
dplyr::filter(SurveySeason == "2019 - 2020")%>%
  forage_density(., 'FeedCat')

# Now we load the ROBT `RivOtter_OtherSigns` dataset and filter to the same
# year as the forage density raster.

CS_201920 <- RivOtter_OtherSigns %>%
dplyr::filter(SurveySeason == "2019 - 2020")

# run territory classification
otter_poly <- estimate_territories(ROBT_201920, confirm_signs = CS_201920)

# create the map for checking automated territory classification
check_auto_terr(otter_poly, basemap=FALSE, label=TRUE)

user_classify(otter_poly, territory = c(10, 28))

h-a-graham/beavertools documentation built on July 21, 2023, 12:47 a.m.