@gmod/cram
Advanced tools
Comparing version 1.5.7 to 1.5.8
@@ -313,3 +313,3 @@ "use strict"; | ||
searchPosition = Math.round((upperBound + lowerBound) / 2); | ||
searchPosition = Math.floor((upperBound + lowerBound) / 2); | ||
nextSearchDirection = compare(seqEntries[searchPosition]); | ||
@@ -316,0 +316,0 @@ |
{ | ||
"name": "@gmod/cram", | ||
"version": "1.5.7", | ||
"version": "1.5.8", | ||
"description": "read CRAM files with pure Javascript", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -28,3 +28,3 @@ # @gmod/cram | ||
//Use indexedfasta library for seqFetch, if using local file (see below) | ||
const { IndexedFasta, BgzipIndexedFasta } = require('@gmod/indexedfasta') | ||
const { IndexedFasta, BgzipIndexedFasta } = require('@gmod/indexedfasta') | ||
@@ -45,7 +45,7 @@ | ||
seqFetch: async (seqId, start, end) => { | ||
// note: | ||
// note: | ||
// * seqFetch should return a promise for a string, in this instance retrieved from IndexedFasta | ||
// * we use start-1 because cram-js uses 1-based but IndexedFasta uses 0-based coordinates | ||
// * the seqId is a numeric identifier | ||
return seq = await t.getSequence(seqId, start-1, end) | ||
return t.getSequence(seqId, start-1, end) | ||
} | ||
@@ -57,3 +57,3 @@ }, | ||
// example of fetching records from an indexed CRAM file. | ||
// NOTE: only numeric IDs for the reference sequence are accepted. | ||
// NOTE: only numeric IDs for the reference sequence are accepted. | ||
// For indexedfasta the numeric ID is the order in which the sequence names appear in the header | ||
@@ -60,0 +60,0 @@ |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
570578