OEMonomerData

Attention

This is a preliminary API and may be improved based on user feedback. It is currently available in C++ and Python.

class OEMonomerData

Stores the basic definition required for a monomer (OEMonomer) to be used as a building block for representing biological macromolecules.

Example of monomer definition of L-Alanine

Property

Value

Required/Optional/Generated

Smiles

[H:1]N[C@@H](C)C(=O)[OH:2]

required

Canonical Smiles

C[C@@H](C(=O)O)N

generated

Name

L-Alanine (optional)

optional

Polymer type

OEPolymerType.Peptide

required

Monomer type

OEMonomerType.Backbone

required

Monomer code-set/code pair

A in code-set Standard

required for at least one code-set

Constructors

OEMonomerData()

Default constructor that creates an OEMonomerData object.

OEMonomerData(const std::string& smiles,
              unsigned polymerType = OEPolymerType::Peptide,
              unsigned monomerType = OEMonomerType::Backbone)

Constructor that initializes an OEMonomerData object.

See also

OEMonomerData(const OEMonomerData &)

Copy constructor.

AddCode

void AddCode(const std::string& codeSet, const std::string& code)

Adds a code to a monomer for a given code-set.

GetCode

std::string GetCode(const std::string& codeSet) const

Returns the code of the monomer for the given code-set. Returns an empty string if there is no code defined for the code-set.

GetCodes

const std::map<std::string, std::string>& GetCodes() const

Returns the map that contains all the code-set and code pairs defined for the monomer.

GetMonomerType

unsigned int GetMonomerType() const

Returns the monomer type of the monomer.

See also

GetName

std::string GetName() const

Returns the full name of the monomer. It is optional to define and only used to reference name.

GetPolymerType

unsigned int GetPolymerType() const

Returns the polymer type of the monomer.

See also

GetSmiles

std::string GetSmiles() const

Returns the smiles representation of the monomer that contains the atom map indices representing connection points. Such as [H:1]N[C@@H](C)C(=O)[OH:2] defining alanine.

GetCanonicalSmiles

std::string GetCanonicalSmiles() const

Returns the canonical smiles representation of the monomer (without atom mapping) Such as C[C@@H](C(=O)O)N] for alanine.

HasCode

bool HasCode(const std::string& codeSet) const

Returns whether the monomer has a code defined for the given code set.

IsValid

bool IsValid() const

Returns whether the OEMonomerData object is fully defined and correct.

See also

NumCodes

unsigned int NumCodes() const

Returns the number of codes defined for the monomer in various code-sets.

SetCodes

void SetCodes(const std::map<std::string, std::string>& codes)

Sets a code of the monomer for a specific code-set.

SetMonomerType

void SetMonomerType(unsigned int)

Sets the monomer type of the monomer.

See also

SetName

void SetName(const std::string &)

Sets the name of the monomer. The name can be arbitrary, but it is recommended use the IUPAC name or any other name that well the monomer. For example, the name of the C[C@@H](C(=O)O)N] monomer of can be Alanine , L-alanine or L-alpha-Alanine or (2S)-2-aminopropanoic acid. Setting the name is optional.

SetPolymerType

void SetPolymerType(unsigned int)

Sets the polymer type of the monomer.

See also

SetSmiles

void SetSmiles(const std::string &)

Sets the smiles of the monomer. The given smiles has to define possible attachment points of the monomer using map indices. For example, [H:1]N[C@@H](C)C(=O)[OH:2] defining alanine with two connection points to from a peptide bonds with adjacent amino acid monomers.

Validate

bool Validate() const

Calls the OEIsValidMonomerData function to validate the monomer data object.