Description Usage Arguments Value Examples
View source: R/sigfit_utility.R
Cosine similarity between two vectors
1 | cosine_sim(x, y)
|
x |
Vector of real values |
y |
Vector of real values, same length as |
Similarity measure between x
and y
, where 0
means no similarity, and 1 means maximum similarity.
1 | cosine_sim(c(1,2,3,4), c(4,3,2,1))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.