getGeneSim {GOSim} | R Documentation

## Compute functional similarity for genes

### Description

Calculate the pairwise functional similarities for a list of genes using different strategies.

### Usage

    getGeneSim(genelist1, genelist2=NULL, similarity="funSimMax", similarityTerm="relevance", normalization=TRUE, method="sqrt", avg=(similarity=="OA"), verbose=FALSE)

### Arguments

`genelist1` | character vector of primary gene IDs according to organism annotation package (see `setEvidenceLevel`)
`genelist2` | optional other character vector of primary gene IDs to compare against
`similarity` | method to calculate the functional similarity between gene products
`similarityTerm` | method to compute the similarity of GO terms
`normalization` | normalize similarities yes/no
`method` | "sqrt": normalize sim(x,y) <- sim(x,y)/sqrt(sim(x,x)*sim(y,y)); "Lin": normalize sim(x,y) <- 2*sim(x,y)/(sim(x,x) + sim(y,y)); "Tanimoto": normalize sim(x,y) <- sim(x,y)/(sim(x,x) + sim(y,y) - sim(x,y)). NOTE: normalization does not have any effect, if term similarity is NOT "relevance" and similarity = "funSimMax", "funSimAvg" or similarity = "OA" and avg=TRUE
`avg` | standardize the OA kernel by the maximum number of GO terms for both genes
`verbose` | print out some information

### Details

The method to calculate the pairwise functional similarity between gene products can either be:

"max"

  the maximum similarity between any two GO terms

"mean"

  the average similarity between any two GO terms

funSimMax

  the average of best matching GO term similarities. Take the maximum of the scores achieved by assignments of GO terms from gene 1 to gene 2 and vice versa. [2]

funSimAvg

  the average of best matching GO term similarities. Take the average of the scores achieved by assignments of GO terms from gene 1 to gene 2 and vice versa. [2]

"OA"

  the optimal assignment (maximally weighted bipartite matching) of GO terms associated to the gene having fewer annotation to the GO terms of the other gene. [1]

"hausdorff"

  Hausdorff distance between two sets: Let X and Y be the two sets of GO terms associated to two genes. Then dist(X,Y) = \max\{\sup_{t \in X} \inf_{t' \in Y} d(t,t'), \sup_{t' \in Y} \inf_{t \in X} d(t,t') [3]. Since GOSim 1.2.8 we translate the Haussdorff distance into a similarity measure by taking sim(X,Y) = \exp(-dist(X,Y).

"dot"

  the dot product between feature vectors describing the absence/presence of each GO term. The absence of each GO term is weighted by its information content. Depending on the type of later normalization one can arrive at the cosine similarity (method="sqrt") or at the Tanimoto coefficient (method="Tanimoto").[4]

### Value

n x n similarity matrix (n = number of genes)

### Note

The result depends on the currently set ontology.

### Author(s)

Holger Froehlich

### References

[1] H. Froehlich, N. Speer, C. Spieth, A. Zell, Kernel Based Functional Gene Grouping, Proc. Int. Joint Conf. on Neural Networks (IJCNN), 6886 - 6891, 2006.

[2] A. Schlicker, F. Domingues, J. Rahnenfuehrer, T. Lengauer, A new measure for functional similarity of gene products based on Gene Ontology, BMC Bioinformatics, 7, 302, 2006.

[3] A. del Pozo, F. Pazos, A. Valencia, Defining functional distances over Gene Ontology, BMC Bioinformatics, 9:50, 2008.

[4] M. Mistry, P Pavlidis, Gene Ontology term overlap as a measure of gene functional similarity, BMC Bioinformatics, 9:327, 2008.

### See Also

`getGeneSimPrototypes`, `getTermSim`, `setOntology`

### Examples

    	# see evaluateClustering

[Package GOSim version 1.32.0 Index]