OEPrepareDepictionOptions

class OEPrepareDepictionOptions

This class represents OEPrepareDepictionOptions that stores the following parameters that are used when preparing a molecule for depiction.

Property Get method Set method Corresponding namespace / type
re-generating 2D coordinates GetClearCoords SetClearCoords boolean
adding depiction hydrogens GetAddDepictionHydrogens SetAddDepictionHydrogens boolean
perceiving MDL bond stereo (wedge/hash) GetPerceiveBondStereo SetPerceiveBondStereo boolean
suppressing explicit (non-depiction) hydrogens GetSuppressHydrogens SetSuppressHydrogens boolean
depiction orientation GetDepictOrientation SetDepictOrientation OEDepictOrientation

See also

See the effect of the above parameters in Table: Depictions generated with various parameter combinations when depiction are generated from the following input:

SMILES
Parsing the “CC([C@@H]1C[C@@H]2C[C@H]1NC2)N(H)(H)” string with three explicit hydrogens necessary to define tetrahedral stereo centers and two additional explicit hydrogens.
MDL
Reading an MDL file with 2D coordinates and pre-assigned wedge/hash bonds. It also includes two explicit hydrogens.
Depictions generated with various parameter combinations
index clear coordinates suppress explicit H add depict H perceive wedge/hash from SMILES from MDL
(1) F F F F ../../_images/OEPrepDepictOpts-SMI-cc-0-sH-0-aH-0-pBS-0.png ../../_images/OEPrepDepictOpts-MDL-cc-0-sH-0-aH-0-pBS-0.png
(2) F F F T    
(3) F F T F    
(4) F F T T ../../_images/OEPrepDepictOpts-SMI-cc-0-sH-0-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-0-sH-0-aH-1-pBS-1.png
(5) F T F F    
(6) F T F T    
(7) F T T F    
(8) F T T T ../../_images/OEPrepDepictOpts-SMI-cc-0-sH-1-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-0-sH-1-aH-1-pBS-1.png
(9) T F F F    
(10) T F F T ../../_images/OEPrepDepictOpts-SMI-cc-1-sH-0-aH-0-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-1-sH-0-aH-0-pBS-1.png
(11) T F T F    
(12) T F T T ../../_images/OEPrepDepictOpts-SMI-cc-1-sH-0-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-1-sH-0-aH-1-pBS-1.png
(13) T T F F    
(14) T T F T    
(15) T T T F    
(16) T T T T ../../_images/OEPrepDepictOpts-SMI-cc-1-sH-1-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-1-sH-1-aH-1-pBS-1.png

Comments:

(1)
MDL = no op; SMILES = generating 2D coordinates is necessary
(4)
MDL = keeping original 2D coordinates, adding depiction hydrogens, re-perceiving wedge/hash bonds; SMILES = generating 2D coordinates, depiction hydrogens are kept; perceiving wedge/hash bonds
(8)
Default parameters; MDL = keeping original 2D coordinates, re-perceiving all other information; SMILES = generating 2D coordinates, regenerating all other information;
(10)
MDL = regenerating 2D coordinates and re-perceiving wedge/hash bonds (since no depiction hydrogens are added the wedge/hash bonds are on ring bonds); SMILES generating 2D coordinates and perceiving wedge/hash bonds;
(12)
Regenerating all information and keeping all explicit hydrogens
(16)
Regenerating all information; the depiction of identical molecules imported from SMILES and MDL will be identical

Constructors

OEPrepareDepictionOptions(bool clearcoords=false, bool suppressH=true)

Default constructor that initializes an OEPrepareDepictionOptions object with the following properties:

clearcoords
See the OEPrepareDepictionOptions.SetClearCoords method.
suppressH
See the OEPrepareDepictionOptions.SetSuppressHydrogens method.
Default parameters of the OEPrepareDepictionOptions class
Property Default value
re-generating 2D coordinates false
adding depiction hydrogens true
perceiving MDL bond stereo (wedge/hash) true
suppressing explicit (non-depiction) hydrogens true
depiction orientation OEDepictOrientation.Default
OEPrepareDepictionOptions(const OEPrepareDepictionOptions &rhs)

Copy constructor.

operator=

OEPrepareDepictionOptions &operator=(const OEPrepareDepictionOptions &rhs)

Assignment operator.

GetAddDepictionHydrogens

bool GetAddDepictionHydrogens() const

Returns whether the depiction hydrogens are kept/added.

GetClearCoords

bool GetClearCoords() const

Returns whether the 2D coordinates of a molecule are re-calculated.

GetDepictOrientation

unsigned int GetDepictOrientation() const

Returns the preferred orientation of the 2D coordinates. The return value is taken from the OEDepictOrientation namespace.

GetPerceiveBondStereo

bool GetPerceiveBondStereo() const

Returns whether the hash/wedge bonds are re-assigned.

GetSuppressHydrogens

bool GetSuppressHydrogens() const

Returns whether the explicit (non-depiction) hydrogens are suppressed.

SetAddDepictionHydrogens

void SetAddDepictionHydrogens(bool)

Sets whether depiction hydrogens are kept/added.

SetClearCoords

void SetClearCoords(bool clearcoords)

Sets whether the 2D coordinates of the molecule are re-calculated. If the molecule has no 2D coordinates, then the 2D coordinates are always calculated by calling the OEDepictCoordinates regardless of this setting.

SetDepictOrientation

void SetDepictOrientation(unsigned int orientation)

Sets the preferred orientation of the 2D coordinates.

orientation
This value has to be from the OEDepictOrientation namespace.

SetPerceiveBondStereo

void SetPerceiveBondStereo(bool)

Sets whether to re-assign the wedge and hash bonds by calling the OEMDLPerceiveBondStereo function.

See also

SetSuppressHydrogens

void SetSuppressHydrogens(bool)

Sets whether the explicit (non-depiction) hydrogens are suppressed in the molecule. Only hydrogens that are necessary to faithfully represent tetrahedral stereo-chemistry will be kept.

See also