R/kstar_vlines.R

Defines functions kstar_vlines

Documented in kstar_vlines

#' Prepare K-star vertical lines
#' 
#' @template args-he
#' @param plot_params Plots parameters
#' @keywords internal
#' 
kstar_vlines <- function(he, plot_params) {
  
  if (length(he$kstar) > 0) {
    abline(v = he$kstar,
           col = "dark grey",
           lty = "dotted")
    
    text(x = he$kstar,
         y = min(plot_params$ylim),
         paste("k* = ", he$kstar , sep = ""))
  }
}
giabaio/BCEA documentation built on March 27, 2024, 5:32 p.m.