Skip to content

cheminfo/openchemlib-utils

Repository files navigation

openchemlib-utils

NPM version build status npm download

.

Installation

$ npm i openchemlib-utils

Usage

import OCL from 'openchemlib'; // version should be greater than 7.4

import { getPathsInfo, initOCL } from 'openchemlib-utils';
initOCL(OCL);

const molecule = OCL.Molecule.fromSmiles('CCCCC');

const paths = getPathsInfo(molecule, {
  fromLabel: 'H',
  toLabel: 'H',
  minLength: 1,
  maxLength: 4,
});

console.log(paths);

We will add more examples in /examples.

License

MIT