#' Get the nth minimum value
#'
#' @export
nmin <- function(x, n=2){
len <- length(x)
if(n > len){
warning('n greater than length(x). Setting n=length(x)')
n <- length(x)
}
sort(x,partial=n)[n]
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.