Skip to content

Transformation

Transformation

Instance of (bio-)transformation, using RDKit Reaction class.

It's instantiate by providing SMARTS but it's also possible to from_smiles() and from_metwork_v0() class method.

Example

from chem_kit import Transformation
tsf = Transformation("[#6:1]-[#8:2]-[#1:3]>>[#6:1]-[#8:2]-[#6:3](-[#1])(-[#1])-[#1]")

__init__(self, smarts) special

Parameters:

Name Type Description Default
smarts str

SMARTS of the transformation to create

required

from_metwork_v0(smarts) classmethod

Parameters:

Name Type Description Default
smarts str

smarts from MetWork v0 reaction database

required

Returns:

Type Description
Transformation

Transformation instance

from_smiles(reactant, product) classmethod

Parameters:

Name Type Description Default
reactant str

SMILES of reactant

required
product str

SMILES of product

required

Returns:

Type Description
Transformation

Transformation instance

get_chemdoodle_json(self)

ChemDoodle JSON format of the transformation.

mass_delta: float property readonly

product: Molecule property readonly

Transformation product

rdkit: Chem.rdChemReactions.ChemicalReaction property readonly

The Chem.rdChemReactions.ChemicalReaction instance associate with the transformation.

reactant: Molecule property readonly

Transformation reactant

reverse(self)

Reverse the way of the transformation, i.e. reactant become product and product become reactant.

run(self, smiles)

Run the transformation for a reactant.

Parameters:

Name Type Description Default
smiles str

SMILES of the reactant

required

simplify(self, **params)

Simplify the transformation by removing non changing atoms that are not 'connected' to the reaction site (i.e. atoms that changes).

Parameters:

Name Type Description Default
params SimplifierParams

See SimplifierParams

{}

Returns:

Type Description
List[Transformation]

List of simplified transformations.

smarts: str property readonly

The SMARTS of the transformation.

SimplifierParams

aromatic: bool pydantic-field

Include aromatic cycles close to transformation site

conjugated: bool pydantic-field

Include conjugated bonds close to transformation site

cycles: bool pydantic-field

Include cycles close to transformation site

hetero_atoms: bool pydantic-field

Include hetero atoms close to transformation site