#' Similarity from correlation
#'
#' @param data correlation matrix
#' @param method similarity function
#'
#' @return
#' @export
#'
#'
similarity <- function(data, method = "not") {
if(method == "not") {
data
}
else if(method == "shift") {
(data + 1) / 2
}
else if(method == "abs") {
abs(data)
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.