nmrium 0.38.1 → 0.38.2
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/component/1d/ApodizationLine.js +27 -4
- package/lib/component/1d/ExclusionZoneAnnotation.js +1 -1
- package/lib/component/1d/ExclusionZonesAnnotations.js +1 -1
- package/lib/component/1d/FooterBanner.js +5 -5
- package/lib/component/1d/SpectraLegends.js +2 -3
- package/lib/component/1d/Viewer1D.js +1 -1
- package/lib/component/1d/integral/Integral.d.ts +1 -1
- package/lib/component/1d/integral/IntegralResizable.d.ts +1 -1
- package/lib/component/1d/jCouplingGraph/JsCouplings.d.ts +1 -1
- package/lib/component/1d/multiAnalysis/MultiAnalysisRanges.js +2 -2
- package/lib/component/1d/multiplicityTree/LevelNode.d.ts +1 -1
- package/lib/component/1d/multiplicityTree/MultiplicityTree.d.ts +1 -1
- package/lib/component/1d/multiplicityTree/StringNode.d.ts +1 -1
- package/lib/component/1d/multiplicityTree/buildTreeNode.d.ts +1 -1
- package/lib/component/1d/peaks/usePeakShapesPath.d.ts +2 -1
- package/lib/component/1d/ranges/Range.d.ts +1 -1
- package/lib/component/1d/tool/PeakPointer.js +6 -6
- package/lib/component/1d/tool/XLabelPointer.js +5 -5
- package/lib/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.d.ts +1 -1
- package/lib/component/1d-2d/components/FloatMoleculeStructures/index.d.ts +1 -1
- package/lib/component/1d-2d/tools/BrushX.js +2 -3
- package/lib/component/1d-2d/tools/BrushXY.js +2 -3
- package/lib/component/1d-2d/tools/CrossLinePointer.js +4 -5
- package/lib/component/2d/Chart2D.js +4 -4
- package/lib/component/2d/FooterBanner.js +5 -5
- package/lib/component/2d/Viewer2D.js +1 -1
- package/lib/component/2d/tools/XYLabelPointer.js +5 -5
- package/lib/component/2d/zones/Signal.d.ts +1 -1
- package/lib/component/2d/zones/SignalCrosshair.d.ts +1 -1
- package/lib/component/2d/zones/Zone.d.ts +1 -1
- package/lib/component/EventsTrackers/BrushTracker.d.ts +20 -12
- package/lib/component/EventsTrackers/BrushTracker.js +35 -22
- package/lib/component/EventsTrackers/MouseTracker.d.ts +6 -2
- package/lib/component/EventsTrackers/MouseTracker.js +4 -1
- package/lib/component/NMRium.d.ts +4 -5
- package/lib/component/NMRium.js +11 -14
- package/lib/component/assignment/AssignmentsReducer.d.ts +2 -2
- package/lib/component/context/PreferencesContext.d.ts +6 -6
- package/lib/component/elements/Button.d.ts +13 -11
- package/lib/component/elements/Button.js +16 -25
- package/lib/component/elements/ColorInput.d.ts +0 -1
- package/lib/component/elements/ColorInput.js +2 -2
- package/lib/component/elements/EditableColumn.js +5 -2
- package/lib/component/elements/Input.js +2 -4
- package/lib/component/elements/Label.d.ts +1 -0
- package/lib/component/elements/Label.js +2 -2
- package/lib/component/elements/MolecularFormulaInput.d.ts +2 -2
- package/lib/component/elements/MolecularFormulaInput.js +15 -18
- package/lib/component/elements/NextPrev.d.ts +5 -3
- package/lib/component/elements/NextPrev.js +26 -8
- package/lib/component/elements/NumberInput.js +2 -2
- package/lib/component/elements/ReactTable/ReactTable.js +4 -4
- package/lib/component/elements/formik/FormikCheckBox.d.ts +2 -1
- package/lib/component/elements/formik/FormikCheckBox.js +2 -2
- package/lib/component/elements/formik/FormikColumnFormatField.d.ts +4 -0
- package/lib/component/elements/formik/FormikColumnFormatField.js +19 -16
- package/lib/component/elements/formik/FormikInput.js +10 -6
- package/lib/component/elements/formik/FormikSelect.js +1 -1
- package/lib/component/header/ApodizationOptionsPanel.js +4 -3
- package/lib/component/header/AutoPeakPickingOptionPanel.js +16 -7
- package/lib/component/header/BaseLineCorrectionPanel.js +5 -2
- package/lib/component/header/PhaseCorrectionPanel.js +5 -2
- package/lib/component/header/RangesPickingOptionPanel.js +15 -7
- package/lib/component/header/ZeroFillingOptionsPanel.js +1 -1
- package/lib/component/highlight/index.d.ts +1 -1
- package/lib/component/hooks/useActiveSpectra.d.ts +1 -1
- package/lib/component/hooks/useActiveSpectrum.d.ts +1 -1
- package/lib/component/hooks/useActiveSpectrumPeaksViewState.d.ts +1 -1
- package/lib/component/hooks/useCheckPointsNumberInWindowArea.d.ts +2 -0
- package/lib/component/hooks/useCheckPointsNumberInWindowArea.js +17 -0
- package/lib/component/hooks/useCheckToolsVisibility.d.ts +2 -2
- package/lib/component/hooks/useDatumWithSpectraStatistics.d.ts +3 -2
- package/lib/component/hooks/useExport.js +1 -1
- package/lib/component/hooks/useFilter.d.ts +2 -1
- package/lib/component/hooks/usePanelPreferences.d.ts +3 -3
- package/lib/component/hooks/usePanelPreferences.js +4 -0
- package/lib/component/hooks/useSaveSettings.d.ts +1 -1
- package/lib/component/hooks/useSaveSettings.js +1 -1
- package/lib/component/hooks/useVerticalAlign.d.ts +1 -1
- package/lib/component/loader/DropZone.js +1 -2
- package/lib/component/modal/EditPeakShapeModal.d.ts +2 -2
- package/lib/component/modal/LoadJCAMPModal.d.ts +3 -3
- package/lib/component/modal/LoadJCAMPModal.js +35 -66
- package/lib/component/modal/ModalStyle.js +0 -10
- package/lib/component/modal/MoleculeStructureEditorModal.d.ts +2 -1
- package/lib/component/modal/MoleculeStructureEditorModal.js +12 -6
- package/lib/component/modal/MultipletAnalysisModal.d.ts +2 -2
- package/lib/component/modal/PredictSpectraModal.d.ts +4 -2
- package/lib/component/modal/PredictSpectraModal.js +43 -105
- package/lib/component/modal/SaveAsModal.d.ts +2 -0
- package/lib/component/modal/SaveAsModal.js +21 -14
- package/lib/component/modal/changeSum/ChangeSumModal.js +25 -38
- package/lib/component/modal/editRange/forms/components/AddSignalFormTab.d.ts +1 -1
- package/lib/component/modal/editRange/forms/components/DeltaInput.js +2 -0
- package/lib/component/modal/editRange/forms/components/SignalsForm.d.ts +2 -2
- package/lib/component/modal/metaImportation/MetaImportationModal.js +15 -5
- package/lib/component/modal/setting/GeneralSettings.js +1 -6
- package/lib/component/modal/setting/settings-tabs/DatabasesTabContent.d.ts +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralPanel.d.ts +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralTable.d.ts +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralsPreferences.js +7 -15
- package/lib/component/panels/MoleculesPanel/MoleculeHeader.js +2 -2
- package/lib/component/panels/MoleculesPanel/MoleculePanel.d.ts +1 -11
- package/lib/component/panels/MoleculesPanel/MoleculePanel.js +20 -25
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.d.ts +6 -11
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js +71 -81
- package/lib/component/panels/MoleculesPanel/Utilities.d.ts +1 -1
- package/lib/component/panels/MoleculesPanel/Utilities.js +3 -1
- package/lib/component/panels/MultipleSpectraAnalysisPanel/base/AnalysisColumnHeader.js +6 -6
- package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/AnalysisTablePreferences.js +2 -2
- package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/index.js +2 -2
- package/lib/component/panels/PeaksPanel/PeaksPanel.d.ts +1 -1
- package/lib/component/panels/RangesPanel/RangesHeader.js +39 -53
- package/lib/component/panels/RangesPanel/RangesPreferences.d.ts +1 -1
- package/lib/component/panels/RangesPanel/RangesPreferences.js +7 -22
- package/lib/component/panels/RangesPanel/RangesTable.d.ts +2 -2
- package/lib/component/panels/RangesPanel/RangesTableRow.d.ts +2 -2
- package/lib/component/panels/RangesPanel/TableColumns/SignalDeltaHzColumn.d.ts +1 -1
- package/lib/component/panels/RangesPanel/hooks/useMapRanges.d.ts +1 -1
- package/lib/component/panels/SpectrumsPanel/SpectraTable.js +5 -1
- package/lib/component/panels/SpectrumsPanel/base/SpectraColumnsManager.js +10 -4
- package/lib/component/panels/SpectrumsPanel/base/setting/processSnapPlot.d.ts +2 -2
- package/lib/component/panels/SummaryPanel/CorrelationTable/AdditionalColumnField.js +1 -1
- package/lib/component/panels/SummaryPanel/CorrelationTable/CorrelationTableRow.js +1 -1
- package/lib/component/panels/SummaryPanel/CorrelationTable/editLink/EditPathLength.d.ts +1 -1
- package/lib/component/panels/ZonesPanel/hooks/useMapZones.d.ts +1 -1
- package/lib/component/panels/databasePanel/DatabasePanel.d.ts +1 -1
- package/lib/component/panels/databasePanel/DatabasePanel.js +5 -24
- package/lib/component/panels/databasePanel/DatabasePreferences.js +2 -2
- package/lib/component/panels/header/DefaultPanelHeader.d.ts +2 -3
- package/lib/component/panels/header/DefaultPanelHeader.js +18 -26
- package/lib/component/panels/header/PanelHeader.d.ts +7 -0
- package/lib/component/panels/header/PanelHeader.js +12 -0
- package/lib/component/panels/predictionPanel/PredictionOptionsPanel.d.ts +9 -0
- package/lib/component/panels/predictionPanel/PredictionOptionsPanel.js +94 -0
- package/lib/component/panels/predictionPanel/PredictionPanel.d.ts +1 -1
- package/lib/component/panels/predictionPanel/PredictionPanel.js +107 -37
- package/lib/component/panels/predictionPanel/PredictionPreferences.d.ts +3 -0
- package/lib/component/panels/predictionPanel/PredictionPreferences.js +24 -0
- package/lib/component/panels/predictionPanel/PredictionSimpleOptions.d.ts +2 -0
- package/lib/component/panels/predictionPanel/PredictionSimpleOptions.js +44 -0
- package/lib/component/reducer/Reducer.d.ts +5 -87
- package/lib/component/reducer/Reducer.js +1 -29
- package/lib/component/reducer/actions/FiltersActions.d.ts +1 -2
- package/lib/component/reducer/actions/FiltersActions.js +47 -52
- package/lib/component/reducer/actions/HistoryActions.d.ts +4 -0
- package/lib/component/reducer/actions/HistoryActions.js +40 -0
- package/lib/component/reducer/actions/IntegralsActions.d.ts +1 -1
- package/lib/component/reducer/actions/LoadActions.d.ts +1 -2
- package/lib/component/reducer/actions/LoadActions.js +1 -1
- package/lib/component/reducer/actions/MoleculeActions.d.ts +7 -4
- package/lib/component/reducer/actions/MoleculeActions.js +57 -28
- package/lib/component/reducer/actions/PeaksActions.d.ts +1 -2
- package/lib/component/reducer/actions/PeaksActions.js +3 -3
- package/lib/component/reducer/actions/RangesActions.d.ts +4 -5
- package/lib/component/reducer/actions/RangesActions.js +5 -27
- package/lib/component/reducer/actions/SpectrumsActions.js +2 -2
- package/lib/component/reducer/actions/ToolsActions.d.ts +2 -2
- package/lib/component/reducer/actions/ZonesActions.d.ts +2 -1
- package/lib/component/reducer/actions/ZonesActions.js +1 -2
- package/lib/component/reducer/helper/getActiveSpectra.d.ts +1 -1
- package/lib/component/reducer/helper/getActiveSpectrum.d.ts +1 -1
- package/lib/component/reducer/helper/getVerticalAlign.d.ts +1 -1
- package/lib/component/reducer/preferences/panelsPreferencesDefaultValues.d.ts +1 -1
- package/lib/component/reducer/preferences/preferencesReducer.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/getActiveWorkspace.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/getPreferencesByWorkspace.d.ts +2 -3
- package/lib/component/reducer/preferences/utilities/initWorkspace.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/mapNucleiFormatting.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/mapWorkspaces.d.ts +1 -1
- package/lib/component/toolbar/BasicToolBar.js +6 -11
- package/lib/component/toolbar/ToolTypes.d.ts +2 -2
- package/lib/component/toolbar/ToolTypes.js +1 -1
- package/lib/component/workspaces/assignment.d.ts +1 -1
- package/lib/component/workspaces/basic.d.ts +1 -1
- package/lib/component/workspaces/embedded.d.ts +1 -1
- package/lib/component/workspaces/exercise.d.ts +1 -1
- package/lib/component/workspaces/index.d.ts +6 -6
- package/lib/component/workspaces/prediction.d.ts +1 -1
- package/lib/component/workspaces/prediction.js +193 -0
- package/lib/component/workspaces/process1D.d.ts +1 -1
- package/lib/component/workspaces/workspaceDefaultProperties.d.ts +1 -1
- package/lib/component/workspaces/workspaceDefaultProperties.js +1 -1
- package/lib/data/PredictionManager.js +16 -2
- package/lib/data/SpectraManager.d.ts +1 -2
- package/lib/data/constants/DefaultApodizationOptions.d.ts +2 -0
- package/lib/data/constants/DefaultApodizationOptions.js +5 -0
- package/lib/data/data1d/Spectrum1D/SumManager.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/convertDataToFloat64Array.d.ts +2 -2
- package/lib/data/data1d/Spectrum1D/generateJGraphData.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/index.d.ts +1 -5
- package/lib/data/data1d/Spectrum1D/index.js +1 -5
- package/lib/data/data1d/Spectrum1D/initiateDatum1D.js +3 -3
- package/lib/data/data1d/Spectrum1D/integrals/initiateIntegrals.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/integrals/initiateIntegrals.js +1 -1
- package/lib/data/data1d/Spectrum1D/isRangeAssigned.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/peaks/autoPeakPicking.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/peaks/autoPeakPicking.js +1 -2
- package/lib/data/data1d/Spectrum1D/peaks/initiatePeaks.d.ts +3 -2
- package/lib/data/data1d/Spectrum1D/peaks/initiatePeaks.js +1 -1
- package/lib/data/data1d/Spectrum1D/peaks/lookupPeak.d.ts +2 -2
- package/lib/data/data1d/Spectrum1D/peaks/optimizePeaks.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/peaks/optimizePeaks.js +1 -2
- package/lib/data/data1d/Spectrum1D/ranges/addRange.d.ts +7 -7
- package/lib/data/data1d/Spectrum1D/ranges/addRange.js +5 -24
- package/lib/data/data1d/Spectrum1D/ranges/autoRangesDetection.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/ranges/changeRange.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/ranges/changeRange.js +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/checkRangeKind.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/detectRange.js +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/detectRanges.js +1 -2
- package/lib/data/data1d/Spectrum1D/ranges/initiateRanges.d.ts +37 -2
- package/lib/data/data1d/Spectrum1D/ranges/initiateRanges.js +1 -1
- package/lib/data/data1d/database.js +2 -4
- package/lib/data/data1d/multipleSpectraAnalysis.d.ts +3 -30
- package/lib/data/data1d/multipleSpectraAnalysis.js +4 -15
- package/lib/data/data2d/Spectrum2D/getMissingProjection.d.ts +3 -2
- package/lib/data/data2d/Spectrum2D/getShift.js +1 -1
- package/lib/data/data2d/Spectrum2D/getSlice.d.ts +1 -1
- package/lib/data/data2d/Spectrum2D/initiateDatum2D.js +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZones.d.ts +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.d.ts +1 -1
- package/lib/data/data2d/Spectrum2D/zones/initiateZones.d.ts +3 -2
- package/lib/data/data2d/Spectrum2D/zones/isZoneExists.d.ts +2 -1
- package/lib/data/data2d/Spectrum2D/zones/mapZones.d.ts +3 -2
- package/lib/data/getDefaultMatrixFilters.d.ts +1 -1
- package/lib/data/types/data1d/ComplexData1D.d.ts +2 -2
- package/lib/data/types/data1d/RangeDetectionResult.d.ts +1 -1
- package/lib/data/utilities/FindUtilities.d.ts +2 -1
- package/lib/data/utilities/RangeUtilities.d.ts +1 -1
- package/lib/data/utilities/ZoneUtilities.d.ts +1 -1
- package/lib/data/utilities/calculateSanPlot.d.ts +2 -2
- package/lib/types/NMRiumDataReturn.d.ts +1 -3
- package/lib/versionInfo.js +1 -1
- package/lib-cjs/component/1d/ApodizationLine.js +28 -5
- package/lib-cjs/component/1d/ExclusionZoneAnnotation.js +3 -26
- package/lib-cjs/component/1d/ExclusionZonesAnnotations.js +5 -28
- package/lib-cjs/component/1d/FooterBanner.js +2 -2
- package/lib-cjs/component/1d/SpectraLegends.js +1 -2
- package/lib-cjs/component/1d/multiAnalysis/MultiAnalysisRanges.js +2 -2
- package/lib-cjs/component/1d/tool/PeakPointer.js +3 -3
- package/lib-cjs/component/1d/tool/XLabelPointer.js +2 -2
- package/lib-cjs/component/1d-2d/tools/BrushX.js +1 -2
- package/lib-cjs/component/1d-2d/tools/BrushXY.js +1 -2
- package/lib-cjs/component/1d-2d/tools/CrossLinePointer.js +2 -3
- package/lib-cjs/component/2d/Chart2D.js +4 -4
- package/lib-cjs/component/2d/FooterBanner.js +2 -2
- package/lib-cjs/component/2d/tools/XYLabelPointer.js +2 -2
- package/lib-cjs/component/EventsTrackers/BrushTracker.js +36 -22
- package/lib-cjs/component/EventsTrackers/MouseTracker.js +4 -1
- package/lib-cjs/component/NMRium.js +8 -11
- package/lib-cjs/component/elements/Button.js +16 -25
- package/lib-cjs/component/elements/ColorInput.js +2 -2
- package/lib-cjs/component/elements/EditableColumn.js +5 -2
- package/lib-cjs/component/elements/Input.js +2 -4
- package/lib-cjs/component/elements/Label.js +2 -2
- package/lib-cjs/component/elements/MolecularFormulaInput.js +14 -16
- package/lib-cjs/component/elements/NextPrev.js +26 -8
- package/lib-cjs/component/elements/NumberInput.js +2 -2
- package/lib-cjs/component/elements/ReactTable/ReactTable.js +4 -4
- package/lib-cjs/component/elements/formik/FormikCheckBox.js +2 -2
- package/lib-cjs/component/elements/formik/FormikColumnFormatField.js +20 -16
- package/lib-cjs/component/elements/formik/FormikInput.js +10 -6
- package/lib-cjs/component/elements/formik/FormikSelect.js +1 -1
- package/lib-cjs/component/header/ApodizationOptionsPanel.js +6 -5
- package/lib-cjs/component/header/AutoPeakPickingOptionPanel.js +15 -6
- package/lib-cjs/component/header/BaseLineCorrectionPanel.js +6 -3
- package/lib-cjs/component/header/PhaseCorrectionPanel.js +6 -26
- package/lib-cjs/component/header/RangesPickingOptionPanel.js +15 -7
- package/lib-cjs/component/header/ZeroFillingOptionsPanel.js +2 -25
- package/lib-cjs/component/hooks/useCheckPointsNumberInWindowArea.js +24 -0
- package/lib-cjs/component/hooks/useExport.js +1 -1
- package/lib-cjs/component/hooks/usePanelPreferences.js +4 -0
- package/lib-cjs/component/hooks/useSaveSettings.js +1 -1
- package/lib-cjs/component/loader/DropZone.js +1 -2
- package/lib-cjs/component/modal/LoadJCAMPModal.js +60 -67
- package/lib-cjs/component/modal/ModalStyle.js +0 -10
- package/lib-cjs/component/modal/MoleculeStructureEditorModal.js +12 -6
- package/lib-cjs/component/modal/PredictSpectraModal.js +43 -126
- package/lib-cjs/component/modal/SaveAsModal.js +22 -14
- package/lib-cjs/component/modal/changeSum/ChangeSumModal.js +24 -37
- package/lib-cjs/component/modal/editRange/forms/components/DeltaInput.js +2 -0
- package/lib-cjs/component/modal/metaImportation/MetaImportationModal.js +15 -5
- package/lib-cjs/component/modal/setting/GeneralSettings.js +1 -6
- package/lib-cjs/component/panels/IntegralsPanel/IntegralsPreferences.js +6 -14
- package/lib-cjs/component/panels/MoleculesPanel/MoleculeHeader.js +2 -2
- package/lib-cjs/component/panels/MoleculesPanel/MoleculePanel.js +19 -24
- package/lib-cjs/component/panels/MoleculesPanel/MoleculePanelHeader.js +76 -86
- package/lib-cjs/component/panels/MoleculesPanel/Utilities.js +3 -1
- package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/base/AnalysisColumnHeader.js +6 -6
- package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/AnalysisTablePreferences.js +2 -2
- package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/index.js +2 -2
- package/lib-cjs/component/panels/RangesPanel/RangesHeader.js +38 -52
- package/lib-cjs/component/panels/RangesPanel/RangesPreferences.js +5 -20
- package/lib-cjs/component/panels/SpectrumsPanel/SpectraTable.js +5 -1
- package/lib-cjs/component/panels/SpectrumsPanel/base/SpectraColumnsManager.js +10 -4
- package/lib-cjs/component/panels/SummaryPanel/CorrelationTable/AdditionalColumnField.js +1 -1
- package/lib-cjs/component/panels/SummaryPanel/CorrelationTable/CorrelationTableRow.js +1 -1
- package/lib-cjs/component/panels/databasePanel/DatabasePanel.js +5 -24
- package/lib-cjs/component/panels/databasePanel/DatabasePreferences.js +25 -2
- package/lib-cjs/component/panels/header/DefaultPanelHeader.js +18 -26
- package/lib-cjs/component/panels/header/PanelHeader.js +15 -0
- package/lib-cjs/component/panels/predictionPanel/PredictionOptionsPanel.js +122 -0
- package/lib-cjs/component/panels/predictionPanel/PredictionPanel.js +107 -37
- package/lib-cjs/component/panels/predictionPanel/PredictionPreferences.js +29 -0
- package/lib-cjs/component/panels/predictionPanel/PredictionSimpleOptions.js +72 -0
- package/lib-cjs/component/reducer/Reducer.js +2 -31
- package/lib-cjs/component/reducer/actions/FiltersActions.js +66 -94
- package/lib-cjs/component/reducer/actions/HistoryActions.js +45 -0
- package/lib-cjs/component/reducer/actions/MoleculeActions.js +58 -32
- package/lib-cjs/component/reducer/actions/PeaksActions.js +3 -3
- package/lib-cjs/component/reducer/actions/RangesActions.js +7 -52
- package/lib-cjs/component/reducer/actions/SpectrumsActions.js +4 -27
- package/lib-cjs/component/reducer/actions/ZonesActions.js +4 -28
- package/lib-cjs/component/toolbar/BasicToolBar.js +5 -10
- package/lib-cjs/component/toolbar/ToolTypes.js +9 -32
- package/lib-cjs/component/workspaces/prediction.js +193 -0
- package/lib-cjs/component/workspaces/workspaceDefaultProperties.js +21 -44
- package/lib-cjs/data/PredictionManager.js +16 -2
- package/lib-cjs/data/constants/DefaultApodizationOptions.js +8 -0
- package/lib-cjs/data/data1d/Spectrum1D/index.js +7 -11
- package/lib-cjs/data/data1d/Spectrum1D/initiateDatum1D.js +9 -32
- package/lib-cjs/data/data1d/Spectrum1D/integrals/initiateIntegrals.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/peaks/autoPeakPicking.js +1 -2
- package/lib-cjs/data/data1d/Spectrum1D/peaks/initiatePeaks.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/peaks/optimizePeaks.js +1 -2
- package/lib-cjs/data/data1d/Spectrum1D/ranges/addRange.js +7 -26
- package/lib-cjs/data/data1d/Spectrum1D/ranges/changeRange.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/ranges/detectRange.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/ranges/detectRanges.js +3 -4
- package/lib-cjs/data/data1d/Spectrum1D/ranges/initiateRanges.js +2 -2
- package/lib-cjs/data/data1d/database.js +2 -4
- package/lib-cjs/data/data1d/multipleSpectraAnalysis.js +5 -16
- package/lib-cjs/data/data2d/Spectrum2D/getShift.js +3 -26
- package/lib-cjs/data/data2d/Spectrum2D/initiateDatum2D.js +2 -25
- package/lib-cjs/versionInfo.js +1 -1
- package/package.json +25 -25
- package/lib/component/panels/predictionPanel/PredictionOptions.d.ts +0 -7
- package/lib/component/panels/predictionPanel/PredictionOptions.js +0 -74
- package/lib/component/workspaces/Workspace.d.ts +0 -188
- package/lib/component/workspaces/Workspace.js +0 -1
- package/lib/data/Filters.d.ts +0 -12
- package/lib/data/Filters.js +0 -12
- package/lib/data/FiltersManager.d.ts +0 -30
- package/lib/data/FiltersManager.js +0 -175
- package/lib/data/data1d/Spectrum1D/getShiftX.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/getShiftX.js +0 -6
- package/lib/data/data1d/Spectrum1D/getSpectrumErrorValue.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/getSpectrumErrorValue.js +0 -4
- package/lib/data/data1d/Spectrum1D/integrals/checkIntegralKind.d.ts +0 -7
- package/lib/data/data1d/Spectrum1D/integrals/checkIntegralKind.js +0 -9
- package/lib/data/data1d/Spectrum1D/integrals/mapIntegrals.d.ts +0 -12
- package/lib/data/data1d/Spectrum1D/integrals/mapIntegrals.js +0 -36
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegrals.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegrals.js +0 -6
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegralsRelativeValues.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegralsRelativeValues.js +0 -5
- package/lib/data/data1d/Spectrum1D/integrals/updateRelatives.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/integrals/updateRelatives.js +0 -26
- package/lib/data/data1d/Spectrum1D/peaks/mapPeaks.d.ts +0 -3
- package/lib/data/data1d/Spectrum1D/peaks/mapPeaks.js +0 -45
- package/lib/data/data1d/Spectrum1D/peaks/updatePeaks.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/peaks/updatePeaks.js +0 -7
- package/lib/data/data1d/Spectrum1D/ranges/mapRanges.d.ts +0 -4
- package/lib/data/data1d/Spectrum1D/ranges/mapRanges.js +0 -78
- package/lib/data/data1d/Spectrum1D/ranges/updateRanges.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/ranges/updateRanges.js +0 -9
- package/lib/data/data1d/Spectrum1D/ranges/updateRangesRelativeValues.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/ranges/updateRangesRelativeValues.js +0 -5
- package/lib/data/data1d/filter1d/apodization.d.ts +0 -27
- package/lib/data/data1d/filter1d/apodization.js +0 -81
- package/lib/data/data1d/filter1d/baselineCorrection.d.ts +0 -33
- package/lib/data/data1d/filter1d/baselineCorrection.js +0 -51
- package/lib/data/data1d/filter1d/digitalFilter.d.ts +0 -20
- package/lib/data/data1d/filter1d/digitalFilter.js +0 -44
- package/lib/data/data1d/filter1d/equallySpaced.d.ts +0 -33
- package/lib/data/data1d/filter1d/equallySpaced.js +0 -52
- package/lib/data/data1d/filter1d/exclusionZones.d.ts +0 -15
- package/lib/data/data1d/filter1d/exclusionZones.js +0 -32
- package/lib/data/data1d/filter1d/fft.d.ts +0 -18
- package/lib/data/data1d/filter1d/fft.js +0 -90
- package/lib/data/data1d/filter1d/phaseCorrection.d.ts +0 -26
- package/lib/data/data1d/filter1d/phaseCorrection.js +0 -64
- package/lib/data/data1d/filter1d/shiftX.d.ts +0 -20
- package/lib/data/data1d/filter1d/shiftX.js +0 -26
- package/lib/data/data1d/filter1d/signalProcessing.d.ts +0 -26
- package/lib/data/data1d/filter1d/signalProcessing.js +0 -65
- package/lib/data/data1d/filter1d/utils/padDataToNextPowerOfTwo.d.ts +0 -2
- package/lib/data/data1d/filter1d/utils/padDataToNextPowerOfTwo.js +0 -35
- package/lib/data/data1d/filter1d/zeroFilling.d.ts +0 -22
- package/lib/data/data1d/filter1d/zeroFilling.js +0 -60
- package/lib/data/data2d/filter2d/shiftX.d.ts +0 -18
- package/lib/data/data2d/filter2d/shiftX.js +0 -27
- package/lib/data/data2d/filter2d/shiftY.d.ts +0 -18
- package/lib/data/data2d/filter2d/shiftY.js +0 -27
- package/lib/data/types/view-state/PeaksViewState.d.ts +0 -17
- package/lib/data/types/view-state/PeaksViewState.js +0 -1
- package/lib/types/NMRiumGeneralPreferences.d.ts +0 -7
- package/lib/types/NMRiumGeneralPreferences.js +0 -1
- package/lib/types/NMRiumPanelPreferences.d.ts +0 -17
- package/lib/types/NMRiumPanelPreferences.js +0 -1
- package/lib/types/NMRiumToolBarPreferences.d.ts +0 -22
- package/lib/types/NMRiumToolBarPreferences.js +0 -1
- package/lib/types/PanelPreferencesType.d.ts +0 -4
- package/lib/types/PanelPreferencesType.js +0 -1
- package/lib-cjs/component/panels/predictionPanel/PredictionOptions.js +0 -102
- package/lib-cjs/component/workspaces/Workspace.js +0 -2
- package/lib-cjs/data/Filters.js +0 -38
- package/lib-cjs/data/FiltersManager.js +0 -206
- package/lib-cjs/data/data1d/Spectrum1D/getShiftX.js +0 -33
- package/lib-cjs/data/data1d/Spectrum1D/getSpectrumErrorValue.js +0 -8
- package/lib-cjs/data/data1d/Spectrum1D/integrals/checkIntegralKind.js +0 -13
- package/lib-cjs/data/data1d/Spectrum1D/integrals/mapIntegrals.js +0 -40
- package/lib-cjs/data/data1d/Spectrum1D/integrals/updateIntegrals.js +0 -10
- package/lib-cjs/data/data1d/Spectrum1D/integrals/updateIntegralsRelativeValues.js +0 -9
- package/lib-cjs/data/data1d/Spectrum1D/integrals/updateRelatives.js +0 -30
- package/lib-cjs/data/data1d/Spectrum1D/peaks/mapPeaks.js +0 -49
- package/lib-cjs/data/data1d/Spectrum1D/peaks/updatePeaks.js +0 -11
- package/lib-cjs/data/data1d/Spectrum1D/ranges/mapRanges.js +0 -82
- package/lib-cjs/data/data1d/Spectrum1D/ranges/updateRanges.js +0 -13
- package/lib-cjs/data/data1d/Spectrum1D/ranges/updateRangesRelativeValues.js +0 -9
- package/lib-cjs/data/data1d/filter1d/apodization.js +0 -88
- package/lib-cjs/data/data1d/filter1d/baselineCorrection.js +0 -60
- package/lib-cjs/data/data1d/filter1d/digitalFilter.js +0 -50
- package/lib-cjs/data/data1d/filter1d/equallySpaced.js +0 -61
- package/lib-cjs/data/data1d/filter1d/exclusionZones.js +0 -38
- package/lib-cjs/data/data1d/filter1d/fft.js +0 -96
- package/lib-cjs/data/data1d/filter1d/phaseCorrection.js +0 -70
- package/lib-cjs/data/data1d/filter1d/shiftX.js +0 -32
- package/lib-cjs/data/data1d/filter1d/signalProcessing.js +0 -95
- package/lib-cjs/data/data1d/filter1d/utils/padDataToNextPowerOfTwo.js +0 -39
- package/lib-cjs/data/data1d/filter1d/zeroFilling.js +0 -66
- package/lib-cjs/data/data2d/filter2d/shiftX.js +0 -33
- package/lib-cjs/data/data2d/filter2d/shiftY.js +0 -33
- package/lib-cjs/data/types/view-state/PeaksViewState.js +0 -2
- package/lib-cjs/types/NMRiumGeneralPreferences.js +0 -2
- package/lib-cjs/types/NMRiumPanelPreferences.js +0 -2
- package/lib-cjs/types/NMRiumToolBarPreferences.js +0 -2
- package/lib-cjs/types/PanelPreferencesType.js +0 -2
|
@@ -3,8 +3,6 @@ export { get1DDataXY } from './get1DDataXY';
|
|
|
3
3
|
export { getReferenceShift } from './getReferenceShift';
|
|
4
4
|
export { initiateDatum1D } from './initiateDatum1D';
|
|
5
5
|
export { changeIntegralsRelative } from './integrals/changeIntegralsRelative';
|
|
6
|
-
export { checkIntegralKind } from './integrals/checkIntegralKind';
|
|
7
|
-
export { updateIntegralsRelativeValues } from './integrals/updateIntegralsRelativeValues';
|
|
8
6
|
export { isSpectrum1D } from './isSpectrum1D';
|
|
9
7
|
export { autoPeakPicking } from './peaks/autoPeakPicking';
|
|
10
8
|
export { lookupPeak } from './peaks/lookupPeak';
|
|
@@ -17,7 +15,5 @@ export { checkRangeKind } from './ranges/checkRangeKind';
|
|
|
17
15
|
export { detectRange } from './ranges/detectRange';
|
|
18
16
|
export { detectRanges } from './ranges/detectRanges';
|
|
19
17
|
export { generateSpectrumFromRanges } from './ranges/generateSpectrumFromRanges';
|
|
20
|
-
export { mapRanges } from '
|
|
21
|
-
export { updateRangesRelativeValues } from './ranges/updateRangesRelativeValues';
|
|
22
|
-
export { getShiftX } from './getShiftX';
|
|
18
|
+
export { mapRanges, getShiftX, checkIntegralKind, updateRangesRelativeValues, updateIntegralsRelativeValues, } from 'nmr-processing';
|
|
23
19
|
export { get1DColor } from './get1DColor';
|
|
@@ -3,8 +3,6 @@ export { get1DDataXY } from './get1DDataXY';
|
|
|
3
3
|
export { getReferenceShift } from './getReferenceShift';
|
|
4
4
|
export { initiateDatum1D } from './initiateDatum1D';
|
|
5
5
|
export { changeIntegralsRelative } from './integrals/changeIntegralsRelative';
|
|
6
|
-
export { checkIntegralKind } from './integrals/checkIntegralKind';
|
|
7
|
-
export { updateIntegralsRelativeValues } from './integrals/updateIntegralsRelativeValues';
|
|
8
6
|
export { isSpectrum1D } from './isSpectrum1D';
|
|
9
7
|
export { autoPeakPicking } from './peaks/autoPeakPicking';
|
|
10
8
|
export { lookupPeak } from './peaks/lookupPeak';
|
|
@@ -17,7 +15,5 @@ export { checkRangeKind } from './ranges/checkRangeKind';
|
|
|
17
15
|
export { detectRange } from './ranges/detectRange';
|
|
18
16
|
export { detectRanges } from './ranges/detectRanges';
|
|
19
17
|
export { generateSpectrumFromRanges } from './ranges/generateSpectrumFromRanges';
|
|
20
|
-
export { mapRanges } from '
|
|
21
|
-
export { updateRangesRelativeValues } from './ranges/updateRangesRelativeValues';
|
|
22
|
-
export { getShiftX } from './getShiftX';
|
|
18
|
+
export { mapRanges, getShiftX, checkIntegralKind, updateRangesRelativeValues, updateIntegralsRelativeValues, } from 'nmr-processing';
|
|
23
19
|
export { get1DColor } from './get1DColor';
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { v4 } from '@lukeed/uuid';
|
|
2
|
-
import
|
|
3
|
-
import * as FiltersManager from '../../FiltersManager';
|
|
2
|
+
import { FiltersManager, Filters } from 'nmr-processing';
|
|
4
3
|
import { convertDataToFloat64Array } from './convertDataToFloat64Array';
|
|
5
4
|
import { get1DColor } from './get1DColor';
|
|
6
5
|
import { initiateIntegrals } from './integrals/initiateIntegrals';
|
|
@@ -8,7 +7,8 @@ import { initiatePeaks } from './peaks/initiatePeaks';
|
|
|
8
7
|
import { initiateRanges } from './ranges/initiateRanges';
|
|
9
8
|
export function initiateDatum1D(spectrum, options = {}) {
|
|
10
9
|
const { usedColors = {}, filters = [] } = options;
|
|
11
|
-
const
|
|
10
|
+
const { ranges, ...restSpectrum } = spectrum;
|
|
11
|
+
const spectrumObj = { ...restSpectrum };
|
|
12
12
|
spectrumObj.id = spectrum.id || v4();
|
|
13
13
|
spectrumObj.display = {
|
|
14
14
|
isVisible: true,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Range } from 'nmr-
|
|
1
|
+
import { Range } from 'nmr-processing';
|
|
2
2
|
export declare function isRangeAssigned(range: Range): boolean;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import median from 'ml-array-median';
|
|
2
|
-
import { xyAutoPeaksPicking } from 'nmr-processing';
|
|
3
|
-
import { mapPeaks } from './mapPeaks';
|
|
2
|
+
import { xyAutoPeaksPicking, mapPeaks } from 'nmr-processing';
|
|
4
3
|
export function autoPeakPicking(spectrum, options) {
|
|
5
4
|
const { minMaxRatio, maxNumberOfPeaks, noiseFactor, direction, windowFromIndex, windowToIndex, } = options;
|
|
6
5
|
// we calculate the noise but this could be improved
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { Spectrum1D
|
|
1
|
+
import { Spectrum1D } from 'nmr-load-save';
|
|
2
|
+
import { Peaks } from 'nmr-processing';
|
|
2
3
|
export declare function initiatePeaks(options: Partial<{
|
|
3
4
|
peaks: Peaks;
|
|
4
5
|
}>, spectrum: Spectrum1D): {
|
|
5
6
|
values: never[];
|
|
6
7
|
options: {};
|
|
7
8
|
} & Peaks & {
|
|
8
|
-
values: import("nmr-
|
|
9
|
+
values: import("nmr-processing").Peak1D[];
|
|
9
10
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import merge from 'lodash/merge';
|
|
2
|
-
import { mapPeaks } from '
|
|
2
|
+
import { mapPeaks } from 'nmr-processing';
|
|
3
3
|
export function initiatePeaks(options, spectrum) {
|
|
4
4
|
return merge({ values: [], options: {} }, options.peaks, {
|
|
5
5
|
values: mapPeaks(options?.peaks?.values || [], spectrum),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { NmrData1D } from 'cheminfo-types';
|
|
2
2
|
/**
|
|
3
3
|
*
|
|
4
4
|
* @param {object<{x:Array<number>,re:Array<number>}>} data
|
|
@@ -13,5 +13,5 @@ interface LookupPeakResult {
|
|
|
13
13
|
y: number;
|
|
14
14
|
xIndex: number;
|
|
15
15
|
}
|
|
16
|
-
export declare function lookupPeak(data:
|
|
16
|
+
export declare function lookupPeak(data: NmrData1D, options: LookupPeakOptions): LookupPeakResult | null;
|
|
17
17
|
export {};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { xFindClosestIndex } from 'ml-spectra-processing';
|
|
2
|
-
import { xyPeaksOptimization } from 'nmr-processing';
|
|
3
|
-
import { mapPeaks } from './mapPeaks';
|
|
2
|
+
import { xyPeaksOptimization, mapPeaks } from 'nmr-processing';
|
|
4
3
|
export function optimizePeaks(spectrum, options) {
|
|
5
4
|
const { from, to, peaks } = options;
|
|
6
5
|
const { originFrequency: frequency } = spectrum.info;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Spectrum1D } from 'nmr-load-save';
|
|
2
|
+
import { Signal1D } from 'nmr-processing';
|
|
2
3
|
import { SumParams } from '../SumManager';
|
|
3
4
|
interface RangeOptions {
|
|
4
5
|
from: number;
|
|
5
6
|
to: number;
|
|
6
|
-
id?: string;
|
|
7
7
|
}
|
|
8
|
-
export declare function createRangeObj({ from, to, absolute,
|
|
8
|
+
export declare function createRangeObj({ from, to, absolute, signal, }: RangeOptions & {
|
|
9
9
|
signal: Omit<Signal1D, 'id'>;
|
|
10
10
|
absolute: number;
|
|
11
11
|
}): {
|
|
@@ -14,16 +14,16 @@ export declare function createRangeObj({ from, to, absolute, id, signal, }: Rang
|
|
|
14
14
|
to: number;
|
|
15
15
|
absolute: number;
|
|
16
16
|
signals: {
|
|
17
|
-
|
|
18
|
-
diaIDs?: string[] | undefined;
|
|
17
|
+
peaks?: import("nmr-processing").NMRPeak1D[] | undefined;
|
|
19
18
|
kind?: string | undefined;
|
|
19
|
+
diaIDs?: string[] | undefined;
|
|
20
|
+
integration?: number | undefined;
|
|
20
21
|
multiplicity: string;
|
|
21
22
|
nbAtoms?: number | undefined;
|
|
22
|
-
delta: number;
|
|
23
23
|
js: import("nmr-processing").Jcoupling[];
|
|
24
|
+
delta: number;
|
|
24
25
|
atoms?: number[] | undefined;
|
|
25
26
|
assignment?: string | undefined;
|
|
26
|
-
peaks?: import("nmr-processing").NMRPeak1D[] | undefined;
|
|
27
27
|
statistic?: {
|
|
28
28
|
mean: number;
|
|
29
29
|
sd: number;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { v4 } from '@lukeed/uuid';
|
|
2
2
|
import { xyIntegration } from 'ml-spectra-processing';
|
|
3
|
+
import { updateRangesRelativeValues, mapRanges, } from 'nmr-processing';
|
|
3
4
|
import { DatumKind } from '../../../constants/SignalsKinds';
|
|
4
5
|
import { initSumOptions } from '../SumManager';
|
|
5
6
|
import detectSignal from './detectSignal';
|
|
6
|
-
|
|
7
|
-
import { updateRangesRelativeValues } from './updateRangesRelativeValues';
|
|
8
|
-
export function createRangeObj({ from, to, absolute, id, signal, }) {
|
|
7
|
+
export function createRangeObj({ from, to, absolute, signal, }) {
|
|
9
8
|
return {
|
|
10
|
-
id:
|
|
9
|
+
id: v4(),
|
|
11
10
|
from,
|
|
12
11
|
to,
|
|
13
12
|
absolute,
|
|
@@ -17,7 +16,7 @@ export function createRangeObj({ from, to, absolute, id, signal, }) {
|
|
|
17
16
|
};
|
|
18
17
|
}
|
|
19
18
|
export function addRange(spectrum, options) {
|
|
20
|
-
const { from, to,
|
|
19
|
+
const { from, to, molecules, nucleus } = options;
|
|
21
20
|
const { x, re } = spectrum.data;
|
|
22
21
|
const absolute = xyIntegration({ x, y: re }, { from, to, reverse: true });
|
|
23
22
|
// detectSignal use the advance multiplet-analysis that can crash if too many points
|
|
@@ -27,28 +26,10 @@ export function addRange(spectrum, options) {
|
|
|
27
26
|
frequency: spectrum.info.originFrequency,
|
|
28
27
|
});
|
|
29
28
|
let range;
|
|
30
|
-
if (
|
|
31
|
-
if (id === 'new') {
|
|
32
|
-
range = createRangeObj({
|
|
33
|
-
from,
|
|
34
|
-
to,
|
|
35
|
-
id,
|
|
36
|
-
absolute,
|
|
37
|
-
signal: {
|
|
38
|
-
multiplicity: '',
|
|
39
|
-
kind: 'signal',
|
|
40
|
-
delta: 0,
|
|
41
|
-
js: [],
|
|
42
|
-
diaIDs: [],
|
|
43
|
-
},
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
else {
|
|
29
|
+
if (signal) {
|
|
48
30
|
range = createRangeObj({
|
|
49
31
|
from,
|
|
50
32
|
to,
|
|
51
|
-
id,
|
|
52
33
|
absolute,
|
|
53
34
|
signal,
|
|
54
35
|
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { v4 } from '@lukeed/uuid';
|
|
2
2
|
import { xyIntegration } from 'ml-spectra-processing';
|
|
3
|
+
import { updateRangesRelativeValues } from 'nmr-processing';
|
|
3
4
|
import detectSignal from './detectSignal';
|
|
4
|
-
import { updateRangesRelativeValues } from './updateRangesRelativeValues';
|
|
5
5
|
export function changeRange(spectrum, range) {
|
|
6
6
|
const { from, to, id } = range;
|
|
7
7
|
const { x, re } = spectrum.data;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Range } from 'nmr-
|
|
1
|
+
import { Range } from 'nmr-processing';
|
|
2
2
|
export declare function checkRangeKind(range: Range): boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { v4 } from '@lukeed/uuid';
|
|
2
2
|
import { xyIntegration, xyMaxYPoint, xyMinYPoint } from 'ml-spectra-processing';
|
|
3
|
-
import { getShiftX } from '
|
|
3
|
+
import { getShiftX } from 'nmr-processing';
|
|
4
4
|
export function detectRange(spectrum, options) {
|
|
5
5
|
const { from, to } = options;
|
|
6
6
|
const { x, re: y } = spectrum.data;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
+
import { updateRangesRelativeValues, mapRanges } from 'nmr-processing';
|
|
1
2
|
import { initSumOptions } from '../SumManager';
|
|
2
3
|
import autoRangesDetection from './autoRangesDetection';
|
|
3
|
-
import { mapRanges } from './mapRanges';
|
|
4
|
-
import { updateRangesRelativeValues } from './updateRangesRelativeValues';
|
|
5
4
|
export function detectRanges(spectrum, options) {
|
|
6
5
|
const { molecules, nucleus, ...detectOptions } = options;
|
|
7
6
|
detectOptions.impurities = { solvent: spectrum.info.solvent || '' };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Spectrum1D } from 'nmr-load-save';
|
|
2
|
+
import { Ranges } from 'nmr-processing';
|
|
2
3
|
export declare function initiateRanges(options: Partial<{
|
|
3
4
|
ranges: Ranges;
|
|
4
5
|
}>, spectrum: Spectrum1D): {
|
|
@@ -9,5 +10,39 @@ export declare function initiateRanges(options: Partial<{
|
|
|
9
10
|
sumAuto: boolean;
|
|
10
11
|
};
|
|
11
12
|
} & Ranges & {
|
|
12
|
-
values:
|
|
13
|
+
values: {
|
|
14
|
+
absolute: number;
|
|
15
|
+
signals: {
|
|
16
|
+
originDelta: number | undefined;
|
|
17
|
+
delta: number;
|
|
18
|
+
multiplicity: string;
|
|
19
|
+
js: import("nmr-processing").Jcoupling[];
|
|
20
|
+
diaIDs?: string[] | undefined;
|
|
21
|
+
atoms?: number[] | undefined;
|
|
22
|
+
assignment?: string | undefined;
|
|
23
|
+
nbAtoms?: number | undefined;
|
|
24
|
+
integration?: number | undefined;
|
|
25
|
+
peaks?: import("nmr-processing").NMRPeak1D[] | undefined;
|
|
26
|
+
statistic?: {
|
|
27
|
+
mean: number;
|
|
28
|
+
sd: number;
|
|
29
|
+
min: number;
|
|
30
|
+
max: number;
|
|
31
|
+
nb: number;
|
|
32
|
+
} | undefined;
|
|
33
|
+
kind: string;
|
|
34
|
+
id: string;
|
|
35
|
+
}[];
|
|
36
|
+
originFrom: number | undefined;
|
|
37
|
+
originTo: number | undefined;
|
|
38
|
+
from: number;
|
|
39
|
+
to: number;
|
|
40
|
+
id: string;
|
|
41
|
+
kind: string;
|
|
42
|
+
integration: number;
|
|
43
|
+
nbAtoms?: number | undefined;
|
|
44
|
+
multiplicity?: string | undefined;
|
|
45
|
+
diaIDs?: string[] | undefined;
|
|
46
|
+
pubIntegral?: number | undefined;
|
|
47
|
+
}[];
|
|
13
48
|
};
|
|
@@ -53,8 +53,7 @@ function prepareMoleculesDB(array) {
|
|
|
53
53
|
index: entry.ocl.index,
|
|
54
54
|
});
|
|
55
55
|
}
|
|
56
|
-
catch
|
|
57
|
-
reportError(error);
|
|
56
|
+
catch {
|
|
58
57
|
// eslint-disable-next-line no-console
|
|
59
58
|
console.error(`Could not parse idCode: ${JSON.stringify(entry.ocl)}`);
|
|
60
59
|
}
|
|
@@ -64,8 +63,7 @@ function prepareMoleculesDB(array) {
|
|
|
64
63
|
const molecule = OCL.Molecule.fromSmiles(entry.smiles);
|
|
65
64
|
moleculesDB.pushEntry(molecule, entry);
|
|
66
65
|
}
|
|
67
|
-
catch
|
|
68
|
-
reportError(error);
|
|
66
|
+
catch {
|
|
69
67
|
// eslint-disable-next-line no-console
|
|
70
68
|
console.error(`Could not parse smiles: ${entry.smiles}`);
|
|
71
69
|
}
|
|
@@ -1,32 +1,6 @@
|
|
|
1
|
-
import { Spectrum, Spectrum1D } from 'nmr-load-save';
|
|
2
|
-
import { MultipleSpectraAnalysisPreferences, PanelsPreferences, WorkSpacePanelPreferences } from '../../component/workspaces/Workspace';
|
|
1
|
+
import { Spectrum, Spectrum1D, MultipleSpectraAnalysisPreferences, PanelsPreferences, WorkSpacePanelPreferences, AnalysisOptions, AnalysisColumnsTypes, SpectraAnalysisColumns, AnalisisColumnsValuesKeys } from 'nmr-load-save';
|
|
3
2
|
import { RangeDetectionResult } from '../types/data1d/index';
|
|
4
|
-
export
|
|
5
|
-
NORMAL = "NORMAL",
|
|
6
|
-
FORMULA = "FORMULA"
|
|
7
|
-
}
|
|
8
|
-
export declare enum COLUMNS_VALUES_KEYS {
|
|
9
|
-
RELATIVE = "relative",
|
|
10
|
-
ABSOLUTE = "absolute",
|
|
11
|
-
MIN = "min",
|
|
12
|
-
MAX = "max"
|
|
13
|
-
}
|
|
14
|
-
export type ColumnType = keyof typeof COLUMNS_TYPES;
|
|
15
|
-
interface Column {
|
|
16
|
-
type: ColumnType;
|
|
17
|
-
valueKey: COLUMNS_VALUES_KEYS;
|
|
18
|
-
from: number;
|
|
19
|
-
to: number;
|
|
20
|
-
formula?: string;
|
|
21
|
-
index: number;
|
|
22
|
-
}
|
|
23
|
-
export type SpectraAnalysisColumns = Record<string, Column>;
|
|
24
|
-
export interface AnalysisOptions {
|
|
25
|
-
sum: number;
|
|
26
|
-
code: string | null;
|
|
27
|
-
columns: SpectraAnalysisColumns;
|
|
28
|
-
columnIndex: number;
|
|
29
|
-
}
|
|
3
|
+
export type ColumnType = keyof typeof AnalysisColumnsTypes;
|
|
30
4
|
export interface AnalysisRow extends RangeDetectionResult {
|
|
31
5
|
SID: string;
|
|
32
6
|
colKey?: string;
|
|
@@ -54,7 +28,7 @@ export declare function mapColumns(options: MultipleSpectraAnalysisPreferences['
|
|
|
54
28
|
code: string | null;
|
|
55
29
|
columns: any;
|
|
56
30
|
};
|
|
57
|
-
export declare function changeColumnValueKey(spectraAnalysis: PanelsPreferences['multipleSpectraAnalysis'], nucleus: string, columnKey: string, newKey:
|
|
31
|
+
export declare function changeColumnValueKey(spectraAnalysis: PanelsPreferences['multipleSpectraAnalysis'], nucleus: string, columnKey: string, newKey: AnalisisColumnsValuesKeys): void;
|
|
58
32
|
export declare function analyzeSpectra(spectraAnalysis: PanelsPreferences['multipleSpectraAnalysis'], options: any): void;
|
|
59
33
|
export declare function generateAnalyzeSpectra(multipleSpectraAnalysis: MultipleSpectraAnalysisPreferences, spectra: Spectrum1D[], nucleus: string): {
|
|
60
34
|
values: unknown[];
|
|
@@ -65,4 +39,3 @@ export declare function generateAnalyzeSpectra(multipleSpectraAnalysis: Multiple
|
|
|
65
39
|
};
|
|
66
40
|
export declare function deleteSpectraAnalysis(spectraAnalysis: PanelsPreferences['multipleSpectraAnalysis'], colKey: string, nucleus: string): void;
|
|
67
41
|
export declare function getDataAsString(spectraAnalysis: SpectraAnalysisData, spectra: Spectrum1D[], spectraPanelPreferences: WorkSpacePanelPreferences['spectra']): string | null;
|
|
68
|
-
export {};
|
|
@@ -1,19 +1,8 @@
|
|
|
1
1
|
import lodashGet from 'lodash/get';
|
|
2
|
+
import { AnalysisColumnsTypes, AnalisisColumnsValuesKeys, } from 'nmr-load-save';
|
|
2
3
|
import { convertSpectraArrayToObject } from '../utilities/convertSpectraListToObject';
|
|
3
4
|
import generateChar from '../utilities/generateChar';
|
|
4
5
|
import { detectRange, isSpectrum1D } from './Spectrum1D/index';
|
|
5
|
-
export var COLUMNS_TYPES;
|
|
6
|
-
(function (COLUMNS_TYPES) {
|
|
7
|
-
COLUMNS_TYPES["NORMAL"] = "NORMAL";
|
|
8
|
-
COLUMNS_TYPES["FORMULA"] = "FORMULA";
|
|
9
|
-
})(COLUMNS_TYPES || (COLUMNS_TYPES = {}));
|
|
10
|
-
export var COLUMNS_VALUES_KEYS;
|
|
11
|
-
(function (COLUMNS_VALUES_KEYS) {
|
|
12
|
-
COLUMNS_VALUES_KEYS["RELATIVE"] = "relative";
|
|
13
|
-
COLUMNS_VALUES_KEYS["ABSOLUTE"] = "absolute";
|
|
14
|
-
COLUMNS_VALUES_KEYS["MIN"] = "min";
|
|
15
|
-
COLUMNS_VALUES_KEYS["MAX"] = "max";
|
|
16
|
-
})(COLUMNS_VALUES_KEYS || (COLUMNS_VALUES_KEYS = {}));
|
|
17
6
|
function addColumnKey(spectraAnalysis, nucleus, columnProps, columnKey) {
|
|
18
7
|
const spectraAnalysisOptions = spectraAnalysis[nucleus].analysisOptions;
|
|
19
8
|
const key = columnKey || generateChar(spectraAnalysisOptions.columnIndex).toUpperCase();
|
|
@@ -78,8 +67,8 @@ export function analyzeSpectra(spectraAnalysis, options) {
|
|
|
78
67
|
const { from, to, nucleus, columnKey = null } = options;
|
|
79
68
|
init(spectraAnalysis, nucleus);
|
|
80
69
|
addColumnKey(spectraAnalysis, nucleus, {
|
|
81
|
-
type:
|
|
82
|
-
valueKey:
|
|
70
|
+
type: AnalysisColumnsTypes.NORMAL,
|
|
71
|
+
valueKey: AnalisisColumnsValuesKeys.ABSOLUTE,
|
|
83
72
|
from,
|
|
84
73
|
to,
|
|
85
74
|
index: 1,
|
|
@@ -109,7 +98,7 @@ export function generateAnalyzeSpectra(multipleSpectraAnalysis, spectra, nucleus
|
|
|
109
98
|
}
|
|
110
99
|
const newData = Object.fromEntries(Object.entries(data).map((spectra) => {
|
|
111
100
|
const result = Object.fromEntries(Object.keys(columns).map((key) => {
|
|
112
|
-
const isFormula = columns[key].type ===
|
|
101
|
+
const isFormula = columns[key].type === AnalysisColumnsTypes.FORMULA;
|
|
113
102
|
return [
|
|
114
103
|
key,
|
|
115
104
|
isFormula
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { NmrData2DFt } from 'cheminfo-types';
|
|
2
|
+
import { Info2D } from 'nmr-processing';
|
|
2
3
|
import { UsedColors } from '../../../types/UsedColors';
|
|
3
4
|
/**
|
|
4
5
|
* calculate the missing projection
|
|
5
6
|
*/
|
|
6
|
-
export declare function getMissingProjection(datum:
|
|
7
|
+
export declare function getMissingProjection(datum: NmrData2DFt['rr'], nucleus: string, datumInfo: Info2D, usedColors: UsedColors): import("nmr-load-save").Spectrum1D;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { v4 } from '@lukeed/uuid';
|
|
2
|
-
import
|
|
2
|
+
import { FiltersManager } from 'nmr-processing';
|
|
3
3
|
import { DEFAULT_CONTOURS_OPTIONS } from './contours';
|
|
4
4
|
import { get2DColor } from './get2DColor';
|
|
5
5
|
import { initiateZones } from './zones/initiateZones';
|
|
@@ -36,7 +36,7 @@ export declare function detectZonesManual(datum: any, options: DetectionZonesOpt
|
|
|
36
36
|
diaIDs?: string[] | undefined;
|
|
37
37
|
};
|
|
38
38
|
sign?: number | undefined;
|
|
39
|
-
peaks?: import("nmr-
|
|
39
|
+
peaks?: import("nmr-processing").Peak2D[] | undefined;
|
|
40
40
|
j?: {
|
|
41
41
|
pathLength?: number | import("cheminfo-types").FromTo | undefined;
|
|
42
42
|
} | undefined;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Spectrum2D
|
|
1
|
+
import { Spectrum2D } from 'nmr-load-save';
|
|
2
|
+
import { Zones } from 'nmr-processing';
|
|
2
3
|
export declare function initiateZones(options: Partial<{
|
|
3
4
|
zones: Zones;
|
|
4
5
|
}>, spectrum: Spectrum2D): {
|
|
@@ -35,7 +36,7 @@ export declare function initiateZones(options: Partial<{
|
|
|
35
36
|
diaIDs?: string[] | undefined;
|
|
36
37
|
};
|
|
37
38
|
sign?: number | undefined;
|
|
38
|
-
peaks?: import("nmr-
|
|
39
|
+
peaks?: import("nmr-processing").Peak2D[] | undefined;
|
|
39
40
|
j?: {
|
|
40
41
|
pathLength?: number | import("cheminfo-types").FromTo | undefined;
|
|
41
42
|
} | undefined;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import { Spectrum2D
|
|
1
|
+
import { Spectrum2D } from 'nmr-load-save';
|
|
2
|
+
import { Zone } from 'nmr-processing';
|
|
2
3
|
import { Zone2DError } from '../get2DSpectrumErrorValue';
|
|
3
4
|
export declare function isZoneExists(zone: Zone, spectrum: Spectrum2D, error: Zone2DError): boolean;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Spectrum2D
|
|
1
|
+
import { Spectrum2D } from 'nmr-load-save';
|
|
2
|
+
import { Zone } from 'nmr-processing';
|
|
2
3
|
import { MapOptions } from '../../../types/common/MapOptions';
|
|
3
4
|
export declare function mapZones(zones: Zone[], datum: Spectrum2D, options?: MapOptions): {
|
|
4
5
|
id: string;
|
|
@@ -26,7 +27,7 @@ export declare function mapZones(zones: Zone[], datum: Spectrum2D, options?: Map
|
|
|
26
27
|
diaIDs?: string[] | undefined;
|
|
27
28
|
};
|
|
28
29
|
sign?: number | undefined;
|
|
29
|
-
peaks?: import("nmr-
|
|
30
|
+
peaks?: import("nmr-processing").Peak2D[] | undefined;
|
|
30
31
|
j?: {
|
|
31
32
|
pathLength?: number | import("cheminfo-types").FromTo | undefined;
|
|
32
33
|
} | undefined;
|
|
@@ -10,7 +10,7 @@ export type MatrixFilters = {
|
|
|
10
10
|
options: FiltersObjectRecord;
|
|
11
11
|
}[];
|
|
12
12
|
export declare function getDefaultMatrixFilters(): {
|
|
13
|
-
name: "
|
|
13
|
+
name: "fromTo" | "centerMean" | "centerMedian" | "normed" | "divideBySD" | "rescale" | "paretoNormalization" | "airPLSBaseline" | "iterativePolynomialBaseline" | "rollingAverageBaseline" | "rollingBallBaseline" | "rollingMedianBaseline" | "firstDerivative" | "secondDerivative" | "thirdDerivative" | "savitzkyGolay" | "ensureGrowing" | "equallySpaced" | "filterX" | "calibrateX" | "xFunction" | "yFunction";
|
|
14
14
|
options: FiltersObjectRecord;
|
|
15
15
|
}[];
|
|
16
16
|
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export type ComplexData1D = Omit<
|
|
1
|
+
import { NmrData1D } from 'cheminfo-types';
|
|
2
|
+
export type ComplexData1D = Omit<NmrData1D, 'im'> & Required<Pick<NmrData1D, 'im'>>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Spectrum, Spectrum1D, Spectrum2D } from 'nmr-load-save';
|
|
2
|
+
import { Range, Signal1D, Signal2D, Zone } from 'nmr-processing';
|
|
2
3
|
declare function findSpectrum(spectraData: Spectrum[], spectrumID: string, checkIsVisible: boolean): Spectrum | undefined;
|
|
3
4
|
declare function findSignal1D(spectrum: Spectrum1D, signalID: string): Signal1D | undefined;
|
|
4
5
|
declare function findSignal2D(spectrum: Spectrum2D, signalID: string): Signal2D | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Range } from 'nmr-
|
|
1
|
+
import { Range } from 'nmr-processing';
|
|
2
2
|
export declare function getDiaIDs(range: Range): string[];
|
|
3
3
|
export declare function getNbAtoms(range: Range, signalIndex?: number): number;
|
|
4
4
|
export declare function setNbAtoms(range: Range, signalIndex?: number): void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Zone } from 'nmr-
|
|
1
|
+
import { Zone } from 'nmr-processing';
|
|
2
2
|
export declare function getDiaIDs(zone: Zone, axis: string): string[];
|
|
3
3
|
export declare function getNbAtoms(zone: Zone, axis: string): number;
|
|
4
4
|
export declare function setNbAtoms(zone: Zone, axis: string): void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function calculateSanPlot<T extends '1D' | '2D'>(dimension: T, data: T extends '1D' ?
|
|
1
|
+
import { NmrData2DFt, NmrData1D } from 'cheminfo-types';
|
|
2
|
+
export declare function calculateSanPlot<T extends '1D' | '2D'>(dimension: T, data: T extends '1D' ? NmrData1D : NmrData2DFt['rr']): {
|
|
3
3
|
positive: number;
|
|
4
4
|
negative: number;
|
|
5
5
|
snr: number;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { CorrelationData } from 'nmr-correlation';
|
|
2
|
-
import { Spectrum } from 'nmr-load-save';
|
|
3
|
-
import { ViewState } from '../component/reducer/Reducer';
|
|
4
|
-
import { Workspace } from '../component/workspaces/Workspace';
|
|
2
|
+
import { Workspace, ViewState, Spectrum } from 'nmr-load-save';
|
|
5
3
|
import { StateMolecule } from '../data/molecules/Molecule';
|
|
6
4
|
export interface NMRiumDataReturn {
|
|
7
5
|
version: number;
|
package/lib/versionInfo.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export default { version: 'v0.38.
|
|
1
|
+
export default { version: 'v0.38.2' };
|