nmr-processing 9.8.0 → 9.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/assignment/get13CAssignments.js +1 -1
- package/lib/assignment/get13CAssignments.js.map +1 -1
- package/lib/assignment/get1HAssignments.js +1 -1
- package/lib/assignment/get1HAssignments.js.map +1 -1
- package/lib/assignment/getAssignments.js +1 -1
- package/lib/assignment/getAssignments.js.map +1 -1
- package/lib/assignment/utils/generalAssignment/buildAssignments.d.ts +1 -1
- package/lib/datum/Filters.js +2 -2
- package/lib/datum/Filters.js.map +1 -1
- package/lib/datum/data1d/utils/getShiftX.js +1 -2
- package/lib/datum/data1d/utils/getShiftX.js.map +1 -1
- package/lib/datum/data2d/filter2d/fftDimension1.d.ts +1 -1
- package/lib/datum/data2d/filter2d/fftDimension1.js +1 -2
- package/lib/datum/data2d/filter2d/fftDimension1.js.map +1 -1
- package/lib/datum/data2d/filter2d/fftDimension2.d.ts +1 -1
- package/lib/datum/data2d/filter2d/fftDimension2.js +2 -2
- package/lib/datum/data2d/filter2d/fftDimension2.js.map +1 -1
- package/lib/datum/data2d/filter2d/shiftX.d.ts +6 -7
- package/lib/datum/data2d/filter2d/shiftX.js +8 -10
- package/lib/datum/data2d/filter2d/shiftX.js.map +1 -1
- package/lib/datum/data2d/filter2d/shiftY.d.ts +6 -7
- package/lib/datum/data2d/filter2d/shiftY.js +8 -10
- package/lib/datum/data2d/filter2d/shiftY.js.map +1 -1
- package/lib/prediction/Prediction2D.d.ts +1 -1
- package/lib/prediction/predictAll.js +10 -10
- package/lib/prediction/predictAll.js.map +1 -1
- package/lib/prediction/predictCOSY.d.ts +1 -1
- package/lib/prediction/predictHMBC.d.ts +1 -1
- package/lib/prediction/predictHSQC.d.ts +1 -1
- package/lib/prediction/predictProton.js +1 -1
- package/lib/prediction/predictProton.js.map +1 -1
- package/lib/prediction/utils/fetchPrediction.d.ts +1 -1
- package/lib/prediction/utils/getFilteredIDiaIDs.js +1 -1
- package/lib/prediction/utils/getFilteredIDiaIDs.js.map +1 -1
- package/lib/prediction/utils/isEmptyMolecule.d.ts +1 -1
- package/lib/prediction/utils/predict2D.d.ts +1 -1
- package/lib/utilities/resurrectRange.js +1 -1
- package/lib/utilities/resurrectRange.js.map +1 -1
- package/lib/xyz/util/phaseCorrection/applyOverImag.js +1 -1
- package/lib/xyz/util/phaseCorrection/applyOverImag.js.map +1 -1
- package/lib/xyz/util/phaseCorrection/applyOverReal.js +1 -1
- package/lib/xyz/util/phaseCorrection/applyOverReal.js.map +1 -1
- package/lib/xyz/xyzPhaseCorrectionDirectDimension.js +1 -1
- package/lib/xyz/xyzPhaseCorrectionDirectDimension.js.map +1 -1
- package/lib/xyz/xyzPhaseCorrectionIndirectDimension.js +1 -1
- package/lib/xyz/xyzPhaseCorrectionIndirectDimension.js.map +1 -1
- package/lib-esm/assignment/get13CAssignments.js +2 -2
- package/lib-esm/assignment/get13CAssignments.js.map +1 -1
- package/lib-esm/assignment/get1HAssignments.js +2 -2
- package/lib-esm/assignment/get1HAssignments.js.map +1 -1
- package/lib-esm/assignment/getAssignments.js +2 -2
- package/lib-esm/assignment/getAssignments.js.map +1 -1
- package/lib-esm/datum/Filters.js +2 -2
- package/lib-esm/datum/Filters.js.map +1 -1
- package/lib-esm/datum/data1d/utils/getShiftX.js +1 -2
- package/lib-esm/datum/data1d/utils/getShiftX.js.map +1 -1
- package/lib-esm/datum/data2d/filter2d/fftDimension1.js +1 -2
- package/lib-esm/datum/data2d/filter2d/fftDimension1.js.map +1 -1
- package/lib-esm/datum/data2d/filter2d/fftDimension2.js +2 -2
- package/lib-esm/datum/data2d/filter2d/fftDimension2.js.map +1 -1
- package/lib-esm/datum/data2d/filter2d/shiftX.js +8 -10
- package/lib-esm/datum/data2d/filter2d/shiftX.js.map +1 -1
- package/lib-esm/datum/data2d/filter2d/shiftY.js +8 -10
- package/lib-esm/datum/data2d/filter2d/shiftY.js.map +1 -1
- package/lib-esm/prediction/predictAll.js +10 -10
- package/lib-esm/prediction/predictAll.js.map +1 -1
- package/lib-esm/prediction/predictProton.js +2 -2
- package/lib-esm/prediction/predictProton.js.map +1 -1
- package/lib-esm/prediction/utils/getFilteredIDiaIDs.js +2 -2
- package/lib-esm/prediction/utils/getFilteredIDiaIDs.js.map +1 -1
- package/lib-esm/utilities/resurrectRange.js +1 -1
- package/lib-esm/utilities/resurrectRange.js.map +1 -1
- package/lib-esm/xyz/util/phaseCorrection/applyOverImag.js +1 -1
- package/lib-esm/xyz/util/phaseCorrection/applyOverImag.js.map +1 -1
- package/lib-esm/xyz/util/phaseCorrection/applyOverReal.js +1 -1
- package/lib-esm/xyz/util/phaseCorrection/applyOverReal.js.map +1 -1
- package/lib-esm/xyz/xyzPhaseCorrectionDirectDimension.js +1 -1
- package/lib-esm/xyz/xyzPhaseCorrectionDirectDimension.js.map +1 -1
- package/lib-esm/xyz/xyzPhaseCorrectionIndirectDimension.js +1 -1
- package/lib-esm/xyz/xyzPhaseCorrectionIndirectDimension.js.map +1 -1
- package/package.json +20 -20
- package/src/assignment/get13CAssignments.ts +2 -2
- package/src/assignment/get1HAssignments.ts +2 -2
- package/src/assignment/getAssignments.ts +2 -2
- package/src/assignment/utils/generalAssignment/buildAssignments.ts +1 -1
- package/src/datum/Filters.ts +2 -2
- package/src/datum/data1d/utils/getShiftX.ts +3 -3
- package/src/datum/data2d/filter2d/fftDimension1.ts +7 -7
- package/src/datum/data2d/filter2d/fftDimension2.ts +6 -5
- package/src/datum/data2d/filter2d/shiftX.ts +12 -11
- package/src/datum/data2d/filter2d/shiftY.ts +12 -10
- package/src/openchemlib-utils.d.ts +2 -2
- package/src/prediction/Prediction2D.ts +1 -1
- package/src/prediction/predictAll.ts +10 -11
- package/src/prediction/predictCOSY.ts +1 -1
- package/src/prediction/predictHMBC.ts +1 -1
- package/src/prediction/predictHSQC.ts +1 -1
- package/src/prediction/predictProton.ts +2 -2
- package/src/prediction/utils/fetchPrediction.ts +1 -1
- package/src/prediction/utils/getFilteredIDiaIDs.ts +2 -2
- package/src/prediction/utils/isEmptyMolecule.ts +1 -1
- package/src/prediction/utils/predict2D.ts +1 -1
- package/src/utilities/resurrectRange.ts +1 -1
- package/src/xyz/util/phaseCorrection/applyOverImag.ts +4 -2
- package/src/xyz/util/phaseCorrection/applyOverReal.ts +4 -2
- package/src/xyz/xyzPhaseCorrectionDirectDimension.ts +3 -1
- package/src/xyz/xyzPhaseCorrectionIndirectDimension.ts +4 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Molecule } from 'openchemlib/full';
|
|
2
|
-
import {
|
|
2
|
+
import { ensureHeterotopicChiralBonds } from 'openchemlib-utils';
|
|
3
3
|
|
|
4
4
|
import { NMRSignal1D } from '..';
|
|
5
5
|
import type { PredictCarbonOptions } from '../prediction/predictCarbon';
|
|
@@ -115,7 +115,7 @@ export async function getAssignments(
|
|
|
115
115
|
if (!molecule) throw new Error('It is needed a molecule to assign');
|
|
116
116
|
|
|
117
117
|
molecule.addImplicitHydrogens();
|
|
118
|
-
|
|
118
|
+
ensureHeterotopicChiralBonds(molecule);
|
|
119
119
|
|
|
120
120
|
const spectra = checkIDs(input.spectra);
|
|
121
121
|
const { targets, correlations } = getTargetsAndCorrelations(
|
package/src/datum/Filters.ts
CHANGED
|
@@ -9,10 +9,10 @@ import * as phaseCorrection from './data1d/filter1d/phaseCorrection';
|
|
|
9
9
|
import * as shiftX from './data1d/filter1d/shiftX';
|
|
10
10
|
import * as signalProcessing from './data1d/filter1d/signalProcessing';
|
|
11
11
|
import * as zeroFilling from './data1d/filter1d/zeroFilling';
|
|
12
|
-
import * as shift2DX from './data2d/filter2d/shiftX';
|
|
13
|
-
import * as shift2DY from './data2d/filter2d/shiftY';
|
|
14
12
|
import * as fftDimension1 from './data2d/filter2d/fftDimension1';
|
|
15
13
|
import * as fftDimension2 from './data2d/filter2d/fftDimension2';
|
|
14
|
+
import * as shift2DX from './data2d/filter2d/shiftX';
|
|
15
|
+
import * as shift2DY from './data2d/filter2d/shiftY';
|
|
16
16
|
|
|
17
17
|
export type { ApodizationOptions } from './data1d/filter1d/apodization/apodization';
|
|
18
18
|
export type {
|
|
@@ -2,9 +2,9 @@ import { Filters } from '../../Filters';
|
|
|
2
2
|
import { Entry1D } from '../Entry1D';
|
|
3
3
|
|
|
4
4
|
export function getShiftX(spectrum: Entry1D): number {
|
|
5
|
-
const filter =
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
const filter = spectrum?.filters?.find(
|
|
6
|
+
(filter) => filter.name === Filters.shiftX.id,
|
|
7
|
+
);
|
|
8
8
|
|
|
9
9
|
return filter?.flag ? filter.value.shift : 0;
|
|
10
10
|
}
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { DoubleArray, NmrData2DFid } from 'cheminfo-types';
|
|
2
|
-
import { FilterDomainUpdateRules } from '../../FiltersManager';
|
|
3
|
-
import { Entry2D } from '../Entry2D';
|
|
4
|
-
import {
|
|
5
|
-
DirectDimensionOptions,
|
|
6
|
-
fftDirectDimension,
|
|
7
|
-
} from '../../../xyz/util/fft2d/fftDirectDimension';
|
|
8
2
|
import {
|
|
9
3
|
xAdd,
|
|
10
4
|
xEnsureFloat64,
|
|
11
5
|
xMultiply,
|
|
12
6
|
xSubtract,
|
|
13
7
|
} from 'ml-spectra-processing';
|
|
8
|
+
|
|
14
9
|
import { Data2DFidComplete } from '../../../utilities/checkData2DFid';
|
|
10
|
+
import {
|
|
11
|
+
DirectDimensionOptions,
|
|
12
|
+
fftDirectDimension,
|
|
13
|
+
} from '../../../xyz/util/fft2d/fftDirectDimension';
|
|
14
|
+
import { FilterDomainUpdateRules } from '../../FiltersManager';
|
|
15
|
+
import { Entry2D } from '../Entry2D';
|
|
15
16
|
|
|
16
17
|
export const id = 'fftDimension1';
|
|
17
18
|
export const name = 'FFT Dimension 1';
|
|
@@ -26,7 +27,6 @@ export function apply(datum2D: Entry2D, options: DirectDimensionOptions) {
|
|
|
26
27
|
throw new Error('fft dimension 1 not applicable on this data');
|
|
27
28
|
}
|
|
28
29
|
|
|
29
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
30
30
|
const { data, info } = datum2D;
|
|
31
31
|
const { digitalFilter: digitalFilterValue = 0 } = info;
|
|
32
32
|
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { NmrData2DFid, NmrData2DFt } from 'cheminfo-types';
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
2
|
+
import Matrix from 'ml-matrix';
|
|
3
|
+
import { xEnsureFloat64 } from 'ml-spectra-processing';
|
|
4
|
+
|
|
4
5
|
import {
|
|
5
6
|
IndirectDimensionOptions,
|
|
6
7
|
fftIndirectDimension,
|
|
7
8
|
} from '../../../xyz/util/fft2d/fftIndirectDimension';
|
|
8
|
-
import { xEnsureFloat64 } from 'ml-spectra-processing';
|
|
9
9
|
import { getMinMaxXY } from '../../../xyz/util/getMinMaxXY';
|
|
10
|
-
import
|
|
10
|
+
import { FilterDomainUpdateRules } from '../../FiltersManager';
|
|
11
|
+
import { Entry2D } from '../Entry2D';
|
|
11
12
|
|
|
12
13
|
export const id = 'fftDimension2';
|
|
13
14
|
export const name = 'FFT Dimension 2';
|
|
@@ -73,7 +74,7 @@ function getQuadrants(
|
|
|
73
74
|
return quadrants as NmrData2DFt;
|
|
74
75
|
};
|
|
75
76
|
|
|
76
|
-
if (fnMode === 'QF') {
|
|
77
|
+
if (fnMode[1] === 'QF') {
|
|
77
78
|
return buildQuandrants(['rr', 'ir']);
|
|
78
79
|
}
|
|
79
80
|
|
|
@@ -11,17 +11,15 @@ export const DOMAIN_UPDATE_RULES: Readonly<FilterDomainUpdateRules> = {
|
|
|
11
11
|
updateYDomain: false,
|
|
12
12
|
};
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
export function apply(datum2D: Entry2D, shiftValue = 0) {
|
|
14
|
+
interface Shift2DXOptions {
|
|
15
|
+
shift: number;
|
|
16
|
+
}
|
|
17
|
+
export function apply(datum2D: Entry2D, options: Shift2DXOptions) {
|
|
18
|
+
const { shift } = options;
|
|
21
19
|
const data: Record<string, NmrData2DContent> = { ...datum2D.data };
|
|
22
20
|
for (const key in data) {
|
|
23
|
-
data[key].minX +=
|
|
24
|
-
data[key].maxX +=
|
|
21
|
+
data[key].minX += shift;
|
|
22
|
+
data[key].maxX += shift;
|
|
25
23
|
}
|
|
26
24
|
}
|
|
27
25
|
|
|
@@ -29,9 +27,12 @@ export function isApplicable() {
|
|
|
29
27
|
return true;
|
|
30
28
|
}
|
|
31
29
|
|
|
32
|
-
export function reduce(
|
|
30
|
+
export function reduce(previous: Shift2DXOptions, next: Shift2DXOptions) {
|
|
31
|
+
const { shift: previousValue = 0 } = previous;
|
|
32
|
+
const { shift: nextShift } = next;
|
|
33
|
+
|
|
33
34
|
return {
|
|
34
35
|
once: true,
|
|
35
|
-
reduce: previousValue +
|
|
36
|
+
reduce: previousValue + nextShift,
|
|
36
37
|
};
|
|
37
38
|
}
|
|
@@ -11,16 +11,16 @@ export const DOMAIN_UPDATE_RULES: Readonly<FilterDomainUpdateRules> = {
|
|
|
11
11
|
updateYDomain: true,
|
|
12
12
|
};
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
14
|
+
interface Shift2DYOptions {
|
|
15
|
+
shift: number;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export function apply(datum2D: Entry2D, options: Shift2DYOptions) {
|
|
19
|
+
const { shift } = options;
|
|
20
20
|
const data: Record<string, NmrData2DContent> = { ...datum2D.data };
|
|
21
21
|
for (const key in data) {
|
|
22
|
-
data[key].minY +=
|
|
23
|
-
data[key].maxY +=
|
|
22
|
+
data[key].minY += shift;
|
|
23
|
+
data[key].maxY += shift;
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
26
|
|
|
@@ -28,9 +28,11 @@ export function isApplicable() {
|
|
|
28
28
|
return true;
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
-
export function reduce(
|
|
31
|
+
export function reduce(previous: Shift2DYOptions, next: Shift2DYOptions) {
|
|
32
|
+
const { shift: previousValue = 0 } = previous;
|
|
33
|
+
const { shift: nextShift } = next;
|
|
32
34
|
return {
|
|
33
35
|
once: true,
|
|
34
|
-
reduce: previousValue +
|
|
36
|
+
reduce: previousValue + nextShift,
|
|
35
37
|
};
|
|
36
38
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
declare module 'openchemlib-utils' {
|
|
2
|
-
import { Molecule } from 'openchemlib/full';
|
|
2
|
+
import type { Molecule } from 'openchemlib/full';
|
|
3
3
|
|
|
4
4
|
export interface GroupDiastereotopicAtomIDs {
|
|
5
5
|
counter: number;
|
|
@@ -38,7 +38,7 @@ declare module 'openchemlib-utils' {
|
|
|
38
38
|
options: GetHoseCodesForAtomOptions,
|
|
39
39
|
): string[];
|
|
40
40
|
|
|
41
|
-
function
|
|
41
|
+
function ensureHeterotopicChiralBonds(molecule: Molecule): Molecule;
|
|
42
42
|
|
|
43
43
|
export interface GetPathsInfoOptions {
|
|
44
44
|
fromLabel?: string;
|
|
@@ -72,10 +72,9 @@ export async function predictAll(
|
|
|
72
72
|
} = options;
|
|
73
73
|
|
|
74
74
|
const diaIDs = getDiastereotopicAtomIDs(molecule);
|
|
75
|
-
|
|
76
75
|
let { predictions } = options;
|
|
77
76
|
|
|
78
|
-
const
|
|
77
|
+
const protonPrediction = await getPredictions(
|
|
79
78
|
'H',
|
|
80
79
|
molecule,
|
|
81
80
|
predictOptions,
|
|
@@ -83,7 +82,7 @@ export async function predictAll(
|
|
|
83
82
|
predictions,
|
|
84
83
|
);
|
|
85
84
|
|
|
86
|
-
const
|
|
85
|
+
const carbonPrediction = await getPredictions(
|
|
87
86
|
'C',
|
|
88
87
|
molecule,
|
|
89
88
|
predictOptions,
|
|
@@ -91,23 +90,23 @@ export async function predictAll(
|
|
|
91
90
|
predictions,
|
|
92
91
|
);
|
|
93
92
|
|
|
94
|
-
if (!
|
|
93
|
+
if (!protonPrediction || !carbonPrediction) {
|
|
95
94
|
throw new Error('predictions are not availaible');
|
|
96
95
|
}
|
|
97
96
|
|
|
98
97
|
const spectra: any = {};
|
|
99
|
-
if (check1DPrediction(
|
|
100
|
-
spectra.proton =
|
|
98
|
+
if (check1DPrediction(protonPrediction)) {
|
|
99
|
+
spectra.proton = protonPrediction;
|
|
101
100
|
}
|
|
102
|
-
if (check1DPrediction(
|
|
103
|
-
spectra.carbon =
|
|
101
|
+
if (check1DPrediction(carbonPrediction)) {
|
|
102
|
+
spectra.carbon = carbonPrediction;
|
|
104
103
|
}
|
|
105
104
|
|
|
106
|
-
const { molfile } =
|
|
105
|
+
const { molfile } = protonPrediction;
|
|
107
106
|
|
|
108
107
|
predictions = {
|
|
109
|
-
H:
|
|
110
|
-
C:
|
|
108
|
+
H: protonPrediction,
|
|
109
|
+
C: carbonPrediction,
|
|
111
110
|
};
|
|
112
111
|
|
|
113
112
|
if (spectra.proton) {
|
|
@@ -3,7 +3,7 @@ import fetch from 'cross-fetch';
|
|
|
3
3
|
import FormData from 'form-data';
|
|
4
4
|
import type { Molecule } from 'openchemlib/full';
|
|
5
5
|
import {
|
|
6
|
-
|
|
6
|
+
ensureHeterotopicChiralBonds,
|
|
7
7
|
getConnectivityMatrix,
|
|
8
8
|
getDiastereotopicAtomIDs,
|
|
9
9
|
} from 'openchemlib-utils';
|
|
@@ -51,7 +51,7 @@ export async function predictProton(
|
|
|
51
51
|
const { cache } = options;
|
|
52
52
|
molecule = molecule.getCompactCopy();
|
|
53
53
|
molecule.addImplicitHydrogens();
|
|
54
|
-
|
|
54
|
+
ensureHeterotopicChiralBonds(molecule);
|
|
55
55
|
const molfile = molecule.toMolfile();
|
|
56
56
|
|
|
57
57
|
let result;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Molecule } from 'openchemlib/full';
|
|
2
2
|
import {
|
|
3
3
|
getHoseCodesFromDiastereotopicID,
|
|
4
|
-
|
|
4
|
+
ensureHeterotopicChiralBonds,
|
|
5
5
|
groupDiastereotopicAtomIDs,
|
|
6
6
|
} from 'openchemlib-utils';
|
|
7
7
|
import type { GroupDiastereotopicAtomIDs } from 'openchemlib-utils';
|
|
@@ -20,7 +20,7 @@ export function getFilteredIDiaIDs(
|
|
|
20
20
|
|
|
21
21
|
molecule.addImplicitHydrogens();
|
|
22
22
|
molecule.addMissingChirality();
|
|
23
|
-
|
|
23
|
+
ensureHeterotopicChiralBonds(molecule);
|
|
24
24
|
|
|
25
25
|
const molfile = molecule.toMolfile();
|
|
26
26
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { v4 as generateID } from '@lukeed/uuid';
|
|
2
2
|
import { agnes, Cluster } from 'ml-hclust';
|
|
3
3
|
import { Matrix } from 'ml-matrix';
|
|
4
|
-
import { Molecule } from 'openchemlib/full';
|
|
4
|
+
import type { Molecule } from 'openchemlib/full';
|
|
5
5
|
import {
|
|
6
6
|
getGroupedDiastereotopicAtomIDs,
|
|
7
7
|
getPathsInfo,
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { NmrData2DFt } from 'cheminfo-types';
|
|
2
|
-
import { PhaseCorrectionOptions } from '../../xyzPhaseCorrectionDirectDimension';
|
|
3
|
-
import { getZMinMax } from './getZMinMax';
|
|
4
2
|
import Matrix from 'ml-matrix';
|
|
3
|
+
|
|
4
|
+
import { PhaseCorrectionOptions } from '../../xyzPhaseCorrectionDirectDimension';
|
|
5
|
+
|
|
5
6
|
import { checkNmrData2DFourQuad } from './checkNmrData2DFourQuad';
|
|
7
|
+
import { getZMinMax } from './getZMinMax';
|
|
6
8
|
|
|
7
9
|
export function applyOverImag<T extends NmrData2DFt>(
|
|
8
10
|
data: T,
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { NmrData2DFt } from 'cheminfo-types';
|
|
2
|
-
import { checkNmrData2DTwoQuad } from './checkNmrData2DTwoQuad';
|
|
3
2
|
import Matrix from 'ml-matrix';
|
|
4
|
-
|
|
3
|
+
|
|
5
4
|
import { PhaseCorrectionOptions } from '../../xyzPhaseCorrectionDirectDimension';
|
|
6
5
|
|
|
6
|
+
import { checkNmrData2DTwoQuad } from './checkNmrData2DTwoQuad';
|
|
7
|
+
import { getZMinMax } from './getZMinMax';
|
|
8
|
+
|
|
7
9
|
export function applyOverReal<T extends NmrData2DFt>(
|
|
8
10
|
data: T,
|
|
9
11
|
options: PhaseCorrectionOptions,
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { NmrData2DFt } from 'cheminfo-types';
|
|
2
|
-
import { degreeToRadians } from '../constants/degreeToRadians';
|
|
3
2
|
import Matrix from 'ml-matrix';
|
|
4
3
|
import { reimPhaseCorrection } from 'ml-spectra-processing';
|
|
4
|
+
|
|
5
|
+
import { degreeToRadians } from '../constants/degreeToRadians';
|
|
6
|
+
|
|
5
7
|
import { applyOverImag } from './util/phaseCorrection/applyOverImag';
|
|
6
8
|
import { applyOverReal } from './util/phaseCorrection/applyOverReal';
|
|
7
9
|
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { NmrData2DFt } from 'cheminfo-types';
|
|
2
|
-
import { degreeToRadians } from '../constants/degreeToRadians';
|
|
3
2
|
import Matrix from 'ml-matrix';
|
|
4
3
|
import { reimPhaseCorrection } from 'ml-spectra-processing';
|
|
4
|
+
|
|
5
|
+
import { degreeToRadians } from '../constants/degreeToRadians';
|
|
6
|
+
|
|
5
7
|
import { applyOverImag } from './util/phaseCorrection/applyOverImag';
|
|
6
|
-
import { PhaseCorrectionOptions } from './xyzPhaseCorrectionDirectDimension';
|
|
7
8
|
import { applyOverReal } from './util/phaseCorrection/applyOverReal';
|
|
9
|
+
import { PhaseCorrectionOptions } from './xyzPhaseCorrectionDirectDimension';
|
|
8
10
|
|
|
9
11
|
export type PhaseCorrectionIndirectDimensionOptions = PhaseCorrectionOptions & {
|
|
10
12
|
quad: 'imag' | 'real';
|