Skip to content

Commit 25e405e

Browse files
Dom LaetschDom Laetsch
Dom Laetsch
authored and
Dom Laetsch
committed
new release
1 parent 8270f95 commit 25e405e

24 files changed

+1032
-589
lines changed

scripts/__init__.py __init__.py

File renamed without changes.

bam2cov.py

-157
This file was deleted.

blobtools

-55
This file was deleted.

blobtools

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blobtools.py

blobtools.py

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
#!/usr/bin/env python
2+
# -*- coding: utf-8 -*-
3+
4+
"""
5+
usage: blobtools <command> [<args>...] [--help]
6+
7+
commands:
8+
version print version number
9+
10+
create create a BlobDB
11+
view print BlobDB as a table
12+
blobplot plot BlobDB as a blobplot
13+
covplot compare BlobDB cov(s) to additional cov file
14+
15+
bam2cov generate cov file from bam file
16+
sumcov sum coverage from multiple COV files
17+
seqfilter filter FASTA sequences based on header in list
18+
taxify assign taxids to blast-results based on list
19+
20+
-h --help show this
21+
22+
"""
23+
24+
from __future__ import division
25+
import sys
26+
from subprocess import call
27+
from os.path import join, dirname
28+
from docopt import docopt
29+
30+
__version__ = "blobtools v0.9.18"
31+
MAINDIR = join(dirname(__file__), '')
32+
DATADIR = join(MAINDIR, 'data/')
33+
SRCDIR = join(MAINDIR, 'src/')
34+
LIBDIR = join(MAINDIR, 'lib/')
35+
36+
if __name__ == '__main__':
37+
args = docopt(__doc__,
38+
version=__version__,
39+
options_first=True)
40+
41+
argv = [args['<command>']] + args['<args>']
42+
if args['<command>'] == 'create':
43+
exit(call(['python', SRCDIR + 'create.py'] + argv))
44+
elif args['<command>'] == 'view':
45+
exit(call(['python', SRCDIR + 'view.py'] + argv))
46+
elif args['<command>'] == 'blobplot' or args['<command>'] == 'plot':
47+
argv[0] = "blobplot"
48+
exit(call(['python', SRCDIR + 'blobplot.py'] + argv))
49+
elif args['<command>'] == 'bam2cov':
50+
exit(call(['python', SRCDIR + 'bam2cov.py'] + argv))
51+
elif args['<command>'] == 'covplot' or args['<command>'] == 'comparecov':
52+
argv[0] = "covplot"
53+
exit(call(['python', SRCDIR + 'covplot.py'] + argv))
54+
elif args['<command>'] == 'sumcov':
55+
exit(call(['python', SRCDIR + 'sumcov.py'] + argv))
56+
elif args['<command>'] == 'seqfilter':
57+
exit(call(['python', SRCDIR + 'seqfilter.py'] + argv))
58+
elif args['<command>'] == 'taxify':
59+
exit(call(['python', SRCDIR + 'taxify.py'] + argv))
60+
else:
61+
exit("%r is not a blobtools command. See 'blobtools -h'." % args['<command>'])

data/colours

+11-11
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
#48a365=Nematoda
2-
#d0694a=Arthropoda
3-
#ffb917=Proteobacteria
4-
#926eb3=Actinobacteria
5-
#a6cee3=Ascomycota
6-
#d3d3d3=no-hit
7-
#ec84ba=Chordata
8-
#e0d799=Cnidaria
9-
#b89c75=Platyhelminthes
10-
#fdb761=Bacteriodetes
11-
#ffffff=other
1+
Nematoda #48a365
2+
Arthropoda #d0694a
3+
Proteobacteria #ffb917
4+
Actinobacteria #926eb3
5+
Ascomycota #a6cee3
6+
no-hit #d3d3d3
7+
Chordata #ec84ba
8+
Cnidaria #e0d799
9+
Platyhelminthes #b89c75
10+
Bacteriodetes #fdb761
11+
other #ffffff

0 commit comments

Comments
 (0)