R/oracle.r

Defines functions query_oracle

Documented in query_oracle

#' Automatic query of an oracle.
#'
#' This function reports the true classification for a set of observations.
#'
#' @export
#' @param i a vector of the queried observation indices
#' @param y_truth the true classification labels for the data
#' @return a vector containing the classifications of observations x[i]
query_oracle <- function(i, y_truth) {
  as.vector(y_truth[i])
}
ramhiser/activelearning documentation built on May 26, 2019, 10:06 p.m.