src/pybel/struct/graph.py
def add_reaction(
        self,
        reactants: Union[BaseAbundance, Iterable[BaseAbundance]],
        products: Union[BaseAbundance, Iterable[BaseAbundance]],
    ) -> None:
        """Add a reaction directly to the graph."""
        return self.add_node_from_data(Reaction(reactants=reactants, products=products))
Add a reaction directly to the graph.
Add a reaction directly to the graph.
Add a reaction directly to the graph .
def add_reaction(
        self,
        reactants: Union[BaseAbundance, Iterable[BaseAbundance]],
        products: Union[BaseAbundance, Iterable[BaseAbundance]],
    ) -> None:
        return self.add_node_from_data(Reaction(reactants=reactants, products=products))
def add_reaction ( self , reactants : Union [ BaseAbundance , Iterable [ BaseAbundance ] ] , products : Union [ BaseAbundance , Iterable [ BaseAbundance ] ] , ) -> None : return self . add_node_from_data ( Reaction ( reactants = reactants , products = products ) )
Add a reaction directly to the graph.
Add a reaction directly to the graph .
"""Add a reaction directly to the graph."""
self
reactants
Union[BaseAbundance, Iterable[BaseAbundance]]
products
Union[BaseAbundance, Iterable[BaseAbundance]]