#' Find all Y_j - X_i differences
#'
#' @param x List of x values
#' @param y List of y values
#' @return Ascending list of differences
#' @export
findDiffs<-function(x,y) {
diff<-numeric(0)
m<-length(x)
n<-length(y)
for (i in 1:m)
for (j in 1:n)
diff<-c(diff,y[j]-x[i])
diff<-sort(diff)
return(diff)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.