get_functional_similarity: get_functional_similarity()

Description Usage Arguments Value Examples

Description

Function that gets the functional similarity between two terms. That is a measure of the shared terms in the annotations resources. This functional similarity is implemented as a distance between binary vectors.

Usage

1
get_functional_similarity(x, term1, term2, distance_measure)

Arguments

x

The GeneAnnotations class on which the method will run.

term1

The first term on which to calculate the functional similarity.

term2

The second term on which to calculate the functional similarity.

distance_measure

The binary distance method (one of UI, binary, bray-curtis, cosine)

Value

The functional similarity between term1 and term2

Examples

1
2
3
4
5
6
7
kegg <- TCGAome::load_kegg()
random_kegg_term1 = kegg@term2gene$Term[runif(1, max = length(kegg@term2gene$Term))]
random_kegg_term2 = kegg@term2gene$Term[runif(1, max = length(kegg@term2gene$Term))]
get_functional_similarity(kegg, random_kegg_term1, random_kegg_term2, "cosine")
get_functional_similarity(kegg, random_kegg_term1, random_kegg_term2, "binary")
get_functional_similarity(kegg, random_kegg_term1, random_kegg_term2, "UI")
get_functional_similarity(kegg, random_kegg_term1, random_kegg_term2, "bray-curtis")

priesgo/TCGAome documentation built on May 25, 2019, 11:26 a.m.