Package Exports
- ml-spectra-processing
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (ml-spectra-processing) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
spectra-processing
Various method to process spectra. There are sorted in 4 categories:
- array : functions that apply on a 1D array
- xy : functions that apply on an object
{x: [], y:[]}
- xreim: functions that apply on an object
{x: [], re:[], im:[]}
- reim: functions that apply on an object
{re: [], im:[]}
There will be probably more categories related to 2D spectra
Installation
$ npm i ml-spectra-processing
Build the project and publish it on npm
npm install --global cheminfo-build
cheminfo-publish
Usage
const closest = require('ml-spectra-processing').arrayFindClosestIndex;
// or
const {arrayFindClosestIndex} = require('ml-spectra-processing');
or using ES6 modules
import {arrayFindClosestIndex} from 'ml-spectra-processing';
// you can also extract only one function
import {arrayFindClosestIndex} from 'ml-spectra-processing/src/array/arrayFindClosestIndex';