Ontology¶
-
class
openomics.database.ontology.Ontology(path, file_resources=None, col_rename=None, npartitions=0, verbose=False)[source][source]¶ Bases:
openomics.database.base.DatabaseAttributes Summary
Methods Summary
filter_annotation(annotation)filter_network(namespace)get_adjacency_matrix(node_list)get_dfs_paths(root_nodes[, filter_duplicates])Return all depth-first search paths from root node(s) to children node by traversing the ontology directed graph.
get_node_color([file])load_network(file_resources)- rtype
(<class ‘networkx.classes.multidigraph.MultiDiGraph’>, <class ‘list’>)
remove_predecessor_terms(annotation)Attributes Documentation
Methods Documentation
-
get_dfs_paths(root_nodes, filter_duplicates=False)[source][source]¶ Return all depth-first search paths from root node(s) to children node by traversing the ontology directed graph. :param root_nodes: [“GO:0008150”] if biological processes, [“GO:0003674”] if molecular_function, or [“GO:0005575”] if cellular_component :type root_nodes: list :param filter_duplicates: whether to remove duplicated paths that end up at the same leaf nodes :type filter_duplicates: bool
Returns: pd.DataFrame of all paths starting from the root nodes.
-
static
get_node_color(file='~/Bioinformatics_ExternalData/GeneOntology/go_colors_biological.csv')[source][source]¶