{"_id":"ml-tree-similarity","_rev":"16-a6b9354e099b1c17bb061e21584f7c33","name":"ml-tree-similarity","description":"Compares two spectra using a tree similarity","dist-tags":{"latest":"2.2.0"},"versions":{"0.0.0":{"name":"ml-tree-similarity","version":"0.0.0","description":"Tree similarity in Javascript","main":"src/index.js","directories":{"lib":"src","test":"test"},"scripts":{"test":"mocha --require should --reporter mocha-better-spec-reporter --recursive"},"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"keywords":["spectra","similarity","nmr","chemistry","mining","datamining","machine","learning"],"author":{"name":"Miguel Asencio"},"license":"MIT","bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"homepage":"https://github.com/mljs/tree-similarity","devDependencies":{"mocha":"latest","mocha-better-spec-reporter":"latest","should":"latest"},"gitHead":"20effb1ad04476320ced9491e66ce8070f401422","_id":"ml-tree-similarity@0.0.0","_shasum":"0884655798caada2cc6f1f137457b4b0a2ab6cdd","_from":".","_npmVersion":"2.11.0","_nodeVersion":"2.2.1","_npmUser":{"name":"maasencioh","email":"maasencioh@gmail.com"},"dist":{"shasum":"0884655798caada2cc6f1f137457b4b0a2ab6cdd","tarball":"https://registry.npmjs.org/ml-tree-similarity/-/ml-tree-similarity-0.0.0.tgz","integrity":"sha512-KwWB8BcGTSBnXPuXMrpZE4/hB4Wg1mm9GOPlB1+2RGbz5Zxl4HkQOyPIVKh8wPFznYCsCCeAi4ZqQehIvALlkw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD5GiyfbcUxnPD+C6g5REvfq7IZTFDHzz3Jtxeq/hH/AQIhAJ7PRNO7go8zzOm+oIERojMkkbSZbj/7pxxjdlBkMAoL"}]},"maintainers":[{"name":"maasencioh","email":"maasencioh@gmail.com"}]},"0.1.0":{"name":"ml-tree-similarity","version":"0.1.0","description":"Compares two spectra using a tree similarity","main":"lib/index.js","module":"src/index.js","files":["lib","src"],"scripts":{"eslint":"eslint src","eslint-fix":"npm run eslint -- --fix","prepublish":"rollup -c","test":"run-s testonly eslint","testonly":"jest","test-travis":"jest --coverage && codecov"},"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"keywords":[],"author":{"name":"Miguel Asencio"},"license":"MIT","bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"homepage":"https://github.com/mljs/tree-similarity#readme","jest":{"testEnvironment":"node"},"devDependencies":{"babel-plugin-transform-es2015-modules-commonjs":"^6.24.1","codecov":"^2.3.0","eslint":"^4.1.1","eslint-config-cheminfo":"^1.8.0","eslint-plugin-no-only-tests":"^2.0.0","jest":"^20.0.4","npm-run-all":"^4.0.2","rollup":"^0.43.0"},"dependencies":{"binary-search":"^1.3.2","num-sort":"^1.0.0"},"gitHead":"4db1f55c5ed23177f90a7888c3b91d73541f7c6d","_id":"ml-tree-similarity@0.1.0","_npmVersion":"5.3.0","_nodeVersion":"8.0.0","_npmUser":{"name":"maasencioh","email":"maasencioh@gmail.com"},"dist":{"integrity":"sha512-y5ZWXubn8jn67+UNxiKBXaT57qEnhgKtTyAUW3BOi6b8qT2v4iPDRxA221bzV3w+/Z+U6L7oOmbITYD+UF0Fxw==","shasum":"8912413faaa8ff5e99b00bc2cec183e2da4528af","tarball":"https://registry.npmjs.org/ml-tree-similarity/-/ml-tree-similarity-0.1.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEtoH6RSYPlqXKb5jjmjqi4EA0qNprHn9i+IyDbMySJxAiAJrwDwo9ygHY9hOLDi18KJtqQahvNrqc7jr9R7PUZwwg=="}]},"maintainers":[{"email":"maasencioh@gmail.com","name":"maasencioh"},{"email":"swrt_9950@hotmail.com","name":"jeffersonh44"},{"email":"lpatiny@gmail.com","name":"lpatiny"},{"email":"targos@live.com","name":"targos"},{"email":"kostro.d@gmail.com","name":"stropitek"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ml-tree-similarity-0.1.0.tgz_1502356659597_0.33545851870439947"},"directories":{}},"1.0.0":{"name":"ml-tree-similarity","version":"1.0.0","description":"Compares two spectra using a tree similarity","main":"lib/index.js","module":"src/index.js","scripts":{"compile":"rollup -c","eslint":"eslint src","eslint-fix":"npm run eslint -- --fix","prepublishOnly":"npm run compile","test":"npm run test-coverage && npm run eslint","test-only":"jest","test-coverage":"jest --coverage"},"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"keywords":[],"author":{"name":"Miguel Asencio"},"license":"MIT","bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"homepage":"https://github.com/mljs/tree-similarity#readme","jest":{"testEnvironment":"node"},"devDependencies":{"@babel/plugin-transform-modules-commonjs":"^7.4.4","eslint":"^6.0.1","eslint-config-cheminfo":"^1.20.1","eslint-plugin-import":"^2.18.0","eslint-plugin-jest":"^22.7.1","jest":"^24.8.0","rollup":"^1.16.3"},"dependencies":{"binary-search":"^1.3.5","num-sort":"^2.0.0"},"gitHead":"5a9b0730818e72253299c8746db7310f91053d54","_id":"ml-tree-similarity@1.0.0","_nodeVersion":"12.5.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-XJUyYqjSuUQkNQHMscr6tcjldsOoAekxADTplt40QKfwW6nd++1wHWV9AArl0Zvw/TIHgNaZZNvr8QGvE8wLRg==","shasum":"24705a107e32829e24d945e87219e892159c53f0","tarball":"https://registry.npmjs.org/ml-tree-similarity/-/ml-tree-similarity-1.0.0.tgz","fileCount":11,"unpackedSize":12871,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdF9x1CRA9TVsSAnZWagAASZwP/Roet3T4DXSppW97cwyH\n3YfSbPWeE6Qfq2s3Ym6+eiGnaTG0CA0qH+SB03s+xg+GzHlt8KOw4aHg/o7E\n1Q8CODbcxZS/4Byl1ng6Gg4AEqooSoSuBTeM7tPZw9zix5cqON7LqoB8Ouhw\nBE20DoGA/pJD6JJnincHpZvtkoiJNgLsQ8fU5MLbO27vTvh+eBw69mkAHM7M\nwrpel0LxLoOpNQmY1p27dcX28DshCA5dcDCxLlIlJRo6DIZJ4UCucKh2ob/4\n1DuuSwXyx9+/sPF24qHqEOYwyRL7HlXIVSla3fwrVfxsiUApMVuzpCeH6xUG\n4CbL0taj3Ja432uXPtV5YnIL2PVFE0BPT1qkIQjyeHOVo0fp0cgiz8aAmqWa\nMydjbFEJLAJ6wcCvwW2kAEchkSEHkTjWnAQGIDqY+rqnBMeYO1vgRw0sHUUr\n4sCwb/mitttnprR5BSOFxFNTMprlCVdhRxkMvF2M5gT0BfTaQtepU52Aby3h\naoKZgL5DvV/lH75dWjDTbvnyYHcpFpc2RcGoBC4YyDvvy+Xsjmb3NrY/B5LD\nY+Tzqe+3PS5d6SeIQoLDQ1V7fzrCWhtSV9w1kML+8kXPrU4PRSK5+XfxD8NR\ndRVkyWufpTwpP7Q5UYS+3Q9rJHd9BbH2k89s8wk8Gg/0uu3b+ranWLJakbzg\nYXiV\r\n=1/7m\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDXAnSje43WIf0d23HG0x7YKhWN/eoP4y+2RTsicfUE9AiBacqGHlH28xMMCPvzwvOONn+SlGjBM6sZ00E1NnIf8Pg=="}]},"maintainers":[{"email":"swrt_9950@hotmail.com","name":"jeffersonh44"},{"email":"lpatiny@gmail.com","name":"lpatiny"},{"email":"maasencioh@gmail.com","name":"maasencioh"},{"email":"kostro.d@gmail.com","name":"stropitek"},{"email":"targos@live.com","name":"targos"}],"_npmUser":{"name":"targos","email":"targos+npm@protonmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ml-tree-similarity_1.0.0_1561844852960_0.9705818641888713"},"_hasShrinkwrap":false},"2.0.0":{"name":"ml-tree-similarity","version":"2.0.0","description":"Compares two spectra using a tree similarity","main":"lib/index.js","module":"src/index.js","scripts":{"compile":"rollup -c","eslint":"eslint src","eslint-fix":"npm run eslint -- --fix","prepack":"npm run compile","prettier":"prettier --check src","prettier-write":"prettier --write src","test":"npm run test-only && npm run eslint && npm run prettier","test-only":"vitest run --coverage"},"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"keywords":[],"author":{"name":"Miguel Asencio"},"license":"MIT","bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"homepage":"https://github.com/mljs/tree-similarity#readme","devDependencies":{"@babel/plugin-transform-modules-commonjs":"^7.23.3","@vitest/coverage-v8":"^1.2.2","eslint":"^8.56.0","eslint-config-cheminfo":"^9.1.1","prettier":"^3.2.5","rollup":"^4.9.6","vitest":"^1.2.2"},"dependencies":{"binary-search":"^1.3.6","cheminfo-types":"^1.7.2","num-sort":"^3.0.0"},"_id":"ml-tree-similarity@2.0.0","gitHead":"c43482e0c5dfaa1e6798e7d905fd999be12eb1cf","_nodeVersion":"20.11.0","_npmVersion":"10.2.4","dist":{"integrity":"sha512-o7qIIkQNfRROrHqDF9Av83MI6e6B9uGgBJiqy+66wmlvrfsh+hAco6m5Pi+MjNVuTGN5z5fTEQEPao47b5K1pA==","shasum":"c306129d5f9c1a5c3c2b2b030f6e3749b92f8148","tarball":"https://registry.npmjs.org/ml-tree-similarity/-/ml-tree-similarity-2.0.0.tgz","fileCount":10,"unpackedSize":11826,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHl6drY1NuAQy8km6itTAd29rjIlIMZDYYsL6Qms6rmWAiEApbxTbFS4Jk3VdOGD9Q1dnTrukLQnz8HPj9pWWfJgJew="}]},"_npmUser":{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},"directories":{},"maintainers":[{"name":"stropitek","email":"kostro.d@gmail.com"},{"name":"targos","email":"targos+npm@protonmail.com"},{"name":"lpatiny","email":"luc@patiny.com"},{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},{"name":"maasencioh","email":"maasencioh@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ml-tree-similarity_2.0.0_1707506285430_0.7525725809768706"},"_hasShrinkwrap":false},"2.1.0":{"name":"ml-tree-similarity","version":"2.1.0","description":"Compares two spectra using a tree similarity","main":"lib/index.js","module":"src/index.js","types":"tree-similarity.d.ts","scripts":{"compile":"rollup -c","eslint":"eslint src","eslint-fix":"npm run eslint -- --fix","prepack":"npm run compile","prettier":"prettier --check src","prettier-write":"prettier --write src","test":"npm run test-only && npm run eslint && npm run prettier","test-only":"vitest run --coverage"},"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"keywords":[],"author":{"name":"Miguel Asencio"},"license":"MIT","bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"homepage":"https://github.com/mljs/tree-similarity#readme","devDependencies":{"@babel/plugin-transform-modules-commonjs":"^7.23.3","@vitest/coverage-v8":"^1.2.2","eslint":"^8.56.0","eslint-config-cheminfo":"^9.1.1","prettier":"^3.2.5","rollup":"^4.9.6","vitest":"^1.2.2"},"dependencies":{"binary-search":"^1.3.6","cheminfo-types":"^1.7.2"},"_id":"ml-tree-similarity@2.1.0","gitHead":"226db00203d5286ae5873b3c12cdfb19a2905c60","_nodeVersion":"20.11.0","_npmVersion":"10.2.4","dist":{"integrity":"sha512-c3Ey//GtV5JjbMS4YNC9HEtGVp0gKl/pEJnQaNBFouHG+A7YvtWaS0wwsSv1BN5NEft+pMxNOsEfqp0XvgjL7A==","shasum":"fdfc9f4f4738f1b13819bdeffa7ca4516d574f36","tarball":"https://registry.npmjs.org/ml-tree-similarity/-/ml-tree-similarity-2.1.0.tgz","fileCount":13,"unpackedSize":14531,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDoa5GDpDcjERorRoMR+UuF5dsXXxiEI1NS+YdSpmnPwwIgXrBQsxTZRIpMm3FyxVp0AJWlQSymbvb5Ada5L7D4lQ8="}]},"_npmUser":{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},"directories":{},"maintainers":[{"name":"stropitek","email":"kostro.d@gmail.com"},{"name":"targos","email":"targos+npm@protonmail.com"},{"name":"lpatiny","email":"luc@patiny.com"},{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},{"name":"maasencioh","email":"maasencioh@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ml-tree-similarity_2.1.0_1707829772970_0.0645438080102112"},"_hasShrinkwrap":false},"2.2.0":{"name":"ml-tree-similarity","version":"2.2.0","description":"Compares two spectra using a tree similarity","main":"./lib/index.js","module":"./lib-esm/index.js","types":"./lib/index.d.ts","scripts":{"check-types":"tsc --noEmit","clean":"rimraf lib lib-esm","eslint":"eslint src","eslint-fix":"npm run eslint -- --fix","prepack":"npm run tsc","prettier":"prettier --check src","prettier-write":"prettier --write src","test":"npm run test-only && npm run eslint && npm run prettier && npm run check-types","test-only":"vitest run --coverage","tsc":"npm run clean && npm run tsc-cjs && npm run tsc-esm","tsc-cjs":"tsc --project tsconfig.cjs.json","tsc-esm":"tsc --project tsconfig.esm.json"},"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"keywords":[],"author":{"name":"Miguel Asencio"},"license":"MIT","bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"homepage":"https://github.com/mljs/tree-similarity#readme","devDependencies":{"@babel/plugin-transform-modules-commonjs":"^7.23.3","@babel/preset-typescript":"^7.23.3","@vitest/coverage-v8":"^1.2.2","eslint":"^8.56.0","eslint-config-cheminfo-typescript":"^12.2.0","prettier":"^3.2.5","rimraf":"^5.0.5","typescript":"^5.3.3","vitest":"^1.2.2"},"dependencies":{"binary-search":"^1.3.6","cheminfo-types":"^1.7.2"},"_id":"ml-tree-similarity@2.2.0","gitHead":"ae0d9a1bddeebbc190d6d349d1ffe8974a8d5b07","_nodeVersion":"20.11.0","_npmVersion":"10.2.4","dist":{"integrity":"sha512-fL/+YBDNQRE1YpjigSIID0Jy4K1f1c2N877n53E4B11x2kNufo4q7Phlfl0J5V812ljoR15qKRb7i1me0PgBpw==","shasum":"f18310416a0f9862dce28716777fccb76b8071ab","tarball":"https://registry.npmjs.org/ml-tree-similarity/-/ml-tree-similarity-2.2.0.tgz","fileCount":43,"unpackedSize":33544,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIC/Hb1kh+B3Pz1RGwMHuibh4tN8g1Zh7HdtCPTxnqDICAiEAy++Ppmhkb6OaWPvL5s4ho/EZZHSgEUvVaR27uokZ0XU="}]},"_npmUser":{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},"directories":{},"maintainers":[{"name":"stropitek","email":"kostro.d@gmail.com"},{"name":"targos","email":"targos+npm@protonmail.com"},{"name":"lpatiny","email":"luc@patiny.com"},{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},{"name":"maasencioh","email":"maasencioh@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ml-tree-similarity_2.2.0_1708004859568_0.26970394782173335"},"_hasShrinkwrap":false}},"readme":"# tree-similarity\n\n[![NPM version][npm-image]][npm-url]\n[![Test coverage][codecov-image]][codecov-url]\n[![npm download][download-image]][download-url]\n\nCompares two spectra using a tree similarity.\n\n## Installation\n\n`$ npm i ml-tree-similarity`\n\n## Usage\n\n```js\nimport { createTree, treeSimilarity } from 'ml-tree-similarity';\n\nconst a = {\n  x: [1, 2, 3, 4, 5, 6, 7],\n  y: [0.3, 0.7, 4, 0.3, 0.2, 5, 0.3],\n};\nconst b = {\n  x: [1, 2, 3, 4, 5, 6, 7],\n  y: [0.3, 4, 0.7, 0.3, 5, 0.2, 0.3],\n};\n\n// create a tree\nconst options = { from: 1, to: 7 };\nconst aTree = createTree(a, options);\nconst bTree = createTree(b, options);\n\nconst ans = treeSimilarity(aTree, bTree, options);\n```\n\n## [API Documentation](https://mljs.github.io/tree-similarity/)\n\nThis algorithm was based in the following papers:\n\n- [A new method for the comparison of 1H NMR predictors based on tree-similarity of spectra](https://doi.org/10.1186/1758-2946-6-9)\n- [Fast and shift-insensitive similarity comparisons of NMR using a tree-representation of spectra](https://doi.org/10.1016/j.chemolab.2013.05.009)\n\n## License\n\n[MIT](./LICENSE)\n\n[npm-image]: https://img.shields.io/npm/v/ml-tree-similarity.svg?style=flat-square\n[npm-url]: https://npmjs.org/package/ml-tree-similarity\n[codecov-image]: https://img.shields.io/codecov/c/github/mljs/tree-similarity.svg?style=flat-square\n[codecov-url]: https://codecov.io/github/mljs/tree-similarity\n[download-image]: https://img.shields.io/npm/dm/ml-tree-similarity.svg?style=flat-square\n[download-url]: https://npmjs.org/package/ml-tree-similarity\n","maintainers":[{"name":"stropitek","email":"kostro.d@gmail.com"},{"name":"targos","email":"targos+npm@protonmail.com"},{"name":"lpatiny","email":"luc@patiny.com"},{"name":"mljs-bot","email":"bot+npm-mljs@zakodium.com"},{"name":"maasencioh","email":"maasencioh@gmail.com"}],"time":{"modified":"2024-02-15T13:47:40.213Z","created":"2015-07-15T11:59:55.318Z","0.0.0":"2015-07-15T11:59:55.318Z","0.1.0":"2017-08-10T09:17:40.545Z","1.0.0":"2019-06-29T21:47:33.085Z","2.0.0":"2024-02-09T19:18:05.583Z","2.1.0":"2024-02-13T13:09:33.153Z","2.2.0":"2024-02-15T13:47:39.773Z"},"homepage":"https://github.com/mljs/tree-similarity#readme","keywords":[],"repository":{"type":"git","url":"git+https://github.com/mljs/tree-similarity.git"},"author":{"name":"Miguel Asencio"},"bugs":{"url":"https://github.com/mljs/tree-similarity/issues"},"license":"MIT","readmeFilename":"README.md","users":{"maasencioh":true}}