Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

nmr-predictor

Package Overview
Dependencies
Maintainers
6
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nmr-predictor - npm Package Compare versions

Comparing version 1.1.4 to 1.1.5

27

lib/index.js

@@ -35,2 +35,8 @@ 'use strict';

/**
* Fetch the data base from a url.
* @param {string} url - url of data base.
* @param {string} dbName - name of data base.
* @return {promise}
*/
function fetchProton(url = defaultProtonUrl, dbName = 'proton') {

@@ -40,2 +46,8 @@ return fetch(url, dbName, 'proton');

/**
* Fetch the data base from a url.
* @param {string} url - url of data base.
* @param {string} dbName - name of data base.
* @return {promise}
*/
function fetchCarbon(url = defaultCarbonUrl, dbName = 'carbon') {

@@ -72,2 +84,9 @@ return fetch(url, dbName, 'carbon');

/**
* Predict a 1D NMR proton spectrum by Hose code method
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options
* @param {Array} options.levels - contain the levels for hose code query.
* @return {promise}
*/
function proton(molecule, options) {

@@ -80,2 +99,10 @@ options.atomLabel = 'H';

/**
* Predict a 1D NMR proton spectrum by Hose code method
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options
* @param {Array} options.levels - contain the levels for hose code query.
* @param {string} options.db - name of data base to be used.
* @return {promise}
*/
function carbon(molecule, options) {

@@ -82,0 +109,0 @@ options.atomLabel = 'C';

5

lib/spinus.js

@@ -26,4 +26,5 @@ 'use strict';

* Makes a prediction using spinus
* @param {string|Molecule} molecule
* @param {object} [options]
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options
* @param {object} options.OCLE - to recicle the OCLE object for prediction.
* @return {Promise<Array>}

@@ -30,0 +31,0 @@ */

@@ -14,2 +14,12 @@ 'use strict';

/**
* construct a bidimensional spectrum from 1D predictions.
* @param {Array} dim1 - 1D prediction
* @param {Array} dim2 - 1D prediction
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options - object options for getAllpPaths function from {@link https://github.com/cheminfo-js/openchemlib-extended OCLE}.
* @param {object=} [options.OCLE] - to recicle the OCLE object for prediction.
* @return {Array<object>} paths - the path information of the bidimensional spectrum.
*/
function twoD(dim1, dim2, molecule, options) {

@@ -16,0 +26,0 @@ [molecule, options] = (0, _normalizeOptions2.default)(molecule, options);

2

package.json
{
"name": "nmr-predictor",
"version": "1.1.4",
"version": "1.1.5",
"description": "NMR chemical shift predictor",

@@ -5,0 +5,0 @@ "keywords": [],

@@ -14,2 +14,8 @@

/**
* Fetch the data base from a url.
* @param {string} url - url of data base.
* @param {string} dbName - name of data base.
* @return {promise}
*/
function fetchProton(url = defaultProtonUrl, dbName = 'proton') {

@@ -19,2 +25,8 @@ return fetch(url, dbName, 'proton');

/**
* Fetch the data base from a url.
* @param {string} url - url of data base.
* @param {string} dbName - name of data base.
* @return {promise}
*/
function fetchCarbon(url = defaultCarbonUrl, dbName = 'carbon') {

@@ -51,2 +63,9 @@ return fetch(url, dbName, 'carbon');

/**
* Predict a 1D NMR proton spectrum by Hose code method
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options
* @param {Array} options.levels - contain the levels for hose code query.
* @return {promise}
*/
function proton(molecule, options) {

@@ -59,2 +78,10 @@ options.atomLabel = 'H';

/**
* Predict a 1D NMR proton spectrum by Hose code method
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options
* @param {Array} options.levels - contain the levels for hose code query.
* @param {string} options.db - name of data base to be used.
* @return {promise}
*/
function carbon(molecule, options) {

@@ -61,0 +88,0 @@ options.atomLabel = 'C';

@@ -9,4 +9,5 @@

* Makes a prediction using spinus
* @param {string|Molecule} molecule
* @param {object} [options]
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options
* @param {object} options.OCLE - to recicle the OCLE object for prediction.
* @return {Promise<Array>}

@@ -13,0 +14,0 @@ */

import normalizeOptions from './normalizeOptions';
/**
* construct a bidimensional spectrum from 1D predictions.
* @param {Array} dim1 - 1D prediction
* @param {Array} dim2 - 1D prediction
* @param {string|Molecule} molecule - could be a string of molfile, smile or Molecule instance.
* @param {object} options - object options for getAllpPaths function from {@link https://github.com/cheminfo-js/openchemlib-extended OCLE}.
* @param {object=} [options.OCLE] - to recicle the OCLE object for prediction.
* @return {Array<object>} paths - the path information of the bidimensional spectrum.
*/
export default function twoD(dim1, dim2, molecule, options) {

@@ -4,0 +14,0 @@ [molecule, options] = normalizeOptions(molecule, options);

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc