Manager¶
Manager for Bio2BEL ChEBI.
-
class
bio2bel_chebi.manager.
Manager
(*args, **kwargs)[source]¶ Chemical multi-hierarchy.
-
namespace_model
¶ alias of
bio2bel_chebi.models.Chemical
-
summarize
() → Mapping[str, int][source]¶ Return a summary dictionary over the content of the database.
-
get_or_create_chemical
(chebi_id: str, **kwargs) → bio2bel_chebi.models.Chemical[source]¶ Get a chemical from the database by ChEBI.
-
get_chemical_by_chebi_id
(chebi_id: str) → Optional[bio2bel_chebi.models.Chemical][source]¶ Get a chemical from the database.
-
get_chemical_by_chebi_name
(name: str) → Optional[bio2bel_chebi.models.Chemical][source]¶ Get a chemical from the database.
-
build_chebi_id_name_mapping
() → Mapping[str, str][source]¶ Build a mapping from ChEBI identifier to ChEBI name.
-
build_chebi_name_id_mapping
() → Mapping[str, str][source]¶ Build a mapping from ChEBI name to ChEBI identifier.
-
populate
(inchis_url: Optional[str] = None, compounds_url: Optional[str] = None, relations_url: Optional[str] = None, names_url: Optional[str] = None, accessions_url: Optional[str] = None) → None[source]¶ Populate all tables.
-
iter_chemicals
(graph: pybel.struct.graph.BELGraph, use_tqdm: bool = False) → Iterable[Tuple[pybel.dsl.node_classes.BaseEntity, bio2bel_chebi.models.Chemical]][source]¶ Iterate over pairs of BEL nodes and ChEBI chemicals.
-