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

ml-spectra-processing

Package Overview
Dependencies
Maintainers
6
Versions
152
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ml-spectra-processing - npm Package Compare versions

Comparing version 8.0.3 to 8.1.0

lib-esm/matrix/matrixApplyNumericalEncoding.d.ts

19

lib-esm/index.d.ts

@@ -94,23 +94,40 @@ import { DoubleArray } from 'cheminfo-types';

export * from './matrix/matrixZRescale';
export * from './matrix/matrixClone';
export * from './matrix/matrixNumericalEncoding';
export * from './matrix/matrixNumericalDecoding';
export * from './matrix/matrixApplyNumericalEncoding';
export * from './utils/createSequentialArray';
export declare type DoubleMatrix = DoubleArray[];
export interface Zone {
/** starting index */
fromIndex?: number;
/** finishing index */
toIndex?: number;
/** starting value */
from: number;
/** finishing value */
to: number;
/** number of points */
nbPoints?: number;
from: number;
}
export interface Point {
/** x value */
x: number;
/** y value */
y: number;
/** point index */
index?: number;
}
export interface DataXReIm {
/** Array of x values */
x: DoubleArray;
/** Array of re values */
re: DoubleArray;
/** Array of im values */
im: DoubleArray;
}
export interface DataReIm {
/** Array of re values */
re: DoubleArray;
/** Array of im values */
im: DoubleArray;

@@ -117,0 +134,0 @@ }

@@ -93,3 +93,7 @@ export * from './x/xAbsolute';

export * from './matrix/matrixZRescale';
export * from './matrix/matrixClone';
export * from './matrix/matrixNumericalEncoding';
export * from './matrix/matrixNumericalDecoding';
export * from './matrix/matrixApplyNumericalEncoding';
export * from './utils/createSequentialArray';
//# sourceMappingURL=index.js.map

3

lib-esm/matrix/matrixCenterZMean.d.ts

@@ -5,6 +5,5 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/
export declare function matrixCenterZMean(matrix: DoubleMatrix): DoubleMatrix;
//# sourceMappingURL=matrixCenterZMean.d.ts.map
/**
* Center mean of columns
*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -7,0 +6,0 @@ export function matrixCenterZMean(matrix) {

@@ -5,6 +5,5 @@ import { DoubleMatrix } from '..';

*
* @param [A] - matrix [rows][cols]
* @returns result
* @param A - matrix [rows][cols]
*/
export declare function matrixColumnsCorrelation(A: DoubleMatrix): DoubleMatrix;
//# sourceMappingURL=matrixColumnsCorrelation.d.ts.map

@@ -6,4 +6,3 @@ import { Matrix } from 'ml-matrix';

*
* @param [A] - matrix [rows][cols]
* @returns result
* @param A - matrix [rows][cols]
*/

@@ -10,0 +9,0 @@ export function matrixColumnsCorrelation(A) {

@@ -6,24 +6,44 @@ import { DataXY } from 'cheminfo-types';

*
* @param [matrix] - matrix [rows][cols].
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axi
* @param [options.logBaseY] We can apply a log on the resulting histogra
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and
* @param options.histogram histogram
* @returns of the histogram
* @param matrix - matrix [rows][cols].
* @param options - options
* @returns - result of the histogram
*/
export declare function matrixHistogram(matrix: DoubleMatrix, options?: {
/**
* Center the X value. We will enlarge the first and
* @default true
* */
centerX?: boolean;
/**
* histogram
* */
histogram?: DataXY;
/**
* Number of slots
* @default 256
* */
nbSlots?: number;
/**
* We can first apply a log on x axis
* */
logBaseX?: number;
/**
* We can apply a log on the resulting histogram
*/
logBaseY?: number;
/**
* Take the absolute value
*/
absolute?: boolean;
/**
* Maximal value to calculate used to calculate slot size
* @default maxValue
* */
max?: number;
/**
* Minimum value to calculate used to calculate slot size
* @default minValue
* */
min?: number;
}): DataXY;
//# sourceMappingURL=matrixHistogram.d.ts.map

@@ -7,13 +7,5 @@ import { xHistogram } from '../x/xHistogram';

*
* @param [matrix] - matrix [rows][cols].
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axi
* @param [options.logBaseY] We can apply a log on the resulting histogra
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and
* @param options.histogram histogram
* @returns of the histogram
* @param matrix - matrix [rows][cols].
* @param options - options
* @returns - result of the histogram
*/

@@ -20,0 +12,0 @@ export function matrixHistogram(matrix, options = {}) {

@@ -5,4 +5,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns results
* @param matrix - matrix [rows][cols].
*/

@@ -9,0 +8,0 @@ export declare function matrixMinMaxAbsoluteZ(matrix: DoubleMatrix): {

/**
* Get min and max of the absolute values of Z
*
* @param [matrix] - matrix [rows][cols].
* @returns results
* @param matrix - matrix [rows][cols].
*/

@@ -7,0 +6,0 @@ export function matrixMinMaxAbsoluteZ(matrix) {

@@ -5,4 +5,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -9,0 +8,0 @@ export declare function matrixMinMaxZ(matrix: DoubleMatrix): {

/**
* Get min and max Z
*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -7,0 +6,0 @@ export function matrixMinMaxZ(matrix) {

@@ -8,7 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.max=100] - Normalization integral constant.
* @param options.min min
* @returns result
* @param matrix - matrix [rows][cols].
* @param options Options
* data: Normalized dataset.

@@ -18,3 +15,10 @@ * medianOfQuotients: The median of quotients of each variables.

export declare function matrixPQN(matrix: DoubleMatrix, options?: {
/**
* Normalization integral constant.
* @default 100
* */
max?: number;
/**
* min
*/
min?: number;

@@ -21,0 +25,0 @@ }): {

@@ -8,7 +8,4 @@ import median from 'ml-array-median';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.max=100] - Normalization integral constant.
* @param options.min min
* @returns result
* @param matrix - matrix [rows][cols].
* @param options Options
* data: Normalized dataset.

@@ -15,0 +12,0 @@ * medianOfQuotients: The median of quotients of each variables.

@@ -5,12 +5,17 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.min=0] min
* @param [options.max=1] max
* @returns result
* @param matrix - matrix [rows][cols].
* @param options - Options
*/
export declare function matrixZRescale(matrix: DoubleMatrix, options?: {
/**
* min
* @default 0
* */
min?: number;
/**
* max
* @default 1
* */
max?: number;
}): DoubleMatrix;
//# sourceMappingURL=matrixZRescale.d.ts.map
/**
* Rescale columns
*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.min=0] min
* @param [options.max=1] max
* @returns result
* @param matrix - matrix [rows][cols].
* @param options - Options
*/

@@ -10,0 +7,0 @@ export function matrixZRescale(matrix, options = {}) {

@@ -6,6 +6,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param data DATA
* @returns array of float
* @param data - DATA
* @returns - array of float
*/
export declare function reimAbsolute(data: DataReIm): DoubleArray;
//# sourceMappingURL=reimAbsolute.d.ts.map
/**
* Calculates reimAbsolute value of a complex spectrum
*
* @param data DATA
* @returns array of float
* @param data - DATA
* @returns - array of float
*/

@@ -7,0 +7,0 @@ export function reimAbsolute(data) {

@@ -5,2 +5,5 @@ import { DataReIm } from '../index';

* correction algorithm for high-resolution NMR data. 10.1002/mrc.4586
*
* @param data - DataReim.
* @param options - Options.
*/

@@ -7,0 +10,0 @@ export declare function reimAutoPhaseCorrection(data: DataReIm, options?: {

@@ -7,2 +7,5 @@ import { xNoiseSanPlot } from '../x/xNoiseSanPlot';

* correction algorithm for high-resolution NMR data. 10.1002/mrc.4586
*
* @param data - DataReim.
* @param options - Options.
*/

@@ -9,0 +12,0 @@ export function reimAutoPhaseCorrection(data, options = {}) {

@@ -7,4 +7,2 @@ import { DataReIm } from '..';

* @param options - Options.
* @param options.inverse -
* @param options.applyZeroShift -
* @returns DataReim.

@@ -11,0 +9,0 @@ */

@@ -8,4 +8,2 @@ import FFT from 'fft.js';

* @param options - Options.
* @param options.inverse -
* @param options.applyZeroShift -
* @returns DataReim.

@@ -12,0 +10,0 @@ */

@@ -6,7 +6,7 @@ import { DataReIm } from '..';

* @param data DataReIm
* @param [phi0=0] - Angle in radians for zero order phase correction
* @param [phi1=0] - Angle in radians for first order phase correction
* @returns returns a new object {re:[], im:[]}
* @param phi0 - Angle in radians for zero order phase correction
* @param phi1 - Angle in radians for first order phase correction
* @returns - returns a new object {re:[], im:[]}
*/
export declare function reimPhaseCorrection(data: DataReIm, phi0: number, phi1: number): DataReIm;
export declare function reimPhaseCorrection(data: DataReIm, phi0?: number, phi1?: number): DataReIm;
//# sourceMappingURL=reimPhaseCorrection.d.ts.map

@@ -5,7 +5,7 @@ /**

* @param data DataReIm
* @param [phi0=0] - Angle in radians for zero order phase correction
* @param [phi1=0] - Angle in radians for first order phase correction
* @returns returns a new object {re:[], im:[]}
* @param phi0 - Angle in radians for zero order phase correction
* @param phi1 - Angle in radians for first order phase correction
* @returns - returns a new object {re:[], im:[]}
*/
export function reimPhaseCorrection(data, phi0, phi1) {
export function reimPhaseCorrection(data, phi0 = 0, phi1 = 0) {
phi0 = Number.isFinite(phi0) ? phi0 : 0;

@@ -12,0 +12,0 @@ phi1 = Number.isFinite(phi1) ? phi1 : 0;

@@ -5,13 +5,16 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param options Options
* @param [options.from=0] from
* @param [options.to=1] to
* @param [options.length=1001] length
* @returns array of floats
* @param options - Options
* @param options.from - from
* @param options.to - to
* @param options.length - length
* @returns - array of floats
*/
export declare function createSequentialArray(options?: {
/**@default 0 */
from?: number;
/**@default 1 */
to?: number;
/**@default 1001 */
length?: number;
}): DoubleArray;
//# sourceMappingURL=createSequentialArray.d.ts.map
/**
* Create an array with sequential numbers between from and to of length
*
* @param options Options
* @param [options.from=0] from
* @param [options.to=1] to
* @param [options.length=1001] length
* @returns array of floats
* @param options - Options
* @param options.from - from
* @param options.to - to
* @param options.length - length
* @returns - array of floats
*/

@@ -10,0 +10,0 @@ export function createSequentialArray(options = {}) {

@@ -5,6 +5,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns absolute array
* @param array - array of number
* @returns - absolute array
*/
export declare function xAbsolute(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xAbsolute.d.ts.map
/**
* This function returns an array with absolute values
*
* @param array array of number
* @returns absolute array
* @param array - array of number
* @returns - absolute array
*/

@@ -7,0 +7,0 @@ export function xAbsolute(array) {

@@ -6,5 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns median
* @returns - median
*/
export declare function xAbsoluteMedian(array: DoubleArray): number;
//# sourceMappingURL=xAbsoluteMedian.d.ts.map

@@ -7,3 +7,3 @@ import median from 'ml-array-median';

* @param array - the array that will be rotated
* @returns median
* @returns - median
*/

@@ -10,0 +10,0 @@ export function xAbsoluteMedian(array) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 the second array
* @returns result
* @param array2 - the second array
*/
export declare function xAdd(array1: DoubleArray, array2: DoubleArray | number | Float32Array): DoubleArray;
//# sourceMappingURL=xAdd.d.ts.map

@@ -6,4 +6,3 @@ import { isAnyArray } from 'is-any-array';

* @param array1 - the array that will be rotated
* @param array2 the second array
* @returns result
* @param array2 - the second array
*/

@@ -10,0 +9,0 @@ export function xAdd(array1, array2) {

@@ -5,9 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - the array that will be fixed
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns result
* @param A - the array that will be fixed
* @param options - Options
*/
export declare function xAutoCorrelation(A: DoubleArray, options?: {}): DoubleArray;
export declare function xAutoCorrelation(A: DoubleArray, options?: {
/**
* sweep increment size (in number of points, min=1, max=A.length)
* @default 1
*/
tau?: number;
/**
* scalar lag parameter
* @default A.length-1
*/
lag?: number;
}): DoubleArray;
//# sourceMappingURL=xAutoCorrelation.d.ts.map

@@ -5,7 +5,4 @@ import { xCrossCorrelation } from './xCrossCorrelation';

*
* @param [A] - the array that will be fixed
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns result
* @param A - the array that will be fixed
* @param options - Options
*/

@@ -12,0 +9,0 @@ export function xAutoCorrelation(A, options = {}) {

@@ -6,3 +6,2 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns result
*/

@@ -9,0 +8,0 @@ export declare function xBoxPlot(array: DoubleArray): {

@@ -5,3 +5,2 @@ /**

* @param array - the array that will be rotated
* @returns result
*/

@@ -8,0 +7,0 @@ export function xBoxPlot(array) {

@@ -5,3 +5,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param input input
* @param input - input
*/

@@ -8,0 +8,0 @@ export declare function xCheck(input?: DoubleArray | Uint16Array): void;

@@ -5,3 +5,3 @@ import { isAnyArray } from 'is-any-array';

*
* @param input input
* @param input - input
*/

@@ -8,0 +8,0 @@ export function xCheck(input) {

@@ -6,7 +6,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - the array that will be rotated
* @param [B] sencond array
* @returns result
* @param A - the array that will be rotated
* @param B - sencond array
*/
export declare function xCorrelation(A: DoubleArray, B: DoubleArray): number;
//# sourceMappingURL=xCorrelation.d.ts.map

@@ -5,5 +5,4 @@ /**

*
* @param [A] - the array that will be rotated
* @param [B] sencond array
* @returns result
* @param A - the array that will be rotated
* @param B - sencond array
*/

@@ -10,0 +9,0 @@ export function xCorrelation(A, B) {

@@ -5,13 +5,18 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - fixed array
* @param [B] - sweeping array
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns results
* @param A - fixed array
* @param B - sweeping array
* @param options - Options
*/
export declare function xCrossCorrelation(A: DoubleArray, B: DoubleArray, options?: {
/**
* sweep increment size (in number of points, min=1, max=A.length)
* @default 1
* */
tau?: number;
/**
* scalar lag parameter
* @default A.length-1
* */
lag?: number;
}): DoubleArray;
//# sourceMappingURL=xCrossCorrelation.d.ts.map

@@ -5,8 +5,5 @@ import { xDotProduct } from './xDotProduct';

*
* @param [A] - fixed array
* @param [B] - sweeping array
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns results
* @param A - fixed array
* @param B - sweeping array
* @param options - Options
*/

@@ -13,0 +10,0 @@ export function xCrossCorrelation(A, B, options = {}) {

@@ -5,6 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array
* @returns result
* @param array - DoubleArray
*/
export declare function xCumulative(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xCumulative.d.ts.map

@@ -5,4 +5,3 @@ import { isAnyArray } from 'is-any-array';

*
* @param array array
* @returns result
* @param array - DoubleArray
*/

@@ -9,0 +8,0 @@ export function xCumulative(array) {

@@ -6,4 +6,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*

@@ -10,0 +9,0 @@ */

@@ -6,4 +6,3 @@ import { isAnyArray } from 'is-any-array';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*

@@ -10,0 +9,0 @@ */

@@ -7,5 +7,4 @@ import { DoubleArray } from 'cheminfo-types';

* @param B - Second array.
* @returns Result.
*/
export declare function xDotProduct(A: DoubleArray, B: DoubleArray): number;
//# sourceMappingURL=xDotProduct.d.ts.map

@@ -7,3 +7,2 @@ import { xMultiply } from './xMultiply';

* @param B - Second array.
* @returns Result.
*/

@@ -10,0 +9,0 @@ export function xDotProduct(A, B) {

@@ -5,5 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param target target
* @returns closest index
* @param array - array of numbers
* @param target - target
* @returns - closest index
*/

@@ -10,0 +10,0 @@ export declare function xFindClosestIndex(array: DoubleArray, target: number, options?: {

/**
* Returns the closest index of a `target`
*
* @param array array of numbers
* @param target target
* @returns closest index
* @param array - array of numbers
* @param target - target
* @returns - closest index
*/

@@ -8,0 +8,0 @@ export function xFindClosestIndex(array, target, options = {}) {

@@ -5,14 +5,23 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param x array of numbers
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param x - array of numbers
* @param options - Options
*/
export declare function xGetFromToIndex(x: DoubleArray, options?: {
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* First value for xyIntegration in the X scale
* */
from?: number;
/**
* Last value for xyIntegration in the X scale
* */
to?: number;

@@ -19,0 +28,0 @@ }): {

@@ -5,9 +5,4 @@ import { xFindClosestIndex } from './xFindClosestIndex';

*
* @param x array of numbers
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param x - array of numbers
* @param options - Options
*/

@@ -14,0 +9,0 @@ export function xGetFromToIndex(x, options = {}) {

@@ -5,12 +5,12 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [x] array of numbers
* @param [options={}] options
* @param [options.target] target
* @param [options.targetIndex=0] targetindex
*@returns results
* @param x - array of numbers
* @param options - options
*/
export declare function xGetTargetIndex(x: DoubleArray, options?: {
target?: number;
/**
* @default 0
*/
targetIndex?: number;
}): number;
//# sourceMappingURL=xGetTargetIndex.d.ts.map

@@ -5,7 +5,4 @@ import { xFindClosestIndex } from './xFindClosestIndex';

*
* @param [x] array of numbers
* @param [options={}] options
* @param [options.target] target
* @param [options.targetIndex=0] targetindex
*@returns results
* @param x - array of numbers
* @param options - options
*/

@@ -12,0 +9,0 @@ export function xGetTargetIndex(x, options = {}) {

@@ -5,24 +5,45 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

*
* @param [array] Array containing values
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axis
* @param [options.logBaseY] We can apply a log on the resulting histogram
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and last values.
* @param [options.histogram={x:[], y:[]}] Previously existing histogram to continue to fill
* @returns of the histogram
* @param array - Array containing values
* @param options - options
* @returns - result of the histogram
*/
export declare function xHistogram(array: DoubleArray, options?: {
/**
* Center the X value. We will enlarge the first and
* @default true
* */
centerX?: boolean;
/**
* Previously existing histogram to continue to fill
* @default {x:[],y:[]}
* */
histogram?: DataXY;
/**
* Number of slots
* @default 256
* */
nbSlots?: number;
/**
* We can first apply a log on x axis
* */
logBaseX?: number;
/**
* We can apply a log on the resulting histogram
*/
logBaseY?: number;
/**
* Take the absolute value
*/
absolute?: boolean;
/**
* Maximal value to calculate used to calculate slot size
* @default maxValue
* */
max?: number;
/**
* Minimum value to calculate used to calculate slot size
* @default minValue
* */
min?: number;
}): DataXY;
//# sourceMappingURL=xHistogram.d.ts.map

@@ -9,13 +9,5 @@ import fill from 'ml-array-sequential-fill';

*
* @param [array] Array containing values
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axis
* @param [options.logBaseY] We can apply a log on the resulting histogram
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and last values.
* @param [options.histogram={x:[], y:[]}] Previously existing histogram to continue to fill
* @returns of the histogram
* @param array - Array containing values
* @param options - options
* @returns - result of the histogram
*/

@@ -22,0 +14,0 @@ export function xHistogram(array, options = {}) {

@@ -5,6 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/
export declare function xIsMonotone(array: DoubleArray): boolean;
//# sourceMappingURL=xIsMonotone.d.ts.map
/**
* Returns true if x is monotone
*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/

@@ -7,0 +6,0 @@ export function xIsMonotone(array) {

@@ -5,6 +5,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns indexe
* @param array - array of numbers
* @returns - indexe
*/
export declare function xMaxIndex(array: DoubleArray | Uint16Array): number;
//# sourceMappingURL=xMaxIndex.d.ts.map

@@ -5,4 +5,4 @@ import { xCheck } from './xCheck';

*
* @param array array of numbers
* @returns indexe
* @param array - array of numbers
* @returns - indexe
*/

@@ -9,0 +9,0 @@ export function xMaxIndex(array) {

@@ -5,12 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of number
* @param options - options
*/
export declare function xMaxValue(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xMaxValue.d.ts.map

@@ -5,7 +5,4 @@ import { xCheck } from './xCheck';

*
* @param array array of number
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of number
* @param options - options
*/

@@ -12,0 +9,0 @@ export function xMaxValue(array, options = {}) {

@@ -5,12 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/
export declare function xMean(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xMean.d.ts.map

@@ -5,7 +5,4 @@ import { xCheck } from './xCheck';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/

@@ -12,0 +9,0 @@ export function xMean(array, options = {}) {

@@ -5,7 +5,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array1 -first array
* @param array2 second array
* @returns result
* @param array1 - first array
* @param array2 - second array
*/
export declare function xMeanAbsoluteError(array1: DoubleArray, array2: DoubleArray): number;
//# sourceMappingURL=xMeanAbsoluteError.d.ts.map

@@ -5,5 +5,4 @@ import { xCheckLengths } from './xCheck';

*
* @param array1 -first array
* @param array2 second array
* @returns result
* @param array1 - first array
* @param array2 - second array
*/

@@ -10,0 +9,0 @@ export function xMeanAbsoluteError(array1, array2) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 -first array
* @param array2 second array
* @returns result
* @param array2 - second array
*/
export declare function xMeanSquaredError(array1: DoubleArray, array2: DoubleArray): number;
//# sourceMappingURL=xMeanSquaredError.d.ts.map

@@ -6,4 +6,3 @@ import { xCheckLengths } from './xCheck';

* @param array1 -first array
* @param array2 second array
* @returns result
* @param array2 - second array
*/

@@ -10,0 +9,0 @@ export function xMeanSquaredError(array1, array2) {

@@ -5,6 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/
export declare function xMinIndex(array: DoubleArray | Uint16Array): number;
//# sourceMappingURL=xMinIndex.d.ts.map

@@ -5,4 +5,3 @@ import { xCheck } from './xCheck';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/

@@ -9,0 +8,0 @@ export function xMinIndex(array) {

@@ -5,4 +5,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns Object with 2 properties, min and max
* @param array - array of number
* @returns - Object with 2 properties, min and max
*/

@@ -9,0 +9,0 @@ export declare function xMinMaxValues(array: DoubleArray | Uint16Array): {

@@ -5,4 +5,4 @@ import { xCheck } from './xCheck';

*
* @param array array of number
* @returns Object with 2 properties, min and max
* @param array - array of number
* @returns - Object with 2 properties, min and max
*/

@@ -9,0 +9,0 @@ export function xMinMaxValues(array) {

@@ -5,12 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/
export declare function xMinValue(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xMinValue.d.ts.map

@@ -5,7 +5,4 @@ import { xCheck } from './xCheck';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/

@@ -12,0 +9,0 @@ export function xMinValue(array, options = {}) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 --second array
* @returns array of result
* @param array2 - second array
*/
export declare function xMultiply(array1: DoubleArray, array2: DoubleArray | number): DoubleArray;
//# sourceMappingURL=xMultiply.d.ts.map

@@ -6,4 +6,3 @@ import { isAnyArray } from 'is-any-array';

* @param array1 - the array that will be rotated
* @param array2 --second array
* @returns array of result
* @param array2 - second array
*/

@@ -10,0 +9,0 @@ export function xMultiply(array1, array2) {

@@ -6,26 +6,38 @@ import { DataXY, FromTo, DoubleArray } from 'cheminfo-types';

* @param data - real or magnitude spectra data.
* @param [options = {}] options
* @param [options.mask] - boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
* @param [options.scaleFactor=1] - factor to scale the data input[i]*=scaleFactor.
* @param [options.cutOff] - percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
* @param [options.factorStd=5] - factor times std to determine what will be marked as signals.
* @param [options.refine=true] - if true the noise level will be recalculated get out the signals using factorStd.
* @param [options.fixOffset=true] - If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @param [options.logBaseY=2] - log scale to apply in the intensity axis in order to avoid big numbers.
* @param options.magnitudeMode -
* @param options.considerList -
* @param options.considerList.from -
* @param options.considerList.step -
* @param options.considerList.to -
* @param options.fromTo -
* @returns result
* @param options - options
*/
export declare function xNoiseSanPlot(data: DoubleArray, options?: {
/**
* boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
*/
mask?: DoubleArray;
/**
* percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
*/
cutOff?: number;
/**
* true the noise level will be recalculated get out the signals using factorStd.
* @default true
*/
refine?: boolean;
magnitudeMode?: boolean;
/**
* factor to scale the data input[i]*=scaleFactor.
* @default 1
*/
scaleFactor?: number;
/**
* factor times std to determine what will be marked as signals.
* @default 5
*/
factorStd?: number;
/**
* If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @default true
*/
fixOffset?: boolean;
/**
* log scale to apply in the intensity axis in order to avoid big numbers.
* @default 2
*/
logBaseY?: number;

@@ -32,0 +44,0 @@ considerList?: {

import fill from 'ml-array-sequential-fill';
// @ts-ignore
// @ts-expect-error javascript package used
import SplineInterpolator from 'spline-interpolator';

@@ -10,17 +10,3 @@ import erfcinv from './erfcinv';

* @param data - real or magnitude spectra data.
* @param [options = {}] options
* @param [options.mask] - boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
* @param [options.scaleFactor=1] - factor to scale the data input[i]*=scaleFactor.
* @param [options.cutOff] - percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
* @param [options.factorStd=5] - factor times std to determine what will be marked as signals.
* @param [options.refine=true] - if true the noise level will be recalculated get out the signals using factorStd.
* @param [options.fixOffset=true] - If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @param [options.logBaseY=2] - log scale to apply in the intensity axis in order to avoid big numbers.
* @param options.magnitudeMode -
* @param options.considerList -
* @param options.considerList.from -
* @param options.considerList.step -
* @param options.considerList.to -
* @param options.fromTo -
* @returns result
* @param options - options
*/

@@ -27,0 +13,0 @@ export function xNoiseSanPlot(data, options = {}) {

@@ -7,5 +7,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns calculated norm
* @returns - calculated norm
*/
export declare function xNorm(array: DoubleArray): number;
//# sourceMappingURL=xNorm.d.ts.map

@@ -6,3 +6,3 @@ /**

* @param array - the array that will be rotated
* @returns calculated norm
* @returns - calculated norm
*/

@@ -9,0 +9,0 @@ export function xNorm(array) {

@@ -7,13 +7,21 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be padded
* @param [options={}] options
* @param [options.algorithm=''] '', value, circular, duplicate
* @param [options.size=0] padding size before first element and after last element
* @param [options.value=0] value to use for padding (if algorithm='value')
* @returns result
* @param options - options
*/
export declare function xPadding(array: DoubleArray, options?: {
/**
* padding size before first element and after last element
* @default 0
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
}): DoubleArray;
//# sourceMappingURL=xPadding.d.ts.map

@@ -7,7 +7,3 @@ import { xCheck } from './xCheck';

* @param array - the array that will be padded
* @param [options={}] options
* @param [options.algorithm=''] '', value, circular, duplicate
* @param [options.size=0] padding size before first element and after last element
* @param [options.value=0] value to use for padding (if algorithm='value')
* @returns result
* @param options - options
*/

@@ -14,0 +10,0 @@ export function xPadding(array, options = {}) {

@@ -7,6 +7,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns result
* @param array - array of number
*/
export declare function xParetoNormalization(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xParetoNormalization.d.ts.map

@@ -8,4 +8,3 @@ import sd from 'ml-array-standard-deviation';

*
* @param array array of number
* @returns result
* @param array - array of number
*/

@@ -12,0 +11,0 @@ export function xParetoNormalization(array) {

@@ -6,19 +6,32 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param fct callback function that from an array returns a value.
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=0] none, value, circular, duplicate
* @param [options.padding.algorithm='value'] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param fct - callback function that from an array returns a value.
* @param options - options
*/
export declare function xRolling(array: DoubleArray, fct?: (array: DoubleArray) => number, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default 0
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default 'value'
*/
algorithm?: string;
value?: number;
};
}): DoubleArray;
//# sourceMappingURL=xRolling.d.ts.map

@@ -7,10 +7,4 @@ import { xCheck } from './xCheck';

* @param array - the array that will be rotated
* @param fct callback function that from an array returns a value.
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=0] none, value, circular, duplicate
* @param [options.padding.algorithm='value'] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param fct - callback function that from an array returns a value.
* @param options - options
*/

@@ -17,0 +11,0 @@ export function xRolling(array, fct, options = {}) {

@@ -6,11 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param options - option
*/
export declare function xRollingAverage(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingAverage(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingAverage.d.ts.map

@@ -7,9 +7,3 @@ import mean from 'ml-array-mean';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param options - option
*/

@@ -16,0 +10,0 @@ export function xRollingAverage(array, options = {}) {

@@ -6,10 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export declare function xRollingMax(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingMax(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingMax.d.ts.map

@@ -7,8 +7,3 @@ import max from 'ml-array-max';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/

@@ -15,0 +10,0 @@ export function xRollingMax(array, options = {}) {

@@ -6,10 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export declare function xRollingMedian(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingMedian(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingMedian.d.ts.map

@@ -7,8 +7,3 @@ import median from 'ml-array-median';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/

@@ -15,0 +10,0 @@ export function xRollingMedian(array, options = {}) {

@@ -6,10 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export declare function xRollingMin(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingMin(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingMin.d.ts.map

@@ -7,8 +7,3 @@ import min from 'ml-array-min';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/

@@ -15,0 +10,0 @@ export function xRollingMin(array, options = {}) {

@@ -9,6 +9,6 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param shift number
* @returns array of float
* @param shift - number
* @returns - array of float
*/
export declare function xRotate(array: DoubleArray, shift: number): DoubleArray;
//# sourceMappingURL=xRotate.d.ts.map

@@ -8,4 +8,4 @@ /**

* @param array - the array that will be rotated
* @param shift number
* @returns array of float
* @param shift - number
* @returns - array of float
*/

@@ -12,0 +12,0 @@ export function xRotate(array, shift) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*/
export declare function xSubtract(array1: DoubleArray | Float32Array, array2: DoubleArray | number): DoubleArray;
//# sourceMappingURL=xSubtract.d.ts.map

@@ -6,4 +6,3 @@ import { isAnyArray } from 'is-any-array';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*/

@@ -10,0 +9,0 @@ export function xSubtract(array1, array2) {

@@ -5,12 +5,18 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [array={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param [options={}] - Options.
* @param [options.fromIndex=0] - First point for xSum.
* @param [options.toIndex=x.length-1] - Last point for xSum.
* @param array - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns XSum value on the specified range.
*/
export declare function xSum(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xSum.
* @default 0
*/
fromIndex?: number;
/**
* Last point for xSum.
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xSum.d.ts.map

@@ -5,6 +5,4 @@ import { xCheck } from './xCheck';

*
* @param [array={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param [options={}] - Options.
* @param [options.fromIndex=0] - First point for xSum.
* @param [options.toIndex=x.length-1] - Last point for xSum.
* @param array - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns XSum value on the specified range.

@@ -11,0 +9,0 @@ */

@@ -6,5 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - Array of number.
* @returns Sorted array.
* @returns - Sorted array.
*/
export declare function xUniqueSorted(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xUniqueSorted.d.ts.map

@@ -5,3 +5,3 @@ /**

* @param array - Array of number.
* @returns Sorted array.
* @returns - Sorted array.
*/

@@ -8,0 +8,0 @@ export function xUniqueSorted(array) {

@@ -6,5 +6,5 @@ import { DataXReIm } from '..';

* @param data - Object of kind {x:[], re:[], im:[]}.
* @returns Data.
* @returns - Data.
*/
export declare function xreimSortX(data: DataXReIm): DataXReIm;
//# sourceMappingURL=xreimSortX.d.ts.map

@@ -5,3 +5,3 @@ /**

* @param data - Object of kind {x:[], re:[], im:[]}.
* @returns Data.
* @returns - Data.
*/

@@ -8,0 +8,0 @@ export function xreimSortX(data) {

@@ -7,5 +7,5 @@ import { DataXReIm } from '..';

* @param totalLength - Final number of points.
* @returns Data.
* @returns - Data.
*/
export declare function xreimZeroFilling(data: DataXReIm, totalLength: number): DataXReIm;
//# sourceMappingURL=xreimZeroFilling.d.ts.map

@@ -6,3 +6,3 @@ /**

* @param totalLength - Final number of points.
* @returns Data.
* @returns - Data.
*/

@@ -9,0 +9,0 @@ export function xreimZeroFilling(data, totalLength) {

@@ -7,13 +7,19 @@ import { DataXY } from 'cheminfo-types';

*
* @param data1 First spectrum data
* @param data2 Second spectrum data
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @param [options.common=true] If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @param [options.x='x1'] Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @returns result
* @param data1 - First spectrum data
* @param data2 - Second spectrum data
* @param options - Options
*/
export declare function xyAlign(data1: DataXY, data2: DataXY, options?: {
/**The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
/**If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @default true
*/
common?: boolean;
/** Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @default "x1"
* */
x?: string;

@@ -20,0 +26,0 @@ }): {

@@ -6,9 +6,6 @@ /**

*
* @param data1 First spectrum data
* @param data2 Second spectrum data
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @param [options.common=true] If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @param [options.x='x1'] Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @returns result
* @param data1 - First spectrum data
* @param data2 - Second spectrum data
* @param options - Options
*/

@@ -15,0 +12,0 @@ export function xyAlign(data1, data2, options = {}) {

import { DataXYZ } from '..';
/**
* Throw an error in no an object of x,y arrays
*
* @param data - array of points {x,y,z}
*/
export declare function xyCheck(data?: DataXYZ): void;
//# sourceMappingURL=xyCheck.d.ts.map
import { isAnyArray } from 'is-any-array';
/**
* Throw an error in no an object of x,y arrays
*
* @param data - array of points {x,y,z}
*/

@@ -5,0 +7,0 @@ export function xyCheck(data = {}) {

@@ -5,3 +5,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] array of points {x,y}
* @param data - array of points {x,y}
* @returns x0, x25, x50, x75, x100, mode (x for maxY)

@@ -8,0 +8,0 @@ */

@@ -9,3 +9,3 @@ import max from 'ml-array-max';

*
* @param [data] array of points {x,y}
* @param data - array of points {x,y}
* @returns x0, x25, x50, x75, x100, mode (x for maxY)

@@ -12,0 +12,0 @@ */

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
/**
* Filters x,y values to allow strictly growing values in x axis.
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @returns Result.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
*/
export declare function xyEnsureGrowingX(data?: DataXYZ): DataXY;
export declare function xyEnsureGrowingX(data: DataXY): DataXY;
//# sourceMappingURL=xyEnsureGrowingX.d.ts.map

@@ -5,6 +5,6 @@ import { xyCheck } from './xyCheck';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @returns Result.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
*/
export function xyEnsureGrowingX(data = {}) {
export function xyEnsureGrowingX(data) {
xyCheck(data);

@@ -11,0 +11,0 @@ if (data.x === undefined || data.y === undefined)

import { DataXY } from 'cheminfo-types';
import { DataXYZ, Zone } from '..';
import { Zone } from '..';
/**
* XyExtract zones from a XY data
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.zones=[]] zones
* @returns Array of points
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Array of points
*/
export declare function xyExtract(data?: DataXYZ, options?: {
export declare function xyExtract(data: DataXY, options?: {
zones?: Zone[];
}): DataXY;
//# sourceMappingURL=xyExtract.d.ts.map

@@ -6,8 +6,7 @@ import { zonesNormalize } from '../zones/zonesNormalize';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.zones=[]] zones
* @returns Array of points
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Array of points
*/
export function xyExtract(data = {}, options = {}) {
export function xyExtract(data, options = {}) {
xyCheck(data);

@@ -14,0 +13,0 @@ const { x, y } = data;

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
/**
* Filter out all the points for which x <= 0. Useful to display log scale data
*
* @param [data={}] data
* @returns An object with the filtered data
* @param data - data
* @returns - An object with the filtered data
*/
export declare function xyFilterXPositive(data?: DataXYZ): DataXY;
export declare function xyFilterXPositive(data: DataXY): DataXY;
//# sourceMappingURL=xyFilterXPositive.d.ts.map

@@ -5,6 +5,6 @@ import { xyCheck } from './xyCheck';

*
* @param [data={}] data
* @returns An object with the filtered data
* @param data - data
* @returns - An object with the filtered data
*/
export function xyFilterXPositive(data = {}) {
export function xyFilterXPositive(data) {
xyCheck(data);

@@ -11,0 +11,0 @@ const { x, y } = data;

@@ -7,5 +7,5 @@ import { DataXY } from 'cheminfo-types';

* @param numberMaxPoints - Number of points to keep.
* @returns The points filtered to keep the `numberMaxPoints` most intense points of the input.
* @returns - The points filtered to keep the `numberMaxPoints` most intense points of the input.
*/
export declare function xyGetNMaxY(data: DataXY, numberMaxPoints: number): DataXY;
//# sourceMappingURL=xyGetNMaxY.d.ts.map

@@ -7,3 +7,3 @@ import { xyCheck } from './xyCheck';

* @param numberMaxPoints - Number of points to keep.
* @returns The points filtered to keep the `numberMaxPoints` most intense points of the input.
* @returns - The points filtered to keep the `numberMaxPoints` most intense points of the input.
*/

@@ -10,0 +10,0 @@ export function xyGetNMaxY(data, numberMaxPoints) {

@@ -6,6 +6,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param data Object of kind {x:[], y:[]}.
* @returns result
* @param data - Object of kind {x:[], y:[]}.
*/
export declare function xyGrowingX(data: DataXY): DataXY;
//# sourceMappingURL=xyGrowingX.d.ts.map

@@ -5,4 +5,3 @@ /**

*
* @param data Object of kind {x:[], y:[]}.
* @returns result
* @param data - Object of kind {x:[], y:[]}.
*/

@@ -9,0 +8,0 @@ export function xyGrowingX(data) {

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
/**
* Generate a X / Y of the xyIntegral
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @param [options.reverse=false] - Integrate from the larger value to the smallest value
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export declare function xyIntegral(data?: DataXYZ, options?: {
export declare function xyIntegral(data: DataXY, options?: {
/**
* Integrate from the larger value to the smallest value
* @default false
* */
reverse?: boolean;
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;
}): DataXY | number;
//# sourceMappingURL=xyIntegral.d.ts.map

@@ -6,12 +6,7 @@ import { xGetFromToIndex } from '../x/xGetFromToIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @param [options.reverse=false] - Integrate from the larger value to the smallest value
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export function xyIntegral(data = {}, options = {}) {
export function xyIntegral(data, options = {}) {
const { reverse = false } = options;

@@ -18,0 +13,0 @@ xyCheck(data);

@@ -1,14 +0,10 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**
* Calculate integration
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns xyIntegration value on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - xyIntegration value on the specified range
*/
export declare function xyIntegration(data?: DataXYZ, options?: {}): number;
export declare function xyIntegration(data: DataXY, options?: {}): number;
//# sourceMappingURL=xyIntegration.d.ts.map

@@ -6,11 +6,7 @@ import { xGetFromToIndex } from '../x/xGetFromToIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns xyIntegration value on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - xyIntegration value on the specified range
*/
export function xyIntegration(data = {}, options = {}) {
export function xyIntegration(data, options = {}) {
xyCheck(data);

@@ -17,0 +13,0 @@ const { x, y } = data;

import { DataXY } from 'cheminfo-types';
import { DataXYZ, OptionsType } from '..';
/**

@@ -7,8 +6,13 @@ * Join x / y values when difference in X is closer than delta.

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export declare function xyJoinX(data?: DataXYZ, options?: OptionsType): DataXY;
export declare function xyJoinX(data: DataXY, options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): DataXY;
//# sourceMappingURL=xyJoinX.d.ts.map

@@ -6,8 +6,7 @@ import { xyCheck } from './xyCheck';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export function xyJoinX(data = {}, options = {}) {
export function xyJoinX(data, options = {}) {
xyCheck(data);

@@ -14,0 +13,0 @@ const { delta = 1 } = options;

@@ -5,10 +5,9 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/
export declare function xyMaxClosestYPoint(data: DataXY, options?: {
target?: number;
/**@default 0 */
targetIndex?: number;

@@ -15,0 +14,0 @@ }): {

@@ -6,7 +6,5 @@ import { xFindClosestIndex } from '../x/xFindClosestIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -13,0 +11,0 @@ export function xyMaxClosestYPoint(data, options = {}) {

@@ -7,7 +7,7 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns - Array of points.
*/
export declare function xyMaximaY(data?: DataXYZ, _options?: {}): {
export declare function xyMaximaY(data?: DataXYZ, options?: {}): {
x: number;

@@ -14,0 +14,0 @@ y: number;

@@ -7,8 +7,8 @@ import { xyCheck } from './xyCheck';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns - Array of points.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
export function xyMaximaY(data = {}, _options = {}) {
export function xyMaximaY(data = {}, options = {}) {
xyCheck(data);

@@ -15,0 +15,0 @@ const { x, y } = data;

@@ -5,16 +5,26 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns Max y on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - Max y on the specified range
*/
export declare function xyMaxY(data?: DataXYZ, options?: {
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;
}): number;
//# sourceMappingURL=xyMaxY.d.ts.map

@@ -6,9 +6,5 @@ import { xGetFromToIndex } from '../x/xGetFromToIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns Max y on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - Max y on the specified range
*/

@@ -15,0 +11,0 @@ export function xyMaxY(data = {}, options = {}) {

@@ -5,17 +5,23 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param data.x x
* @param data.y y
* @param data.z z
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
*/
export declare function xyMaxYPoint(data?: DataXYZ, options?: {
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;

@@ -22,0 +28,0 @@ }): {

@@ -6,12 +6,4 @@ import { xGetFromToIndex } from '../x/xGetFromToIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param data.x x
* @param data.y y
* @param data.z z
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
*/

@@ -18,0 +10,0 @@ export function xyMaxYPoint(data = {}, options = {}) {

@@ -5,6 +5,6 @@ import { DataXY } from 'cheminfo-types';

*
* @param data x should be sorted in increasing order
* @returns the median of x values
* @param data - x should be sorted in increasing order
* @returns - the median of x values
*/
export declare function xyMedian(data: DataXY): number;
//# sourceMappingURL=xyMedian.d.ts.map
/**
* Finds the median x value for an object with properties x and y (arrays of the same length)
*
* @param data x should be sorted in increasing order
* @returns the median of x values
* @param data - x should be sorted in increasing order
* @returns - the median of x values
*/

@@ -7,0 +7,0 @@ export function xyMedian(data) {

@@ -5,10 +5,9 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
* @returns - An object with the x/y value
*/
export declare function xyMinClosestYPoint(data: DataXY, options?: {
target?: number;
/**@default 0 */
targetIndex?: number;

@@ -15,0 +14,0 @@ }): {

@@ -6,7 +6,5 @@ import { xFindClosestIndex } from '../x/xFindClosestIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
* @returns - An object with the x/y value
*/

@@ -13,0 +11,0 @@ export function xyMinClosestYPoint(data, options = {}) {

@@ -1,2 +0,2 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**

@@ -7,10 +7,7 @@ * Finds all the min values

*
* @param [data={}] - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param data.x - X.
* @param data.y - Y.
* @param data.z - Z.
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param options - Options.
* @returns - Array of points.
*/
export declare function xyMinimaY(data?: DataXYZ, _options?: {}): {
export declare function xyMinimaY(data: DataXY, options?: {}): {
x: number;

@@ -17,0 +14,0 @@ y: number;

@@ -7,11 +7,8 @@ import { xyCheck } from './xyCheck';

*
* @param [data={}] - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param data.x - X.
* @param data.y - Y.
* @param data.z - Z.
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param options - Options.
* @returns - Array of points.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
export function xyMinimaY(data = {}, _options = {}) {
export function xyMinimaY(data, options = {}) {
xyCheck(data);

@@ -18,0 +15,0 @@ const { x, y } = data;

@@ -1,14 +0,9 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**
* Finds the max y value in a range and return a {x,y} point
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
*/
export declare function xyMinYPoint(data?: DataXYZ, options?: {}): 0 | {
export declare function xyMinYPoint(data: DataXY, options?: {}): 0 | {
x: number;

@@ -15,0 +10,0 @@ y: number;

@@ -6,11 +6,6 @@ import { xGetFromToIndex } from '../x/xGetFromToIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
*/
export function xyMinYPoint(data = {}, options = {}) {
export function xyMinYPoint(data, options = {}) {
xyCheck(data);

@@ -17,0 +12,0 @@ const { x, y } = data;

@@ -1,2 +0,2 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**

@@ -12,9 +12,7 @@ * Returns an information about a signal.

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex] number
* @returns Information about signal
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Information about signal
*/
export declare function xyPeakInfo(data?: DataXYZ, options?: {
export declare function xyPeakInfo(data: DataXY, options?: {
targetIndex?: number;

@@ -21,0 +19,0 @@ target?: number;

@@ -13,9 +13,7 @@ import { xFindClosestIndex } from '../x/xFindClosestIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex] number
* @returns Information about signal
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Information about signal
*/
export function xyPeakInfo(data = {}, options = {}) {
export function xyPeakInfo(data, options = {}) {
xyCheck(data);

@@ -22,0 +20,0 @@ const { x, y } = data;

@@ -5,7 +5,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -12,0 +10,0 @@ export declare function xyRealMaxYPoint(data: DataXY, options?: {}): {

@@ -6,7 +6,5 @@ import { xGetTargetIndex } from '../x/xGetTargetIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -13,0 +11,0 @@ export function xyRealMaxYPoint(data, options = {}) {

@@ -7,3 +7,2 @@ import { DataXY } from 'cheminfo-types';

* @param options - Options.
* @returns Results.
*/

@@ -10,0 +9,0 @@ export declare function xyRealMinYPoint(data: DataXY, options?: {}): {

@@ -8,3 +8,2 @@ import { xGetTargetIndex } from '../x/xGetTargetIndex';

* @param options - Options.
* @returns Results.
*/

@@ -11,0 +10,0 @@ export function xyRealMinYPoint(data, options = {}) {

@@ -9,18 +9,25 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.from=x[0]] number
* @param [options.to=x[x.length-1]] number
* @param [options.nbPoints=4001] Number of points
* @param [options.zones=[]] Array of zones to keep (from/to object)
* @param [options.optimize=false] If optimize we may have less than nbPoints at the end
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
*/
export declare function xyReduce(data: DataXY, options?: {
/**@default x[0] */
from?: number;
/**@default x[x.length-1] */
to?: number;
/**
* Number of points
* @default 4001
* */
nbPoints?: number;
/**
* If optimize we may have less than nbPoints at the end
* @default false
* */
optimize?: boolean;
/**Array of zones to keep (from/to object)
* @default []
* */
zones?: Zone[];
}): DataXY;
//# sourceMappingURL=xyReduce.d.ts.map

@@ -10,10 +10,4 @@ import { xFindClosestIndex } from '../x/xFindClosestIndex';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.from=x[0]] number
* @param [options.to=x[x.length-1]] number
* @param [options.nbPoints=4001] Number of points
* @param [options.zones=[]] Array of zones to keep (from/to object)
* @param [options.optimize=false] If optimize we may have less than nbPoints at the end
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
*/

@@ -20,0 +14,0 @@ export function xyReduce(data, options = {}) {

@@ -7,8 +7,7 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

*
* @param [points] array of points {x,y}
* @param [fct] callback function that from an array returns a value.
* @param options options
* @returns results
* @param points - array of points {x,y}
* @param fct - callback function that from an array returns a value.
* @param options - options
*/
export declare function xyRolling(points: DataXY, fct?: (array: DoubleArray) => number, options?: {}): DataXY;
//# sourceMappingURL=xyRolling.d.ts.map

@@ -8,6 +8,5 @@ import { xRolling } from '../x/xRolling';

*
* @param [points] array of points {x,y}
* @param [fct] callback function that from an array returns a value.
* @param options options
* @returns results
* @param points - array of points {x,y}
* @param fct - callback function that from an array returns a value.
* @param options - options
*/

@@ -14,0 +13,0 @@ export function xyRolling(points, fct, options = {}) {

@@ -5,6 +5,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] - Object that contains property x (Array) and y (Array).
* @returns Results.
* @param data - Object that contains property x (Array) and y (Array).
*/
export declare function xySortX(data: DataXY): DataXY;
//# sourceMappingURL=xySortX.d.ts.map

@@ -5,4 +5,3 @@ import { xIsMonotone } from '../x/xIsMonotone';

*
* @param [data] - Object that contains property x (Array) and y (Array).
* @returns Results.
* @param data - Object that contains property x (Array) and y (Array).
*/

@@ -9,0 +8,0 @@ export function xySortX(data) {

@@ -6,6 +6,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] - Array of points {x,y}.
* @returns Results.
* @param data - Array of points {x,y}.
*/
export declare function xyToXYObject(data: DataXY): Point[];
//# sourceMappingURL=xyToXYObject.d.ts.map

@@ -5,4 +5,3 @@ import { xyCheck } from './xyCheck';

*
* @param [data] - Array of points {x,y}.
* @returns Results.
* @param data - Array of points {x,y}.
*/

@@ -9,0 +8,0 @@ export function xyToXYObject(data) {

@@ -5,12 +5,17 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] Object that contains property x (Array) and y (Array)
* @param [options={}] Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
* @param [options.algorithm='average'] either 'average' or 'sum'
* @param [options.isSorted=true] if false the DataXY has to be sorted first
* @returns result
* @param data - Object that contains property x (Array) and y (Array)
* @param options - Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
*/
export declare function xyUniqueX(data: DataXY, options?: {
/**
* either 'average' or 'sum'
* @default 'average'
* */
algorithm?: string;
/**
* if false the DataXY has to be sorted first
* @default true
* */
isSorted?: boolean;
}): DataXY;
//# sourceMappingURL=xyUniqueX.d.ts.map

@@ -6,7 +6,4 @@ import { xyCheck } from './xyCheck';

*
* @param [data] Object that contains property x (Array) and y (Array)
* @param [options={}] Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
* @param [options.algorithm='average'] either 'average' or 'sum'
* @param [options.isSorted=true] if false the DataXY has to be sorted first
* @returns result
* @param data - Object that contains property x (Array) and y (Array)
* @param options - Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
*/

@@ -13,0 +10,0 @@ export function xyUniqueX(data, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '../..';
/**

@@ -8,5 +7,10 @@ * GetSlots.

* @param options - Options.
* @returns Result.
*/
export declare function getSlots(spectra: DataXY[], options?: OptionsType): {
export declare function getSlots(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
from: number;

@@ -13,0 +17,0 @@ to: number;

@@ -6,3 +6,2 @@ /**

* @param options - Options.
* @returns Result.
*/

@@ -9,0 +8,0 @@ export function getSlots(spectra, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '../..';
/**

@@ -8,6 +7,10 @@ * GetSlotsToFirst.

* @param options - Options.
* @param options.delta - Delta.
* @returns Result.
*/
export declare function getSlotsToFirst(spectra: DataXY[], options?: OptionsType): {
export declare function getSlotsToFirst(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
from: number;

@@ -14,0 +17,0 @@ to: number;

@@ -7,4 +7,2 @@ import { xyArrayWeightedMerge } from '../xyArrayWeightedMerge';

* @param options - Options.
* @param options.delta - Delta.
* @returns Result.
*/

@@ -11,0 +9,0 @@ export function getSlotsToFirst(spectra, options = {}) {

import { DoubleArray, DataXY } from 'cheminfo-types';
export interface OptionsType {
delta?: ((arg: number) => number) | number;
}
/**
* Aligns spectra
*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param spectra - spectra
* @param options - Options
*/
export declare function xyArrayAlign(spectra: DataXY[], options?: OptionsType): {
export declare function xyArrayAlign(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
x: DoubleArray;

@@ -15,0 +16,0 @@ ys: DoubleArray[];

@@ -6,6 +6,4 @@ import { xyJoinX } from '../xy/xyJoinX';

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param spectra - spectra
* @param options - Options
*/

@@ -12,0 +10,0 @@ export function xyArrayAlign(spectra, options = {}) {

import { DoubleArray, DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
/**

@@ -8,7 +7,11 @@ * We align all the spectra to the first array of X.

* @param spectra spectra
* @param [options={}] options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param options options
*/
export declare function xyArrayAlignToFirst(spectra: Array<DataXY>, options?: OptionsType): {
export declare function xyArrayAlignToFirst(spectra: Array<DataXY>, options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
x: DoubleArray;

@@ -15,0 +18,0 @@ ys: DoubleArray[];

@@ -7,5 +7,3 @@ import { getSlotsToFirst } from './utils/getSlotsToFirst';

* @param spectra spectra
* @param [options={}] options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param options options
*/

@@ -12,0 +10,0 @@ export function xyArrayAlignToFirst(spectra, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
/**

@@ -7,8 +6,12 @@ * Merge DataXY

*
* @param spectra Spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns result
* @param spectra - Spectra
* @param options - Options
*/
export declare function xyArrayMerge(spectra: DataXY[], options?: OptionsType): DataXY;
export declare function xyArrayMerge(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): DataXY;
//# sourceMappingURL=xyArrayMerge.d.ts.map

@@ -7,6 +7,4 @@ import { xyJoinX } from '../xy/xyJoinX';

*
* @param spectra Spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns result
* @param spectra - Spectra
* @param options - Options
*/

@@ -13,0 +11,0 @@ export function xyArrayMerge(spectra, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
/**

@@ -8,8 +7,12 @@ * Merge DataXY

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns results
* @param spectra - spectra
* @param options - Options
*/
export declare function xyArrayWeightedMerge(spectra: DataXY[], options?: OptionsType): DataXY;
export declare function xyArrayWeightedMerge(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): DataXY;
//# sourceMappingURL=xyArrayWeightedMerge.d.ts.map

@@ -6,6 +6,4 @@ /**

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns results
* @param spectra - spectra
* @param options - Options
*/

@@ -12,0 +10,0 @@ export function xyArrayWeightedMerge(spectra, options = {}) {

@@ -10,19 +10,32 @@ import { Point } from '..';

* @param points - array of all the points
* @param [options={}] Options
* @param [options.from] - min X value of the window to consider
* @param [options.to] - max X value of the window to consider
* @param [options.limit=20] - max number of points
* @param [options.threshold=0.01] - minimal intensity compare to more intense point
* @param [options.numberSlots=10] - define the number of slots and indirectly the slot width
* @param [options.numberCloseSlots=50] numberCloseSlots
* @param options - Options
* @returns - copy of points with 'close' property
*/
export declare function xyObjectBestPoints(points: Point[], options?: {
/**
* min X value of the window to consider
*/
from?: number;
/**
* max X value of the window to consider
*/
to?: number;
/**
* max number of points
* @default 20
* */
limit?: number;
/**
* minimal intensity compare to more intense
* @default 0.01
* */
threshold?: number;
/**@default 50 */
numberCloseSlots?: number;
/**
* define the number of slots and indirectly the slot width
* @default 10
* */
numberSlots?: number;
}): Point[];
//# sourceMappingURL=xyObjectBestPoints.d.ts.map

@@ -11,9 +11,3 @@ import { xyObjectMaxXPoint } from './xyObjectMaxXPoint';

* @param points - array of all the points
* @param [options={}] Options
* @param [options.from] - min X value of the window to consider
* @param [options.to] - max X value of the window to consider
* @param [options.limit=20] - max number of points
* @param [options.threshold=0.01] - minimal intensity compare to more intense point
* @param [options.numberSlots=10] - define the number of slots and indirectly the slot width
* @param [options.numberCloseSlots=50] numberCloseSlots
* @param options - Options
* @returns - copy of points with 'close' property

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

@@ -5,5 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] list of points
* @param points - list of points
*/
export declare function xyObjectCheck(points?: Point[]): void;
//# sourceMappingURL=xyObjectCheck.d.ts.map
/**
* Throw an error in no an object of x,y arrays
*
* @param [points=[]] list of points
* @param points - list of points
*/

@@ -6,0 +6,0 @@ export function xyObjectCheck(points = []) {

@@ -6,10 +6,12 @@ import { Point } from '..';

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.xError=Number.EPSILON] - Limit to join the data.
* @returns Results.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/
export declare function xyObjectJoinX(points: Point[], options?: {
/**
* Limit to join the data.
* @default Number.EPSILON
* */
xError?: number;
}): Point[];
//# sourceMappingURL=xyObjectJoinX.d.ts.map

@@ -5,6 +5,4 @@ /**

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.xError=Number.EPSILON] - Limit to join the data.
* @returns Results.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/

@@ -11,0 +9,0 @@ export function xyObjectJoinX(points, options = {}) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMaxXPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMaxXPoint.d.ts.map

@@ -5,4 +5,3 @@ import { xyObjectCheck } from './xyObjectCheck';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -9,0 +8,0 @@ export function xyObjectMaxXPoint(points = []) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMaxYPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMaxYPoint.d.ts.map

@@ -5,4 +5,3 @@ import { xyObjectCheck } from './xyObjectCheck';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -9,0 +8,0 @@ export function xyObjectMaxYPoint(points = []) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMinXPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMinXPoint.d.ts.map

@@ -5,4 +5,3 @@ import { xyObjectCheck } from './xyObjectCheck';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -9,0 +8,0 @@ export function xyObjectMinXPoint(points = []) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMinYPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMinYPoint.d.ts.map

@@ -5,4 +5,3 @@ import { xyObjectCheck } from './xyObjectCheck';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -9,0 +8,0 @@ export function xyObjectMinYPoint(points = []) {

@@ -6,10 +6,12 @@ import { Point } from '..';

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.slotWidth=1] - Limit to join the dataPoints[].
* @returns Result.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/
export declare function xyObjectSlotX(points: Point[], options?: {
/**
* Limit to join the dataPoints[].
* @default 1
* */
slotWidth?: number;
}): Point[];
//# sourceMappingURL=xyObjectSlotX.d.ts.map

@@ -5,6 +5,4 @@ /**

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.slotWidth=1] - Limit to join the dataPoints[].
* @returns Result.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/

@@ -11,0 +9,0 @@ export function xyObjectSlotX(points, options = {}) {

@@ -5,6 +5,6 @@ import { Point } from '..';

*
* @param [points] array of points {x,y}
* @returns sorted array of points {x,y}
* @param points - array of points {x,y}
* @returns - sorted array of points {x,y}
*/
export declare function xyObjectSortX(points: Point[]): Point[];
//# sourceMappingURL=xyObjectSortX.d.ts.map
/**
* Sorts an array of points
*
* @param [points] array of points {x,y}
* @returns sorted array of points {x,y}
* @param points - array of points {x,y}
* @returns - sorted array of points {x,y}
*/

@@ -7,0 +7,0 @@ export function xyObjectSortX(points) {

@@ -7,6 +7,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [points] - Array of points {x,y}.
* @returns DataXY.
* @param points - Array of points {x,y}.
*/
export declare function xyObjectToXY(points: Point[]): DataXY;
//# sourceMappingURL=xyObjectToXY.d.ts.map

@@ -5,4 +5,3 @@ /**

*
* @param [points] - Array of points {x,y}.
* @returns DataXY.
* @param points - Array of points {x,y}.
*/

@@ -9,0 +8,0 @@ export function xyObjectToXY(points) {

@@ -7,5 +7,5 @@ import { Zone } from '..';

* @param size - Size.
* @returns Array of float.
* @returns - Array of float.
*/
export declare function zoneToX(zone: Zone, size: number): Float64Array;
//# sourceMappingURL=zoneToX.d.ts.map

@@ -6,3 +6,3 @@ /**

* @param size - Size.
* @returns Array of float.
* @returns - Array of float.
*/

@@ -9,0 +9,0 @@ export function zoneToX(zone, size) {

@@ -7,7 +7,5 @@ import { Zone } from '../index';

*
* @param [zones=[]] array of zones
* @param [options={}] Options
* @param options.from -
* @param options.to -
* @returns array of{to: number,from: number}
* @param zones - array of zones
* @param options - Options
* @returns array of zones
*/

@@ -14,0 +12,0 @@ export declare function zonesNormalize(zones?: Zone[], options?: {

@@ -6,7 +6,5 @@ /**

*
* @param [zones=[]] array of zones
* @param [options={}] Options
* @param options.from -
* @param options.to -
* @returns array of{to: number,from: number}
* @param zones - array of zones
* @param options - Options
* @returns array of zones
*/

@@ -13,0 +11,0 @@ export function zonesNormalize(zones = [], options = {}) {

@@ -94,23 +94,40 @@ import { DoubleArray } from 'cheminfo-types';

export * from './matrix/matrixZRescale';
export * from './matrix/matrixClone';
export * from './matrix/matrixNumericalEncoding';
export * from './matrix/matrixNumericalDecoding';
export * from './matrix/matrixApplyNumericalEncoding';
export * from './utils/createSequentialArray';
export declare type DoubleMatrix = DoubleArray[];
export interface Zone {
/** starting index */
fromIndex?: number;
/** finishing index */
toIndex?: number;
/** starting value */
from: number;
/** finishing value */
to: number;
/** number of points */
nbPoints?: number;
from: number;
}
export interface Point {
/** x value */
x: number;
/** y value */
y: number;
/** point index */
index?: number;
}
export interface DataXReIm {
/** Array of x values */
x: DoubleArray;
/** Array of re values */
re: DoubleArray;
/** Array of im values */
im: DoubleArray;
}
export interface DataReIm {
/** Array of re values */
re: DoubleArray;
/** Array of im values */
im: DoubleArray;

@@ -117,0 +134,0 @@ }

@@ -105,3 +105,7 @@ "use strict";

__exportStar(require("./matrix/matrixZRescale"), exports);
__exportStar(require("./matrix/matrixClone"), exports);
__exportStar(require("./matrix/matrixNumericalEncoding"), exports);
__exportStar(require("./matrix/matrixNumericalDecoding"), exports);
__exportStar(require("./matrix/matrixApplyNumericalEncoding"), exports);
__exportStar(require("./utils/createSequentialArray"), exports);
//# sourceMappingURL=index.js.map

@@ -5,6 +5,5 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/
export declare function matrixCenterZMean(matrix: DoubleMatrix): DoubleMatrix;
//# sourceMappingURL=matrixCenterZMean.d.ts.map

@@ -7,4 +7,3 @@ "use strict";

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -11,0 +10,0 @@ function matrixCenterZMean(matrix) {

@@ -5,6 +5,5 @@ import { DoubleMatrix } from '..';

*
* @param [A] - matrix [rows][cols]
* @returns result
* @param A - matrix [rows][cols]
*/
export declare function matrixColumnsCorrelation(A: DoubleMatrix): DoubleMatrix;
//# sourceMappingURL=matrixColumnsCorrelation.d.ts.map

@@ -9,4 +9,3 @@ "use strict";

*
* @param [A] - matrix [rows][cols]
* @returns result
* @param A - matrix [rows][cols]
*/

@@ -13,0 +12,0 @@ function matrixColumnsCorrelation(A) {

@@ -6,24 +6,44 @@ import { DataXY } from 'cheminfo-types';

*
* @param [matrix] - matrix [rows][cols].
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axi
* @param [options.logBaseY] We can apply a log on the resulting histogra
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and
* @param options.histogram histogram
* @returns of the histogram
* @param matrix - matrix [rows][cols].
* @param options - options
* @returns - result of the histogram
*/
export declare function matrixHistogram(matrix: DoubleMatrix, options?: {
/**
* Center the X value. We will enlarge the first and
* @default true
* */
centerX?: boolean;
/**
* histogram
* */
histogram?: DataXY;
/**
* Number of slots
* @default 256
* */
nbSlots?: number;
/**
* We can first apply a log on x axis
* */
logBaseX?: number;
/**
* We can apply a log on the resulting histogram
*/
logBaseY?: number;
/**
* Take the absolute value
*/
absolute?: boolean;
/**
* Maximal value to calculate used to calculate slot size
* @default maxValue
* */
max?: number;
/**
* Minimum value to calculate used to calculate slot size
* @default minValue
* */
min?: number;
}): DataXY;
//# sourceMappingURL=matrixHistogram.d.ts.map

@@ -10,13 +10,5 @@ "use strict";

*
* @param [matrix] - matrix [rows][cols].
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axi
* @param [options.logBaseY] We can apply a log on the resulting histogra
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and
* @param options.histogram histogram
* @returns of the histogram
* @param matrix - matrix [rows][cols].
* @param options - options
* @returns - result of the histogram
*/

@@ -23,0 +15,0 @@ function matrixHistogram(matrix, options = {}) {

@@ -5,4 +5,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns results
* @param matrix - matrix [rows][cols].
*/

@@ -9,0 +8,0 @@ export declare function matrixMinMaxAbsoluteZ(matrix: DoubleMatrix): {

@@ -7,4 +7,3 @@ "use strict";

*
* @param [matrix] - matrix [rows][cols].
* @returns results
* @param matrix - matrix [rows][cols].
*/

@@ -11,0 +10,0 @@ function matrixMinMaxAbsoluteZ(matrix) {

@@ -5,4 +5,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -9,0 +8,0 @@ export declare function matrixMinMaxZ(matrix: DoubleMatrix): {

@@ -7,4 +7,3 @@ "use strict";

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -11,0 +10,0 @@ function matrixMinMaxZ(matrix) {

@@ -8,7 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.max=100] - Normalization integral constant.
* @param options.min min
* @returns result
* @param matrix - matrix [rows][cols].
* @param options Options
* data: Normalized dataset.

@@ -18,3 +15,10 @@ * medianOfQuotients: The median of quotients of each variables.

export declare function matrixPQN(matrix: DoubleMatrix, options?: {
/**
* Normalization integral constant.
* @default 100
* */
max?: number;
/**
* min
*/
min?: number;

@@ -21,0 +25,0 @@ }): {

@@ -14,7 +14,4 @@ "use strict";

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.max=100] - Normalization integral constant.
* @param options.min min
* @returns result
* @param matrix - matrix [rows][cols].
* @param options Options
* data: Normalized dataset.

@@ -21,0 +18,0 @@ * medianOfQuotients: The median of quotients of each variables.

@@ -5,12 +5,17 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.min=0] min
* @param [options.max=1] max
* @returns result
* @param matrix - matrix [rows][cols].
* @param options - Options
*/
export declare function matrixZRescale(matrix: DoubleMatrix, options?: {
/**
* min
* @default 0
* */
min?: number;
/**
* max
* @default 1
* */
max?: number;
}): DoubleMatrix;
//# sourceMappingURL=matrixZRescale.d.ts.map

@@ -7,7 +7,4 @@ "use strict";

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.min=0] min
* @param [options.max=1] max
* @returns result
* @param matrix - matrix [rows][cols].
* @param options - Options
*/

@@ -14,0 +11,0 @@ function matrixZRescale(matrix, options = {}) {

@@ -6,6 +6,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param data DATA
* @returns array of float
* @param data - DATA
* @returns - array of float
*/
export declare function reimAbsolute(data: DataReIm): DoubleArray;
//# sourceMappingURL=reimAbsolute.d.ts.map

@@ -7,4 +7,4 @@ "use strict";

*
* @param data DATA
* @returns array of float
* @param data - DATA
* @returns - array of float
*/

@@ -11,0 +11,0 @@ function reimAbsolute(data) {

@@ -5,2 +5,5 @@ import { DataReIm } from '../index';

* correction algorithm for high-resolution NMR data. 10.1002/mrc.4586
*
* @param data - DataReim.
* @param options - Options.
*/

@@ -7,0 +10,0 @@ export declare function reimAutoPhaseCorrection(data: DataReIm, options?: {

@@ -10,2 +10,5 @@ "use strict";

* correction algorithm for high-resolution NMR data. 10.1002/mrc.4586
*
* @param data - DataReim.
* @param options - Options.
*/

@@ -12,0 +15,0 @@ function reimAutoPhaseCorrection(data, options = {}) {

@@ -7,4 +7,2 @@ import { DataReIm } from '..';

* @param options - Options.
* @param options.inverse -
* @param options.applyZeroShift -
* @returns DataReim.

@@ -11,0 +9,0 @@ */

@@ -14,4 +14,2 @@ "use strict";

* @param options - Options.
* @param options.inverse -
* @param options.applyZeroShift -
* @returns DataReim.

@@ -18,0 +16,0 @@ */

@@ -6,7 +6,7 @@ import { DataReIm } from '..';

* @param data DataReIm
* @param [phi0=0] - Angle in radians for zero order phase correction
* @param [phi1=0] - Angle in radians for first order phase correction
* @returns returns a new object {re:[], im:[]}
* @param phi0 - Angle in radians for zero order phase correction
* @param phi1 - Angle in radians for first order phase correction
* @returns - returns a new object {re:[], im:[]}
*/
export declare function reimPhaseCorrection(data: DataReIm, phi0: number, phi1: number): DataReIm;
export declare function reimPhaseCorrection(data: DataReIm, phi0?: number, phi1?: number): DataReIm;
//# sourceMappingURL=reimPhaseCorrection.d.ts.map

@@ -8,7 +8,7 @@ "use strict";

* @param data DataReIm
* @param [phi0=0] - Angle in radians for zero order phase correction
* @param [phi1=0] - Angle in radians for first order phase correction
* @returns returns a new object {re:[], im:[]}
* @param phi0 - Angle in radians for zero order phase correction
* @param phi1 - Angle in radians for first order phase correction
* @returns - returns a new object {re:[], im:[]}
*/
function reimPhaseCorrection(data, phi0, phi1) {
function reimPhaseCorrection(data, phi0 = 0, phi1 = 0) {
phi0 = Number.isFinite(phi0) ? phi0 : 0;

@@ -15,0 +15,0 @@ phi1 = Number.isFinite(phi1) ? phi1 : 0;

@@ -5,13 +5,16 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param options Options
* @param [options.from=0] from
* @param [options.to=1] to
* @param [options.length=1001] length
* @returns array of floats
* @param options - Options
* @param options.from - from
* @param options.to - to
* @param options.length - length
* @returns - array of floats
*/
export declare function createSequentialArray(options?: {
/**@default 0 */
from?: number;
/**@default 1 */
to?: number;
/**@default 1001 */
length?: number;
}): DoubleArray;
//# sourceMappingURL=createSequentialArray.d.ts.map

@@ -7,7 +7,7 @@ "use strict";

*
* @param options Options
* @param [options.from=0] from
* @param [options.to=1] to
* @param [options.length=1001] length
* @returns array of floats
* @param options - Options
* @param options.from - from
* @param options.to - to
* @param options.length - length
* @returns - array of floats
*/

@@ -14,0 +14,0 @@ function createSequentialArray(options = {}) {

@@ -5,6 +5,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns absolute array
* @param array - array of number
* @returns - absolute array
*/
export declare function xAbsolute(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xAbsolute.d.ts.map

@@ -7,4 +7,4 @@ "use strict";

*
* @param array array of number
* @returns absolute array
* @param array - array of number
* @returns - absolute array
*/

@@ -11,0 +11,0 @@ function xAbsolute(array) {

@@ -6,5 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns median
* @returns - median
*/
export declare function xAbsoluteMedian(array: DoubleArray): number;
//# sourceMappingURL=xAbsoluteMedian.d.ts.map

@@ -13,3 +13,3 @@ "use strict";

* @param array - the array that will be rotated
* @returns median
* @returns - median
*/

@@ -16,0 +16,0 @@ function xAbsoluteMedian(array) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 the second array
* @returns result
* @param array2 - the second array
*/
export declare function xAdd(array1: DoubleArray, array2: DoubleArray | number | Float32Array): DoubleArray;
//# sourceMappingURL=xAdd.d.ts.map

@@ -9,4 +9,3 @@ "use strict";

* @param array1 - the array that will be rotated
* @param array2 the second array
* @returns result
* @param array2 - the second array
*/

@@ -13,0 +12,0 @@ function xAdd(array1, array2) {

@@ -5,9 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - the array that will be fixed
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns result
* @param A - the array that will be fixed
* @param options - Options
*/
export declare function xAutoCorrelation(A: DoubleArray, options?: {}): DoubleArray;
export declare function xAutoCorrelation(A: DoubleArray, options?: {
/**
* sweep increment size (in number of points, min=1, max=A.length)
* @default 1
*/
tau?: number;
/**
* scalar lag parameter
* @default A.length-1
*/
lag?: number;
}): DoubleArray;
//# sourceMappingURL=xAutoCorrelation.d.ts.map

@@ -8,7 +8,4 @@ "use strict";

*
* @param [A] - the array that will be fixed
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns result
* @param A - the array that will be fixed
* @param options - Options
*/

@@ -15,0 +12,0 @@ function xAutoCorrelation(A, options = {}) {

@@ -6,3 +6,2 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns result
*/

@@ -9,0 +8,0 @@ export declare function xBoxPlot(array: DoubleArray): {

@@ -8,3 +8,2 @@ "use strict";

* @param array - the array that will be rotated
* @returns result
*/

@@ -11,0 +10,0 @@ function xBoxPlot(array) {

@@ -5,3 +5,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param input input
* @param input - input
*/

@@ -8,0 +8,0 @@ export declare function xCheck(input?: DoubleArray | Uint16Array): void;

@@ -8,3 +8,3 @@ "use strict";

*
* @param input input
* @param input - input
*/

@@ -11,0 +11,0 @@ function xCheck(input) {

@@ -6,7 +6,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - the array that will be rotated
* @param [B] sencond array
* @returns result
* @param A - the array that will be rotated
* @param B - sencond array
*/
export declare function xCorrelation(A: DoubleArray, B: DoubleArray): number;
//# sourceMappingURL=xCorrelation.d.ts.map

@@ -8,5 +8,4 @@ "use strict";

*
* @param [A] - the array that will be rotated
* @param [B] sencond array
* @returns result
* @param A - the array that will be rotated
* @param B - sencond array
*/

@@ -13,0 +12,0 @@ function xCorrelation(A, B) {

@@ -5,13 +5,18 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - fixed array
* @param [B] - sweeping array
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns results
* @param A - fixed array
* @param B - sweeping array
* @param options - Options
*/
export declare function xCrossCorrelation(A: DoubleArray, B: DoubleArray, options?: {
/**
* sweep increment size (in number of points, min=1, max=A.length)
* @default 1
* */
tau?: number;
/**
* scalar lag parameter
* @default A.length-1
* */
lag?: number;
}): DoubleArray;
//# sourceMappingURL=xCrossCorrelation.d.ts.map

@@ -8,8 +8,5 @@ "use strict";

*
* @param [A] - fixed array
* @param [B] - sweeping array
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns results
* @param A - fixed array
* @param B - sweeping array
* @param options - Options
*/

@@ -16,0 +13,0 @@ function xCrossCorrelation(A, B, options = {}) {

@@ -5,6 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array
* @returns result
* @param array - DoubleArray
*/
export declare function xCumulative(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xCumulative.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param array array
* @returns result
* @param array - DoubleArray
*/

@@ -12,0 +11,0 @@ function xCumulative(array) {

@@ -6,4 +6,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*

@@ -10,0 +9,0 @@ */

@@ -9,4 +9,3 @@ "use strict";

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*

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

@@ -7,5 +7,4 @@ import { DoubleArray } from 'cheminfo-types';

* @param B - Second array.
* @returns Result.
*/
export declare function xDotProduct(A: DoubleArray, B: DoubleArray): number;
//# sourceMappingURL=xDotProduct.d.ts.map

@@ -10,3 +10,2 @@ "use strict";

* @param B - Second array.
* @returns Result.
*/

@@ -13,0 +12,0 @@ function xDotProduct(A, B) {

@@ -5,5 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param target target
* @returns closest index
* @param array - array of numbers
* @param target - target
* @returns - closest index
*/

@@ -10,0 +10,0 @@ export declare function xFindClosestIndex(array: DoubleArray, target: number, options?: {

@@ -7,5 +7,5 @@ "use strict";

*
* @param array array of numbers
* @param target target
* @returns closest index
* @param array - array of numbers
* @param target - target
* @returns - closest index
*/

@@ -12,0 +12,0 @@ function xFindClosestIndex(array, target, options = {}) {

@@ -5,14 +5,23 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param x array of numbers
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param x - array of numbers
* @param options - Options
*/
export declare function xGetFromToIndex(x: DoubleArray, options?: {
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* First value for xyIntegration in the X scale
* */
from?: number;
/**
* Last value for xyIntegration in the X scale
* */
to?: number;

@@ -19,0 +28,0 @@ }): {

@@ -8,9 +8,4 @@ "use strict";

*
* @param x array of numbers
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param x - array of numbers
* @param options - Options
*/

@@ -17,0 +12,0 @@ function xGetFromToIndex(x, options = {}) {

@@ -5,12 +5,12 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [x] array of numbers
* @param [options={}] options
* @param [options.target] target
* @param [options.targetIndex=0] targetindex
*@returns results
* @param x - array of numbers
* @param options - options
*/
export declare function xGetTargetIndex(x: DoubleArray, options?: {
target?: number;
/**
* @default 0
*/
targetIndex?: number;
}): number;
//# sourceMappingURL=xGetTargetIndex.d.ts.map

@@ -8,7 +8,4 @@ "use strict";

*
* @param [x] array of numbers
* @param [options={}] options
* @param [options.target] target
* @param [options.targetIndex=0] targetindex
*@returns results
* @param x - array of numbers
* @param options - options
*/

@@ -15,0 +12,0 @@ function xGetTargetIndex(x, options = {}) {

@@ -5,24 +5,45 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

*
* @param [array] Array containing values
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axis
* @param [options.logBaseY] We can apply a log on the resulting histogram
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and last values.
* @param [options.histogram={x:[], y:[]}] Previously existing histogram to continue to fill
* @returns of the histogram
* @param array - Array containing values
* @param options - options
* @returns - result of the histogram
*/
export declare function xHistogram(array: DoubleArray, options?: {
/**
* Center the X value. We will enlarge the first and
* @default true
* */
centerX?: boolean;
/**
* Previously existing histogram to continue to fill
* @default {x:[],y:[]}
* */
histogram?: DataXY;
/**
* Number of slots
* @default 256
* */
nbSlots?: number;
/**
* We can first apply a log on x axis
* */
logBaseX?: number;
/**
* We can apply a log on the resulting histogram
*/
logBaseY?: number;
/**
* Take the absolute value
*/
absolute?: boolean;
/**
* Maximal value to calculate used to calculate slot size
* @default maxValue
* */
max?: number;
/**
* Minimum value to calculate used to calculate slot size
* @default minValue
* */
min?: number;
}): DataXY;
//# sourceMappingURL=xHistogram.d.ts.map

@@ -15,13 +15,5 @@ "use strict";

*
* @param [array] Array containing values
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axis
* @param [options.logBaseY] We can apply a log on the resulting histogram
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and last values.
* @param [options.histogram={x:[], y:[]}] Previously existing histogram to continue to fill
* @returns of the histogram
* @param array - Array containing values
* @param options - options
* @returns - result of the histogram
*/

@@ -28,0 +20,0 @@ function xHistogram(array, options = {}) {

@@ -5,6 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/
export declare function xIsMonotone(array: DoubleArray): boolean;
//# sourceMappingURL=xIsMonotone.d.ts.map

@@ -7,4 +7,3 @@ "use strict";

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/

@@ -11,0 +10,0 @@ function xIsMonotone(array) {

@@ -5,6 +5,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns indexe
* @param array - array of numbers
* @returns - indexe
*/
export declare function xMaxIndex(array: DoubleArray | Uint16Array): number;
//# sourceMappingURL=xMaxIndex.d.ts.map

@@ -8,4 +8,4 @@ "use strict";

*
* @param array array of numbers
* @returns indexe
* @param array - array of numbers
* @returns - indexe
*/

@@ -12,0 +12,0 @@ function xMaxIndex(array) {

@@ -5,12 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of number
* @param options - options
*/
export declare function xMaxValue(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xMaxValue.d.ts.map

@@ -8,7 +8,4 @@ "use strict";

*
* @param array array of number
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of number
* @param options - options
*/

@@ -15,0 +12,0 @@ function xMaxValue(array, options = {}) {

@@ -5,12 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/
export declare function xMean(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xMean.d.ts.map

@@ -8,7 +8,4 @@ "use strict";

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/

@@ -15,0 +12,0 @@ function xMean(array, options = {}) {

@@ -5,7 +5,6 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array1 -first array
* @param array2 second array
* @returns result
* @param array1 - first array
* @param array2 - second array
*/
export declare function xMeanAbsoluteError(array1: DoubleArray, array2: DoubleArray): number;
//# sourceMappingURL=xMeanAbsoluteError.d.ts.map

@@ -8,5 +8,4 @@ "use strict";

*
* @param array1 -first array
* @param array2 second array
* @returns result
* @param array1 - first array
* @param array2 - second array
*/

@@ -13,0 +12,0 @@ function xMeanAbsoluteError(array1, array2) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 -first array
* @param array2 second array
* @returns result
* @param array2 - second array
*/
export declare function xMeanSquaredError(array1: DoubleArray, array2: DoubleArray): number;
//# sourceMappingURL=xMeanSquaredError.d.ts.map

@@ -9,4 +9,3 @@ "use strict";

* @param array1 -first array
* @param array2 second array
* @returns result
* @param array2 - second array
*/

@@ -13,0 +12,0 @@ function xMeanSquaredError(array1, array2) {

@@ -5,6 +5,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/
export declare function xMinIndex(array: DoubleArray | Uint16Array): number;
//# sourceMappingURL=xMinIndex.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/

@@ -12,0 +11,0 @@ function xMinIndex(array) {

@@ -5,4 +5,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns Object with 2 properties, min and max
* @param array - array of number
* @returns - Object with 2 properties, min and max
*/

@@ -9,0 +9,0 @@ export declare function xMinMaxValues(array: DoubleArray | Uint16Array): {

@@ -8,4 +8,4 @@ "use strict";

*
* @param array array of number
* @returns Object with 2 properties, min and max
* @param array - array of number
* @returns - Object with 2 properties, min and max
*/

@@ -12,0 +12,0 @@ function xMinMaxValues(array) {

@@ -5,12 +5,17 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/
export declare function xMinValue(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xMinValue.d.ts.map

@@ -8,7 +8,4 @@ "use strict";

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/

@@ -15,0 +12,0 @@ function xMinValue(array, options = {}) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 --second array
* @returns array of result
* @param array2 - second array
*/
export declare function xMultiply(array1: DoubleArray, array2: DoubleArray | number): DoubleArray;
//# sourceMappingURL=xMultiply.d.ts.map

@@ -9,4 +9,3 @@ "use strict";

* @param array1 - the array that will be rotated
* @param array2 --second array
* @returns array of result
* @param array2 - second array
*/

@@ -13,0 +12,0 @@ function xMultiply(array1, array2) {

@@ -6,26 +6,38 @@ import { DataXY, FromTo, DoubleArray } from 'cheminfo-types';

* @param data - real or magnitude spectra data.
* @param [options = {}] options
* @param [options.mask] - boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
* @param [options.scaleFactor=1] - factor to scale the data input[i]*=scaleFactor.
* @param [options.cutOff] - percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
* @param [options.factorStd=5] - factor times std to determine what will be marked as signals.
* @param [options.refine=true] - if true the noise level will be recalculated get out the signals using factorStd.
* @param [options.fixOffset=true] - If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @param [options.logBaseY=2] - log scale to apply in the intensity axis in order to avoid big numbers.
* @param options.magnitudeMode -
* @param options.considerList -
* @param options.considerList.from -
* @param options.considerList.step -
* @param options.considerList.to -
* @param options.fromTo -
* @returns result
* @param options - options
*/
export declare function xNoiseSanPlot(data: DoubleArray, options?: {
/**
* boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
*/
mask?: DoubleArray;
/**
* percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
*/
cutOff?: number;
/**
* true the noise level will be recalculated get out the signals using factorStd.
* @default true
*/
refine?: boolean;
magnitudeMode?: boolean;
/**
* factor to scale the data input[i]*=scaleFactor.
* @default 1
*/
scaleFactor?: number;
/**
* factor times std to determine what will be marked as signals.
* @default 5
*/
factorStd?: number;
/**
* If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @default true
*/
fixOffset?: boolean;
/**
* log scale to apply in the intensity axis in order to avoid big numbers.
* @default 2
*/
logBaseY?: number;

@@ -32,0 +44,0 @@ considerList?: {

@@ -8,3 +8,3 @@ "use strict";

const ml_array_sequential_fill_1 = __importDefault(require("ml-array-sequential-fill"));
// @ts-ignore
// @ts-expect-error javascript package used
const spline_interpolator_1 = __importDefault(require("spline-interpolator"));

@@ -17,17 +17,3 @@ const erfcinv_1 = __importDefault(require("./erfcinv"));

* @param data - real or magnitude spectra data.
* @param [options = {}] options
* @param [options.mask] - boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
* @param [options.scaleFactor=1] - factor to scale the data input[i]*=scaleFactor.
* @param [options.cutOff] - percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
* @param [options.factorStd=5] - factor times std to determine what will be marked as signals.
* @param [options.refine=true] - if true the noise level will be recalculated get out the signals using factorStd.
* @param [options.fixOffset=true] - If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @param [options.logBaseY=2] - log scale to apply in the intensity axis in order to avoid big numbers.
* @param options.magnitudeMode -
* @param options.considerList -
* @param options.considerList.from -
* @param options.considerList.step -
* @param options.considerList.to -
* @param options.fromTo -
* @returns result
* @param options - options
*/

@@ -34,0 +20,0 @@ function xNoiseSanPlot(data, options = {}) {

@@ -7,5 +7,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns calculated norm
* @returns - calculated norm
*/
export declare function xNorm(array: DoubleArray): number;
//# sourceMappingURL=xNorm.d.ts.map

@@ -9,3 +9,3 @@ "use strict";

* @param array - the array that will be rotated
* @returns calculated norm
* @returns - calculated norm
*/

@@ -12,0 +12,0 @@ function xNorm(array) {

@@ -7,13 +7,21 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be padded
* @param [options={}] options
* @param [options.algorithm=''] '', value, circular, duplicate
* @param [options.size=0] padding size before first element and after last element
* @param [options.value=0] value to use for padding (if algorithm='value')
* @returns result
* @param options - options
*/
export declare function xPadding(array: DoubleArray, options?: {
/**
* padding size before first element and after last element
* @default 0
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
}): DoubleArray;
//# sourceMappingURL=xPadding.d.ts.map

@@ -10,7 +10,3 @@ "use strict";

* @param array - the array that will be padded
* @param [options={}] options
* @param [options.algorithm=''] '', value, circular, duplicate
* @param [options.size=0] padding size before first element and after last element
* @param [options.value=0] value to use for padding (if algorithm='value')
* @returns result
* @param options - options
*/

@@ -17,0 +13,0 @@ function xPadding(array, options = {}) {

@@ -7,6 +7,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns result
* @param array - array of number
*/
export declare function xParetoNormalization(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xParetoNormalization.d.ts.map

@@ -14,4 +14,3 @@ "use strict";

*
* @param array array of number
* @returns result
* @param array - array of number
*/

@@ -18,0 +17,0 @@ function xParetoNormalization(array) {

@@ -6,19 +6,32 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param fct callback function that from an array returns a value.
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=0] none, value, circular, duplicate
* @param [options.padding.algorithm='value'] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param fct - callback function that from an array returns a value.
* @param options - options
*/
export declare function xRolling(array: DoubleArray, fct?: (array: DoubleArray) => number, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default 0
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default 'value'
*/
algorithm?: string;
value?: number;
};
}): DoubleArray;
//# sourceMappingURL=xRolling.d.ts.map

@@ -10,10 +10,4 @@ "use strict";

* @param array - the array that will be rotated
* @param fct callback function that from an array returns a value.
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=0] none, value, circular, duplicate
* @param [options.padding.algorithm='value'] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param fct - callback function that from an array returns a value.
* @param options - options
*/

@@ -20,0 +14,0 @@ function xRolling(array, fct, options = {}) {

@@ -6,11 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param options - option
*/
export declare function xRollingAverage(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingAverage(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingAverage.d.ts.map

@@ -13,9 +13,3 @@ "use strict";

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param options - option
*/

@@ -22,0 +16,0 @@ function xRollingAverage(array, options = {}) {

@@ -6,10 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export declare function xRollingMax(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingMax(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingMax.d.ts.map

@@ -13,8 +13,3 @@ "use strict";

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/

@@ -21,0 +16,0 @@ function xRollingMax(array, options = {}) {

@@ -6,10 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export declare function xRollingMedian(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingMedian(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingMedian.d.ts.map

@@ -13,8 +13,3 @@ "use strict";

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/

@@ -21,0 +16,0 @@ function xRollingMedian(array, options = {}) {

@@ -6,10 +6,31 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export declare function xRollingMin(array: DoubleArray, options?: {}): DoubleArray;
export declare function xRollingMin(array: DoubleArray, options?: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
}): DoubleArray;
//# sourceMappingURL=xRollingMin.d.ts.map

@@ -13,8 +13,3 @@ "use strict";

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/

@@ -21,0 +16,0 @@ function xRollingMin(array, options = {}) {

@@ -9,6 +9,6 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param shift number
* @returns array of float
* @param shift - number
* @returns - array of float
*/
export declare function xRotate(array: DoubleArray, shift: number): DoubleArray;
//# sourceMappingURL=xRotate.d.ts.map

@@ -11,4 +11,4 @@ "use strict";

* @param array - the array that will be rotated
* @param shift number
* @returns array of float
* @param shift - number
* @returns - array of float
*/

@@ -15,0 +15,0 @@ function xRotate(array, shift) {

@@ -6,6 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*/
export declare function xSubtract(array1: DoubleArray | Float32Array, array2: DoubleArray | number): DoubleArray;
//# sourceMappingURL=xSubtract.d.ts.map

@@ -9,4 +9,3 @@ "use strict";

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*/

@@ -13,0 +12,0 @@ function xSubtract(array1, array2) {

@@ -5,12 +5,18 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [array={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param [options={}] - Options.
* @param [options.fromIndex=0] - First point for xSum.
* @param [options.toIndex=x.length-1] - Last point for xSum.
* @param array - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns XSum value on the specified range.
*/
export declare function xSum(array: DoubleArray | Uint16Array, options?: {
/**
* First point for xSum.
* @default 0
*/
fromIndex?: number;
/**
* Last point for xSum.
* @default x.length-1
*/
toIndex?: number;
}): number;
//# sourceMappingURL=xSum.d.ts.map

@@ -8,6 +8,4 @@ "use strict";

*
* @param [array={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param [options={}] - Options.
* @param [options.fromIndex=0] - First point for xSum.
* @param [options.toIndex=x.length-1] - Last point for xSum.
* @param array - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns XSum value on the specified range.

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

@@ -6,5 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - Array of number.
* @returns Sorted array.
* @returns - Sorted array.
*/
export declare function xUniqueSorted(array: DoubleArray): DoubleArray;
//# sourceMappingURL=xUniqueSorted.d.ts.map

@@ -8,3 +8,3 @@ "use strict";

* @param array - Array of number.
* @returns Sorted array.
* @returns - Sorted array.
*/

@@ -11,0 +11,0 @@ function xUniqueSorted(array) {

@@ -6,5 +6,5 @@ import { DataXReIm } from '..';

* @param data - Object of kind {x:[], re:[], im:[]}.
* @returns Data.
* @returns - Data.
*/
export declare function xreimSortX(data: DataXReIm): DataXReIm;
//# sourceMappingURL=xreimSortX.d.ts.map

@@ -8,3 +8,3 @@ "use strict";

* @param data - Object of kind {x:[], re:[], im:[]}.
* @returns Data.
* @returns - Data.
*/

@@ -11,0 +11,0 @@ function xreimSortX(data) {

@@ -7,5 +7,5 @@ import { DataXReIm } from '..';

* @param totalLength - Final number of points.
* @returns Data.
* @returns - Data.
*/
export declare function xreimZeroFilling(data: DataXReIm, totalLength: number): DataXReIm;
//# sourceMappingURL=xreimZeroFilling.d.ts.map

@@ -9,3 +9,3 @@ "use strict";

* @param totalLength - Final number of points.
* @returns Data.
* @returns - Data.
*/

@@ -12,0 +12,0 @@ function xreimZeroFilling(data, totalLength) {

@@ -7,13 +7,19 @@ import { DataXY } from 'cheminfo-types';

*
* @param data1 First spectrum data
* @param data2 Second spectrum data
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @param [options.common=true] If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @param [options.x='x1'] Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @returns result
* @param data1 - First spectrum data
* @param data2 - Second spectrum data
* @param options - Options
*/
export declare function xyAlign(data1: DataXY, data2: DataXY, options?: {
/**The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
/**If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @default true
*/
common?: boolean;
/** Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @default "x1"
* */
x?: string;

@@ -20,0 +26,0 @@ }): {

@@ -9,9 +9,6 @@ "use strict";

*
* @param data1 First spectrum data
* @param data2 Second spectrum data
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @param [options.common=true] If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @param [options.x='x1'] Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @returns result
* @param data1 - First spectrum data
* @param data2 - Second spectrum data
* @param options - Options
*/

@@ -18,0 +15,0 @@ function xyAlign(data1, data2, options = {}) {

import { DataXYZ } from '..';
/**
* Throw an error in no an object of x,y arrays
*
* @param data - array of points {x,y,z}
*/
export declare function xyCheck(data?: DataXYZ): void;
//# sourceMappingURL=xyCheck.d.ts.map

@@ -7,2 +7,4 @@ "use strict";

* Throw an error in no an object of x,y arrays
*
* @param data - array of points {x,y,z}
*/

@@ -9,0 +11,0 @@ function xyCheck(data = {}) {

@@ -5,3 +5,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] array of points {x,y}
* @param data - array of points {x,y}
* @returns x0, x25, x50, x75, x100, mode (x for maxY)

@@ -8,0 +8,0 @@ */

@@ -15,3 +15,3 @@ "use strict";

*
* @param [data] array of points {x,y}
* @param data - array of points {x,y}
* @returns x0, x25, x50, x75, x100, mode (x for maxY)

@@ -18,0 +18,0 @@ */

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
/**
* Filters x,y values to allow strictly growing values in x axis.
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @returns Result.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
*/
export declare function xyEnsureGrowingX(data?: DataXYZ): DataXY;
export declare function xyEnsureGrowingX(data: DataXY): DataXY;
//# sourceMappingURL=xyEnsureGrowingX.d.ts.map

@@ -8,6 +8,6 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @returns Result.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
*/
function xyEnsureGrowingX(data = {}) {
function xyEnsureGrowingX(data) {
(0, xyCheck_1.xyCheck)(data);

@@ -14,0 +14,0 @@ if (data.x === undefined || data.y === undefined)

import { DataXY } from 'cheminfo-types';
import { DataXYZ, Zone } from '..';
import { Zone } from '..';
/**
* XyExtract zones from a XY data
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.zones=[]] zones
* @returns Array of points
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Array of points
*/
export declare function xyExtract(data?: DataXYZ, options?: {
export declare function xyExtract(data: DataXY, options?: {
zones?: Zone[];
}): DataXY;
//# sourceMappingURL=xyExtract.d.ts.map

@@ -9,8 +9,7 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.zones=[]] zones
* @returns Array of points
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Array of points
*/
function xyExtract(data = {}, options = {}) {
function xyExtract(data, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -17,0 +16,0 @@ const { x, y } = data;

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
/**
* Filter out all the points for which x <= 0. Useful to display log scale data
*
* @param [data={}] data
* @returns An object with the filtered data
* @param data - data
* @returns - An object with the filtered data
*/
export declare function xyFilterXPositive(data?: DataXYZ): DataXY;
export declare function xyFilterXPositive(data: DataXY): DataXY;
//# sourceMappingURL=xyFilterXPositive.d.ts.map

@@ -8,6 +8,6 @@ "use strict";

*
* @param [data={}] data
* @returns An object with the filtered data
* @param data - data
* @returns - An object with the filtered data
*/
function xyFilterXPositive(data = {}) {
function xyFilterXPositive(data) {
(0, xyCheck_1.xyCheck)(data);

@@ -14,0 +14,0 @@ const { x, y } = data;

@@ -7,5 +7,5 @@ import { DataXY } from 'cheminfo-types';

* @param numberMaxPoints - Number of points to keep.
* @returns The points filtered to keep the `numberMaxPoints` most intense points of the input.
* @returns - The points filtered to keep the `numberMaxPoints` most intense points of the input.
*/
export declare function xyGetNMaxY(data: DataXY, numberMaxPoints: number): DataXY;
//# sourceMappingURL=xyGetNMaxY.d.ts.map

@@ -10,3 +10,3 @@ "use strict";

* @param numberMaxPoints - Number of points to keep.
* @returns The points filtered to keep the `numberMaxPoints` most intense points of the input.
* @returns - The points filtered to keep the `numberMaxPoints` most intense points of the input.
*/

@@ -13,0 +13,0 @@ function xyGetNMaxY(data, numberMaxPoints) {

@@ -6,6 +6,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param data Object of kind {x:[], y:[]}.
* @returns result
* @param data - Object of kind {x:[], y:[]}.
*/
export declare function xyGrowingX(data: DataXY): DataXY;
//# sourceMappingURL=xyGrowingX.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param data Object of kind {x:[], y:[]}.
* @returns result
* @param data - Object of kind {x:[], y:[]}.
*/

@@ -12,0 +11,0 @@ function xyGrowingX(data) {

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
/**
* Generate a X / Y of the xyIntegral
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @param [options.reverse=false] - Integrate from the larger value to the smallest value
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export declare function xyIntegral(data?: DataXYZ, options?: {
export declare function xyIntegral(data: DataXY, options?: {
/**
* Integrate from the larger value to the smallest value
* @default false
* */
reverse?: boolean;
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;
}): DataXY | number;
//# sourceMappingURL=xyIntegral.d.ts.map

@@ -9,12 +9,7 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @param [options.reverse=false] - Integrate from the larger value to the smallest value
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
function xyIntegral(data = {}, options = {}) {
function xyIntegral(data, options = {}) {
const { reverse = false } = options;

@@ -21,0 +16,0 @@ (0, xyCheck_1.xyCheck)(data);

@@ -1,14 +0,10 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**
* Calculate integration
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns xyIntegration value on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - xyIntegration value on the specified range
*/
export declare function xyIntegration(data?: DataXYZ, options?: {}): number;
export declare function xyIntegration(data: DataXY, options?: {}): number;
//# sourceMappingURL=xyIntegration.d.ts.map

@@ -9,11 +9,7 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns xyIntegration value on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - xyIntegration value on the specified range
*/
function xyIntegration(data = {}, options = {}) {
function xyIntegration(data, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -20,0 +16,0 @@ const { x, y } = data;

import { DataXY } from 'cheminfo-types';
import { DataXYZ, OptionsType } from '..';
/**

@@ -7,8 +6,13 @@ * Join x / y values when difference in X is closer than delta.

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export declare function xyJoinX(data?: DataXYZ, options?: OptionsType): DataXY;
export declare function xyJoinX(data: DataXY, options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): DataXY;
//# sourceMappingURL=xyJoinX.d.ts.map

@@ -9,8 +9,7 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
function xyJoinX(data = {}, options = {}) {
function xyJoinX(data, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -17,0 +16,0 @@ const { delta = 1 } = options;

@@ -5,10 +5,9 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/
export declare function xyMaxClosestYPoint(data: DataXY, options?: {
target?: number;
/**@default 0 */
targetIndex?: number;

@@ -15,0 +14,0 @@ }): {

@@ -9,7 +9,5 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -16,0 +14,0 @@ function xyMaxClosestYPoint(data, options = {}) {

@@ -7,7 +7,7 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns - Array of points.
*/
export declare function xyMaximaY(data?: DataXYZ, _options?: {}): {
export declare function xyMaximaY(data?: DataXYZ, options?: {}): {
x: number;

@@ -14,0 +14,0 @@ y: number;

@@ -10,8 +10,8 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns - Array of points.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
function xyMaximaY(data = {}, _options = {}) {
function xyMaximaY(data = {}, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -18,0 +18,0 @@ const { x, y } = data;

@@ -5,16 +5,26 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns Max y on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - Max y on the specified range
*/
export declare function xyMaxY(data?: DataXYZ, options?: {
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;
}): number;
//# sourceMappingURL=xyMaxY.d.ts.map

@@ -9,9 +9,5 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns Max y on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - Max y on the specified range
*/

@@ -18,0 +14,0 @@ function xyMaxY(data = {}, options = {}) {

@@ -5,17 +5,23 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param data.x x
* @param data.y y
* @param data.z z
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
*/
export declare function xyMaxYPoint(data?: DataXYZ, options?: {
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;

@@ -22,0 +28,0 @@ }): {

@@ -9,12 +9,4 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param data.x x
* @param data.y y
* @param data.z z
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
*/

@@ -21,0 +13,0 @@ function xyMaxYPoint(data = {}, options = {}) {

@@ -5,6 +5,6 @@ import { DataXY } from 'cheminfo-types';

*
* @param data x should be sorted in increasing order
* @returns the median of x values
* @param data - x should be sorted in increasing order
* @returns - the median of x values
*/
export declare function xyMedian(data: DataXY): number;
//# sourceMappingURL=xyMedian.d.ts.map

@@ -7,4 +7,4 @@ "use strict";

*
* @param data x should be sorted in increasing order
* @returns the median of x values
* @param data - x should be sorted in increasing order
* @returns - the median of x values
*/

@@ -11,0 +11,0 @@ function xyMedian(data) {

@@ -5,10 +5,9 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
* @returns - An object with the x/y value
*/
export declare function xyMinClosestYPoint(data: DataXY, options?: {
target?: number;
/**@default 0 */
targetIndex?: number;

@@ -15,0 +14,0 @@ }): {

@@ -9,7 +9,5 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
* @returns - An object with the x/y value
*/

@@ -16,0 +14,0 @@ function xyMinClosestYPoint(data, options = {}) {

@@ -1,2 +0,2 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**

@@ -7,10 +7,7 @@ * Finds all the min values

*
* @param [data={}] - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param data.x - X.
* @param data.y - Y.
* @param data.z - Z.
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param options - Options.
* @returns - Array of points.
*/
export declare function xyMinimaY(data?: DataXYZ, _options?: {}): {
export declare function xyMinimaY(data: DataXY, options?: {}): {
x: number;

@@ -17,0 +14,0 @@ y: number;

@@ -10,11 +10,8 @@ "use strict";

*
* @param [data={}] - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param data.x - X.
* @param data.y - Y.
* @param data.z - Z.
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param options - Options.
* @returns - Array of points.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
function xyMinimaY(data = {}, _options = {}) {
function xyMinimaY(data, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -21,0 +18,0 @@ const { x, y } = data;

@@ -1,14 +0,9 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**
* Finds the max y value in a range and return a {x,y} point
*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
*/
export declare function xyMinYPoint(data?: DataXYZ, options?: {}): 0 | {
export declare function xyMinYPoint(data: DataXY, options?: {}): 0 | {
x: number;

@@ -15,0 +10,0 @@ y: number;

@@ -9,11 +9,6 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
*/
function xyMinYPoint(data = {}, options = {}) {
function xyMinYPoint(data, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -20,0 +15,0 @@ const { x, y } = data;

@@ -1,2 +0,2 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
/**

@@ -12,9 +12,7 @@ * Returns an information about a signal.

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex] number
* @returns Information about signal
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Information about signal
*/
export declare function xyPeakInfo(data?: DataXYZ, options?: {
export declare function xyPeakInfo(data: DataXY, options?: {
targetIndex?: number;

@@ -21,0 +19,0 @@ target?: number;

@@ -16,9 +16,7 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex] number
* @returns Information about signal
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Information about signal
*/
function xyPeakInfo(data = {}, options = {}) {
function xyPeakInfo(data, options = {}) {
(0, xyCheck_1.xyCheck)(data);

@@ -25,0 +23,0 @@ const { x, y } = data;

@@ -5,7 +5,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -12,0 +10,0 @@ export declare function xyRealMaxYPoint(data: DataXY, options?: {}): {

@@ -9,7 +9,5 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -16,0 +14,0 @@ function xyRealMaxYPoint(data, options = {}) {

@@ -7,3 +7,2 @@ import { DataXY } from 'cheminfo-types';

* @param options - Options.
* @returns Results.
*/

@@ -10,0 +9,0 @@ export declare function xyRealMinYPoint(data: DataXY, options?: {}): {

@@ -11,3 +11,2 @@ "use strict";

* @param options - Options.
* @returns Results.
*/

@@ -14,0 +13,0 @@ function xyRealMinYPoint(data, options = {}) {

@@ -9,18 +9,25 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.from=x[0]] number
* @param [options.to=x[x.length-1]] number
* @param [options.nbPoints=4001] Number of points
* @param [options.zones=[]] Array of zones to keep (from/to object)
* @param [options.optimize=false] If optimize we may have less than nbPoints at the end
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
*/
export declare function xyReduce(data: DataXY, options?: {
/**@default x[0] */
from?: number;
/**@default x[x.length-1] */
to?: number;
/**
* Number of points
* @default 4001
* */
nbPoints?: number;
/**
* If optimize we may have less than nbPoints at the end
* @default false
* */
optimize?: boolean;
/**Array of zones to keep (from/to object)
* @default []
* */
zones?: Zone[];
}): DataXY;
//# sourceMappingURL=xyReduce.d.ts.map

@@ -13,10 +13,4 @@ "use strict";

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.from=x[0]] number
* @param [options.to=x[x.length-1]] number
* @param [options.nbPoints=4001] Number of points
* @param [options.zones=[]] Array of zones to keep (from/to object)
* @param [options.optimize=false] If optimize we may have less than nbPoints at the end
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
*/

@@ -23,0 +17,0 @@ function xyReduce(data, options = {}) {

@@ -7,8 +7,7 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

*
* @param [points] array of points {x,y}
* @param [fct] callback function that from an array returns a value.
* @param options options
* @returns results
* @param points - array of points {x,y}
* @param fct - callback function that from an array returns a value.
* @param options - options
*/
export declare function xyRolling(points: DataXY, fct?: (array: DoubleArray) => number, options?: {}): DataXY;
//# sourceMappingURL=xyRolling.d.ts.map

@@ -11,6 +11,5 @@ "use strict";

*
* @param [points] array of points {x,y}
* @param [fct] callback function that from an array returns a value.
* @param options options
* @returns results
* @param points - array of points {x,y}
* @param fct - callback function that from an array returns a value.
* @param options - options
*/

@@ -17,0 +16,0 @@ function xyRolling(points, fct, options = {}) {

@@ -5,6 +5,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] - Object that contains property x (Array) and y (Array).
* @returns Results.
* @param data - Object that contains property x (Array) and y (Array).
*/
export declare function xySortX(data: DataXY): DataXY;
//# sourceMappingURL=xySortX.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [data] - Object that contains property x (Array) and y (Array).
* @returns Results.
* @param data - Object that contains property x (Array) and y (Array).
*/

@@ -12,0 +11,0 @@ function xySortX(data) {

@@ -6,6 +6,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] - Array of points {x,y}.
* @returns Results.
* @param data - Array of points {x,y}.
*/
export declare function xyToXYObject(data: DataXY): Point[];
//# sourceMappingURL=xyToXYObject.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [data] - Array of points {x,y}.
* @returns Results.
* @param data - Array of points {x,y}.
*/

@@ -12,0 +11,0 @@ function xyToXYObject(data) {

@@ -5,12 +5,17 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] Object that contains property x (Array) and y (Array)
* @param [options={}] Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
* @param [options.algorithm='average'] either 'average' or 'sum'
* @param [options.isSorted=true] if false the DataXY has to be sorted first
* @returns result
* @param data - Object that contains property x (Array) and y (Array)
* @param options - Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
*/
export declare function xyUniqueX(data: DataXY, options?: {
/**
* either 'average' or 'sum'
* @default 'average'
* */
algorithm?: string;
/**
* if false the DataXY has to be sorted first
* @default true
* */
isSorted?: boolean;
}): DataXY;
//# sourceMappingURL=xyUniqueX.d.ts.map

@@ -9,7 +9,4 @@ "use strict";

*
* @param [data] Object that contains property x (Array) and y (Array)
* @param [options={}] Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
* @param [options.algorithm='average'] either 'average' or 'sum'
* @param [options.isSorted=true] if false the DataXY has to be sorted first
* @returns result
* @param data - Object that contains property x (Array) and y (Array)
* @param options - Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
*/

@@ -16,0 +13,0 @@ function xyUniqueX(data, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '../..';
/**

@@ -8,5 +7,10 @@ * GetSlots.

* @param options - Options.
* @returns Result.
*/
export declare function getSlots(spectra: DataXY[], options?: OptionsType): {
export declare function getSlots(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
from: number;

@@ -13,0 +17,0 @@ to: number;

@@ -9,3 +9,2 @@ "use strict";

* @param options - Options.
* @returns Result.
*/

@@ -12,0 +11,0 @@ function getSlots(spectra, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '../..';
/**

@@ -8,6 +7,10 @@ * GetSlotsToFirst.

* @param options - Options.
* @param options.delta - Delta.
* @returns Result.
*/
export declare function getSlotsToFirst(spectra: DataXY[], options?: OptionsType): {
export declare function getSlotsToFirst(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
from: number;

@@ -14,0 +17,0 @@ to: number;

@@ -10,4 +10,2 @@ "use strict";

* @param options - Options.
* @param options.delta - Delta.
* @returns Result.
*/

@@ -14,0 +12,0 @@ function getSlotsToFirst(spectra, options = {}) {

import { DoubleArray, DataXY } from 'cheminfo-types';
export interface OptionsType {
delta?: ((arg: number) => number) | number;
}
/**
* Aligns spectra
*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param spectra - spectra
* @param options - Options
*/
export declare function xyArrayAlign(spectra: DataXY[], options?: OptionsType): {
export declare function xyArrayAlign(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
x: DoubleArray;

@@ -15,0 +16,0 @@ ys: DoubleArray[];

@@ -9,6 +9,4 @@ "use strict";

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param spectra - spectra
* @param options - Options
*/

@@ -15,0 +13,0 @@ function xyArrayAlign(spectra, options = {}) {

import { DoubleArray, DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
/**

@@ -8,7 +7,11 @@ * We align all the spectra to the first array of X.

* @param spectra spectra
* @param [options={}] options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param options options
*/
export declare function xyArrayAlignToFirst(spectra: Array<DataXY>, options?: OptionsType): {
export declare function xyArrayAlignToFirst(spectra: Array<DataXY>, options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): {
x: DoubleArray;

@@ -15,0 +18,0 @@ ys: DoubleArray[];

@@ -10,5 +10,3 @@ "use strict";

* @param spectra spectra
* @param [options={}] options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param options options
*/

@@ -15,0 +13,0 @@ function xyArrayAlignToFirst(spectra, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
/**

@@ -7,8 +6,12 @@ * Merge DataXY

*
* @param spectra Spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns result
* @param spectra - Spectra
* @param options - Options
*/
export declare function xyArrayMerge(spectra: DataXY[], options?: OptionsType): DataXY;
export declare function xyArrayMerge(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): DataXY;
//# sourceMappingURL=xyArrayMerge.d.ts.map

@@ -10,6 +10,4 @@ "use strict";

*
* @param spectra Spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns result
* @param spectra - Spectra
* @param options - Options
*/

@@ -16,0 +14,0 @@ function xyArrayMerge(spectra, options = {}) {

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
/**

@@ -8,8 +7,12 @@ * Merge DataXY

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns results
* @param spectra - spectra
* @param options - Options
*/
export declare function xyArrayWeightedMerge(spectra: DataXY[], options?: OptionsType): DataXY;
export declare function xyArrayWeightedMerge(spectra: DataXY[], options?: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
}): DataXY;
//# sourceMappingURL=xyArrayWeightedMerge.d.ts.map

@@ -9,6 +9,4 @@ "use strict";

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns results
* @param spectra - spectra
* @param options - Options
*/

@@ -15,0 +13,0 @@ function xyArrayWeightedMerge(spectra, options = {}) {

@@ -10,19 +10,32 @@ import { Point } from '..';

* @param points - array of all the points
* @param [options={}] Options
* @param [options.from] - min X value of the window to consider
* @param [options.to] - max X value of the window to consider
* @param [options.limit=20] - max number of points
* @param [options.threshold=0.01] - minimal intensity compare to more intense point
* @param [options.numberSlots=10] - define the number of slots and indirectly the slot width
* @param [options.numberCloseSlots=50] numberCloseSlots
* @param options - Options
* @returns - copy of points with 'close' property
*/
export declare function xyObjectBestPoints(points: Point[], options?: {
/**
* min X value of the window to consider
*/
from?: number;
/**
* max X value of the window to consider
*/
to?: number;
/**
* max number of points
* @default 20
* */
limit?: number;
/**
* minimal intensity compare to more intense
* @default 0.01
* */
threshold?: number;
/**@default 50 */
numberCloseSlots?: number;
/**
* define the number of slots and indirectly the slot width
* @default 10
* */
numberSlots?: number;
}): Point[];
//# sourceMappingURL=xyObjectBestPoints.d.ts.map

@@ -14,9 +14,3 @@ "use strict";

* @param points - array of all the points
* @param [options={}] Options
* @param [options.from] - min X value of the window to consider
* @param [options.to] - max X value of the window to consider
* @param [options.limit=20] - max number of points
* @param [options.threshold=0.01] - minimal intensity compare to more intense point
* @param [options.numberSlots=10] - define the number of slots and indirectly the slot width
* @param [options.numberCloseSlots=50] numberCloseSlots
* @param options - Options
* @returns - copy of points with 'close' property

@@ -23,0 +17,0 @@ */

@@ -5,5 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] list of points
* @param points - list of points
*/
export declare function xyObjectCheck(points?: Point[]): void;
//# sourceMappingURL=xyObjectCheck.d.ts.map

@@ -7,3 +7,3 @@ "use strict";

*
* @param [points=[]] list of points
* @param points - list of points
*/

@@ -10,0 +10,0 @@ function xyObjectCheck(points = []) {

@@ -6,10 +6,12 @@ import { Point } from '..';

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.xError=Number.EPSILON] - Limit to join the data.
* @returns Results.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/
export declare function xyObjectJoinX(points: Point[], options?: {
/**
* Limit to join the data.
* @default Number.EPSILON
* */
xError?: number;
}): Point[];
//# sourceMappingURL=xyObjectJoinX.d.ts.map

@@ -8,6 +8,4 @@ "use strict";

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.xError=Number.EPSILON] - Limit to join the data.
* @returns Results.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/

@@ -14,0 +12,0 @@ function xyObjectJoinX(points, options = {}) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMaxXPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMaxXPoint.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -12,0 +11,0 @@ function xyObjectMaxXPoint(points = []) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMaxYPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMaxYPoint.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -12,0 +11,0 @@ function xyObjectMaxYPoint(points = []) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMinXPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMinXPoint.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -12,0 +11,0 @@ function xyObjectMinXPoint(points = []) {

@@ -5,6 +5,5 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/
export declare function xyObjectMinYPoint(points?: Point[]): Point;
//# sourceMappingURL=xyObjectMinYPoint.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -12,0 +11,0 @@ function xyObjectMinYPoint(points = []) {

@@ -6,10 +6,12 @@ import { Point } from '..';

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.slotWidth=1] - Limit to join the dataPoints[].
* @returns Result.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/
export declare function xyObjectSlotX(points: Point[], options?: {
/**
* Limit to join the dataPoints[].
* @default 1
* */
slotWidth?: number;
}): Point[];
//# sourceMappingURL=xyObjectSlotX.d.ts.map

@@ -8,6 +8,4 @@ "use strict";

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.slotWidth=1] - Limit to join the dataPoints[].
* @returns Result.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/

@@ -14,0 +12,0 @@ function xyObjectSlotX(points, options = {}) {

@@ -5,6 +5,6 @@ import { Point } from '..';

*
* @param [points] array of points {x,y}
* @returns sorted array of points {x,y}
* @param points - array of points {x,y}
* @returns - sorted array of points {x,y}
*/
export declare function xyObjectSortX(points: Point[]): Point[];
//# sourceMappingURL=xyObjectSortX.d.ts.map

@@ -7,4 +7,4 @@ "use strict";

*
* @param [points] array of points {x,y}
* @returns sorted array of points {x,y}
* @param points - array of points {x,y}
* @returns - sorted array of points {x,y}
*/

@@ -11,0 +11,0 @@ function xyObjectSortX(points) {

@@ -7,6 +7,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [points] - Array of points {x,y}.
* @returns DataXY.
* @param points - Array of points {x,y}.
*/
export declare function xyObjectToXY(points: Point[]): DataXY;
//# sourceMappingURL=xyObjectToXY.d.ts.map

@@ -8,4 +8,3 @@ "use strict";

*
* @param [points] - Array of points {x,y}.
* @returns DataXY.
* @param points - Array of points {x,y}.
*/

@@ -12,0 +11,0 @@ function xyObjectToXY(points) {

@@ -7,5 +7,5 @@ import { Zone } from '..';

* @param size - Size.
* @returns Array of float.
* @returns - Array of float.
*/
export declare function zoneToX(zone: Zone, size: number): Float64Array;
//# sourceMappingURL=zoneToX.d.ts.map

@@ -9,3 +9,3 @@ "use strict";

* @param size - Size.
* @returns Array of float.
* @returns - Array of float.
*/

@@ -12,0 +12,0 @@ function zoneToX(zone, size) {

@@ -7,7 +7,5 @@ import { Zone } from '../index';

*
* @param [zones=[]] array of zones
* @param [options={}] Options
* @param options.from -
* @param options.to -
* @returns array of{to: number,from: number}
* @param zones - array of zones
* @param options - Options
* @returns array of zones
*/

@@ -14,0 +12,0 @@ export declare function zonesNormalize(zones?: Zone[], options?: {

@@ -9,7 +9,5 @@ "use strict";

*
* @param [zones=[]] array of zones
* @param [options={}] Options
* @param options.from -
* @param options.to -
* @returns array of{to: number,from: number}
* @param zones - array of zones
* @param options - Options
* @returns array of zones
*/

@@ -16,0 +14,0 @@ function zonesNormalize(zones = [], options = {}) {

{
"name": "ml-spectra-processing",
"version": "8.0.3",
"version": "8.1.0",
"description": "Various method to process spectra",

@@ -5,0 +5,0 @@ "main": "./lib/index.js",

@@ -103,2 +103,6 @@ import { DoubleArray } from 'cheminfo-types';

export * from './matrix/matrixZRescale';
export * from './matrix/matrixClone';
export * from './matrix/matrixNumericalEncoding';
export * from './matrix/matrixNumericalDecoding';
export * from './matrix/matrixApplyNumericalEncoding';

@@ -109,11 +113,19 @@ export * from './utils/createSequentialArray';

export interface Zone {
/** starting index */
fromIndex?: number;
/** finishing index */
toIndex?: number;
/** starting value */
from: number;
/** finishing value */
to: number;
/** number of points */
nbPoints?: number;
from: number;
}
export interface Point {
/** x value */
x: number;
/** y value */
y: number;
/** point index */
index?: number;

@@ -123,8 +135,13 @@ }

export interface DataXReIm {
/** Array of x values */
x: DoubleArray;
/** Array of re values */
re: DoubleArray;
/** Array of im values */
im: DoubleArray;
}
export interface DataReIm {
/** Array of re values */
re: DoubleArray;
/** Array of im values */
im: DoubleArray;

@@ -131,0 +148,0 @@ }

@@ -6,4 +6,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -10,0 +9,0 @@ export function matrixCenterZMean(matrix: DoubleMatrix): DoubleMatrix {

@@ -8,4 +8,3 @@ import { Matrix } from 'ml-matrix';

*
* @param [A] - matrix [rows][cols]
* @returns result
* @param A - matrix [rows][cols]
*/

@@ -12,0 +11,0 @@ export function matrixColumnsCorrelation(A: DoubleMatrix): DoubleMatrix {

@@ -12,13 +12,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [matrix] - matrix [rows][cols].
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axi
* @param [options.logBaseY] We can apply a log on the resulting histogra
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and
* @param options.histogram histogram
* @returns of the histogram
* @param matrix - matrix [rows][cols].
* @param options - options
* @returns - result of the histogram
*/

@@ -28,9 +20,37 @@ export function matrixHistogram(

options: {
/**
* Center the X value. We will enlarge the first and
* @default true
* */
centerX?: boolean;
/**
* histogram
* */
histogram?: DataXY;
/**
* Number of slots
* @default 256
* */
nbSlots?: number;
/**
* We can first apply a log on x axis
* */
logBaseX?: number;
/**
* We can apply a log on the resulting histogram
*/
logBaseY?: number;
/**
* Take the absolute value
*/
absolute?: boolean;
/**
* Maximal value to calculate used to calculate slot size
* @default maxValue
* */
max?: number;
/**
* Minimum value to calculate used to calculate slot size
* @default minValue
* */
min?: number;

@@ -37,0 +57,0 @@ } = {},

@@ -6,4 +6,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns results
* @param matrix - matrix [rows][cols].
*/

@@ -10,0 +9,0 @@ export function matrixMinMaxAbsoluteZ(matrix: DoubleMatrix): {

@@ -6,4 +6,3 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @returns result
* @param matrix - matrix [rows][cols].
*/

@@ -10,0 +9,0 @@ export function matrixMinMaxZ(matrix: DoubleMatrix): {

@@ -12,7 +12,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.max=100] - Normalization integral constant.
* @param options.min min
* @returns result
* @param matrix - matrix [rows][cols].
* @param options Options
* data: Normalized dataset.

@@ -23,3 +20,13 @@ * medianOfQuotients: The median of quotients of each variables.

matrix: DoubleMatrix,
options: { max?: number; min?: number } = {},
options: {
/**
* Normalization integral constant.
* @default 100
* */
max?: number;
/**
* min
*/
min?: number;
} = {},
): {

@@ -26,0 +33,0 @@ data: DoubleMatrix;

@@ -6,11 +6,19 @@ import { DoubleMatrix } from '..';

*
* @param [matrix] - matrix [rows][cols].
* @param [options={}] Options
* @param [options.min=0] min
* @param [options.max=1] max
* @returns result
* @param matrix - matrix [rows][cols].
* @param options - Options
*/
export function matrixZRescale(
matrix: DoubleMatrix,
options: { min?: number; max?: number } = {},
options: {
/**
* min
* @default 0
* */
min?: number;
/**
* max
* @default 1
* */
max?: number;
} = {},
): DoubleMatrix {

@@ -17,0 +25,0 @@ const { min = 0, max = 1 } = options;

@@ -8,4 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param data DATA
* @returns array of float
* @param data - DATA
* @returns - array of float
*/

@@ -12,0 +12,0 @@ export function reimAbsolute(data: DataReIm): DoubleArray {

@@ -12,2 +12,5 @@ import { DoubleArray } from 'cheminfo-types';

* correction algorithm for high-resolution NMR data. 10.1002/mrc.4586
*
* @param data - DataReim.
* @param options - Options.
*/

@@ -14,0 +17,0 @@

@@ -12,4 +12,2 @@ import { DoubleArray } from 'cheminfo-types';

* @param options - Options.
* @param options.inverse -
* @param options.applyZeroShift -
* @returns DataReim.

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

@@ -7,10 +7,10 @@ import { DataReIm } from '..';

* @param data DataReIm
* @param [phi0=0] - Angle in radians for zero order phase correction
* @param [phi1=0] - Angle in radians for first order phase correction
* @returns returns a new object {re:[], im:[]}
* @param phi0 - Angle in radians for zero order phase correction
* @param phi1 - Angle in radians for first order phase correction
* @returns - returns a new object {re:[], im:[]}
*/
export function reimPhaseCorrection(
data: DataReIm,
phi0: number,
phi1: number,
phi0 = 0,
phi1 = 0,
): DataReIm {

@@ -17,0 +17,0 @@ phi0 = Number.isFinite(phi0) ? phi0 : 0;

@@ -6,12 +6,15 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param options Options
* @param [options.from=0] from
* @param [options.to=1] to
* @param [options.length=1001] length
* @returns array of floats
* @param options - Options
* @param options.from - from
* @param options.to - to
* @param options.length - length
* @returns - array of floats
*/
export function createSequentialArray(
options: {
/**@default 0 */
from?: number;
/**@default 1 */
to?: number;
/**@default 1001 */
length?: number;

@@ -18,0 +21,0 @@ } = {},

@@ -6,4 +6,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns absolute array
* @param array - array of number
* @returns - absolute array
*/

@@ -10,0 +10,0 @@ export function xAbsolute(array: DoubleArray): DoubleArray {

@@ -9,3 +9,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns median
* @returns - median
*/

@@ -12,0 +12,0 @@ export function xAbsoluteMedian(array: DoubleArray): number {

@@ -8,4 +8,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 the second array
* @returns result
* @param array2 - the second array
*/

@@ -12,0 +11,0 @@ export function xAdd(

@@ -8,10 +8,21 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - the array that will be fixed
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns result
* @param A - the array that will be fixed
* @param options - Options
*/
export function xAutoCorrelation(A: DoubleArray, options = {}): DoubleArray {
export function xAutoCorrelation(
A: DoubleArray,
options: {
/**
* sweep increment size (in number of points, min=1, max=A.length)
* @default 1
*/
tau?: number;
/**
* scalar lag parameter
* @default A.length-1
*/
lag?: number;
} = {},
): DoubleArray {
return xCrossCorrelation(A, A, options);
}

@@ -7,3 +7,2 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns result
*/

@@ -10,0 +9,0 @@ export function xBoxPlot(array: DoubleArray) {

@@ -7,3 +7,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param input input
* @param input - input
*/

@@ -10,0 +10,0 @@ export function xCheck(input?: DoubleArray | Uint16Array) {

@@ -7,5 +7,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - the array that will be rotated
* @param [B] sencond array
* @returns result
* @param A - the array that will be rotated
* @param B - sencond array
*/

@@ -12,0 +11,0 @@ export function xCorrelation(A: DoubleArray, B: DoubleArray): number {

@@ -8,8 +8,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [A] - fixed array
* @param [B] - sweeping array
* @param [options={}] Options
* @param [options.tau=1] - sweep increment size (in number of points, min=1, max=A.length)
* @param [options.lag=A.length - 1] - scalar lag parameter
* @returns results
* @param A - fixed array
* @param B - sweeping array
* @param options - Options
*/

@@ -20,3 +17,11 @@ export function xCrossCorrelation(

options: {
/**
* sweep increment size (in number of points, min=1, max=A.length)
* @default 1
* */
tau?: number;
/**
* scalar lag parameter
* @default A.length-1
* */
lag?: number;

@@ -23,0 +28,0 @@ } = {},

@@ -7,4 +7,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array
* @returns result
* @param array - DoubleArray
*/

@@ -11,0 +10,0 @@ export function xCumulative(array: DoubleArray): DoubleArray {

@@ -8,4 +8,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*

@@ -12,0 +11,0 @@ */

@@ -10,3 +10,2 @@ import { DoubleArray } from 'cheminfo-types';

* @param B - Second array.
* @returns Result.
*/

@@ -13,0 +12,0 @@ export function xDotProduct(A: DoubleArray, B: DoubleArray): number {

@@ -6,5 +6,5 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param target target
* @returns closest index
* @param array - array of numbers
* @param target - target
* @returns - closest index
*/

@@ -11,0 +11,0 @@ export function xFindClosestIndex(

@@ -8,9 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param x array of numbers
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param x - array of numbers
* @param options - Options
*/

@@ -20,5 +15,19 @@ export function xGetFromToIndex(

options: {
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* First value for xyIntegration in the X scale
* */
from?: number;
/**
* Last value for xyIntegration in the X scale
* */
to?: number;

@@ -25,0 +34,0 @@ } = {},

@@ -8,7 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [x] array of numbers
* @param [options={}] options
* @param [options.target] target
* @param [options.targetIndex=0] targetindex
*@returns results
* @param x - array of numbers
* @param options - options
*/

@@ -19,2 +16,5 @@ export function xGetTargetIndex(

target?: number;
/**
* @default 0
*/
targetIndex?: number;

@@ -21,0 +21,0 @@ } = {},

@@ -12,13 +12,5 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

*
* @param [array] Array containing values
* @param options options
* @param [options.nbSlots=256] Number of slots
* @param [options.min=minValue] Minimum value to calculate used to calculate slot size
* @param [options.max=maxValue] Maximal value to calculate used to calculate slot size
* @param [options.logBaseX] We can first apply a log on x axis
* @param [options.logBaseY] We can apply a log on the resulting histogram
* @param [options.absolute] Take the absolute value
* @param [options.centerX=true] Center the X value. We will enlarge the first and last values.
* @param [options.histogram={x:[], y:[]}] Previously existing histogram to continue to fill
* @returns of the histogram
* @param array - Array containing values
* @param options - options
* @returns - result of the histogram
*/

@@ -28,9 +20,38 @@ export function xHistogram(

options: {
/**
* Center the X value. We will enlarge the first and
* @default true
* */
centerX?: boolean;
/**
* Previously existing histogram to continue to fill
* @default {x:[],y:[]}
* */
histogram?: DataXY;
/**
* Number of slots
* @default 256
* */
nbSlots?: number;
/**
* We can first apply a log on x axis
* */
logBaseX?: number;
/**
* We can apply a log on the resulting histogram
*/
logBaseY?: number;
/**
* Take the absolute value
*/
absolute?: boolean;
/**
* Maximal value to calculate used to calculate slot size
* @default maxValue
* */
max?: number;
/**
* Minimum value to calculate used to calculate slot size
* @default minValue
* */
min?: number;

@@ -37,0 +58,0 @@ } = {},

@@ -6,4 +6,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/

@@ -10,0 +9,0 @@ export function xIsMonotone(array: DoubleArray): boolean {

@@ -7,4 +7,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns indexe
* @param array - array of numbers
* @returns - indexe
*/

@@ -11,0 +11,0 @@ export function xMaxIndex(array: DoubleArray | Uint16Array): number {

@@ -8,7 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of number
* @param options - options
*/

@@ -18,3 +15,11 @@ export function xMaxValue(

options: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;

@@ -21,0 +26,0 @@ } = {},

@@ -8,7 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/

@@ -18,3 +15,11 @@ export function xMean(

options: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;

@@ -21,0 +26,0 @@ } = {},

@@ -7,5 +7,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array1 -first array
* @param array2 second array
* @returns result
* @param array1 - first array
* @param array2 - second array
*/

@@ -12,0 +11,0 @@ export function xMeanAbsoluteError(

@@ -9,4 +9,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 -first array
* @param array2 second array
* @returns result
* @param array2 - second array
*/

@@ -13,0 +12,0 @@ export function xMeanSquaredError(

@@ -8,4 +8,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @returns result
* @param array - array of numbers
*/

@@ -12,0 +11,0 @@ export function xMinIndex(array: DoubleArray | Uint16Array): number {

@@ -8,4 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns Object with 2 properties, min and max
* @param array - array of number
* @returns - Object with 2 properties, min and max
*/

@@ -12,0 +12,0 @@ export function xMinMaxValues(array: DoubleArray | Uint16Array): {

@@ -8,7 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of numbers
* @param [options={}] options
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param array - array of numbers
* @param options - options
*/

@@ -18,3 +15,11 @@ export function xMinValue(

options: {
/**
* First point for xyIntegration
* @default 0
*/
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
*/
toIndex?: number;

@@ -21,0 +26,0 @@ } = {},

@@ -8,4 +8,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 --second array
* @returns array of result
* @param array2 - second array
*/

@@ -12,0 +11,0 @@ export function xMultiply(

import { DataXY, FromTo, DoubleArray } from 'cheminfo-types';
import fill from 'ml-array-sequential-fill';
// @ts-ignore
// @ts-expect-error javascript package used
import SplineInterpolator from 'spline-interpolator';

@@ -13,17 +13,3 @@

* @param data - real or magnitude spectra data.
* @param [options = {}] options
* @param [options.mask] - boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
* @param [options.scaleFactor=1] - factor to scale the data input[i]*=scaleFactor.
* @param [options.cutOff] - percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
* @param [options.factorStd=5] - factor times std to determine what will be marked as signals.
* @param [options.refine=true] - if true the noise level will be recalculated get out the signals using factorStd.
* @param [options.fixOffset=true] - If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @param [options.logBaseY=2] - log scale to apply in the intensity axis in order to avoid big numbers.
* @param options.magnitudeMode -
* @param options.considerList -
* @param options.considerList.from -
* @param options.considerList.step -
* @param options.considerList.to -
* @param options.fromTo -
* @returns result
* @param options - options
*/

@@ -33,9 +19,35 @@ export function xNoiseSanPlot(

options: {
/**
* boolean array to filter data, if the i-th element is true then the i-th element of the distribution will be ignored.
*/
mask?: DoubleArray;
/**
* percent of positive signal distribution where the noise level will be determined, if it is not defined the program calculate it.
*/
cutOff?: number;
/**
* true the noise level will be recalculated get out the signals using factorStd.
* @default true
*/
refine?: boolean;
magnitudeMode?: boolean;
/**
* factor to scale the data input[i]*=scaleFactor.
* @default 1
*/
scaleFactor?: number;
/**
* factor times std to determine what will be marked as signals.
* @default 5
*/
factorStd?: number;
/**
* If the baseline is correct, the midpoint of distribution should be zero. if true, the distribution will be centered.
* @default true
*/
fixOffset?: boolean;
/**
* log scale to apply in the intensity axis in order to avoid big numbers.
* @default 2
*/
logBaseY?: number;

@@ -42,0 +54,0 @@ considerList?: { from: number; step: number; to: number };

@@ -8,3 +8,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @returns calculated norm
* @returns - calculated norm
*/

@@ -11,0 +11,0 @@ export function xNorm(array: DoubleArray): number {

@@ -10,7 +10,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be padded
* @param [options={}] options
* @param [options.algorithm=''] '', value, circular, duplicate
* @param [options.size=0] padding size before first element and after last element
* @param [options.value=0] value to use for padding (if algorithm='value')
* @returns result
* @param options - options
*/

@@ -20,4 +16,16 @@ export function xPadding(

options: {
/**
* padding size before first element and after last element
* @default 0
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;

@@ -24,0 +32,0 @@ } = {},

@@ -11,4 +11,3 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param array array of number
* @returns result
* @param array - array of number
*/

@@ -15,0 +14,0 @@ export function xParetoNormalization(array: DoubleArray): DoubleArray {

@@ -9,10 +9,4 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param fct callback function that from an array returns a value.
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=0] none, value, circular, duplicate
* @param [options.padding.algorithm='value'] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param fct - callback function that from an array returns a value.
* @param options - options
*/

@@ -23,4 +17,27 @@ export function xRolling(

options: {
/**
* rolling window
* @default 5
*/
window?: number;
padding?: { size?: number; algorithm?: string; value?: number };
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default 0
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default 'value'
*/
algorithm?: string;
};
} = {},

@@ -27,0 +44,0 @@ ): DoubleArray {

@@ -10,12 +10,35 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @param options.padding padding
* @returns result
* @param options - option
*/
export function xRollingAverage(array: DoubleArray, options = {}): DoubleArray {
export function xRollingAverage(
array: DoubleArray,
options: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
} = {},
): DoubleArray {
return xRolling(array, mean, options);
}

@@ -10,11 +10,35 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export function xRollingMax(array: DoubleArray, options = {}): DoubleArray {
export function xRollingMax(
array: DoubleArray,
options: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
} = {},
): DoubleArray {
return xRolling(array, max, options);
}

@@ -10,11 +10,35 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export function xRollingMedian(array: DoubleArray, options = {}): DoubleArray {
export function xRollingMedian(
array: DoubleArray,
options: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
} = {},
): DoubleArray {
return xRolling(array, median, options);
}

@@ -10,11 +10,35 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param [options={}] options
* @param [options.window=5] rolling window
* @param [options.padding.size=window-1] none, value, circular, duplicate
* @param [options.padding.algorithm=''] none, value, circular, duplicate
* @param [options.padding.value=0] value to use for padding (if algorithm='value')
* @returns results
* @param options - options
*/
export function xRollingMin(array: DoubleArray, options = {}): DoubleArray {
export function xRollingMin(
array: DoubleArray,
options: {
/**
* rolling window
* @default 5
*/
window?: number;
/**
* padding
*/
padding?: {
/**
* padding size before first element and after last element
* @default window-1
*/
size?: number;
/**
* value to use for padding (if algorithm='value')
* @default 0
*/
value?: number;
/**
* '', value, circular, duplicate
* @default ''
*/
algorithm?: string;
};
} = {},
): DoubleArray {
return xRolling(array, min, options);
}

@@ -10,4 +10,4 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - the array that will be rotated
* @param shift number
* @returns array of float
* @param shift - number
* @returns - array of float
*/

@@ -14,0 +14,0 @@ export function xRotate(array: DoubleArray, shift: number): DoubleArray {

@@ -8,4 +8,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array1 - the array that will be rotated
* @param array2 second array or number
* @returns result
* @param array2 - second array or number
*/

@@ -12,0 +11,0 @@ export function xSubtract(

@@ -8,6 +8,4 @@ import { DoubleArray } from 'cheminfo-types';

*
* @param [array={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param [options={}] - Options.
* @param [options.fromIndex=0] - First point for xSum.
* @param [options.toIndex=x.length-1] - Last point for xSum.
* @param array - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns XSum value on the specified range.

@@ -17,3 +15,14 @@ */

array: DoubleArray | Uint16Array,
options: { fromIndex?: number; toIndex?: number } = {},
options: {
/**
* First point for xSum.
* @default 0
*/
fromIndex?: number;
/**
* Last point for xSum.
* @default x.length-1
*/
toIndex?: number;
} = {},
): number {

@@ -20,0 +29,0 @@ const { fromIndex = 0, toIndex = array.length - 1 } = options;

@@ -7,3 +7,3 @@ import { DoubleArray } from 'cheminfo-types';

* @param array - Array of number.
* @returns Sorted array.
* @returns - Sorted array.
*/

@@ -10,0 +10,0 @@ export function xUniqueSorted(array: DoubleArray): DoubleArray {

@@ -6,3 +6,3 @@ import { DataXReIm } from '..';

* @param data - Object of kind {x:[], re:[], im:[]}.
* @returns Data.
* @returns - Data.
*/

@@ -9,0 +9,0 @@ export function xreimSortX(data: DataXReIm): DataXReIm {

@@ -8,3 +8,3 @@ import { DataXReIm } from '..';

* @param totalLength - Final number of points.
* @returns Data.
* @returns - Data.
*/

@@ -11,0 +11,0 @@ export function xreimZeroFilling(

@@ -8,9 +8,6 @@ import { DataXY } from 'cheminfo-types';

*
* @param data1 First spectrum data
* @param data2 Second spectrum data
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @param [options.common=true] If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @param [options.x='x1'] Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @returns result
* @param data1 - First spectrum data
* @param data2 - Second spectrum data
* @param options - Options
*/

@@ -21,4 +18,13 @@ export function xyAlign(

options: {
/**The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
/**If `true`, only the data considered as common to both spectra is kept. If `false`, the data y arrays are completed with zeroes where no common values are found
* @default true
*/
common?: boolean;
/** Defines what x values should be kept (`x1` : spectrum 1 x values, `x2` spectrum 2 x values, `weighted`: weighted average of both spectra x values)
* @default "x1"
* */
x?: string;

@@ -25,0 +31,0 @@ } = {},

@@ -7,2 +7,4 @@ import { isAnyArray } from 'is-any-array';

* Throw an error in no an object of x,y arrays
*
* @param data - array of points {x,y,z}
*/

@@ -9,0 +11,0 @@ export function xyCheck(data: DataXYZ = {}) {

@@ -13,3 +13,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] array of points {x,y}
* @param data - array of points {x,y}
* @returns x0, x25, x50, x75, x100, mode (x for maxY)

@@ -16,0 +16,0 @@ */

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
import { xyCheck } from './xyCheck';

@@ -10,8 +8,8 @@

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @returns Result.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
*/
export function xyEnsureGrowingX(data: DataXYZ = {}): DataXY {
export function xyEnsureGrowingX(data: DataXY): DataXY {
xyCheck(data);
if (data.x === undefined || data.y === undefined) return data as DataXY;
if (data.x === undefined || data.y === undefined) return data;
const x = Array.from(data.x);

@@ -18,0 +16,0 @@ const y = Array.from(data.y);

import { DataXY } from 'cheminfo-types';
import { DataXYZ, Zone } from '..';
import { Zone } from '..';
import { zonesNormalize } from '../zones/zonesNormalize';

@@ -11,9 +11,8 @@

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.zones=[]] zones
* @returns Array of points
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Array of points
*/
export function xyExtract(
data: DataXYZ = {},
data: DataXY,
options: { zones?: Zone[] } = {},

@@ -33,3 +32,3 @@ ): DataXY {

) {
return data as DataXY;
return data;
}

@@ -36,0 +35,0 @@

import { DoubleArray, DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
import { xyCheck } from './xyCheck';

@@ -9,6 +7,6 @@ /**

*
* @param [data={}] data
* @returns An object with the filtered data
* @param data - data
* @returns - An object with the filtered data
*/
export function xyFilterXPositive(data: DataXYZ = {}): DataXY {
export function xyFilterXPositive(data: DataXY): DataXY {
xyCheck(data);

@@ -15,0 +13,0 @@ const { x, y } = data;

@@ -10,3 +10,3 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

* @param numberMaxPoints - Number of points to keep.
* @returns The points filtered to keep the `numberMaxPoints` most intense points of the input.
* @returns - The points filtered to keep the `numberMaxPoints` most intense points of the input.
*/

@@ -13,0 +13,0 @@ export function xyGetNMaxY(data: DataXY, numberMaxPoints: number): DataXY {

@@ -6,4 +6,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param data Object of kind {x:[], y:[]}.
* @returns result
* @param data - Object of kind {x:[], y:[]}.
*/

@@ -10,0 +9,0 @@ export function xyGrowingX(data: DataXY): DataXY {

import { DataXY } from 'cheminfo-types';
import { DataXYZ } from '..';
import { xGetFromToIndex } from '../x/xGetFromToIndex';

@@ -10,18 +9,31 @@

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @param [options.reverse=false] - Integrate from the larger value to the smallest value
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export function xyIntegral(
data: DataXYZ = {},
data: DataXY,
options: {
/**
* Integrate from the larger value to the smallest value
* @default false
* */
reverse?: boolean;
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;

@@ -28,0 +40,0 @@ } = {},

@@ -1,2 +0,3 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
import { xGetFromToIndex } from '../x/xGetFromToIndex';

@@ -9,11 +10,7 @@

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns xyIntegration value on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - xyIntegration value on the specified range
*/
export function xyIntegration(data: DataXYZ = {}, options = {}): number {
export function xyIntegration(data: DataXY, options = {}): number {
xyCheck(data);

@@ -20,0 +17,0 @@ const { x, y } = data;

import { DataXY } from 'cheminfo-types';
import { DataXYZ, OptionsType } from '..';
import { xyCheck } from './xyCheck';

@@ -10,8 +8,16 @@ /**

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns An object with the xyIntegration function
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - An object with the xyIntegration function
*/
export function xyJoinX(data: DataXYZ = {}, options: OptionsType = {}): DataXY {
export function xyJoinX(
data: DataXY,
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): DataXY {
xyCheck(data);

@@ -18,0 +24,0 @@ const { delta = 1 } = options;

@@ -10,11 +10,13 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/
export function xyMaxClosestYPoint(
data: DataXY,
options: { target?: number; targetIndex?: number } = {},
options: {
target?: number;
/**@default 0 */
targetIndex?: number;
} = {},
): { x: number; y: number; index: number } {

@@ -21,0 +23,0 @@ xyCheck(data);

@@ -9,8 +9,8 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array).
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property x (an ordered increasing array) and y (an array).
* @param options - Options.
* @returns - Array of points.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
export function xyMaximaY(data: DataXYZ = {}, _options = {}) {
export function xyMaximaY(data: DataXYZ = {}, options = {}) {
xyCheck(data);

@@ -17,0 +17,0 @@ const { x, y } = data;

@@ -8,9 +8,5 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns Max y on the specified range
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
* @returns - Max y on the specified range
*/

@@ -20,5 +16,19 @@ export function xyMaxY(

options: {
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;

@@ -25,0 +35,0 @@ } = {},

@@ -8,12 +8,4 @@ import { DataXYZ } from '..';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param data.x x
* @param data.y y
* @param data.z z
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns result
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
*/

@@ -23,5 +15,19 @@ export function xyMaxYPoint(

options: {
/**
* First value for xyIntegration in the X scale
*/
from?: number;
/**
* First point for xyIntegration
* @default 0
* */
fromIndex?: number;
/**
* Last point for xyIntegration
* @default x.length-1
* */
toIndex?: number;
/**
* Last value for xyIntegration in the X scale
*/
to?: number;

@@ -28,0 +34,0 @@ } = {},

@@ -6,4 +6,4 @@ import { DataXY } from 'cheminfo-types';

*
* @param data x should be sorted in increasing order
* @returns the median of x values
* @param data - x should be sorted in increasing order
* @returns - the median of x values
*/

@@ -10,0 +10,0 @@ export function xyMedian(data: DataXY): number {

@@ -10,11 +10,13 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options Options
* @returns - An object with the x/y value
*/
export function xyMinClosestYPoint(
data: DataXY,
options: { target?: number; targetIndex?: number } = {},
options: {
target?: number;
/**@default 0 */
targetIndex?: number;
} = {},
) {

@@ -21,0 +23,0 @@ xyCheck(data);

@@ -1,2 +0,2 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';

@@ -9,11 +9,8 @@ import { xyCheck } from './xyCheck';

*
* @param [data={}] - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param data.x - X.
* @param data.y - Y.
* @param data.z - Z.
* @param _options - Options.
* @returns Array of points.
* @param data - Object that contains property X (an ordered increasing array) and y (an arraY).
* @param options - Options.
* @returns - Array of points.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
export function xyMinimaY(data: DataXYZ = {}, _options = {}) {
export function xyMinimaY(data: DataXY, options = {}) {
xyCheck(data);

@@ -20,0 +17,0 @@ const { x, y } = data;

@@ -1,2 +0,3 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
import { xGetFromToIndex } from '../x/xGetFromToIndex';

@@ -8,11 +9,6 @@

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] Options
* @param [options.from] - First value for xyIntegration in the X scale
* @param [options.fromIndex=0] - First point for xyIntegration
* @param [options.to] - Last value for xyIntegration in the X scale
* @param [options.toIndex=x.length-1] - Last point for xyIntegration
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - Options
*/
export function xyMinYPoint(data: DataXYZ = {}, options = {}) {
export function xyMinYPoint(data: DataXY, options = {}) {
xyCheck(data);

@@ -19,0 +15,0 @@ const { x, y } = data;

@@ -1,2 +0,3 @@

import { DataXYZ } from '..';
import { DataXY } from 'cheminfo-types';
import { xFindClosestIndex } from '../x/xFindClosestIndex';

@@ -16,10 +17,8 @@

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex] number
* @returns Information about signal
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - Information about signal
*/
export function xyPeakInfo(
data: DataXYZ = {},
data: DataXY,
options: { targetIndex?: number; target?: number } = {},

@@ -26,0 +25,0 @@ ) {

@@ -9,7 +9,5 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.target] number
* @param [options.targetIndex=0] number
* @returns An object with the x/y value
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
* @returns - An object with the x/y value
*/

@@ -16,0 +14,0 @@ export function xyRealMaxYPoint(

@@ -12,3 +12,2 @@ import { DataXY } from 'cheminfo-types';

* @param options - Options.
* @returns Results.
*/

@@ -15,0 +14,0 @@ export function xyRealMinYPoint(

@@ -15,10 +15,4 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data={}] - Object that contains property x (an ordered increasing array) and y (an array)
* @param [options={}] options
* @param [options.from=x[0]] number
* @param [options.to=x[x.length-1]] number
* @param [options.nbPoints=4001] Number of points
* @param [options.zones=[]] Array of zones to keep (from/to object)
* @param [options.optimize=false] If optimize we may have less than nbPoints at the end
* @returns results
* @param data - Object that contains property x (an ordered increasing array) and y (an array)
* @param options - options
*/

@@ -28,6 +22,19 @@ export function xyReduce(

options: {
/**@default x[0] */
from?: number;
/**@default x[x.length-1] */
to?: number;
/**
* Number of points
* @default 4001
* */
nbPoints?: number;
/**
* If optimize we may have less than nbPoints at the end
* @default false
* */
optimize?: boolean;
/**Array of zones to keep (from/to object)
* @default []
* */
zones?: Zone[];

@@ -34,0 +41,0 @@ } = {},

@@ -10,6 +10,5 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

*
* @param [points] array of points {x,y}
* @param [fct] callback function that from an array returns a value.
* @param options options
* @returns results
* @param points - array of points {x,y}
* @param fct - callback function that from an array returns a value.
* @param options - options
*/

@@ -16,0 +15,0 @@ export function xyRolling(

@@ -8,4 +8,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] - Object that contains property x (Array) and y (Array).
* @returns Results.
* @param data - Object that contains property x (Array) and y (Array).
*/

@@ -12,0 +11,0 @@ export function xySortX(data: DataXY): DataXY {

@@ -10,4 +10,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] - Array of points {x,y}.
* @returns Results.
* @param data - Array of points {x,y}.
*/

@@ -14,0 +13,0 @@ export function xyToXYObject(data: DataXY): Point[] {

@@ -9,11 +9,19 @@ import { DataXY } from 'cheminfo-types';

*
* @param [data] Object that contains property x (Array) and y (Array)
* @param [options={}] Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
* @param [options.algorithm='average'] either 'average' or 'sum'
* @param [options.isSorted=true] if false the DataXY has to be sorted first
* @returns result
* @param data - Object that contains property x (Array) and y (Array)
* @param options - Object containing a property algorithm (can be 'sum' or 'average', the latter being the default value), and a property isSorted (boolean indicating if the x-array is sorted).
*/
export function xyUniqueX(
data: DataXY,
options: { algorithm?: string; isSorted?: boolean } = {},
options: {
/**
* either 'average' or 'sum'
* @default 'average'
* */
algorithm?: string;
/**
* if false the DataXY has to be sorted first
* @default true
* */
isSorted?: boolean;
} = {},
): DataXY {

@@ -20,0 +28,0 @@ xyCheck(data);

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '../..';
/**

@@ -10,7 +8,12 @@ * GetSlots.

* @param options - Options.
* @returns Result.
*/
export function getSlots(
spectra: DataXY[],
options: OptionsType = {},
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): {

@@ -17,0 +20,0 @@ from: number;

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '../..';
import { xyArrayWeightedMerge } from '../xyArrayWeightedMerge';

@@ -10,8 +9,12 @@ /**

* @param options - Options.
* @param options.delta - Delta.
* @returns Result.
*/
export function getSlotsToFirst(
spectra: DataXY[],
options: OptionsType = {},
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): { from: number; to: number; value: number }[] {

@@ -18,0 +21,0 @@ const { delta = 1 } = options;

@@ -7,16 +7,17 @@ import { DoubleArray, DataXY } from 'cheminfo-types';

export interface OptionsType {
delta?: ((arg: number) => number) | number;
}
/**
* Aligns spectra
*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param spectra - spectra
* @param options - Options
*/
export function xyArrayAlign(
spectra: DataXY[],
options: OptionsType = {},
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): {

@@ -23,0 +24,0 @@ x: DoubleArray;

import { DoubleArray, DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
import { getSlotsToFirst } from './utils/getSlotsToFirst';

@@ -12,9 +10,13 @@

* @param spectra spectra
* @param [options={}] options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns Result
* @param options options
*/
export function xyArrayAlignToFirst(
spectra: Array<DataXY>,
options: OptionsType = {},
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): {

@@ -21,0 +23,0 @@ x: DoubleArray;

import { DataXY } from 'cheminfo-types';
import { OptionsType } from '..';
import { xyJoinX } from '../xy/xyJoinX';

@@ -11,10 +10,14 @@

*
* @param spectra Spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns result
* @param spectra - Spectra
* @param options - Options
*/
export function xyArrayMerge(
spectra: DataXY[],
options: OptionsType = {},
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): DataXY {

@@ -21,0 +24,0 @@ const { delta = 1 } = options;

import { DataXY } from 'cheminfo-types';
import { OptionsType, Point } from '..';
import { Point } from '..';

@@ -10,10 +10,14 @@ /**

*
* @param spectra spectra
* @param [options={}] Options
* @param [options.delta=1] The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @returns results
* @param spectra - spectra
* @param options - Options
*/
export function xyArrayWeightedMerge(
spectra: DataXY[],
options: OptionsType = {},
options: {
/**
* The range in which the two x values of the spectra must be to be placed on the same line. It may also be a function that allows to change `delta` depending on the X values of the spectrum
* @default 1
*/
delta?: ((arg: number) => number) | number;
} = {},
): DataXY {

@@ -20,0 +24,0 @@ let { delta = 1 } = options;

@@ -14,9 +14,3 @@ import { Point } from '..';

* @param points - array of all the points
* @param [options={}] Options
* @param [options.from] - min X value of the window to consider
* @param [options.to] - max X value of the window to consider
* @param [options.limit=20] - max number of points
* @param [options.threshold=0.01] - minimal intensity compare to more intense point
* @param [options.numberSlots=10] - define the number of slots and indirectly the slot width
* @param [options.numberCloseSlots=50] numberCloseSlots
* @param options - Options
* @returns - copy of points with 'close' property

@@ -27,7 +21,26 @@ */

options: {
/**
* min X value of the window to consider
*/
from?: number;
/**
* max X value of the window to consider
*/
to?: number;
/**
* max number of points
* @default 20
* */
limit?: number;
/**
* minimal intensity compare to more intense
* @default 0.01
* */
threshold?: number;
/**@default 50 */
numberCloseSlots?: number;
/**
* define the number of slots and indirectly the slot width
* @default 10
* */
numberSlots?: number;

@@ -34,0 +47,0 @@ } = {},

@@ -6,3 +6,3 @@ import { Point } from '..';

*
* @param [points=[]] list of points
* @param points - list of points
*/

@@ -9,0 +9,0 @@ export function xyObjectCheck(points: Point[] = []) {

@@ -7,6 +7,4 @@ import { Point } from '..';

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.xError=Number.EPSILON] - Limit to join the data.
* @returns Results.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/

@@ -16,2 +14,6 @@ export function xyObjectJoinX(

options: {
/**
* Limit to join the data.
* @default Number.EPSILON
* */
xError?: number;

@@ -18,0 +20,0 @@ } = {},

@@ -7,4 +7,3 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -11,0 +10,0 @@ export function xyObjectMaxXPoint(points: Point[] = []): Point {

@@ -7,4 +7,3 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -11,0 +10,0 @@ export function xyObjectMaxYPoint(points: Point[] = []): Point {

@@ -8,4 +8,3 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -12,0 +11,0 @@ export function xyObjectMinXPoint(points: Point[] = []): Point {

@@ -8,4 +8,3 @@ import { Point } from '..';

*
* @param [points=[]] - Object that contains property x (an ordered increasing array) and y (an array)
* @returns result
* @param points - Object that contains property x (an ordered increasing array) and y (an array)
*/

@@ -12,0 +11,0 @@ export function xyObjectMinYPoint(points: Point[] = []): Point {

@@ -7,6 +7,4 @@ import { Point } from '..';

*
* @param [points] - Array of growing points {x,y}.
* @param [options={}] - Options.
* @param [options.slotWidth=1] - Limit to join the dataPoints[].
* @returns Result.
* @param points - Array of growing points {x,y}.
* @param options - Options.
*/

@@ -16,2 +14,6 @@ export function xyObjectSlotX(

options: {
/**
* Limit to join the dataPoints[].
* @default 1
* */
slotWidth?: number;

@@ -18,0 +20,0 @@ } = {},

@@ -5,4 +5,4 @@ import { Point } from '..';

*
* @param [points] array of points {x,y}
* @returns sorted array of points {x,y}
* @param points - array of points {x,y}
* @returns - sorted array of points {x,y}
*/

@@ -9,0 +9,0 @@ export function xyObjectSortX(points: Point[]): Point[] {

@@ -9,4 +9,3 @@ import { DataXY } from 'cheminfo-types';

*
* @param [points] - Array of points {x,y}.
* @returns DataXY.
* @param points - Array of points {x,y}.
*/

@@ -13,0 +12,0 @@ export function xyObjectToXY(points: Point[]): DataXY {

@@ -8,3 +8,3 @@ import { Zone } from '..';

* @param size - Size.
* @returns Array of float.
* @returns - Array of float.
*/

@@ -11,0 +11,0 @@ export function zoneToX(zone: Zone, size: number): Float64Array {

@@ -8,7 +8,5 @@ import { Zone } from '../index';

*
* @param [zones=[]] array of zones
* @param [options={}] Options
* @param options.from -
* @param options.to -
* @returns array of{to: number,from: number}
* @param zones - array of zones
* @param options - Options
* @returns array of zones
*/

@@ -15,0 +13,0 @@ export function zonesNormalize(

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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