Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bionode-ncbi

Package Overview
Dependencies
Maintainers
1
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bionode-ncbi - npm Package Compare versions

Comparing version 0.2.1 to 0.3.0

366

lib/bionode-ncbi.js

@@ -26,2 +26,3 @@ // # bionode-ncbi

var fs = require('fs')
var path = require('path')
var mkdirp = require('mkdirp')

@@ -38,16 +39,22 @@ var async = require('async')

var pumpify = require('pumpify')
var URL = require('url')
var cheerio = require('cheerio')
var ncbi = exports
module.exports = exports = ncbi = new NCBI()
function NCBI() {
this.APIROOT = 'http://eutils.ncbi.nlm.nih.gov/entrez/eutils/'
this.DEFAULTS = 'retmode=json&version=2.0'
this.RETURNMAX = 50
this.XMLPROPERTIES = {
'sra': ['expxml', 'runs'],
'biosample': ['sampledata'],
'assembly': ['meta' ]
var APIROOT = 'http://eutils.ncbi.nlm.nih.gov/entrez/eutils/'
var DEFAULTS = 'retmode=json&version=2.0'
var RETURNMAX = 50
var XMLPROPERTIES = {
'sra': ['expxml', 'runs'],
'biosample': ['sampledata'],
'assembly': ['meta' ]
}
var LASTSTREAM = {
'sra': function() {
return pumpify.obj(
tool.ensureIsArray('runs.Run'),
tool.filterObjectsArray('total_bases', '', 'runs.Run')
)
}
return this
}

@@ -87,21 +94,13 @@

NCBI.prototype.search = function(db, term, cb) {
var xmlProperties = ncbi.XMLPROPERTIES[db] || through.obj()
ncbi.search = function(db, term, cb) {
return function() {
var xmlProperties = XMLPROPERTIES[db] || through.obj()
var lastStream = LASTSTREAM[db] || through.obj
var finish
if (db === 'sra') {
finish = pumpify.obj(
tool.ensureIsArray('runs.Run'),
tool.filterObjectsArray('total_bases', '', 'runs.Run')
)
}
else {
finish = through.obj()
}
var stream = pumpify.obj(
_searchURL(db, term),
_requestStream(),
_dataURL(),
_requestStream(),
createAPISearchUrl(db, term),
requestStream(),
createAPIDataURL(),
requestStream(),
filterEmptyResults(),
tool.extractProperty('result'),

@@ -111,3 +110,3 @@ tool.deleteProperty('uids'),

tool.XMLToJSProperties(xmlProperties),
finish
lastStream()
)

@@ -118,10 +117,14 @@

else { return stream }
}()
}
function _searchURL(db, term) {
function createAPISearchUrl(db, term) {
var stream = through.obj(transform)
return stream
function transform(obj, enc, next) {
var query = [
ncbi.APIROOT + 'esearch.fcgi?',
ncbi.DEFAULTS,
APIROOT + 'esearch.fcgi?',
DEFAULTS,
'db=' + db,

@@ -135,20 +138,20 @@ 'term=' + encodeURI(obj),

}
return stream
}
function _dataURL() {
function createAPIDataURL() {
var stream = through.obj(transform)
return stream
function transform(obj, enc, next) {
var count = obj.esearchresult.count
var numRequests = Math.floor(count / ncbi.RETURNMAX)
var numRequests = Math.floor(count / RETURNMAX)
for (var i = 0; i <= numRequests; i++) {
var retstart = i * ncbi.RETURNMAX
var retstart = i * RETURNMAX
var query = [
ncbi.APIROOT + 'esummary.fcgi?',
ncbi.DEFAULTS,
APIROOT + 'esummary.fcgi?',
DEFAULTS,
'db=' + obj.db,
'query_key=1',
'WebEnv=' + obj.esearchresult.webenv,
'retmax=' + ncbi.RETURNMAX,
'retmax=' + RETURNMAX,
'retstart=' + retstart

@@ -163,19 +166,18 @@ ].join('&')

function _requestStream() {
function filterEmptyResults() {
var stream = through.obj(transform)
var outStream = through.obj()
return stream
function transform(obj, enc, next) {
var self = this
request({ uri: obj, json: true }, gotData)
function gotData(err, res, body) {
debug('request response', res.statusCode)
debug('request results', body)
if (body.esearchresult && body.esearchresult.ERROR) {
self.emit('error', new Error(body.esearchresult.ERROR))
}
self.push(body)
next()
if (obj.esummaryresult && obj.esummaryresult[0] === 'Empty result - nothing todo') {
return next()
}
if (obj.error && obj.error[0] === 'Empty result - nothing todo') {
return next()
}
if (obj.result) {
this.push(obj)
}
next()
}
return stream
}

@@ -201,41 +203,55 @@

NCBI.prototype.link = function(srcDB, destDB, srcUID, cb) {
var stream = through.obj(getDestUID)
ncbi.link = function(srcDB, destDB, srcUID, cb) {
var stream = pumpify.obj(
createAPILinkURL(srcDB, destDB),
requestStream(true),
createLinkObj()
)
if (srcUID) { stream.write(srcUID); stream.end() }
if (cb) { stream.pipe(concat(cb)) }
else { return stream }
}
function getDestUID(srcUID, enc, next) {
var self = this
function createAPILinkURL(srcDB, destDB) {
var stream = through.obj(transform)
return stream
function transform(obj, enc, next) {
var query = [
ncbi.APIROOT + 'elink.fcgi?',
APIROOT + 'elink.fcgi?',
'dbfrom=' + srcDB,
'db=' + destDB,
'id=' + srcUID
'id=' + obj.toString()
].join('&')
this.push(query)
next()
}
}
var link = {
srcDB: srcDB,
destDB: destDB,
srcUID: srcUID
function createLinkObj() {
var stream = through.obj(transform)
return stream
function transform(obj, enc, next) {
var self = this
var query = URL.parse(obj.url, true).query
var result = {
srcDB: query.dbfrom,
destDB: query.db,
srcUID: query.id
}
var linkName = srcDB+'_'+destDB
var getLink = tool.attachToObject(link, 'destUID')
debug('elink request', query)
request({ uri: query, json: true })
.pipe(_wait(500))
.pipe(tool.XMLToJS(true))
.pipe(tool.extractProperty('LinkSet.0.LinkSetDb'))
.pipe(tool.arraySplit())
.pipe(tool.collectMatch('LinkName.0', linkName))
.pipe(tool.extractProperty('Link'))
.pipe(tool.arraySplit())
.pipe(tool.extractProperty('Id.0'))
.pipe(getLink)
_attachStandardEvents(getLink, self, next)
xml2js(obj.body, function(err, data) {
if (err) { self.emit('error', err) }
if (data.eLinkResult.LinkSet[0].LinkSetDb) {
data.eLinkResult.LinkSet[0].LinkSetDb.forEach(getMatch)
function getMatch(link) {
if (link.LinkName[0] === query.dbfrom + '_' + query.db) {
result.destUID = link.Link[0].Id[0]
self.push(result)
}
}
}
next()
})
}

@@ -260,17 +276,66 @@ }

NCBI.prototype.download = function(db, term, cb) {
var stream = through.obj(transform)
ncbi.download = function(db, term, cb) {
var stream = pumpify.obj(
ncbi.urls(db),
download(db)
)
if (term) { stream.write(term); stream.end() }
if (cb) { stream.pipe(concat(cb)) }
else { return stream }
}
function download(db, term) {
var stream = through.obj(transform)
return stream
function transform(obj, enc, next) {
var self = this
var download = _download()
var searchdb = db === 'gff' ? 'genome' : db
var getdb = db
var prevTime = Date.now()
var currTime
var chunkSizeMB = 1
var chunkSize = chunkSizeMB * 1024 * 1024 //bytes
var folder = obj.uid + '/'
var path = folder + obj.genomic.fna.replace(/.*\//, '')
ncbi.search(searchdb, obj)
.pipe(_getURLs(getdb))
.pipe(download)
_attachStandardEvents(download, self, next)
var log = {
url: obj.genomic.fna,
path: path,
}
mkdirp.sync(obj.uid)
if (!fs.existsSync(path)) {
debug('downloading', obj.url)
dld(obj.genomic.fna, folder, chunkSize)
.on('data', logging)
.on('end', function() {
log.status = 'completed'
log.speed = 'NA'
self.push(log)
next()
})
.on('error', function(err) { self.emit('error', err) })
}
else {
log.status = 'completed'
log.speed = 'NA'
log.size = Math.round(fs.statSync(path).size / 1024 / 1024) + ' MB'
self.push(log)
next()
}
function logging(position, size) {
var progress = (position * 100 / size).toFixed(2) + ' %'
var sizeMB = Math.round(size / 1024 / 1024) + ' MB'
currTime = Date.now()
var diffTimeSec = (currTime - prevTime) / 1000
prevTime = currTime
var speed = (chunkSizeMB / diffTimeSec).toFixed(2) + ' MB/s'
log.status = 'downloading'
log.total = sizeMB
log.progress = progress
log.speed = speed
self.push(log)
}
}

@@ -291,20 +356,17 @@ }

NCBI.prototype.urls = function(db, term, cb) {
var stream = through.obj(transform)
ncbi.urls = function(db, term, cb) {
var searchdb = db === 'gff' ? 'genome' : db
var stream = pumpify.obj(
ncbi.search(searchdb),
createFTPURL(db)
)
if (term) { stream.write(term); stream.end() }
if (cb) { stream.pipe(concat(cb)) }
else { return stream }
function transform(obj, enc, next) {
var self = this
var searchdb = db === 'gff' ? 'genome' : db
var getdb = db
var getURLs = _getURLs(getdb)
ncbi.search(searchdb, obj)
.pipe(getURLs)
_attachStandardEvents(getURLs, self, next)
}
}
function _getURLs(db) {
return through.obj(transform)
function createFTPURL(db) {
var stream = through.obj(transform)
return stream
function transform(obj, enc, next) {

@@ -341,8 +403,27 @@ var self = this

var ftpArray = Array.isArray(ftpPath) ? ftpPath : [ ftpPath ]
ftpArray.forEach(function(ftp) {
var assemblyURL = ftp._.replace('ftp://', 'http://') + 'Primary_Assembly/unplaced_scaffolds/FASTA/unplaced.scaf.fa.gz'
self.push({url: assemblyURL, uid: obj.uid})
})
var httpRoot = ftpArray[0]._.replace('ftp://', 'http://') // NCBI seems to return GenBank and RefSeq accessions for the same thing. We only need one.
request(httpRoot, gotFTPDir)
function gotFTPDir(err, res, body) {
if (err) { self.emit('error', err) }
if (!res || res.statusCode !== 200) { self.emit('err', res) }
if (!body) { return next() }
$ = cheerio.load(body)
var urls = { uid: obj.uid }
$('a').map(attachToResult)
function attachToResult(i, a) {
var href = a.attribs.href
var base = path.basename(href)
var fileNameProperties = base.replace(/.*\//, '').split('_')
var fileNameExtensions = fileNameProperties[fileNameProperties.length-1].split('.')
var fileType = fileNameExtensions[0]
var fileFormat = fileNameExtensions[1] || 'dir'
if (!urls[fileType]) { urls[fileType] = {} }
urls[fileType][fileFormat] = httpRoot + '/' + href
}
self.push(urls)
next()
}
}
next()
}

@@ -368,60 +449,27 @@

function _download(db, term) {
return through.obj(transform)
function transform(obj, enc, next) {
var self = this
var prevTime = Date.now()
var currTime
var chunkSizeMB = 1
var chunkSize = chunkSizeMB * 1024 * 1024 //bytes
var folder = obj.uid + '/'
var path = folder + obj.url.replace(/.*\//, '')
mkdirp.sync(obj.uid)
if (!fs.existsSync(path)) {
debug('downloading', obj.url)
dld(obj.url, folder, chunkSize)
.on('data', log)
.on('end', function() {
self.push(path)
next()
})
.on('error', function(err) { self.emit('error', err) })
}
else {
self.push(path)
next()
}
function requestStream(returnURL) {
var stream = through.obj(transform)
return stream
function log(position, size) {
var progress = (position * 100 / size).toFixed(2) + ' %'
var sizeMB = Math.round(size / 1024 / 1024) + ' MB'
currTime = Date.now()
var diffTimeSec = (currTime - prevTime) / 1000
prevTime = currTime
var speed = (chunkSizeMB / diffTimeSec).toFixed(2) + ' MB/s'
var log = 'Downloading ' + path+' '+ progress + ' of ' + sizeMB + ' at ' + speed
self.push(log)
}
}
}
function _attachStandardEvents(stream, self, next) {
stream
.on('data', function(data) { self.push(data) })
.on('end', function() { next() })
.on('error', function(err) { self.emit('error', err) })
}
function _wait(ms) {
return through.obj(transform)
function transform(obj, enc, next) {
var self = this
setTimeout(pushObj, ms)
function pushObj() {
self.push(obj)
next()
get()
self.tries = 1
function get() {
if (self.tries > 20) { console.warn('tries' + self.tries + obj) }
request({ uri: obj, json: true, timeout: 5000 }, gotData)
function gotData(err, res, body) {
if (err || !res) { self.tries++; return get() }
debug('request response', res.statusCode)
debug('request results', body)
if (body.esearchresult && body.esearchresult.ERROR) {
self.emit('error', new Error(body.esearchresult.ERROR))
}
var result = returnURL ? {url: obj, body: body} : body
self.push(result)
next()
}
}
}
}
{
"name": "bionode-ncbi",
"description": "Node.js module for working with the NCBI API (aka e-utils) using Streams.",
"version": "0.2.1",
"version": "0.3.0",
"homepage": "http://github.com/bionode/bionode-ncbi",

@@ -17,2 +17,5 @@ "repository": {

"async": "^0.9.0",
"cheerio": "^0.17.0",
"concat-stream": "~1.4.6",
"debug": "^1.0.3",
"dld": "0.0.2",

@@ -22,11 +25,10 @@ "docco": "^0.6.3",

"nested-property": "0.0.2",
"pumpify": "^1.3.2",
"request": "^2.37.0",
"through2": "^0.5.1",
"tool-stream": "0.0.1",
"debug": "^1.0.3",
"xml2js": "^0.4.4",
"concat-stream": "~1.4.6",
"pumpify": "^1.3.2"
"xml2js": "^0.4.4"
},
"devDependencies": {
"contributor": "~0.1.16",
"coveralls": "~2.11.1",

@@ -38,3 +40,5 @@ "docco": "~0.6.3",

"should": "~4.0.4",
"contributor": "~0.1.16"
"tap-spec": "^0.2.1",
"tape": "^2.14.0",
"testling": "^1.7.0"
},

@@ -54,5 +58,5 @@ "keywords": [

"scripts": {
"test": "mocha --reporter spec && rm -rf ./503988",
"coverage": "istanbul cover ./node_modules/.bin/_mocha --report lcovonly -- -R spec && rm -rf ./coverage",
"coveralls": "istanbul cover ./node_modules/.bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | ./node_modules/.bin/coveralls && rm -rf ./coverage",
"test": "node test/*.js | tap-spec && rm -rf ./503988",
"coverage": "istanbul cover test/bionode-ncbi.js --report lcovonly -- | tap-spec && rm -rf ./coverage",
"coveralls": "istanbul cover test/bionode-ncbi.js --report lcovonly -- | tap-spec && cat ./coverage/lcov.info | ./node_modules/.bin/coveralls && rm -rf ./coverage",
"build-docs": "docco ./lib/bionode-ncbi.js"

@@ -59,0 +63,0 @@ },

var fs = require('fs')
var crypto = require('crypto')
var async = require('async')
var test = require('tape')
var ncbi = require('../')
var testData = require('./data')
var guillardiaThetaSRAData = require('./guillardia-theta.sra')
var should = require('should')
require('mocha')
test('Download list', function(t) {
t.plan(2)
describe("Download list", function() {
this.timeout(60000)
it("should take a database name (assembly) and search term (Guillardia theta), and list datasets URLs", function(done) {
ncbi.urls('assembly', 'Guillardia theta').on('data', function(data) {
data.should.eql(testData.assembly['guillardia-theta']['download-list'][0])
done()
ncbi.urls('assembly', 'Guillardia theta')
.on('data', function(data) {
var msg = 'should take a database name (assembly) and search term (Guillardia theta), and list datasets URLs'
t.deepEqual(data, testData.assembly['guillardia-theta'].urls, msg)
})
})
it("should take a database name (sra) and search term (Guillardia theta), and list datasets URLs", function(done) {
var results = []
ncbi.urls('sra', 'Guillardia theta')
.on('data', function(data) {
results.push(data)
})
.on('data', function(data) { results.push(data) })
.on('end', function(data) {
results.should.eql(testData.sra['guillardia-theta']['download-list'])
done()
var msg = 'should take a database name (sra) and search term (Guillardia theta), and list datasets URLs'
t.deepEqual(results, testData.sra['guillardia-theta'].urls, msg)
})
})
})
describe("Download", function() {
this.timeout(600000)
it("should take a database name and search term, and download datasets", function(done) {
download(done)
})
it("repeat same download to cover already downloaded branch", function(done) {
download(done)
})
function download(cb) {
test('Download', function(t) {
t.plan(2)
async.eachSeries(
[
'should take a database name and search term, and download datasets',
'repeat same download to cover already downloaded branch'
],
testDownload
)
function testDownload(msg, cb) {
var path
ncbi.download('assembly', 'Guillardia theta')
.on('data', function(data) { path = data })
.on('data', function(data) { path = data.path })
.on('end', function() {

@@ -51,3 +52,3 @@ var file = fs.ReadStream(path)

var sha1 = shasum.digest('hex');
sha1.should.eql('3f9fc7e9698596ca6ba8eb85fed1f2d7a1070995')
t.equal(sha1, 'a2dc7b3b0ae6f40d5205c4394c2fe8bc65d52bc2', msg)
cb()

@@ -59,45 +60,39 @@ })

describe("Search", function() {
this.timeout(60000)
it("should take a database name and search term, and return the data", function(done) {
ncbi.search('assembly', 'Guillardia theta')
.on('data', function (data) {
data.should.eql(testData.assembly['guillardia-theta'].search)
done()
})
test('Search', function(t) {
t.plan(2)
ncbi.search('assembly', 'Guillardia theta')
.on('data', function (data) {
var msg = 'should take a database name and search term, and return the data'
t.deepEqual(data, testData.assembly['guillardia-theta'].search, msg)
})
it("same as previous but searching sra instead of assembly", function(done) {
var results = []
ncbi.search('sra', 'Guillardia theta')
.on('data', function(data) {
results.push(JSON.parse(JSON.stringify(data)))
})
.on('end', function() {
results.should.eql(guillardiaThetaSRAData)
done()
})
var results = []
ncbi.search('sra', 'Guillardia theta')
.on('data', function(data) { results.push(data) })
.on('end', function() {
var msg = 'same as previous but searching sra instead of assembly'
t.deepEqual(results, guillardiaThetaSRAData, msg)
})
})
describe("Link", function() {
this.timeout(60000)
it("should take names for source database, destination database and a NCBI UID, and return the link", function(done) {
var results = []
ncbi.link('sra', 'bioproject', '35533')
.on('data', function(data) {
results.push(JSON.parse(JSON.stringify(data)))
})
.on('end', function() {
results.should.eql(testData.link['sra-bioproject']['35533'])
done()
})
test('Link', function(t) {
t.plan(2)
var results = []
ncbi.link('sra', 'bioproject', '35533')
.on('data', function(data) { results.push(data) })
.on('end', function() {
var msg = 'should take names for source database, destination database and a NCBI UID, and return the link'
t.deepEqual(results, testData.link['sra-bioproject']['35533'], msg)
})
it("same as previous, but doing bioproject->assembly instead of sra->assembly to try get same assembly UID as Search", function(done) {
ncbi.link('bioproject', 'assembly', '53577')
.on('data', function(data) {
var results = []
ncbi.link('bioproject', 'assembly', '53577')
.on('data', function(data) {
data.destUID.should.eql(testData.assembly['guillardia-theta'].search.uid)
done()
})
var msg = 'same as previous, but doing bioproject->assembly instead of sra->assembly to try get same assembly UID as Search'
t.deepEqual(data.destUID, testData.assembly['guillardia-theta'].search.uid, msg)
})
})
{
"assembly": {
"guillardia-theta": {
"search": {"uid":"503988","rsuid":"1011608","gbuid":"503988","assemblyaccession":"GCF_000315625.1","chainid":"315625","assemblyname":"Guith1","ucscname":"","ensemblname":"","assemblydescription":"","taxid":"905079","organism":"Guillardia theta CCMP2712","speciestaxid":"55529","speciesname":"Guillardia theta","assemblyclass":"haploid","wgs":"AEIE01","releaselevel":"Major","rs_projects":["223305"],"gb_projects":["53577"],"rs_bioprojects":[{"bioprojectid":223305,"bioprojectaccn":"PRJNA223305"}],"gb_bioprojects":[{"bioprojectid":53577,"bioprojectaccn":"PRJNA53577"}],"biosampleaccn":"SAMN00116900","biosampleid":"116900","biosource":{"isolate":"","sex":"","infraspecieslist":[{"sub_type":"strain","sub_value":"CCMP2712"}]},"coverage":"0","partialgenomerepresentation":"false","asmreleasedate":"2012/12/06 00:00","seqreleasedate":"2012/12/05 00:00","asmupdatedate":"2014/04/22 00:00","ncbireleasedate":"2012/12/06 00:00","submissiondate":"2012/12/05 00:00","lastmajorreleaseaccession": "GCF_000315625.1","lastupdatedate":"2014/04/22 00:00","primary":"1011598","propertylist":["full-genome-representation","latest","latest_genbank","latest_refseq","representative","species-default","wgs"],"synonym":{"genbank":"GCA_000315625.1","refseq":"GCF_000315625.1","similarity":"identical"},"sortorder":"2C50003156259898","submitterorganization":"JGI","refseq_category":"representative-genome","anomalouslist":[],"assemblystatus":"Scaffold","meta":{"Stats":{"Stat":[{"_":"0","category":"alt_loci_count","sequence_tag":"all"},{"_":"0","category":"chromosome_count","sequence_tag":"all"},{"_":"5126","category":"contig_count","sequence_tag":"all"},{"_":"587","category":"contig_l50","sequence_tag":"all"},{"_":"40445","category":"contig_n50","sequence_tag":"all"},{"_":"0","category":"non_chromosome_replicon_count","sequence_tag":"all"},{"_":"0","category":"replicon_count","sequence_tag":"all"},{"_":"669","category":"scaffold_count","sequence_tag":"all"},{"_":"0","category":"scaffold_count","sequence_tag":"placed"},{"_":"0","category":"scaffold_count","sequence_tag":"unlocalized"},{"_":"669","category":"scaffold_count","sequence_tag":"unplaced"},{"_":"52","category":"scaffold_l50","sequence_tag":"all"},{"_":"545808","category":"scaffold_n50","sequence_tag":"all"},{"_":"87145349","category":"total_length","sequence_tag":"all"},{"_":"83457412","category":"ungapped_length","sequence_tag":"all"}]},"FtpSites":{"FtpPath":{"_":"ftp://ftp.ncbi.nlm.nih.gov/genbank/genomes/Eukaryotes/protozoa/Guillardia_theta/Guith1/","type":"GenBank"}},"assembly-level":"2","assembly-status":"Scaffold","representative-status":"representative-genome","submitter-organization":"JGI"}},
"download-list": [
{"url": "http://ftp.ncbi.nlm.nih.gov/genbank/genomes/Eukaryotes/protozoa/Guillardia_theta/Guith1/Primary_Assembly/unplaced_scaffolds/FASTA/unplaced.scaf.fa.gz", "uid": "503988"}
]
"search": {
"uid":"503988",
"rsuid":"1011608",
"gbuid":"503988",
"assemblyaccession":"GCF_000315625.1",
"lastmajorreleaseaccession":"GCF_000315625.1",
"chainid":"315625",
"assemblyname":"Guith1",
"ucscname":"",
"ensemblname":"",
"taxid":"905079",
"organism":"Guillardia theta CCMP2712",
"speciestaxid":"55529",
"speciesname":"Guillardia theta",
"assemblyclass":"haploid",
"assemblystatus":"Scaffold",
"wgs":"AEIE01",
"gb_bioprojects":[
{
"bioprojectaccn":"PRJNA53577",
"bioprojectid":53577
}
],
"gb_projects":[
"53577"
],
"rs_bioprojects":[
{
"bioprojectaccn":"PRJNA223305",
"bioprojectid":223305
}
],
"rs_projects":[
"223305"
],
"biosampleaccn":"SAMN00116900",
"biosampleid":"116900",
"biosource":{
"infraspecieslist":[
{
"sub_type":"strain",
"sub_value":"CCMP2712"
}
],
"sex":"",
"isolate":""
},
"coverage":"0",
"partialgenomerepresentation":"false",
"primary":"1011598",
"assemblydescription":"",
"releaselevel":"Major",
"asmreleasedate":"2012/12/06 00:00",
"seqreleasedate":"2012/12/05 00:00",
"asmupdatedate":"2014/04/22 00:00",
"ncbireleasedate":"2012/12/06 00:00",
"submissiondate":"2012/12/05 00:00",
"lastupdatedate":"2014/04/22 00:00",
"submitterorganization":"JGI",
"refseq_category":"representative-genome",
"anomalouslist":[
],
"propertylist":[
"full-genome-representation",
"latest",
"latest_genbank",
"latest_refseq",
"representative",
"species-default",
"wgs"
],
"synonym":{
"genbank":"GCA_000315625.1",
"refseq":"GCF_000315625.1",
"similarity":"identical"
},
"sortorder":"2C50003156259898",
"meta":{
"Stats":{
"Stat":[
{
"_":"0",
"category":"alt_loci_count",
"sequence_tag":"all"
},
{
"_":"0",
"category":"chromosome_count",
"sequence_tag":"all"
},
{
"_":"5126",
"category":"contig_count",
"sequence_tag":"all"
},
{
"_":"587",
"category":"contig_l50",
"sequence_tag":"all"
},
{
"_":"40445",
"category":"contig_n50",
"sequence_tag":"all"
},
{
"_":"0",
"category":"non_chromosome_replicon_count",
"sequence_tag":"all"
},
{
"_":"0",
"category":"replicon_count",
"sequence_tag":"all"
},
{
"_":"669",
"category":"scaffold_count",
"sequence_tag":"all"
},
{
"_":"0",
"category":"scaffold_count",
"sequence_tag":"placed"
},
{
"_":"0",
"category":"scaffold_count",
"sequence_tag":"unlocalized"
},
{
"_":"669",
"category":"scaffold_count",
"sequence_tag":"unplaced"
},
{
"_":"52",
"category":"scaffold_l50",
"sequence_tag":"all"
},
{
"_":"545808",
"category":"scaffold_n50",
"sequence_tag":"all"
},
{
"_":"87145349",
"category":"total_length",
"sequence_tag":"all"
},
{
"_":"83457412",
"category":"ungapped_length",
"sequence_tag":"all"
}
]
},
"FtpSites":{
"FtpPath":[
{
"_":"ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1",
"type":"GenBank"
},
{
"_":"ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCF_000315625.1_Guith1",
"type":"RefSeq"
}
]
},
"assembly-level":"2",
"assembly-status":"Scaffold",
"representative-status":"representative-genome",
"submitter-organization":"JGI"
}
},
"urls": {
"rm" : {
"out" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_rm.out.gz",
"run" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_rm.run"
},
"uid" : "503988",
"stats" : {
"txt" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_assembly_stats.txt"
},
"protein" : {
"gpff" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_protein.gpff.gz",
"faa" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_protein.faa.gz"
},
"report" : {
"txt" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_assembly_report.txt"
},
"structure" : {
"dir" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_assembly_structure/"
},
"md5checksums" : {
"txt" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/md5checksums.txt"
},
"genomic" : {
"gbff" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_genomic.gbff.gz",
"gff" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_genomic.gff.gz",
"fna" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/GCA_000315625.1_Guith1_genomic.fna.gz"
},
"README" : {
"txt" : "http://ftp.ncbi.nlm.nih.gov/genomes/all/GCA_000315625.1_Guith1/README.txt"
}
}
}

@@ -12,3 +215,3 @@ },

"guillardia-theta": {
"download-list": [
"urls": [
{"url":"http://ftp.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByRun/sra/SRR/SRR070/SRR070672/SRR070672.sra","uid":"35523"},

@@ -15,0 +218,0 @@ {"url":"http://ftp.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByRun/sra/SRR/SRR070/SRR070673/SRR070673.sra","uid":"35524"},

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc