Ejemplo n.º 1
0
def generate_scaffold(smiles, include_chirality=False):
  """Compute the Bemis-Murcko scaffold for a SMILES string."""
  from rdkit import Chem
  mol = Chem.MolFromSmiles(smiles)
  engine = ScaffoldGenerator(include_chirality=include_chirality)
  scaffold = engine.get_scaffold(mol)
  return scaffold
Ejemplo n.º 2
0
def generate_scaffold(smiles, include_chirality=False):
  """Compute the Bemis-Murcko scaffold for a SMILES string."""
  from rdkit import Chem
  mol = Chem.MolFromSmiles(smiles)
  engine = ScaffoldGenerator(include_chirality=include_chirality)
  scaffold = engine.get_scaffold(mol)
  return scaffold
Ejemplo n.º 3
0
def generate_scaffold(smiles, include_chirality=False):
    """Compute the Bemis-Murcko scaffold for a SMILES string.

  Note
  ----
  This function requires `rdkit` to be installed.
  """
    from rdkit import Chem
    mol = Chem.MolFromSmiles(smiles)
    engine = ScaffoldGenerator(include_chirality=include_chirality)
    scaffold = engine.get_scaffold(mol)
    return scaffold
Ejemplo n.º 4
0
 def _generate_scaffold(self, smile, include_chirality=False):
     """Compute the Bemis-Murcko scaffold for data.test SMILES string."""
     mol = Chem.MolFromSmiles(smile)
     engine = ScaffoldGenerator(include_chirality=include_chirality)
     scaffold = engine.get_scaffold(mol)
     return scaffold