MDL Query Depiction¶
In order to depict an MDL query the query molecule has to be imported by
calling the OEReadMDLQueryFile
function.
The rest of the process is identical to depicting a molecule.
First the OEPrepareDepiction
function has to be
called to generate the 2D atom coordinates, then the image can be
created by rendering the molecule (OERenderMolecule
).
Listing 1: Example of MDL query depiction
if (args.Length != 2)
{
OEChem.OEThrow.Usage("DepictMDLQuery <mdlquery> <imagefile>");
}
oemolistream ifs = new oemolistream(args[0]);
OEGraphMol qmol = new OEGraphMol();
OEChem.OEReadMDLQueryFile(ifs, qmol);
OEDepict.OEPrepareDepiction(qmol);
OEDepict.OERenderMolecule(args[1], qmol);
See also
OEReadMDLQueryFile
function in the OEChem TK manual
Atom Query Features¶
The depiction of the following MDL atom query features is supported:
The 8th column in the atom block in the V2K format file (or
HCOUNT=
in the V3K format file) is used to define the number of allowed hydrogens for an atom. (See examples in Table: Example of depicting hydrogen count)(H0)
means no hydrogen atoms allowed unless explicitly drawn.(Hn)
means atom must haven
or more implicit hydrogen(s)
¶ query
Query atom types:
A
= any atom type except hydrogenQ
= any atom type except hydrogen and carbonL
= atom list
The
M ALS
line in the property block in the V2K format file ( or[aaa,bbb,..]
in the V3K format) is used to list alternative atom types for an atom. (See examples in Table: Examples of depicting query atom types)¶ query
target
target
target
M CHG
line in the property block in the V2K format file (orCHG=
in the V3K format) is used to define atom formal charges. (See examples in Table: Example of depicting formal charge)¶ query
target
target
M RBC
line in the property block in the V2K format file (orRBCNT=
in the V3K format) is used to limit the number of allowed ring bonds attached to an atom. (See examples in Table: Example of depicting ring count)(r0)
means no ring bond allowed(r*)
means as drawn(rn)
meansn
number of ring bonds allowed
¶ query
target
target
M SUB
line in the property block in the V2K format file (orSUBST=
in the V3K format) is used to set the number of allowed substitutions of an atom. (See examples in Table: Examples of depicting substitution count)(s0)
means no substitution allowed(s*)
means as drawn(sn)
meansn
number of substitution(s) allowed
¶ query
target
target
M UNS
line in the property block in the V2K format file (orUNSAT=
in the V3K format) is used to specify whether or not an atom is unsaturated, i.e., having at least one multiple bond. (See examples in Table: Examples of depicting unsaturated property)¶ query
target
target
Bond Query Features¶
The depiction of the following MDL bond query features is supported:
Alternative bond types in the bond block (4 = aromatic, 5 = single or double, 6 = single or aromatic, 7 = double or aromatic, 8 = any bond). (See examples in Table: Examples of depicting query bond types)
¶ query
target
target
target
See also
OEBondDisplayType
namespace
The 6th column in the atom block in the V2K format file ( or
TOPO=
in the V3K format) describes bond topology. (See examples in Table: Examples of depicting bond topology)(rn)
means that it can only mapped to ring bond(ch)
means that it can only mapped to chain bond
¶ query
target
target
Double bond stereochemistry is considered if both ends of the bond are marked with stereo care flags in the atom block in the V2K format file ( or
STBOX=
in the V3K format). (See examples in Table: Examples of depicting bond stereo care)¶ query
target
target
See also
Depicting MDL Query example
R-group Depiction¶
OEDepict TK can also depict R-group information by interpreting the M RGP
line in the property block of an MDL file
(See examples in Table: Examples of depicting R-groups)