RDKit
Open-source cheminformatics and machine learning.
|
Classes | |
class | ForwardSDMolSupplier |
class | MolSupplier |
class | SDMolSupplier |
struct | SmartsParserParams |
class | SmilesMolSupplier |
lazy file parser for Smiles tables More... | |
struct | SmilesParserParams |
class | TDTMolSupplier |
lazy file parser for TDT files More... | |
Functions | |
ChemicalReaction * | RxnBlockToChemicalReaction (const std::string &rxnBlock, bool sanitize=false, bool removeHs=false, bool strictParsing=true) |
Parse a text block in MDL rxn format into a ChemicalReaction. | |
ChemicalReaction * | RxnFileToChemicalReaction (const std::string &fileName, bool sanitize=false, bool removeHs=false, bool strictParsing=true) |
Parse a file in MDL rxn format into a ChemicalReaction. | |
ChemicalReaction * | RxnDataStreamToChemicalReaction (std::istream &rxnStream, unsigned int &line, bool sanitize=false, bool removeHs=false, bool strictParsing=true) |
Parse a text stream in MDL rxn format into a ChemicalReaction. | |
ChemicalReaction * | PNGStreamToChemicalReaction (std::istream &pngStream) |
constructs a ChemicalReaction from the metadata in a PNG stream | |
ChemicalReaction * | PNGStringToChemicalReaction (const std::string &data) |
constructs a ChemicalReaction from the metadata in a PNG string See PNGStreamToChemicalReaction() for more details | |
ChemicalReaction * | PNGFileToChemicalReaction (const std::string &fname) |
constructs a ChemicalReaction from the metadata in a PNG file See PNGStreamToChemicalReaction() for more details | |
std::vector< std::unique_ptr< RWMol > > | CDXMLDataStreamToMols (std::istream &inStream, bool sanitize=true, bool removeHs=true) |
construct molecules from a CDXML file Note that the CDXML format is large and complex, the RDKit doesn't support full functionality, just the base ones required for molecule and reaction parsing. | |
std::vector< std::unique_ptr< RWMol > > | CDXMLFileToMols (const std::string &filename, bool sanitize=true, bool removeHs=true) |
construct molecules from a CDXML file Note that the CDXML format is large and complex, the RDKit doesn't support full functionality, just the base ones required for molecule and reaction parsing. | |
std::vector< std::unique_ptr< RWMol > > | CDXMLToMols (const std::string &cdxml, bool sanitize=true, bool removeHs=true) |
construct molecules from a CDXML file Note that the CDXML format is large and complex, the RDKit doesn't support full functionality, just the base ones required for molecule and reaction parsing. | |
RWMol * | MolDataStreamToMol (std::istream *inStream, unsigned int &line, bool sanitize=true, bool removeHs=true, bool strictParsing=true) |
RWMol * | MolDataStreamToMol (std::istream &inStream, unsigned int &line, bool sanitize=true, bool removeHs=true, bool strictParsing=true) |
RWMol * | MolBlockToMol (const std::string &molBlock, bool sanitize=true, bool removeHs=true, bool strictParsing=true) |
RWMol * | MolFileToMol (const std::string &fName, bool sanitize=true, bool removeHs=true, bool strictParsing=true) |
RWMol * | TPLDataStreamToMol (std::istream *inStream, unsigned int &line, bool sanitize=true, bool skipFirstConf=false) |
translate TPL data (BioCad format) into a multi-conf molecule | |
RWMol * | TPLFileToMol (const std::string &fName, bool sanitize=true, bool skipFirstConf=false) |
construct a multi-conf molecule from a TPL (BioCad format) file | |
RWMol * | Mol2FileToMol (const std::string &fName, bool sanitize=true, bool removeHs=true, Mol2Type variant=Mol2Type::CORINA, bool cleanupSubstructures=true) |
RWMol * | Mol2DataStreamToMol (std::istream &inStream, bool sanitize=true, bool removeHs=true, Mol2Type variant=Mol2Type::CORINA, bool cleanupSubstructures=true) |
RWMol * | Mol2DataStreamToMol (std::istream *inStream, bool sanitize=true, bool removeHs=true, Mol2Type variant=Mol2Type::CORINA, bool cleanupSubstructures=true) |
RWMol * | Mol2BlockToMol (const std::string &molBlock, bool sanitize=true, bool removeHs=true, Mol2Type variant=Mol2Type::CORINA, bool cleanupSubstructures=true) |
RWMol * | XYZDataStreamToMol (std::istream &inStream) |
RWMol * | XYZBlockToMol (const std::string &xyzBlock) |
RWMol * | XYZFileToMol (const std::string &fName) |
RWMol * | PDBBlockToMol (const std::string &str, bool sanitize=true, bool removeHs=true, unsigned int flavor=0, bool proximityBonding=true) |
RWMol * | PDBBlockToMol (const char *str, bool sanitize=true, bool removeHs=true, unsigned int flavor=0, bool proximityBonding=true) |
RWMol * | PDBFileToMol (const std::string &fname, bool sanitize=true, bool removeHs=true, unsigned int flavor=0, bool proximityBonding=true) |
RWMol * | PDBDataStreamToMol (std::istream &inStream, bool sanitize=true, bool removeHs=true, unsigned int flavor=0, bool proximityBonding=true) |
RWMol * | PDBDataStreamToMol (std::istream *inStream, bool sanitize=true, bool removeHs=true, unsigned int flavor=0, bool proximityBonding=true) |
bool | MrvFileIsReaction (const std::string &fname) |
bool | MrvDataStreamIsReaction (std::istream *inStream) |
bool | MrvDataStreamIsReaction (std::istream &inStream) |
bool | MrvBlockIsReaction (const std::string &molmrvText) |
RWMol * | MrvDataStreamToMol (std::istream *inStream, bool sanitize=false, bool removeHs=false) |
RWMol * | MrvDataStreamToMol (std::istream &inStream, bool sanitize=false, bool removeHs=false) |
RWMol * | MrvBlockToMol (const std::string &molmrvText, bool sanitize=false, bool removeHs=false) |
RWMol * | MrvFileToMol (const std::string &fName, bool sanitize=false, bool removeHs=false) |
ChemicalReaction * | MrvDataStreamToChemicalReaction (std::istream *inStream, bool sanitize=false, bool removeHs=false) |
ChemicalReaction * | MrvDataStreamToChemicalReaction (std::istream &inStream, bool sanitize=false, bool removeHs=false) |
ChemicalReaction * | MrvBlockToChemicalReaction (const std::string &molmrvText, bool sanitize=false, bool removeHs=false) |
ChemicalReaction * | MrvFileToChemicalReaction (const std::string &fName, bool sanitize=false, bool removeHs=false) |
RDKit::RWMol * | SmilesToMol (const std::string &smi, const SmilesParserParams &ps) |
Atom * | SmilesToAtom (const std::string &smi) |
Bond * | SmilesToBond (const std::string &smi) |
RWMol * | SmilesToMol (const std::string &smi, int debugParse=0, bool sanitize=true, std::map< std::string, std::string > *replacements=nullptr) |
Construct a molecule from a SMILES string. | |
RWMol * | SmartsToMol (const std::string &sma, const SmartsParserParams &ps) |
RWMol * | SmartsToMol (const std::string &sma, int debugParse=0, bool mergeHs=false, std::map< std::string, std::string > *replacements=nullptr) |
Construct a molecule from a SMARTS string. | |
Atom * | SmartsToAtom (const std::string &sma) |
Bond * | SmartsToBond (const std::string &sma) |
Reaction SMARTS/SMILES Support | |
ChemicalReaction * | RxnSmartsToChemicalReaction (const std::string &text, std::map< std::string, std::string > *replacements=nullptr, bool useSmiles=false, bool allowCXSMILES=true) |
Parse a string containing "Reaction SMARTS" into a ChemicalReaction. | |
|
inline |
construct molecules from a CDXML file Note that the CDXML format is large and complex, the RDKit doesn't support full functionality, just the base ones required for molecule and reaction parsing.
inStream | - string containing the mol block |
sanitize | - toggles sanitization and stereochemistry perception of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized correctness of the contents. |
Definition at line 82 of file CDXMLParser.h.
|
inline |
construct molecules from a CDXML file Note that the CDXML format is large and complex, the RDKit doesn't support full functionality, just the base ones required for molecule and reaction parsing.
fileName | - cdxml fileName |
sanitize | - toggles sanitization and stereochemistry perception of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized correctness of the contents. |
Definition at line 102 of file CDXMLParser.h.
|
inline |
construct molecules from a CDXML file Note that the CDXML format is large and complex, the RDKit doesn't support full functionality, just the base ones required for molecule and reaction parsing.
cdxml | - string containing the mol block |
sanitize | - toggles sanitization and stereochemistry perception of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized correctness of the contents. |
Definition at line 122 of file CDXMLParser.h.
|
inline |
molBlock | - string containing the mol block |
sanitize | - toggles sanitization of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized |
variant | - the atom type definitions to use |
cleanupSubstructures | - toggles recognition and cleanup of common substructures |
Definition at line 310 of file FileParsers.h.
|
inline |
inStream | - stream containing the data |
sanitize | - toggles sanitization of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized |
variant | - the atom type definitions to use |
cleanupSubstructures | - toggles recognition and cleanup of common substructures |
Definition at line 280 of file FileParsers.h.
|
inline |
Definition at line 292 of file FileParsers.h.
|
inline |
fName | - string containing the file name |
sanitize | - toggles sanitization of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized |
variant | - the atom type definitions to use |
cleanupSubstructures | - toggles recognition and cleanup of common substructures |
Definition at line 258 of file FileParsers.h.
|
inline |
molBlock | - string containing the mol block |
sanitize | - toggles sanitization and stereochemistry perception of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized |
strictParsing | - if set to false, the parser is more lax about correctness of the contents. |
Definition at line 112 of file FileParsers.h.
|
inline |
Definition at line 97 of file FileParsers.h.
|
inline |
inStream | - stream containing the data |
line | - current line number (used for error reporting) |
sanitize | - toggles sanitization and stereochemistry perception of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized |
line | - current line number (used for error reporting) |
strictParsing | - if set to false, the parser is more lax about correctness of the contents. |
Definition at line 87 of file FileParsers.h.
|
inline |
fName | - string containing the file name |
sanitize | - toggles sanitization and stereochemistry perception of the molecule |
removeHs | - toggles removal of Hs from the molecule. H removal is only done if the molecule is sanitized |
strictParsing | - if set to false, the parser is more lax about correctness of the contents. |
Definition at line 131 of file FileParsers.h.
Definition at line 67 of file MarvinParser.h.
|
inline |
Definition at line 116 of file MarvinParser.h.
|
inline |
Definition at line 85 of file MarvinParser.h.
|
inline |
Definition at line 64 of file MarvinParser.h.
|
inline |
Definition at line 60 of file MarvinParser.h.
|
inline |
Definition at line 108 of file MarvinParser.h.
|
inline |
Definition at line 100 of file MarvinParser.h.
|
inline |
Definition at line 78 of file MarvinParser.h.
|
inline |
Definition at line 71 of file MarvinParser.h.
Definition at line 57 of file MarvinParser.h.
|
inline |
Definition at line 124 of file MarvinParser.h.
|
inline |
Definition at line 92 of file MarvinParser.h.
|
inline |
Definition at line 395 of file FileParsers.h.
|
inline |
Definition at line 385 of file FileParsers.h.
|
inline |
Definition at line 411 of file FileParsers.h.
|
inline |
Definition at line 421 of file FileParsers.h.
|
inline |
Definition at line 401 of file FileParsers.h.
|
inline |
constructs a ChemicalReaction from the metadata in a PNG file See PNGStreamToChemicalReaction()
for more details
Definition at line 344 of file ReactionParser.h.
|
inline |
constructs a ChemicalReaction from the metadata in a PNG stream
Looks through the metadata in the PNG to find the first tag that matches one of the tags in RDKit::PNGData
. A reaction is constructed from this chunk.
Throws a FileParseException
if no suitable tag is found.
The caller is responsible for the returned pointer.
Definition at line 334 of file ReactionParser.h.
|
inline |
constructs a ChemicalReaction from the metadata in a PNG string See PNGStreamToChemicalReaction()
for more details
Definition at line 339 of file ReactionParser.h.
|
inline |
Parse a text block in MDL rxn format into a ChemicalReaction.
Definition at line 216 of file ReactionParser.h.
|
inline |
Parse a text stream in MDL rxn format into a ChemicalReaction.
Definition at line 238 of file ReactionParser.h.
|
inline |
Parse a file in MDL rxn format into a ChemicalReaction.
Definition at line 227 of file ReactionParser.h.
|
inline |
Parse a string containing "Reaction SMARTS" into a ChemicalReaction.
Our definition of Reaction SMARTS is something that looks a lot like reaction SMILES, except that SMARTS queries are allowed on the reactant side and that atom-map numbers are required (at least for now)
text | the SMARTS to convert |
replacements | a string->string map of replacement strings. |
useSmiles | if set, the SMILES parser will be used instead of the SMARTS parserfor the individual components |
allowCXSMILES | if set, any CXSMILES extensions present will be parsed, otherwise it will be ignored |
Definition at line 114 of file ReactionParser.h.
Definition at line 229 of file SmilesParse.h.
Definition at line 232 of file SmilesParse.h.
|
inline |
Definition at line 189 of file SmilesParse.h.
|
inline |
Construct a molecule from a SMARTS string.
sma | the SMARTS to convert |
debugParse | toggles verbose debugging information from the parser |
mergeHs | toggles merging H atoms in the SMARTS into neighboring atoms |
replacements | a string->string map of replacement strings. |
Definition at line 217 of file SmilesParse.h.
Definition at line 135 of file SmilesParse.h.
Definition at line 140 of file SmilesParse.h.
|
inline |
Definition at line 118 of file SmilesParse.h.
|
inline |
Construct a molecule from a SMILES string.
smi | the SMILES to convert |
debugParse | toggles verbose debugging information from the parser |
sanitize | toggles H removal and sanitization of the molecule |
replacements | a string->string map of replacement strings. See below for more information about replacements. |
The optional replacements map can be used to do string substitution of abbreviations in the input SMILES. The set of substitutions is repeatedly looped through until the string no longer changes. It is the responsibility of the caller to make sure that substitutions results in legal and sensible SMILES.
Examples of substitutions:
Definition at line 171 of file SmilesParse.h.
|
inline |
translate TPL data (BioCad format) into a multi-conf molecule
inStream | the stream from which to read |
line | used to track the line number of errors |
sanitize | toggles sanitization and stereochemistry perception of the molecule |
skipFirstConf | according to the TPL format description, the atomic coords in the atom-information block describe the first conformation and the first conf block describes second conformation. The CombiCode, on the other hand, writes the first conformation data both to the atom-information block and to the first conf block. We want to be able to read CombiCode-style tpls, so we'll allow this mis-feature to be parsed when this flag is set. |
Definition at line 179 of file FileParsers.h.
|
inline |
construct a multi-conf molecule from a TPL (BioCad format) file
fName | the name of the file from which to read |
sanitize | toggles sanitization and stereochemistry perception of the molecule |
skipFirstConf | according to the TPL format description, the atomic coords in the atom-information block describe the first conformation and the first conf block describes second conformation. The CombiCode, on the other hand, writes the first conformation data both to the atom-information block and to the first conf block. We want to be able to read CombiCode-style tpls, so we'll allow this mis-feature to be parsed when this flag is set. |
Definition at line 203 of file FileParsers.h.
xyzBlock | - string containing the xyz block |
Definition at line 350 of file FileParsers.h.
|
inline |
Definition at line 343 of file FileParsers.h.
fName | - string containing the file name |
Definition at line 357 of file FileParsers.h.