% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/augmenters.R
\name{augment_user_tested}
\alias{augment_user_tested}
\title{Nearest wrapper}
\usage{
augment_user_tested(all_facilities, test_data, distance_threshold = 100)
}
\arguments{
\item{all_facilities}{data.frame Facilities selected in maxcovr model}

\item{test_data}{data.frame test data (but it could be any \code{user}-type data)}

\item{distance_threshold}{numeric}
}
\value{
dataframe containing distances between each test data observation
and the nearest facility.
}
\description{
This function is wrapper to \code{nearest}, adding \code{is_covered} to the model. This
function is explicit about inputs, and is useful in cross validation -
evaluating how test data performs against suggested facilities in the
training set. This might be added to \code{nearest}, and may become obsolete.
}
\examples{

\dontrun{

mc_cv_relocate_n100_cut \%>\%
  mutate(user_nearest_test = map2(
    .x = facilities_selected,
    .y = test,
    .f = augment_user_tested
    ))

}

}
