Learn R Programming

ontologySimilarity (version 1.0)

get_term_sim_mat: Get term-term similarity matrix

Description

Get term-term similarity matrix

Usage

get_term_sim_mat(ontology, information_content, term_descendancy_matrix = get_term_descendancy_matrix(ontology, rows = get_ancestors(ontology, restrict_rows_to), cols = names(information_content)), method = c("lin", "resnik"), restrict_rows_to = names(information_content))

Arguments

ontology
ontology_index object.
information_content
Numeric vector of information contents of terms (named by term)
term_descendancy_matrix
Logical term descendancy matrix, dimensions symmetrically labelled by terms, and where by a cell value of TRUE indicates that the row is the ancestor of the column term (in the sense of the DAG structure of the HPO.
method
Character vector - either "lin" (to use Lin's expression of similarity of terms) or "resnik" (to use Resnik's definition)
restrict_rows_to
Restrict rows to Character vector of term names for which to compute corresponding similarities to all terms information_content

Value

Numeric matrix of term-term simliarities

See Also

resnik, lin