How to use @gmod/bam - 1 common examples

To help you get started, we’ve selected a few @gmod/bam examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github higlass / higlass / app / scripts / data-fetchers / bam-fetcher-worker.js View on Github external
const init = (uid, bamUrl, chromSizesUrl) => {
  if (!bamFiles[bamUrl]) {
    bamFiles[bamUrl] = new BamFile({
      bamUrl,
    });

    // we have to fetch the header before we can fetch data
    bamHeaders[bamUrl] = bamFiles[bamUrl].getHeader();
  }

  chromSizes[chromSizesUrl] = chromSizes[chromSizesUrl]
    || new Promise((resolve, reject) => {
      ChromosomeInfo(chromSizesUrl, resolve);
    });

  dataConfs[uid] = {
    bamUrl, chromSizesUrl
  };
};

@gmod/bam

Parser for BAM and BAM index (bai) files

MIT
Latest version published 4 days ago

Package Health Score

73 / 100
Full package analysis

Popular @gmod/bam functions