R/add_letters.R

Defines functions add_letters

Documented in add_letters

##' adds letter grades to a data grade list object
##'
##' @param grades a vector of grades
##' @param scale a grade scale object
##' @export
##'
add_letters <- function(grades, scale = grade_scale()) {

  # Note use of default grade scale
  cut(grades, breaks=scale$grade.cutoffs, labels=scale$grade.labels)

}
adsteen/gradr documentation built on Dec. 18, 2017, 4:45 a.m.