1.6.5 • Published 4 years ago

aromaticity-core v1.6.5

Weekly downloads
2
License
GPL-3.0
Repository
github
Last release
4 years ago

aromaticity-core

npm version

The core of aromaticity.

Use that library to compute Molecule Properties and query PubChem.

For more information visit: https://aromaticity.io/core.

Docs

  • Compute Molecule Properties
    • Constructor
    • Molecule Properties
    • Molfile
  • Query PubChem
    • Query
    • Fetched Properties
  • Examples

Compute Molecule Properties

Constructor

new Molecule(SMILES: string)

Molecule Properties

PropertiesDescription
acceptor: numberReturns the Acceptor Number.
averageBondLength(nonHydrogenBondsOnly: boolean = false): numberReturns the Average Bond Length.
bonds: numberReturns the Bonds Number.
donor: numberReturns the Donor Number.
formula(isHTML: boolean = false): stringReturns the Molecular Formula.
IUPACName(cb: Function): voidGet the IUPAC Name and pass it to a callback function.
logP: numberReturns the LogP.
logS: numberReturns the LogS.
polarSurfaceArea: numberReturns the Polar Surface Area.
rotatableBonds: numberReturn the Rotatable Bonds Number.
stereoCenters: numberReturns the Stereo Centers Number.
SVG(width: number = 400, height: number = 400): stringReturns the SVG.
weight: numberReturns the Molecular Weight.
toMolfile(isV2000: boolean = false): stringReturn the MolFile.
toSMILES(): stringReturns the SMILES.

Molfile

FunctionDescription
molFileToMol(Molfile: string): MoleculeReturns Molecule from Molfile.
molFileToSmiles(Molfile: string): stringReturns SMILES from Molfile.

Query PubChem

Query

PubChem(smiles: string, PropertiesToFetch: Property[]|Property, cb: Function)

Fetched Properties

From PubChem you can fetch the following properties:

PropertyDescription
MolecularFormulaMolecular formula.
MolecularWeightThe molecular weight is the sum of all atomic weights of the constituent atoms in a compound, measured in g/mol. In the absence of explicit isotope labelling, averaged natural abundance is assumed. If an atom bears an explicit isotope label, 100% isotopic purity is assumed at this location.
CanonicalSMILESCanonical SMILES (Simplified Molecular Input Line Entry System) string. It is a unique SMILES string of a compound, generated by a “canonicalization” algorithm.
IsomericSMILESIsomeric SMILES string. It is a SMILES string with stereochemical and isotopic specifications.
InChlStandard IUPAC International Chemical Identifier (InChI). It does not allow for user selectable options in dealing with the stereochemistry and tautomer layers of the InChI string.
InChIKeyHashed version of the full standard InChI, consisting of 27 characters.
IUPACNameChemical name systematically determined according to the IUPAC nomenclatures.
XLogPComputationally generated octanol-water partition coefficient or distribution coefficient. XLogP is used as a measure of hydrophilicity or hydrophobicity of a molecule.
ExactMassThe mass of the most likely isotopic composition for a single molecule, corresponding to the most intense ion/molecule peak in a mass spectrum.
MonoisotopicMassThe mass of a molecule, calculated using the mass of the most abundant isotope of each element.
TPSATopological polar surface area, computed by the algorithm described in the paper by Ertl et al.
ComplexityThe molecular complexity rating of a compound, computed using the Bertz/Hendrickson/Ihlenfeldt formula.
ChargeThe total (or net) charge of a molecule.
HBondDonorCountNumber of hydrogen-bond donors in the structure.
HBondAcceptorCountNumber of hydrogen-bond acceptors in the structure.
rotatableBondCountNumber of rotatable bonds.
HeavyAtomCountNumber of non-hydrogen atoms.
IsotopeAtomCountNumber of atoms with enriched isotope(s)
AtomStereoCountTotal number of atoms with tetrahedral (sp3) stereo e.g., (R)- or (S)-configuration
DefinedAtomStereoCountNumber of atoms with defined tetrahedral (sp3) stereo.
UndefinedAtomStereoCountNumber of atoms with undefined tetrahedral (sp3) stereo.
BondStereoCountTotal number of bonds with planar (sp2) stereo e.g., (E)- or (Z)-configuration.
DefinedBondStereoCountNumber of atoms with defined planar (sp2) stereo.
UndefinedBondStereoCountNumber of atoms with undefined planar (sp2) stereo.
CovalentUnitCountNumber of covalently bound units.
Volume3DAnalytic volume of the first diverse conformer (default conformer) for a compound.
XStericQuadrupole3DThe x component of the quadrupole moment (Qx) of the first diverse conformer (default conformer) for a compound.
YStericQuadrupole3DThe y component of the quadrupole moment (Qy) of the first diverse conformer (default conformer) for a compound.
ZStericQuadrupole3DThe z component of the quadrupole moment (Qz) of the first diverse conformer (default conformer) for a compound.
FeatureCount3DTotal number of 3D features (the sum of FeatureAcceptorCount3D, FeatureDonorCount3D, FeatureAnionCount3D, FeatureCationCount3D, FeatureRingCount3D and FeatureHydrophobeCount3D)
FeatureAcceptorCount3DNumber of hydrogen-bond acceptors of a conformer.
FeatureDonorCount3DNumber of hydrogen-bond donors of a conformer.
FeatureAnionCount3DNumber of anionic centers (at pH 7) of a conformer.
FeatureCationCount3DNumber of cationic centers (at pH 7) of a conformer.
FeatureRingCount3DNumber of rings of a conformer.
FeatureHydrophobeCount3DNumber of hydrophobes of a conformer.
ConformerModelRMSD3DConformer sampling RMSD in Å.
EffectiveRotorCount3DTotal number of 3D features (the sum of FeatureAcceptorCount3D, FeatureDonorCount3D, FeatureAnionCount3D, FeatureCationCount3D, FeatureRingCount3D and FeatureHydrophobeCount3D)
ConformerCount3DThe number of conformers in the conformer model for a compound.
Fingerprint2DBase64-encoded PubChem Substructure Fingerprint of a molecule.

Examples

import { Molecule } from 'aromaticity-core';

let mol = new Molecule('CCCO');

mol.IUPACName((name) => {
    console.log(name);  // propan-1-ol
})

console.log(mol.weight);    // 60

console.log(mol.formula())  // C3H8O
import { PubChem, Property } from 'aromaticity-core';

PubChem('CCC', [Property.MolecularFormula, Property.Complexity], (res) => {
    console.log(res);   // { CID: 6334, MolecularFormula: 'C3H8', Complexity: 0 }
})

PubChem('[Ca++]', Property.Charge, (res) => {
    console.log(res);   // 2
})
1.6.5

4 years ago

1.6.4

4 years ago

1.6.3

4 years ago

1.6.2

4 years ago

1.6.1

4 years ago

1.6.0

4 years ago

1.5.0

4 years ago

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.0

4 years ago