OEWriteMonomerSet

Attention

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

OEWriteMonomerSet(monomers: OEMonomerSet, jsonFileName: str) -> bool

Writes the monomer definitions stored in the monomer set (OEMonomerSet) into a JSON format.

The following example shows how a monomer is represented in the output file:

{
  "smiles": "[H:1]N(C)[C@@H](Cc1ccccc1)C(=O)[OH:2]",
  "name": "N-alpha-methyl-L-Phenylalanine",
  "codes": {
     "OpenEye": "MeF",
     "PDB": "MEA"
  }
},

The OEPolymerType_Peptide and OEMonomerType_Backbone are considered defaults for a monomer and are only written to the json file if their values differ from these defaults.

See more example in the the following file:

monomers-openeye.json