pypath.internals.intera.Complex§
- class pypath.internals.intera.Complex(components, ncbi_tax_id=9606, name=None, ids=None, sources=None, interactions=None, references=None, proteins=None, attrs=None)[source]§
Bases:
object
- __init__(components, ncbi_tax_id=9606, name=None, ids=None, sources=None, interactions=None, references=None, proteins=None, attrs=None)[source]§
Represents a molecular complex.
- componentslist,dict
Either a list of identifiers or a dict with identifiers as keys and stoichiometric coefficients as values. List of identifiers also assumed to represent stoichiometry by repetition of identifiers.
- ncbi_tax_idint
NCBI taxonomy identifier of the complex. It implies all members of the complex belong to the same organism. Support for multi- organism complexes will be implemented in the future.
- namestr
A custom name or identifier of the complex.
- idsdict
Identifiers. If
sources
is a set, list or tuple it should be a dict with database names as keys and set of identifiers as values. Ifsources
is a string, it can be a set of identifiers or a single identifier.- sourcesset,str
Database(s) the complex has been defined in.
- interactionslist,dict
Interactions between the components of the complex. Either a list of tuples of component IDs or a dict with tuples as keys and custom interaction properties as values.
- proteinslist,dict
Synonym for components, kept for compatibility.
Methods
__init__
(components[, ncbi_tax_id, name, ...])Represents a molecular complex.
add_attr
(source, attr)Attributes can store annotations for complexes.
add_ids
(ids[, source])add_source
(source)get_interaction
(component1, component2)has_interaction
(component1, component2)iter_proteins
()merge
(other)Adds the annotations (sources, references, attrs) of the other
Complex
instance to this one.reload
()set_interaction
(component1, component2, ...)Attributes
genesymbol_str
genesymbols
have_stoichiometry
stoichiometry
stoichiometry_str
stoichiometry_str_genesymbols