1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2015 Ricardo Wurmus <rekado@elephly.net>
3 ;;; Copyright © 2015 Ben Woodcroft <donttrustben@gmail.com>
4 ;;; Copyright © 2015 Pjotr Prins <pjotr.guix@thebird.nl>
5 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
7 ;;; This file is part of GNU Guix.
9 ;;; GNU Guix is free software; you can redistribute it and/or modify it
10 ;;; under the terms of the GNU General Public License as published by
11 ;;; the Free Software Foundation; either version 3 of the License, or (at
12 ;;; your option) any later version.
14 ;;; GNU Guix is distributed in the hope that it will be useful, but
15 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 ;;; GNU General Public License for more details.
19 ;;; You should have received a copy of the GNU General Public License
20 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
22 (define-module (gnu packages bioinformatics)
23 #:use-module ((guix licenses) #:prefix license:)
24 #:use-module (guix packages)
25 #:use-module (guix utils)
26 #:use-module (guix download)
27 #:use-module (guix git-download)
28 #:use-module (guix build-system gnu)
29 #:use-module (guix build-system cmake)
30 #:use-module (guix build-system perl)
31 #:use-module (guix build-system python)
32 #:use-module (guix build-system r)
33 #:use-module (guix build-system ruby)
34 #:use-module (guix build-system trivial)
35 #:use-module (gnu packages)
36 #:use-module (gnu packages autotools)
37 #:use-module (gnu packages algebra)
38 #:use-module (gnu packages base)
39 #:use-module (gnu packages boost)
40 #:use-module (gnu packages compression)
41 #:use-module (gnu packages cpio)
42 #:use-module (gnu packages file)
43 #:use-module (gnu packages java)
44 #:use-module (gnu packages linux)
45 #:use-module (gnu packages machine-learning)
46 #:use-module (gnu packages maths)
47 #:use-module (gnu packages mpi)
48 #:use-module (gnu packages ncurses)
49 #:use-module (gnu packages perl)
50 #:use-module (gnu packages pkg-config)
51 #:use-module (gnu packages popt)
52 #:use-module (gnu packages protobuf)
53 #:use-module (gnu packages python)
54 #:use-module (gnu packages ruby)
55 #:use-module (gnu packages statistics)
56 #:use-module (gnu packages tbb)
57 #:use-module (gnu packages textutils)
58 #:use-module (gnu packages tls)
59 #:use-module (gnu packages vim)
60 #:use-module (gnu packages web)
61 #:use-module (gnu packages xml)
62 #:use-module (gnu packages zip)
63 #:use-module (srfi srfi-1))
65 (define-public aragorn
72 "http://mbio-serv2.mbioekol.lu.se/ARAGORN/Downloads/aragorn"
76 "1dg7jlz1qpqy88igjxd6ncs11ccsirb36qv1z01a0np4i4jh61mb"))))
77 (build-system gnu-build-system)
79 `(#:tests? #f ; there are no tests
81 (modify-phases %standard-phases
91 (string-append "aragorn" ,version ".c")))))
93 (lambda* (#:key outputs #:allow-other-keys)
94 (let* ((out (assoc-ref outputs "out"))
95 (bin (string-append out "/bin"))
96 (man (string-append out "/share/man/man1")))
99 (string-append bin "/aragorn"))
101 (copy-file "aragorn.1"
102 (string-append man "/aragorn.1")))
104 (home-page "http://mbio-serv2.mbioekol.lu.se/ARAGORN")
105 (synopsis "Detect tRNA, mtRNA and tmRNA genes in nucleotide sequences")
107 "Aragorn identifies transfer RNA, mitochondrial RNA and
108 transfer-messenger RNA from nucleotide sequences, based on homology to known
109 tRNA consensus sequences and RNA structure. It also outputs the secondary
110 structure of the predicted RNA.")
111 (license license:gpl2)))
113 (define-public bamtools
120 "https://github.com/pezmaster31/bamtools/archive/v"
122 (file-name (string-append name "-" version ".tar.gz"))
125 "1brry29bw2xr2l9pqn240rkqwayg85b8qq78zk2zs6nlspk4d018"))))
126 (build-system cmake-build-system)
128 `(#:tests? #f ;no "check" target
130 (modify-phases %standard-phases
132 'configure 'set-ldflags
133 (lambda* (#:key outputs #:allow-other-keys)
137 (assoc-ref outputs "out") "/lib/bamtools")))))))
138 (inputs `(("zlib" ,zlib)))
139 (home-page "https://github.com/pezmaster31/bamtools")
140 (synopsis "C++ API and command-line toolkit for working with BAM data")
142 "BamTools provides both a C++ API and a command-line toolkit for handling
144 (license license:expat)))
146 (define-public bedops
152 (uri (string-append "https://github.com/bedops/bedops/archive/v"
154 (file-name (string-append name "-" version ".tar.gz"))
157 "1kqbac547wyqma81cyky9n7mkgikjpsfd3nnmcm6hpqwanqgh10v"))))
158 (build-system gnu-build-system)
161 #:make-flags (list (string-append "BINDIR=" %output "/bin"))
164 'unpack 'unpack-tarballs
166 ;; FIXME: Bedops includes tarballs of minimally patched upstream
167 ;; libraries jansson, zlib, and bzip2. We cannot just use stock
168 ;; libraries because at least one of the libraries (zlib) is
169 ;; patched to add a C++ function definition (deflateInit2cpp).
170 ;; Until the Bedops developers offer a way to link against system
171 ;; libraries we have to build the in-tree copies of these three
174 ;; See upstream discussion:
175 ;; https://github.com/bedops/bedops/issues/124
177 ;; Unpack the tarballs to benefit from shebang patching.
178 (with-directory-excursion "third-party"
179 (and (zero? (system* "tar" "xvf" "jansson-2.6.tar.bz2"))
180 (zero? (system* "tar" "xvf" "zlib-1.2.7.tar.bz2"))
181 (zero? (system* "tar" "xvf" "bzip2-1.0.6.tar.bz2"))))
182 ;; Disable unpacking of tarballs in Makefile.
183 (substitute* "system.mk/Makefile.linux"
184 (("^\tbzcat .*") "\t@echo \"not unpacking\"\n")
185 (("\\./configure") "CONFIG_SHELL=bash ./configure"))
186 (substitute* "third-party/zlib-1.2.7/Makefile.in"
187 (("^SHELL=.*$") "SHELL=bash\n")))
188 (alist-delete 'configure %standard-phases))))
189 (home-page "https://github.com/bedops/bedops")
190 (synopsis "Tools for high-performance genomic feature operations")
192 "BEDOPS is a suite of tools to address common questions raised in genomic
193 studies---mostly with regard to overlap and proximity relationships between
194 data sets. It aims to be scalable and flexible, facilitating the efficient
195 and accurate analysis and management of large-scale genomic data.
197 BEDOPS provides tools that perform highly efficient and scalable Boolean and
198 other set operations, statistical calculations, archiving, conversion and
199 other management of genomic data of arbitrary scale. Tasks can be easily
200 split by chromosome for distributing whole-genome analyses across a
201 computational cluster.")
202 (license license:gpl2+)))
204 (define-public bedtools
210 (uri (string-append "https://github.com/arq5x/bedtools2/archive/v"
212 (file-name (string-append name "-" version ".tar.gz"))
215 "0lnxrjvs3nnmb4bmskag1wg3h2hd80przz5q3xd0bvs7vyxrvpbl"))
216 (patches (list (search-patch "bedtools-32bit-compilation.patch")))))
217 (build-system gnu-build-system)
218 (native-inputs `(("python" ,python-2)))
219 (inputs `(("samtools" ,samtools)
222 '(#:test-target "test"
225 'unpack 'patch-makefile-SHELL-definition
227 ;; patch-makefile-SHELL cannot be used here as it does not
228 ;; yet patch definitions with `:='. Since changes to
229 ;; patch-makefile-SHELL result in a full rebuild, features
230 ;; of patch-makefile-SHELL are reimplemented here.
231 (substitute* "Makefile"
232 (("^SHELL := .*$") (string-append "SHELL := " (which "bash") " -e \n"))))
237 (lambda* (#:key outputs #:allow-other-keys)
238 (let ((bin (string-append (assoc-ref outputs "out") "/bin/")))
239 (for-each (lambda (file)
240 (install-file file bin))
241 (find-files "bin" ".*"))))
242 %standard-phases)))))
243 (home-page "https://github.com/arq5x/bedtools2")
244 (synopsis "Tools for genome analysis and arithmetic")
246 "Collectively, the bedtools utilities are a swiss-army knife of tools for
247 a wide-range of genomics analysis tasks. The most widely-used tools enable
248 genome arithmetic: that is, set theory on the genome. For example, bedtools
249 allows one to intersect, merge, count, complement, and shuffle genomic
250 intervals from multiple files in widely-used genomic file formats such as BAM,
252 (license license:gpl2)))
254 (define-public python2-pybedtools
256 (name "python2-pybedtools")
261 "https://pypi.python.org/packages/source/p/pybedtools/pybedtools-"
265 "1ldzdxw1p4y3g2ignmggsdypvqkcwqwzhdha4rbgpih048z5p4an"))))
266 (build-system python-build-system)
267 (arguments `(#:python ,python-2)) ; no Python 3 support
269 `(("python-cython" ,python2-cython)
270 ("python-matplotlib" ,python2-matplotlib)))
272 `(("bedtools" ,bedtools)
273 ("samtools" ,samtools)))
275 `(("python-pyyaml" ,python2-pyyaml)
276 ("python-nose" ,python2-nose)
277 ("python-setuptools" ,python2-setuptools)))
278 (home-page "https://pythonhosted.org/pybedtools/")
279 (synopsis "Python wrapper for BEDtools programs")
281 "pybedtools is a Python wrapper for Aaron Quinlan's BEDtools programs,
282 which are widely used for genomic interval manipulation or \"genome algebra\".
283 pybedtools extends BEDTools by offering feature-level manipulations from with
285 (license license:gpl2+)))
287 (define-public bioperl-minimal
288 (let* ((inputs `(("perl-module-build" ,perl-module-build)
289 ("perl-data-stag" ,perl-data-stag)
290 ("perl-libwww" ,perl-libwww)
291 ("perl-uri" ,perl-uri)))
293 (map (compose package-name cadr)
296 (map (compose package-transitive-target-inputs cadr) inputs))))))
298 (name "bioperl-minimal")
303 (uri (string-append "mirror://cpan/authors/id/C/CJ/CJFIELDS/BioPerl-"
307 "1l3npcvvvwjlhkna9dndpfv1hklhrgva013kw96m0n1wpd37ask1"))))
308 (build-system perl-build-system)
311 (modify-phases %standard-phases
313 'install 'wrap-programs
314 (lambda* (#:key outputs #:allow-other-keys)
315 ;; Make sure all executables in "bin" find the required Perl
316 ;; modules at runtime. As the PERL5LIB variable contains also
317 ;; the paths of native inputs, we pick the transitive target
318 ;; inputs from %build-inputs.
319 (let* ((out (assoc-ref outputs "out"))
320 (bin (string-append out "/bin/"))
322 (cons (string-append out "/lib/perl5/site_perl")
324 (assoc-ref %build-inputs name))
325 ',transitive-inputs))
327 (for-each (lambda (file)
329 `("PERL5LIB" ":" prefix (,path))))
330 (find-files bin "\\.pl$"))
334 `(("perl-test-most" ,perl-test-most)))
335 (home-page "http://search.cpan.org/dist/BioPerl")
336 (synopsis "Bioinformatics toolkit")
338 "BioPerl is the product of a community effort to produce Perl code which
339 is useful in biology. Examples include Sequence objects, Alignment objects
340 and database searching objects. These objects not only do what they are
341 advertised to do in the documentation, but they also interact - Alignment
342 objects are made from the Sequence objects, Sequence objects have access to
343 Annotation and SeqFeature objects and databases, Blast objects can be
344 converted to Alignment objects, and so on. This means that the objects
345 provide a coordinated and extensible framework to do computational biology.")
346 (license (package-license perl)))))
348 (define-public python-biopython
350 (name "python-biopython")
355 "http://biopython.org/DIST/biopython-"
359 "13m8s9jkrw40zvdp1rl709n6lmgdh4f52aann7gzr6sfp0fwhg26"))))
360 (build-system python-build-system)
362 `(("python-numpy" ,python-numpy)))
364 `(("python-setuptools" ,python2-setuptools)))
365 (home-page "http://biopython.org/")
366 (synopsis "Tools for biological computation in Python")
368 "Biopython is a set of tools for biological computation including parsers
369 for bioinformatics files into Python data structures; interfaces to common
370 bioinformatics programs; a standard sequence class and tools for performing
371 common operations on them; code to perform data classification; code for
372 dealing with alignments; code making it easy to split up parallelizable tasks
373 into separate processes; and more.")
374 (license (license:non-copyleft "http://www.biopython.org/DIST/LICENSE"))))
376 (define-public python2-biopython
377 (package (inherit (package-with-python2 python-biopython))
379 `(("python2-numpy" ,python2-numpy)))))
381 (define-public blast+
388 "ftp://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/"
389 version "/ncbi-blast-" version "+-src.tar.gz"))
392 "19gq6as4k1jrgsd26158ads6h7v4jca3h4r5dzg1y0m6ya50x5ph"))
393 (modules '((guix build utils)))
396 ;; Remove bundled bzip2 and zlib
397 (delete-file-recursively "c++/src/util/compress/bzip2")
398 (delete-file-recursively "c++/src/util/compress/zlib")
399 (substitute* "c++/src/util/compress/Makefile.in"
400 (("bzip2 zlib api") "api"))
401 ;; Remove useless msbuild directory
402 (delete-file-recursively
403 "c++/src/build-system/project_tree_builder/msbuild")
405 (build-system gnu-build-system)
407 `(;; There are three(!) tests for this massive library, and all fail with
408 ;; "unparsable timing stats".
409 ;; ERR [127] -- [util/regexp] test_pcre.sh (unparsable timing stats)
410 ;; ERR [127] -- [serial/datatool] datatool.sh (unparsable timing stats)
411 ;; ERR [127] -- [serial/datatool] datatool_xml.sh (unparsable timing stats)
414 #:parallel-build? #f ; not supported
416 (modify-phases %standard-phases
419 ;; $HOME needs to be set at some point during the configure phase
420 (lambda _ (setenv "HOME" "/tmp") #t))
423 (lambda _ (chdir "c++") #t))
425 'enter-dir 'fix-build-system
428 (cond ((string=? cmd "date")
429 ;; make call to "date" deterministic
434 (format (current-error-port)
435 "WARNING: Unable to find absolute path for ~s~%"
439 ;; Rewrite hardcoded paths to various tools
440 (substitute* (append '("src/build-system/configure.ac"
441 "src/build-system/configure"
442 "scripts/common/impl/if_diff.sh"
443 "scripts/common/impl/run_with_lock.sh"
444 "src/build-system/Makefile.configurables.real"
445 "src/build-system/Makefile.in.top"
446 "src/build-system/Makefile.meta.gmake=no"
447 "src/build-system/Makefile.meta.in"
448 "src/build-system/Makefile.meta_l"
449 "src/build-system/Makefile.meta_p"
450 "src/build-system/Makefile.meta_r"
451 "src/build-system/Makefile.mk.in"
452 "src/build-system/Makefile.requirements"
453 "src/build-system/Makefile.rules_with_autodep.in")
454 (find-files "scripts/common/check" "\\.sh$"))
455 (("(/usr/bin/|/bin/)([a-z][-_.a-z]*)" all dir cmd)
456 (or (which* cmd) all)))
458 (substitute* (find-files "src/build-system" "^config.*")
459 (("LN_S=/bin/\\$LN_S") (string-append "LN_S=" (which "ln")))
462 ;; rewrite "/var/tmp" in check script
463 (substitute* "scripts/common/check/check_make_unix.sh"
464 (("/var/tmp") "/tmp"))
467 (substitute* (find-files "scripts/common/impl/" "\\.sh$")
469 (("action=/bin/") "action=")
470 (("export PATH") ":"))
474 (lambda* (#:key inputs outputs #:allow-other-keys)
475 (let ((out (assoc-ref outputs "out"))
476 (lib (string-append (assoc-ref outputs "lib") "/lib"))
477 (include (string-append (assoc-ref outputs "include")
478 "/include/ncbi-tools++")))
479 ;; The 'configure' script doesn't recognize things like
480 ;; '--enable-fast-install'.
481 (zero? (system* "./configure.orig"
482 (string-append "--with-build-root=" (getcwd) "/build")
483 (string-append "--prefix=" out)
484 (string-append "--libdir=" lib)
485 (string-append "--includedir=" include)
486 (string-append "--with-bz2="
487 (assoc-ref inputs "bzip2"))
488 (string-append "--with-z="
489 (assoc-ref inputs "zlib"))
490 ;; Each library is built twice by default, once
491 ;; with "-static" in its name, and again
495 (outputs '("out" ; 19 MB
503 (home-page "http://blast.ncbi.nlm.nih.gov")
504 (synopsis "Basic local alignment search tool")
506 "BLAST is a popular method of performing a DNA or protein sequence
507 similarity search, using heuristics to produce results quickly. It also
508 calculates an “expect value” that estimates how many matches would have
509 occurred at a given score by chance, which can aid a user in judging how much
510 confidence to have in an alignment.")
511 ;; Most of the sources are in the public domain, with the following
514 ;; * ./c++/include/util/bitset/
515 ;; * ./c++/src/html/ncbi_menu*.js
517 ;; * ./c++/include/util/impl/floating_point_comparison.hpp
519 ;; * ./c++/include/dbapi/driver/odbc/unix_odbc/
521 ;; * ./c++/src/corelib/teamcity_*
522 (license (list license:public-domain
534 (uri (string-append "mirror://sourceforge/bless-ec/bless.v"
538 "0rm0gw2s18dqwzzpl3c2x1z05ni2v0xz5dmfk3d33j6g4cgrlrdd"))
539 (modules '((guix build utils)))
542 ;; Remove bundled boost, pigz, zlib, and .git directory
543 ;; FIXME: also remove bundled sources for google-sparsehash,
544 ;; murmurhash3, kmc once packaged.
545 (delete-file-recursively "boost")
546 (delete-file-recursively "pigz")
547 (delete-file-recursively "zlib")
548 (delete-file-recursively ".git")
550 (build-system gnu-build-system)
552 '(#:tests? #f ;no "check" target
554 (list (string-append "ZLIB="
555 (assoc-ref %build-inputs "zlib")
557 (string-append "LDFLAGS="
558 (string-join '("-lboost_filesystem"
565 (modify-phases %standard-phases
566 (add-after 'unpack 'do-not-build-bundled-pigz
567 (lambda* (#:key inputs outputs #:allow-other-keys)
568 (substitute* "Makefile"
569 (("cd pigz/pigz-2.3.3; make") ""))
571 (add-after 'unpack 'patch-paths-to-executables
572 (lambda* (#:key inputs outputs #:allow-other-keys)
573 (substitute* "parse_args.cpp"
575 (string-append "kmc_binary = \""
576 (assoc-ref outputs "out")
578 (("pigz_binary = .*")
579 (string-append "pigz_binary = \""
580 (assoc-ref inputs "pigz")
584 (lambda* (#:key outputs #:allow-other-keys)
585 (let ((bin (string-append (assoc-ref outputs "out") "/bin/")))
586 (for-each (lambda (file)
587 (install-file file bin))
588 '("bless" "kmc/bin/kmc"))
590 (delete 'configure))))
594 `(("openmpi" ,openmpi)
598 (home-page "http://sourceforge.net/p/bless-ec/wiki/Home/")
599 (synopsis "Bloom-filter-based error correction tool for NGS reads")
601 "@dfn{Bloom-filter-based error correction solution for high-throughput
602 sequencing reads} (BLESS) uses a single minimum-sized bloom filter is a
603 correction tool for genomic reads produced by @dfn{Next-generation
604 sequencing} (NGS). BLESS produces accurate correction results with much less
605 memory compared with previous solutions and is also able to tolerate a higher
606 false-positive rate. BLESS can extend reads like DNA assemblers to correct
607 errors at the end of reads.")
608 (license license:gpl3+)))
610 (define-public bowtie
616 (uri (string-append "https://github.com/BenLangmead/bowtie2/archive/v"
618 (file-name (string-append name "-" version ".tar.gz"))
621 "15dnbqippwvhyh9zqjhaxkabk7lm1xbh1nvar1x4b5kwm117zijn"))
622 (modules '((guix build utils)))
624 '(substitute* "Makefile"
625 (("^CC = .*$") "CC = gcc")
626 (("^CPP = .*$") "CPP = g++")
627 ;; replace BUILD_HOST and BUILD_TIME for deterministic build
628 (("-DBUILD_HOST=.*") "-DBUILD_HOST=\"\\\"guix\\\"\"")
629 (("-DBUILD_TIME=.*") "-DBUILD_TIME=\"\\\"0\\\"\"")))
630 (patches (list (search-patch "bowtie-fix-makefile.patch")))))
631 (build-system gnu-build-system)
632 (inputs `(("perl" ,perl)
633 ("perl-clone" ,perl-clone)
634 ("perl-test-deep" ,perl-test-deep)
635 ("perl-test-simple" ,perl-test-simple)
636 ("python" ,python-2)))
638 '(#:make-flags '("allall")
644 (lambda* (#:key outputs #:allow-other-keys)
645 (let ((bin (string-append (assoc-ref outputs "out") "/bin/")))
646 (for-each (lambda (file)
647 (install-file file bin))
648 (find-files "." "bowtie2.*"))))
651 (lambda* (#:key outputs #:allow-other-keys)
653 "scripts/test/simple_tests.pl"
654 "--bowtie2=./bowtie2"
655 "--bowtie2-build=./bowtie2-build"))
656 %standard-phases)))))
657 (home-page "http://bowtie-bio.sourceforge.net/bowtie2/index.shtml")
658 (synopsis "Fast and sensitive nucleotide sequence read aligner")
660 "Bowtie 2 is a fast and memory-efficient tool for aligning sequencing
661 reads to long reference sequences. It is particularly good at aligning reads
662 of about 50 up to 100s or 1,000s of characters, and particularly good at
663 aligning to relatively long (e.g. mammalian) genomes. Bowtie 2 indexes the
664 genome with an FM Index to keep its memory footprint small: for the human
665 genome, its memory footprint is typically around 3.2 GB. Bowtie 2 supports
666 gapped, local, and paired-end alignment modes.")
667 (supported-systems '("x86_64-linux"))
668 (license license:gpl3+)))
676 (uri (string-append "mirror://sourceforge/bio-bwa/bwa-"
680 "1330dpqncv0px3pbhjzz1gwgg39kkcv2r9qp2xs0sixf8z8wl7bh"))))
681 (build-system gnu-build-system)
683 '(#:tests? #f ;no "check" target
687 (lambda* (#:key outputs #:allow-other-keys)
688 (let ((bin (string-append
689 (assoc-ref outputs "out") "/bin"))
691 (assoc-ref outputs "out") "/share/doc/bwa"))
693 (assoc-ref outputs "out") "/share/man/man1")))
697 (install-file "bwa" bin)
698 (install-file "README.md" doc)
699 (install-file "bwa.1" man)))
700 ;; no "configure" script
701 (alist-delete 'configure %standard-phases))))
702 (inputs `(("zlib" ,zlib)))
703 ;; Non-portable SSE instructions are used so building fails on platforms
704 ;; other than x86_64.
705 (supported-systems '("x86_64-linux"))
706 (home-page "http://bio-bwa.sourceforge.net/")
707 (synopsis "Burrows-Wheeler sequence aligner")
709 "BWA is a software package for mapping low-divergent sequences against a
710 large reference genome, such as the human genome. It consists of three
711 algorithms: BWA-backtrack, BWA-SW and BWA-MEM. The first algorithm is
712 designed for Illumina sequence reads up to 100bp, while the rest two for
713 longer sequences ranged from 70bp to 1Mbp. BWA-MEM and BWA-SW share similar
714 features such as long-read support and split alignment, but BWA-MEM, which is
715 the latest, is generally recommended for high-quality queries as it is faster
716 and more accurate. BWA-MEM also has better performance than BWA-backtrack for
717 70-100bp Illumina reads.")
718 (license license:gpl3+)))
720 (define-public python2-bx-python
722 (name "python2-bx-python")
727 "https://pypi.python.org/packages/source/b/bx-python/bx-python-"
731 "0ld49idhc5zjdvbhvjq1a2qmpjj7h5v58rqr25dzmfq7g34b50xh"))
732 (modules '((guix build utils)))
734 '(substitute* "setup.py"
735 ;; remove dependency on outdated "distribute" module
736 (("^from distribute_setup import use_setuptools") "")
737 (("^use_setuptools\\(\\)") "")))))
738 (build-system python-build-system)
740 `(#:tests? #f ;tests fail because test data are not included
743 `(("python-numpy" ,python2-numpy)
746 `(("python-nose" ,python2-nose)
747 ("python-setuptools" ,python2-setuptools)))
748 (home-page "http://bitbucket.org/james_taylor/bx-python/")
749 (synopsis "Tools for manipulating biological data")
751 "bx-python provides tools for manipulating biological data, particularly
752 multiple sequence alignments.")
753 (license license:expat)))
755 (define-public clipper
762 "https://github.com/YeoLab/clipper/archive/"
764 (file-name (string-append name "-" version ".tar.gz"))
767 "1q7jpimsqln7ic44i8v2rx2haj5wvik8hc1s2syd31zcn0xk1iyq"))
768 (modules '((guix build utils)))
770 ;; remove unnecessary setup dependency
771 '(substitute* "setup.py"
772 (("setup_requires = .*") "")))))
773 (build-system python-build-system)
774 (arguments `(#:python ,python-2)) ; only Python 2 is supported
777 ("python-pybedtools" ,python2-pybedtools)
778 ("python-cython" ,python2-cython)
779 ("python-scikit-learn" ,python2-scikit-learn)
780 ("python-matplotlib" ,python2-matplotlib)
781 ("python-pysam" ,python2-pysam)
782 ("python-numpy" ,python2-numpy)
783 ("python-scipy" ,python2-scipy)))
785 `(("python-mock" ,python2-mock) ; for tests
786 ("python-pytz" ,python2-pytz) ; for tests
787 ("python-setuptools" ,python2-setuptools)))
788 (home-page "https://github.com/YeoLab/clipper")
789 (synopsis "CLIP peak enrichment recognition")
791 "CLIPper is a tool to define peaks in CLIP-seq datasets.")
792 (license license:gpl2)))
794 (define-public couger
801 "http://couger.oit.duke.edu/static/assets/COUGER"
805 "04p2b14nmhzxw5h72mpzdhalv21bx4w9b87z0wpw0xzxpysyncmq"))))
806 (build-system gnu-build-system)
810 (modify-phases %standard-phases
815 (lambda* (#:key outputs #:allow-other-keys)
816 (let ((out (assoc-ref outputs "out")))
817 (copy-recursively "src" (string-append out "/src"))
818 (mkdir (string-append out "/bin"))
819 ;; Add "src" directory to module lookup path.
820 (substitute* "couger"
822 (string-append "import sys\nsys.path.append(\""
823 out "\")\nfrom argparse")))
824 (copy-file "couger" (string-append out "/bin/couger")))
827 'install 'wrap-program
828 (lambda* (#:key inputs outputs #:allow-other-keys)
829 ;; Make sure 'couger' runs with the correct PYTHONPATH.
830 (let* ((out (assoc-ref outputs "out"))
831 (path (getenv "PYTHONPATH")))
832 (wrap-program (string-append out "/bin/couger")
833 `("PYTHONPATH" ":" prefix (,path))))
836 `(("python" ,python-2)
837 ("python2-pillow" ,python2-pillow)
838 ("python2-numpy" ,python2-numpy)
839 ("python2-scipy" ,python2-scipy)
840 ("python2-matplotlib" ,python2-matplotlib)))
844 ("randomjungle" ,randomjungle)))
847 (home-page "http://couger.oit.duke.edu")
848 (synopsis "Identify co-factors in sets of genomic regions")
850 "COUGER can be applied to any two sets of genomic regions bound by
851 paralogous TFs (e.g., regions derived from ChIP-seq experiments) to identify
852 putative co-factors that provide specificity to each TF. The framework
853 determines the genomic targets uniquely-bound by each TF, and identifies a
854 small set of co-factors that best explain the in vivo binding differences
857 COUGER uses classification algorithms (support vector machines and random
858 forests) with features that reflect the DNA binding specificities of putative
859 co-factors. The features are generated either from high-throughput TF-DNA
860 binding data (from protein binding microarray experiments), or from large
861 collections of DNA motifs.")
862 (license license:gpl3+)))
864 (define-public clustal-omega
866 (name "clustal-omega")
871 "http://www.clustal.org/omega/clustal-omega-"
875 "02ibkx0m0iwz8nscg998bh41gg251y56cgh86bvyrii5m8kjgwqf"))))
876 (build-system gnu-build-system)
878 `(("argtable" ,argtable)))
879 (home-page "http://www.clustal.org/omega/")
880 (synopsis "Multiple sequence aligner for protein and DNA/RNA")
882 "Clustal-Omega is a general purpose multiple sequence alignment (MSA)
883 program for protein and DNA/RNA. It produces high quality MSAs and is capable
884 of handling data-sets of hundreds of thousands of sequences in reasonable
886 (license license:gpl2+)))
888 (define-public crossmap
894 (uri (string-append "mirror://sourceforge/crossmap/CrossMap-"
898 "07y179f63d7qnzdvkqcziwk9bs3k4zhp81q392fp1hwszjdvy22f"))
899 ;; This patch has been sent upstream already and is available
900 ;; for download from Sourceforge, but it has not been merged.
902 (search-patch "crossmap-allow-system-pysam.patch")))
903 (modules '((guix build utils)))
904 ;; remove bundled copy of pysam
906 '(delete-file-recursively "lib/pysam"))))
907 (build-system python-build-system)
913 (lambda _ (setenv "CROSSMAP_USE_SYSTEM_PYSAM" "1"))
916 `(("python-numpy" ,python2-numpy)
917 ("python-pysam" ,python2-pysam)
920 `(("python-cython" ,python2-cython)
921 ("python-nose" ,python2-nose)
922 ("python-setuptools" ,python2-setuptools)))
923 (home-page "http://crossmap.sourceforge.net/")
924 (synopsis "Convert genome coordinates between assemblies")
926 "CrossMap is a program for conversion of genome coordinates or annotation
927 files between different genome assemblies. It supports most commonly used
928 file formats including SAM/BAM, Wiggle/BigWig, BED, GFF/GTF, VCF.")
929 (license license:gpl2+)))
931 (define-public cutadapt
938 "https://github.com/marcelm/cutadapt/archive/v"
940 (file-name (string-append name "-" version ".tar.gz"))
943 "161bp87y6gd6r5bmvjpn2b1k942i3fizfpa139f0jn6jv1wcp5h5"))))
944 (build-system python-build-system)
946 ;; tests must be run after install
947 `(#:phases (alist-cons-after
949 (lambda* (#:key inputs outputs #:allow-other-keys)
952 (getenv "PYTHONPATH")
953 ":" (assoc-ref outputs "out")
955 (string-take (string-take-right
956 (assoc-ref inputs "python") 5) 3)
958 (zero? (system* "nosetests" "-P" "tests")))
959 (alist-delete 'check %standard-phases))))
961 `(("python-cython" ,python-cython)
962 ("python-nose" ,python-nose)
963 ("python-setuptools" ,python-setuptools)))
964 (home-page "https://code.google.com/p/cutadapt/")
965 (synopsis "Remove adapter sequences from nucleotide sequencing reads")
967 "Cutadapt finds and removes adapter sequences, primers, poly-A tails and
968 other types of unwanted sequence from high-throughput sequencing reads.")
969 (license license:expat)))
971 (define-public deeptools
978 "https://github.com/fidelram/deepTools/archive/"
980 (file-name (string-append name "-" version ".tar.gz"))
983 "1kaagygcbvjs9sxd9cqmskd02wcfp9imvb735r087w7hwqpvz6fs"))))
984 (build-system python-build-system)
986 `(#:python ,python-2))
988 `(("python-scipy" ,python2-scipy)
989 ("python-numpy" ,python2-numpy)
990 ("python-matplotlib" ,python2-matplotlib)
991 ("python-bx-python" ,python2-bx-python)
992 ("python-pysam" ,python2-pysam)))
994 `(("python-mock" ,python2-mock) ;for tests
995 ("python-pytz" ,python2-pytz) ;for tests
996 ("python-setuptools" ,python2-setuptools)))
997 (home-page "https://github.com/fidelram/deepTools")
998 (synopsis "Tools for normalizing and visualizing deep-sequencing data")
1000 "DeepTools addresses the challenge of handling the large amounts of data
1001 that are now routinely generated from DNA sequencing centers. To do so,
1002 deepTools contains useful modules to process the mapped reads data to create
1003 coverage files in standard bedGraph and bigWig file formats. By doing so,
1004 deepTools allows the creation of normalized coverage files or the comparison
1005 between two files (for example, treatment and control). Finally, using such
1006 normalized and standardized files, multiple visualizations can be created to
1007 identify enrichments with functional annotations of the genome.")
1008 (license license:gpl3+)))
1010 (define-public diamond
1017 "https://github.com/bbuchfink/diamond/archive/v"
1019 (file-name (string-append name "-" version ".tar.gz"))
1022 "0hfkcfv9f76h5brbyw9fyvmc0l9cmbsxrcdqk0fa9xv82zj47p15"))
1024 (delete-file "bin/diamond")
1026 (build-system gnu-build-system)
1028 '(#:tests? #f ;no "check" target
1030 (modify-phases %standard-phases
1031 (add-after 'unpack 'enter-source-dir
1037 (lambda* (#:key outputs #:allow-other-keys)
1038 (let ((bin (string-append (assoc-ref outputs "out")
1041 (copy-file "../bin/diamond"
1042 (string-append bin "/diamond"))
1049 (home-page "https://github.com/bbuchfink/diamond")
1050 (synopsis "Accelerated BLAST compatible local sequence aligner")
1052 "DIAMOND is a BLAST-compatible local aligner for mapping protein and
1053 translated DNA query sequences against a protein reference database (BLASTP
1054 and BLASTX alignment mode). The speedup over BLAST is up to 20,000 on short
1055 reads at a typical sensitivity of 90-99% relative to BLAST depending on the
1056 data and settings.")
1057 ;; diamond fails to build on other platforms
1058 ;; https://github.com/bbuchfink/diamond/issues/18
1059 (supported-systems '("x86_64-linux"))
1060 (license (license:non-copyleft "file://src/COPYING"
1061 "See src/COPYING in the distribution."))))
1063 (define-public edirect
1069 ;; Note: older versions are not retained.
1070 (uri "ftp://ftp.ncbi.nlm.nih.gov/entrez/entrezdirect/edirect.zip")
1073 "08afhz2ph66h8h381hl1mqyxkdi5nbvzsyj9gfw3jfbdijnpi4qj"))))
1074 (build-system perl-build-system)
1076 `(#:tests? #f ;no "check" target
1078 (modify-phases %standard-phases
1082 (lambda* (#:key outputs #:allow-other-keys)
1083 (let ((target (string-append (assoc-ref outputs "out")
1086 (copy-file "edirect.pl"
1087 (string-append target "/edirect.pl"))
1090 'install 'wrap-program
1091 (lambda* (#:key inputs outputs #:allow-other-keys)
1092 ;; Make sure 'edirect.pl' finds all perl inputs at runtime.
1093 (let* ((out (assoc-ref outputs "out"))
1094 (path (getenv "PERL5LIB")))
1095 (wrap-program (string-append out "/bin/edirect.pl")
1096 `("PERL5LIB" ":" prefix (,path)))))))))
1098 `(("perl-html-parser" ,perl-html-parser)
1099 ("perl-encode-locale" ,perl-encode-locale)
1100 ("perl-file-listing" ,perl-file-listing)
1101 ("perl-html-tagset" ,perl-html-tagset)
1102 ("perl-html-tree" ,perl-html-tree)
1103 ("perl-http-cookies" ,perl-http-cookies)
1104 ("perl-http-date" ,perl-http-date)
1105 ("perl-http-message" ,perl-http-message)
1106 ("perl-http-negotiate" ,perl-http-negotiate)
1107 ("perl-lwp-mediatypes" ,perl-lwp-mediatypes)
1108 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
1109 ("perl-net-http" ,perl-net-http)
1110 ("perl-uri" ,perl-uri)
1111 ("perl-www-robotrules" ,perl-www-robotrules)
1114 `(("unzip" ,unzip)))
1115 (home-page "http://www.ncbi.nlm.nih.gov/books/NBK179288")
1116 (synopsis "Tools for accessing the NCBI's set of databases")
1118 "Entrez Direct (EDirect) is a method for accessing the National Center
1119 for Biotechnology Information's (NCBI) set of interconnected
1120 databases (publication, sequence, structure, gene, variation, expression,
1121 etc.) from a terminal. Functions take search terms from command-line
1122 arguments. Individual operations are combined to build multi-step queries.
1123 Record retrieval and formatting normally complete the process.
1125 EDirect also provides an argument-driven function that simplifies the
1126 extraction of data from document summaries or other results that are returned
1127 in structured XML format. This can eliminate the need for writing custom
1128 software to answer ad hoc questions.")
1129 (license license:public-domain)))
1131 (define-public express
1139 "http://bio.math.berkeley.edu/eXpress/downloads/express-"
1140 version "/express-" version "-src.tgz"))
1143 "03rczxd0gjp2l1jxcmjfmf5j94j77zqyxa6x063zsc585nj40n0c"))))
1144 (build-system cmake-build-system)
1146 `(#:tests? #f ;no "check" target
1149 'unpack 'use-shared-boost-libs-and-set-bamtools-paths
1150 (lambda* (#:key inputs #:allow-other-keys)
1151 (substitute* "CMakeLists.txt"
1152 (("set\\(Boost_USE_STATIC_LIBS ON\\)")
1153 "set(Boost_USE_STATIC_LIBS OFF)")
1154 (("\\$\\{CMAKE_CURRENT_SOURCE_DIR\\}/bamtools/include")
1155 (string-append (assoc-ref inputs "bamtools") "/include/bamtools")))
1156 (substitute* "src/CMakeLists.txt"
1157 (("\\$\\{CMAKE_CURRENT_SOURCE_DIR\\}/\\.\\./bamtools/lib")
1158 (string-append (assoc-ref inputs "bamtools") "/lib/bamtools")))
1163 ("bamtools" ,bamtools)
1164 ("protobuf" ,protobuf)
1166 (home-page "http://bio.math.berkeley.edu/eXpress")
1167 (synopsis "Streaming quantification for high-throughput genomic sequencing")
1169 "eXpress is a streaming tool for quantifying the abundances of a set of
1170 target sequences from sampled subsequences. Example applications include
1171 transcript-level RNA-Seq quantification, allele-specific/haplotype expression
1172 analysis (from RNA-Seq), transcription factor binding quantification in
1173 ChIP-Seq, and analysis of metagenomic data.")
1174 (license license:artistic2.0)))
1176 (define-public express-beta-diversity
1178 (name "express-beta-diversity")
1184 "https://github.com/dparks1134/ExpressBetaDiversity/archive/v"
1186 (file-name (string-append name "-" version ".tar.gz"))
1189 "1djvdlmqvjf6h0zq7w36y8cl5cli6rgj86x65znl48agnwmzxfxr"))))
1190 (build-system gnu-build-system)
1193 (modify-phases %standard-phases
1195 (add-before 'build 'enter-source (lambda _ (chdir "source") #t))
1197 (lambda _ (zero? (system* "../bin/ExpressBetaDiversity"
1199 (add-after 'check 'exit-source (lambda _ (chdir "..") #t))
1201 (lambda* (#:key outputs #:allow-other-keys)
1202 (let ((bin (string-append (assoc-ref outputs "out")
1205 (copy-file "scripts/convertToEBD.py"
1206 (string-append bin "/convertToEBD.py"))
1207 (copy-file "bin/ExpressBetaDiversity"
1208 (string-append bin "/ExpressBetaDiversity"))
1211 `(("python" ,python-2)))
1212 (home-page "http://kiwi.cs.dal.ca/Software/ExpressBetaDiversity")
1213 (synopsis "Taxon- and phylogenetic-based beta diversity measures")
1215 "Express Beta Diversity (EBD) calculates ecological beta diversity
1216 (dissimilarity) measures between biological communities. EBD implements a
1217 variety of diversity measures including those that make use of phylogenetic
1218 similarity of community members.")
1219 (license license:gpl3+)))
1221 (define-public fasttree
1228 "http://www.microbesonline.org/fasttree/FastTree-"
1232 "0dzqc9vr9iiiw21y159xfjl2z90vw0y7r4x6456pcaxiy5hd2wmi"))))
1233 (build-system gnu-build-system)
1235 `(#:tests? #f ; no "check" target
1237 (modify-phases %standard-phases
1241 (lambda* (#:key source #:allow-other-keys)
1242 (and (zero? (system* "gcc"
1244 "-finline-functions"
1251 (zero? (system* "gcc"
1255 "-finline-functions"
1263 (lambda* (#:key outputs #:allow-other-keys)
1264 (let ((bin (string-append (assoc-ref outputs "out")
1267 (copy-file "FastTree"
1268 (string-append bin "/FastTree"))
1269 (copy-file "FastTreeMP"
1270 (string-append bin "/FastTreeMP"))
1272 (home-page "http://www.microbesonline.org/fasttree")
1273 (synopsis "Infers approximately-maximum-likelihood phylogenetic trees")
1275 "FastTree can handle alignments with up to a million of sequences in a
1276 reasonable amount of time and memory. For large alignments, FastTree is
1277 100-1,000 times faster than PhyML 3.0 or RAxML 7.")
1278 (license license:gpl2+)))
1280 (define-public fastx-toolkit
1282 (name "fastx-toolkit")
1288 "https://github.com/agordon/fastx_toolkit/releases/download/"
1289 version "/fastx_toolkit-" version ".tar.bz2"))
1292 "01jqzw386873sr0pjp1wr4rn8fsga2vxs1qfmicvx1pjr72007wy"))))
1293 (build-system gnu-build-system)
1295 `(("libgtextutils" ,libgtextutils)))
1297 `(("pkg-config" ,pkg-config)))
1298 (home-page "http://hannonlab.cshl.edu/fastx_toolkit/")
1299 (synopsis "Tools for FASTA/FASTQ file preprocessing")
1301 "The FASTX-Toolkit is a collection of command line tools for Short-Reads
1302 FASTA/FASTQ files preprocessing.
1304 Next-Generation sequencing machines usually produce FASTA or FASTQ files,
1305 containing multiple short-reads sequences. The main processing of such
1306 FASTA/FASTQ files is mapping the sequences to reference genomes. However, it
1307 is sometimes more productive to preprocess the files before mapping the
1308 sequences to the genome---manipulating the sequences to produce better mapping
1309 results. The FASTX-Toolkit tools perform some of these preprocessing tasks.")
1310 (license license:agpl3+)))
1312 (define-public flexbar
1319 (string-append "mirror://sourceforge/flexbar/"
1320 version "/flexbar_v" version "_src.tgz"))
1323 "13jaykc3y1x8y5nn9j8ljnb79s5y51kyxz46hdmvvjj6qhyympmf"))))
1324 (build-system cmake-build-system)
1326 `(#:configure-flags (list
1327 (string-append "-DFLEXBAR_BINARY_DIR="
1328 (assoc-ref %outputs "out")
1333 (lambda* (#:key outputs #:allow-other-keys)
1334 (setenv "PATH" (string-append
1335 (assoc-ref outputs "out") "/bin:"
1337 (chdir "../flexbar_v2.5_src/test")
1338 (zero? (system* "bash" "flexbar_validate.sh")))
1339 (alist-delete 'install %standard-phases))))
1344 `(("pkg-config" ,pkg-config)
1346 (home-page "http://flexbar.sourceforge.net")
1347 (synopsis "Barcode and adapter removal tool for sequencing platforms")
1349 "Flexbar preprocesses high-throughput nucleotide sequencing data
1350 efficiently. It demultiplexes barcoded runs and removes adapter sequences.
1351 Moreover, trimming and filtering features are provided. Flexbar increases
1352 read mapping rates and improves genome and transcriptome assemblies. It
1353 supports next-generation sequencing data in fasta/q and csfasta/q format from
1354 Illumina, Roche 454, and the SOLiD platform.")
1355 (license license:gpl3)))
1364 "https://github.com/nboley/grit/archive/"
1366 (file-name (string-append name "-" version ".tar.gz"))
1369 "157in84dj70wimbind3x7sy1whs3h57qfgcnj2s6lrd38fbrb7mj"))))
1370 (build-system python-build-system)
1372 `(#:python ,python-2
1375 'unpack 'generate-from-cython-sources
1376 (lambda* (#:key inputs outputs #:allow-other-keys)
1377 ;; Delete these C files to force fresh generation from pyx sources.
1378 (delete-file "grit/sparsify_support_fns.c")
1379 (delete-file "grit/call_peaks_support_fns.c")
1380 (substitute* "setup.py"
1381 (("Cython.Setup") "Cython.Build")
1382 ;; Add numpy include path to fix compilation
1384 (string-append "pyx\", ], include_dirs = ['"
1385 (assoc-ref inputs "python-numpy")
1386 "/lib/python2.7/site-packages/numpy/core/include/"
1390 `(("python-scipy" ,python2-scipy)
1391 ("python-numpy" ,python2-numpy)
1392 ("python-pysam" ,python2-pysam)
1393 ("python-networkx" ,python2-networkx)))
1395 `(("python-cython" ,python2-cython)
1396 ("python-setuptools" ,python2-setuptools)))
1397 (home-page "http://grit-bio.org")
1398 (synopsis "Tool for integrative analysis of RNA-seq type assays")
1400 "GRIT is designed to use RNA-seq, TES, and TSS data to build and quantify
1401 full length transcript models. When none of these data sources are available,
1402 GRIT can be run by providing a candidate set of TES or TSS sites. In
1403 addition, GRIT can merge in reference junctions and gene boundaries. GRIT can
1404 also be run in quantification mode, where it uses a provided GTF file and just
1405 estimates transcript expression.")
1406 (license license:gpl3+)))
1408 (define-public hisat
1415 "http://ccb.jhu.edu/software/hisat/downloads/hisat-"
1416 version "-beta-source.zip"))
1419 "1k381ydranqxp09yf2y7w1d0chz5d59vb6jchi89hbb0prq19lk5"))))
1420 (build-system gnu-build-system)
1422 `(#:tests? #f ;no check target
1423 #:make-flags '("allall"
1424 ;; Disable unsupported `popcnt' instructions on
1425 ;; architectures other than x86_64
1426 ,@(if (string-prefix? "x86_64"
1427 (or (%current-target-system)
1430 '("POPCNT_CAPABILITY=0")))
1433 'unpack 'patch-sources
1435 ;; XXX Cannot use snippet because zip files are not supported
1436 (substitute* "Makefile"
1437 (("^CC = .*$") "CC = gcc")
1438 (("^CPP = .*$") "CPP = g++")
1439 ;; replace BUILD_HOST and BUILD_TIME for deterministic build
1440 (("-DBUILD_HOST=.*") "-DBUILD_HOST=\"\\\"guix\\\"\"")
1441 (("-DBUILD_TIME=.*") "-DBUILD_TIME=\"\\\"0\\\"\""))
1442 (substitute* '("hisat-build" "hisat-inspect")
1443 (("/usr/bin/env") (which "env"))))
1446 (lambda* (#:key outputs #:allow-other-keys)
1447 (let ((bin (string-append (assoc-ref outputs "out") "/bi/")))
1448 (for-each (lambda (file)
1449 (install-file file bin))
1452 "hisat(-(build|align|inspect)(-(s|l)(-debug)*)*)*$"))))
1453 (alist-delete 'configure %standard-phases)))))
1455 `(("unzip" ,unzip)))
1460 ;; Non-portable SSE instructions are used so building fails on platforms
1461 ;; other than x86_64.
1462 (supported-systems '("x86_64-linux"))
1463 (home-page "http://ccb.jhu.edu/software/hisat/index.shtml")
1464 (synopsis "Hierarchical indexing for spliced alignment of transcripts")
1466 "HISAT is a fast and sensitive spliced alignment program for mapping
1467 RNA-seq reads. In addition to one global FM index that represents a whole
1468 genome, HISAT uses a large set of small FM indexes that collectively cover the
1469 whole genome. These small indexes (called local indexes) combined with
1470 several alignment strategies enable effective alignment of RNA-seq reads, in
1471 particular, reads spanning multiple exons.")
1472 (license license:gpl3+)))
1474 (define-public hmmer
1481 "http://selab.janelia.org/software/hmmer"
1482 (version-prefix version 1) "/"
1483 version "/hmmer-" version ".tar.gz"))
1486 "0djmgc0pfli0jilfx8hql1axhwhqxqb8rxg2r5rg07aw73sfs5nx"))))
1487 (build-system gnu-build-system)
1488 (native-inputs `(("perl", perl)))
1489 (home-page "http://hmmer.janelia.org")
1490 (synopsis "Biosequence analysis using profile hidden Markov models")
1492 "HMMER is used for searching sequence databases for homologs of protein
1493 sequences, and for making protein sequence alignments. It implements methods
1494 using probabilistic models called profile hidden Markov models (profile
1496 (license (list license:gpl3+
1497 ;; The bundled library 'easel' is distributed
1498 ;; under The Janelia Farm Software License.
1499 (license:non-copyleft
1500 "file://easel/LICENSE"
1501 "See easel/LICENSE in the distribution.")))))
1503 (define-public htseq
1510 "https://pypi.python.org/packages/source/H/HTSeq/HTSeq-"
1514 "1i85ppf2j2lj12m0x690qq5nn17xxk23pbbx2c83r8ayb5wngzwv"))))
1515 (build-system python-build-system)
1516 (arguments `(#:python ,python-2)) ; only Python 2 is supported
1517 ;; Numpy needs to be propagated when htseq is used as a Python library.
1519 `(("python-numpy" ,python2-numpy)))
1521 `(("python-setuptools" ,python2-setuptools)))
1522 (home-page "http://www-huber.embl.de/users/anders/HTSeq/")
1523 (synopsis "Analysing high-throughput sequencing data with Python")
1525 "HTSeq is a Python package that provides infrastructure to process data
1526 from high-throughput sequencing assays.")
1527 (license license:gpl3+)))
1529 (define-public htsjdk
1536 "https://github.com/samtools/htsjdk/archive/"
1538 (file-name (string-append name "-" version ".tar.gz"))
1541 "0asdk9b8jx2ij7yd6apg9qx03li8q7z3ml0qy2r2qczkra79y6fw"))
1542 (modules '((guix build utils)))
1543 ;; remove build dependency on git
1544 (snippet '(substitute* "build.xml"
1545 (("failifexecutionfails=\"true\"")
1546 "failifexecutionfails=\"false\"")))))
1547 (build-system gnu-build-system)
1549 `(#:modules ((srfi srfi-1)
1550 (guix build gnu-build-system)
1552 #:phases (alist-replace
1555 (setenv "JAVA_HOME" (assoc-ref %build-inputs "jdk"))
1556 (zero? (system* "ant" "all"
1557 (string-append "-Ddist="
1558 (assoc-ref %outputs "out")
1559 "/share/java/htsjdk/"))))
1560 (fold alist-delete %standard-phases
1561 '(configure install check)))))
1564 ("jdk" ,icedtea6 "jdk")))
1565 (home-page "http://samtools.github.io/htsjdk/")
1566 (synopsis "Java API for high-throughput sequencing data (HTS) formats")
1568 "HTSJDK is an implementation of a unified Java library for accessing
1569 common file formats, such as SAM and VCF, used for high-throughput
1570 sequencing (HTS) data. There are also an number of useful utilities for
1571 manipulating HTS data.")
1572 (license license:expat)))
1574 (define-public htslib
1581 "https://github.com/samtools/htslib/releases/download/"
1582 version "/htslib-" version ".tar.bz2"))
1585 "1c32ssscbnjwfw3dra140fq7riarp2x990qxybh34nr1p5r17nxx"))))
1586 (build-system gnu-build-system)
1589 (modify-phases %standard-phases
1591 'unpack 'patch-tests
1593 (substitute* "test/test.pl"
1594 (("/bin/bash") (which "bash")))
1600 (home-page "http://www.htslib.org")
1601 (synopsis "C library for reading/writing high-throughput sequencing data")
1603 "HTSlib is a C library for reading/writing high-throughput sequencing
1604 data. It also provides the bgzip, htsfile, and tabix utilities.")
1605 ;; Files under cram/ are released under the modified BSD license;
1606 ;; the rest is released under the Expat license
1607 (license (list license:expat license:bsd-3))))
1616 "https://github.com/nboley/idr/archive/"
1618 (file-name (string-append name "-" version ".tar.gz"))
1621 "1k3x44biak00aiv3hpm1yd6nn4hhp7n0qnbs3zh2q9sw7qr1qj5r"))))
1622 (build-system python-build-system)
1625 (modify-phases %standard-phases
1627 'install 'wrap-program
1628 (lambda* (#:key inputs outputs #:allow-other-keys)
1629 (let* ((out (assoc-ref outputs "out"))
1630 (python-version (string-take (string-take-right
1631 (assoc-ref inputs "python") 5) 3))
1634 (string-append (assoc-ref inputs name)
1635 "/lib/python" python-version
1639 "python-matplotlib"))
1641 (wrap-program (string-append out "/bin/idr")
1642 `("PYTHONPATH" ":" prefix (,path))))
1645 `(("python-scipy" ,python-scipy)
1646 ("python-numpy" ,python-numpy)
1647 ("python-matplotlib" ,python-matplotlib)))
1649 `(("python-cython" ,python-cython)
1650 ("python-setuptools" ,python-setuptools)))
1651 (home-page "https://github.com/nboley/idr")
1652 (synopsis "Tool to measure the irreproducible discovery rate (IDR)")
1654 "The IDR (Irreproducible Discovery Rate) framework is a unified approach
1655 to measure the reproducibility of findings identified from replicate
1656 experiments and provide highly stable thresholds based on reproducibility.")
1657 (license license:gpl3+)))
1662 (version "2.1.0.20140616")
1666 "https://pypi.python.org/packages/source/M/MACS2/MACS2-"
1670 "11lmiw6avqhwn75sn59g4lfkrr2kk20r3rgfbx9xfqb8rg9mi2n6"))))
1671 (build-system python-build-system)
1673 `(#:python ,python-2 ; only compatible with Python 2.7
1674 #:tests? #f)) ; no test target
1676 `(("python-numpy" ,python2-numpy)))
1678 `(("python-setuptools" ,python2-setuptools)))
1679 (home-page "http://github.com/taoliu/MACS/")
1680 (synopsis "Model based analysis for ChIP-Seq data")
1682 "MACS is an implementation of a ChIP-Seq analysis algorithm for
1683 identifying transcript factor binding sites named Model-based Analysis of
1684 ChIP-Seq (MACS). MACS captures the influence of genome complexity to evaluate
1685 the significance of enriched ChIP regions and it improves the spatial
1686 resolution of binding sites through combining the information of both
1687 sequencing tag position and orientation.")
1688 (license license:bsd-3)))
1690 (define-public mafft
1697 "http://mafft.cbrc.jp/alignment/software/mafft-" version
1698 "-without-extensions-src.tgz"))
1699 (file-name (string-append name "-" version ".tgz"))
1702 "0xi7klbsgi049vsrk6jiwh9wfj3b770gz3c8c7zwij448v0dr73d"))))
1703 (build-system gnu-build-system)
1705 `(#:tests? #f ; no automated tests, though there are tests in the read me
1706 #:make-flags (let ((out (assoc-ref %outputs "out")))
1707 (list (string-append "PREFIX=" out)
1708 (string-append "BINDIR="
1709 (string-append out "/bin"))))
1711 (modify-phases %standard-phases
1712 (add-after 'unpack 'enter-dir
1713 (lambda _ (chdir "core") #t))
1714 (add-after 'enter-dir 'patch-makefile
1716 ;; on advice from the MAFFT authors, there is no need to
1717 ;; distribute mafft-profile, mafft-distance, or
1718 ;; mafft-homologs.rb as they are too "specialised".
1719 (substitute* "Makefile"
1720 ;; remove mafft-homologs.rb from SCRIPTS
1721 (("^SCRIPTS = mafft mafft-homologs.rb")
1723 ;; remove mafft-distance from PROGS
1724 (("^PROGS = dvtditr dndfast7 dndblast sextet5 mafft-distance")
1725 "PROGS = dvtditr dndfast7 dndblast sextet5")
1726 ;; remove mafft-profile from PROGS
1727 (("splittbfast disttbfast tbfast mafft-profile 2cl mccaskillwrap")
1728 "splittbfast disttbfast tbfast f2cl mccaskillwrap")
1729 (("^rm -f mafft-profile mafft-profile.exe") "#")
1730 (("^rm -f mafft-distance mafft-distance.exe") ")#")
1731 ;; do not install MAN pages in libexec folder
1732 (("^\t\\$\\(INSTALL\\) -m 644 \\$\\(MANPAGES\\) \
1733 \\$\\(DESTDIR\\)\\$\\(LIBDIR\\)") "#"))
1735 (delete 'configure))))
1738 (home-page "http://mafft.cbrc.jp/alignment/software/")
1739 (synopsis "Multiple sequence alignment program")
1741 "MAFFT offers a range of multiple alignment methods for nucleotide and
1742 protein sequences. For instance, it offers L-INS-i (accurate; for alignment
1743 of <~200 sequences) and FFT-NS-2 (fast; for alignment of <~30,000
1745 (license (license:non-copyleft
1746 "http://mafft.cbrc.jp/alignment/software/license.txt"
1747 "BSD-3 with different formatting"))))
1749 (define-public metabat
1756 "https://bitbucket.org/berkeleylab/metabat/get/"
1757 version ".tar.bz2"))
1758 (file-name (string-append name "-" version ".tar.bz2"))
1761 "0vgrhbaxg4dkxyax2kbigak7w0arhqvw0szwp6gd9wmyilc44kfa"))))
1762 (build-system gnu-build-system)
1765 (modify-phases %standard-phases
1766 (add-after 'unpack 'fix-includes
1768 (substitute* "SConstruct"
1769 (("/include/bam/bam.h")
1770 "/include/samtools/bam.h"))
1771 (substitute* "src/BamUtils.h"
1772 (("^#include \"bam/bam\\.h\"")
1773 "#include \"samtools/bam.h\"")
1774 (("^#include \"bam/sam\\.h\"")
1775 "#include \"samtools/sam.h\""))
1776 (substitute* "src/KseqReader.h"
1777 (("^#include \"bam/kseq\\.h\"")
1778 "#include \"samtools/kseq.h\""))
1780 (add-after 'unpack 'fix-scons
1782 (substitute* "SConstruct" ; Do not distribute README
1783 (("^env\\.Install\\(idir_prefix, 'README\\.md'\\)")
1788 (lambda* (#:key inputs outputs #:allow-other-keys)
1789 (mkdir (assoc-ref outputs "out"))
1790 (zero? (system* "scons"
1793 (assoc-ref outputs "out"))
1796 (assoc-ref inputs "htslib"))
1799 (assoc-ref inputs "samtools"))
1802 (assoc-ref inputs "boost"))
1804 ;; check and install carried out during build phase
1806 (delete 'install))))
1810 ("samtools" ,samtools)
1814 `(("scons" ,scons)))
1815 (home-page "https://bitbucket.org/berkeleylab/metabat")
1817 "Reconstruction of single genomes from complex microbial communities")
1819 "Grouping large genomic fragments assembled from shotgun metagenomic
1820 sequences to deconvolute complex microbial communities, or metagenome binning,
1821 enables the study of individual organisms and their interactions. MetaBAT is
1822 an automated metagenome binning software, which integrates empirical
1823 probabilistic distances of genome abundance and tetranucleotide frequency.")
1824 (license (license:non-copyleft "file://license.txt"
1825 "See license.txt in the distribution."))))
1834 "https://pypi.python.org/packages/source/m/misopy/misopy-"
1838 "0x446867az8ir0z8c1vjqffkp0ma37wm4sylixnkhgawllzx8v5w"))
1839 (modules '((guix build utils)))
1841 '(substitute* "setup.py"
1842 ;; Use setuptools, or else the executables are not
1844 (("distutils.core") "setuptools")
1845 ;; use "gcc" instead of "cc" for compilation
1847 "cc.set_executables(
1851 linker_so='gcc -shared'); defines")))))
1852 (build-system python-build-system)
1854 `(#:python ,python-2 ; only Python 2 is supported
1855 #:tests? #f)) ; no "test" target
1857 `(("samtools" ,samtools)
1858 ("python-numpy" ,python2-numpy)
1859 ("python-pysam" ,python2-pysam)
1860 ("python-scipy" ,python2-scipy)
1861 ("python-matplotlib" ,python2-matplotlib)))
1863 `(("python-mock" ,python2-mock) ;for tests
1864 ("python-pytz" ,python2-pytz) ;for tests
1865 ("python-setuptools" ,python2-setuptools)))
1866 (home-page "http://genes.mit.edu/burgelab/miso/index.html")
1867 (synopsis "Mixture of Isoforms model for RNA-Seq isoform quantitation")
1869 "MISO (Mixture-of-Isoforms) is a probabilistic framework that quantitates
1870 the expression level of alternatively spliced genes from RNA-Seq data, and
1871 identifies differentially regulated isoforms or exons across samples. By
1872 modeling the generative process by which reads are produced from isoforms in
1873 RNA-Seq, the MISO model uses Bayesian inference to compute the probability
1874 that a read originated from a particular isoform.")
1875 (license license:gpl2)))
1884 "https://github.com/wwood/OrfM/releases/download/v"
1885 version "/orfm-" version ".tar.gz"))
1888 "05fmw145snk646ly076zby0fjav0k7ysbclck5d4s9pmgcfpijc2"))))
1889 (build-system gnu-build-system)
1890 (inputs `(("zlib" ,zlib)))
1891 (synopsis "Simple and not slow open reading frame (ORF) caller")
1893 "An ORF caller finds stretches of DNA that when translated are not
1894 interrupted by stop codons. OrfM finds and prints these ORFs.")
1895 (home-page "https://github.com/wwood/OrfM")
1896 (license license:lgpl3+)))
1898 (define-public python2-pbcore
1900 (name "python2-pbcore")
1905 "https://github.com/PacificBiosciences/pbcore/archive/"
1907 (file-name (string-append name "-" version ".tar.gz"))
1910 "1z46rwjac93jm87cbj2zgjg6qvsgs65140wkbbxsvxps7ai4pm09"))))
1911 (build-system python-build-system)
1912 (arguments `(#:python ,python-2)) ; pbcore requires Python 2.7
1914 `(("python-cython" ,python2-cython)
1915 ("python-numpy" ,python2-numpy)
1916 ("python-pysam" ,python2-pysam)
1917 ("python-h5py" ,python2-h5py)))
1919 `(("python-setuptools" ,python2-setuptools)))
1920 (home-page "http://pacificbiosciences.github.io/pbcore/")
1921 (synopsis "Library for reading and writing PacBio data files")
1923 "The pbcore package provides Python APIs for interacting with PacBio data
1924 files and writing bioinformatics applications.")
1925 (license license:bsd-3)))
1927 (define-public python2-warpedlmm
1929 (name "python2-warpedlmm")
1935 "https://pypi.python.org/packages/source/W/WarpedLMM/WarpedLMM-"
1939 "1agfz6zqa8nc6cw47yh0s3y14gkpa9wqazwcj7mwwj3ffnw39p3j"))))
1940 (build-system python-build-system)
1942 `(#:python ,python-2 ; requires Python 2.7
1944 (modify-phases %standard-phases
1946 'install 'remove-bin-directory
1947 (lambda* (#:key outputs #:allow-other-keys)
1948 ;; The "bin" directory only contains wrappers for running
1949 ;; the module tests. They are not needed after the
1951 (delete-file-recursively
1952 (string-append (assoc-ref outputs "out") "/bin"))
1955 `(("python-scipy" ,python2-scipy)
1956 ("python-numpy" ,python2-numpy)
1957 ("python-matplotlib" ,python2-matplotlib)
1958 ("python-fastlmm" ,python2-fastlmm)
1959 ("python-pandas" ,python2-pandas)
1960 ("python-pysnptools" ,python2-pysnptools)))
1962 `(("python-setuptools" ,python2-setuptools)
1963 ("python-mock" ,python2-mock)
1964 ("python-nose" ,python2-nose)
1966 (home-page "https://github.com/PMBio/warpedLMM")
1967 (synopsis "Implementation of warped linear mixed models")
1969 "WarpedLMM is a Python implementation of the warped linear mixed model,
1970 which automatically learns an optimal warping function (or transformation) for
1971 the phenotype as it models the data.")
1972 (license license:asl2.0)))
1974 (define-public pbtranscript-tofu
1975 (let ((commit "8f5467fe6"))
1977 (name "pbtranscript-tofu")
1978 (version (string-append "2.2.3." commit))
1982 (url "https://github.com/PacificBiosciences/cDNA_primer.git")
1984 (file-name (string-append name "-" version "-checkout"))
1987 "1lgnpi35ihay42qx0b6yl3kkgra723i413j33kvs0kvs61h82w0f"))
1988 (modules '((guix build utils)))
1991 ;; remove bundled Cython sources
1992 (delete-file "pbtranscript-tofu/pbtranscript/Cython-0.20.1.tar.gz")
1994 (build-system python-build-system)
1996 `(#:python ,python-2
1997 ;; With standard flags, the install phase attempts to create a zip'd
1998 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2000 #:configure-flags '("--single-version-externally-managed"
2001 "--record=pbtranscript-tofu.txt")
2003 (modify-phases %standard-phases
2004 (add-after 'unpack 'enter-directory
2006 (chdir "pbtranscript-tofu/pbtranscript/")
2008 ;; With setuptools version 18.0 and later this setup.py hack causes
2009 ;; a build error, so we disable it.
2010 (add-after 'enter-directory 'patch-setuppy
2012 (substitute* "setup.py"
2013 (("if 'setuptools.extension' in sys.modules:")
2017 `(("python-numpy" ,python2-numpy)
2018 ("python-bx-python" ,python2-bx-python)
2019 ("python-networkx" ,python2-networkx)
2020 ("python-scipy" ,python2-scipy)
2021 ("python-pbcore" ,python2-pbcore)
2022 ("python-h5py" ,python2-h5py)))
2024 `(("python-cython" ,python2-cython)
2025 ("python-nose" ,python2-nose)
2026 ("python-setuptools" ,python2-setuptools)))
2027 (home-page "https://github.com/PacificBiosciences/cDNA_primer")
2028 (synopsis "Analyze transcriptome data generated with the Iso-Seq protocol")
2030 "pbtranscript-tofu contains scripts to analyze transcriptome data
2031 generated using the PacBio Iso-Seq protocol.")
2032 (license license:bsd-3))))
2034 (define-public prodigal
2041 "https://github.com/hyattpd/Prodigal/archive/v"
2043 (file-name (string-append name "-" version ".tar.gz"))
2046 "0m8sb0fg6lmxrlpzna0am6svbnlmd3dckrhgzxxgb3gxr5fyj284"))))
2047 (build-system gnu-build-system)
2049 `(#:tests? #f ;no check target
2050 #:make-flags (list (string-append "INSTALLDIR="
2051 (assoc-ref %outputs "out")
2054 (modify-phases %standard-phases
2055 (delete 'configure))))
2056 (home-page "http://prodigal.ornl.gov")
2057 (synopsis "Protein-coding gene prediction for Archaea and Bacteria")
2059 "Prodigal runs smoothly on finished genomes, draft genomes, and
2060 metagenomes, providing gene predictions in GFF3, Genbank, or Sequin table
2061 format. It runs quickly, in an unsupervised fashion, handles gaps, handles
2062 partial genes, and identifies translation initiation sites.")
2063 (license license:gpl3+)))
2073 (string-append "http://deweylab.biostat.wisc.edu/rsem/src/rsem-"
2076 (base32 "0nzdc0j0hjllhsd5f2xli95dafm3nawskigs140xzvjk67xh0r9q"))
2077 (patches (list (search-patch "rsem-makefile.patch")))
2078 (modules '((guix build utils)))
2081 ;; remove bundled copy of boost
2082 (delete-file-recursively "boost")
2084 (build-system gnu-build-system)
2086 `(#:tests? #f ;no "check" target
2088 (modify-phases %standard-phases
2089 ;; No "configure" script.
2090 ;; Do not build bundled samtools library.
2093 (substitute* "Makefile"
2094 (("^all : sam/libbam.a") "all : "))
2097 (lambda* (#:key outputs #:allow-other-keys)
2098 (let* ((out (string-append (assoc-ref outputs "out")))
2099 (bin (string-append out "/bin/"))
2100 (perl (string-append out "/lib/perl5/site_perl")))
2103 (for-each (lambda (file)
2105 (string-append bin (basename file))))
2106 (find-files "." "rsem-.*"))
2107 (copy-file "rsem_perl_utils.pm"
2108 (string-append perl "/rsem_perl_utils.pm")))
2111 'install 'wrap-program
2112 (lambda* (#:key outputs #:allow-other-keys)
2113 (let ((out (assoc-ref outputs "out")))
2114 (for-each (lambda (prog)
2115 (wrap-program (string-append out "/bin/" prog)
2116 `("PERL5LIB" ":" prefix
2117 (,(string-append out "/lib/perl5/site_perl")))))
2118 '("rsem-plot-transcript-wiggles"
2119 "rsem-calculate-expression"
2120 "rsem-generate-ngvector"
2122 "rsem-prepare-reference")))
2126 ("ncurses" ,ncurses)
2129 ("samtools" ,samtools-0.1)
2131 (home-page "http://deweylab.biostat.wisc.edu/rsem/")
2132 (synopsis "Estimate gene expression levels from RNA-Seq data")
2134 "RSEM is a software package for estimating gene and isoform expression
2135 levels from RNA-Seq data. The RSEM package provides a user-friendly
2136 interface, supports threads for parallel computation of the EM algorithm,
2137 single-end and paired-end read data, quality scores, variable-length reads and
2138 RSPD estimation. In addition, it provides posterior mean and 95% credibility
2139 interval estimates for expression levels. For visualization, it can generate
2140 BAM and Wiggle files in both transcript-coordinate and genomic-coordinate.")
2141 (license license:gpl3+)))
2143 (define-public rseqc
2151 (string-append "mirror://sourceforge/rseqc/"
2152 version "/RSeQC-" version ".tar.gz"))
2154 (base32 "15ly0254yi032qzkdplg00q144qfdsd986gh62829rl5bkxhj330"))
2155 (modules '((guix build utils)))
2158 ;; remove bundled copy of pysam
2159 (delete-file-recursively "lib/pysam")
2160 (substitute* "setup.py"
2161 ;; remove dependency on outdated "distribute" module
2162 (("^from distribute_setup import use_setuptools") "")
2163 (("^use_setuptools\\(\\)") "")
2164 ;; do not use bundled copy of pysam
2165 (("^have_pysam = False") "have_pysam = True"))))))
2166 (build-system python-build-system)
2167 (arguments `(#:python ,python-2))
2169 `(("python-cython" ,python2-cython)
2170 ("python-pysam" ,python2-pysam)
2171 ("python-numpy" ,python2-numpy)
2172 ("python-setuptools" ,python2-setuptools)
2175 `(("python-nose" ,python2-nose)))
2176 (home-page "http://rseqc.sourceforge.net/")
2177 (synopsis "RNA-seq quality control package")
2179 "RSeQC provides a number of modules that can comprehensively evaluate
2180 high throughput sequence data, especially RNA-seq data. Some basic modules
2181 inspect sequence quality, nucleotide composition bias, PCR bias and GC bias,
2182 while RNA-seq specific modules evaluate sequencing saturation, mapped reads
2183 distribution, coverage uniformity, strand specificity, etc.")
2184 (license license:gpl3+)))
2186 (define-public samtools
2194 (string-append "mirror://sourceforge/samtools/"
2195 version "/samtools-" version ".tar.bz2"))
2198 "1akdqb685pk9xk1nb6sa9aq8xssjjhvvc06kp4cpdqvz2157l3j2"))))
2199 (build-system gnu-build-system)
2201 `(;; There are 87 test failures when building on non-64-bit architectures
2202 ;; due to invalid test data. This has since been fixed upstream (see
2203 ;; <https://github.com/samtools/samtools/pull/307>), but as there has
2204 ;; not been a new release we disable the tests for all non-64-bit
2206 #:tests? ,(string=? (or (%current-system) (%current-target-system))
2208 #:modules ((ice-9 ftw)
2210 (guix build gnu-build-system)
2212 #:make-flags (list "LIBCURSES=-lncurses"
2213 (string-append "prefix=" (assoc-ref %outputs "out")))
2218 (lambda* (#:key inputs #:allow-other-keys)
2219 (let ((bash (assoc-ref inputs "bash")))
2220 (substitute* "test/test.pl"
2221 ;; The test script calls out to /bin/bash
2223 (string-append bash "/bin/bash"))
2224 ;; There are two failing tests upstream relating to the "stats"
2225 ;; subcommand in test_usage_subcommand ("did not have Usage"
2226 ;; and "usage did not mention samtools stats"), so we disable
2228 (("(test_usage_subcommand\\(.*\\);)" cmd)
2229 (string-append "unless ($subcommand eq 'stats') {" cmd "};")))))
2231 'install 'install-library
2232 (lambda* (#:key outputs #:allow-other-keys)
2233 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
2234 (install-file "libbam.a" lib)))
2236 'install 'install-headers
2237 (lambda* (#:key outputs #:allow-other-keys)
2238 (let ((include (string-append (assoc-ref outputs "out")
2239 "/include/samtools/")))
2240 (for-each (lambda (file)
2241 (install-file file include))
2242 (scandir "." (lambda (name) (string-match "\\.h$" name))))
2244 (alist-delete 'configure %standard-phases))))))
2245 (native-inputs `(("pkg-config" ,pkg-config)))
2246 (inputs `(("ncurses" ,ncurses)
2250 (home-page "http://samtools.sourceforge.net")
2251 (synopsis "Utilities to efficiently manipulate nucleotide sequence alignments")
2253 "Samtools implements various utilities for post-processing nucleotide
2254 sequence alignments in the SAM, BAM, and CRAM formats, including indexing,
2255 variant calling (in conjunction with bcftools), and a simple alignment
2257 (license license:expat)))
2259 (define-public samtools-0.1
2260 ;; This is the most recent version of the 0.1 line of samtools. The input
2261 ;; and output formats differ greatly from that used and produced by samtools
2262 ;; 1.x and is still used in many bioinformatics pipelines.
2263 (package (inherit samtools)
2269 (string-append "mirror://sourceforge/samtools/"
2270 version "/samtools-" version ".tar.bz2"))
2272 (base32 "1m33xsfwz0s8qi45lylagfllqg7fphf4dr0780rsvw75av9wk06h"))))
2274 (substitute-keyword-arguments (package-arguments samtools)
2275 ((#:tests? tests) #f) ;no "check" target
2277 `(modify-phases ,phases
2279 (lambda* (#:key outputs #:allow-other-keys)
2280 (let ((bin (string-append
2281 (assoc-ref outputs "out") "/bin")))
2283 (copy-file "samtools"
2284 (string-append bin "/samtools")))))
2285 (delete 'patch-tests)))))))
2287 (define-public mosaik
2288 (let ((commit "5c25216d"))
2293 ;; There are no release tarballs nor tags.
2296 (url "https://github.com/wanpinglee/MOSAIK.git")
2298 (file-name (string-append name "-" version))
2301 "17gj3s07cm77r41z92awh0bim7w7q7fbn0sf5nkqmcm1vw052qgw"))))
2302 (build-system gnu-build-system)
2304 `(#:tests? #f ; no tests
2305 #:make-flags (list "CC=gcc")
2307 (modify-phases %standard-phases
2309 (lambda _ (chdir "src") #t))
2311 (lambda* (#:key outputs #:allow-other-keys)
2312 (let ((bin (string-append (assoc-ref outputs "out")
2315 (copy-recursively "../bin" bin)
2320 (supported-systems '("x86_64-linux"))
2321 (home-page "https://code.google.com/p/mosaik-aligner/")
2322 (synopsis "Map nucleotide sequence reads to reference genomes")
2324 "MOSAIK is a program for mapping second and third-generation sequencing
2325 reads to a reference genome. MOSAIK can align reads generated by all the
2326 major sequencing technologies, including Illumina, Applied Biosystems SOLiD,
2327 Roche 454, Ion Torrent and Pacific BioSciences SMRT.")
2328 ;; MOSAIK is released under the GPLv2+ with the exception of third-party
2329 ;; code released into the public domain:
2330 ;; 1. fastlz by Ariya Hidayat - http://www.fastlz.org/
2331 ;; 2. MD5 implementation - RSA Data Security, RFC 1321
2332 (license (list license:gpl2+ license:public-domain)))))
2334 (define-public ngs-sdk
2342 (string-append "https://github.com/ncbi/ngs/archive/"
2344 (file-name (string-append name "-" version ".tar.gz"))
2347 "1x58gpm574n0xmk2a98gmikbgycq78ia0bvnb42k5ck34fmd5v8y"))))
2348 (build-system gnu-build-system)
2350 `(#:parallel-build? #f ; not supported
2351 #:tests? #f ; no "check" target
2355 (lambda* (#:key outputs #:allow-other-keys)
2356 (let ((out (assoc-ref outputs "out")))
2357 ;; The 'configure' script doesn't recognize things like
2358 ;; '--enable-fast-install'.
2359 (zero? (system* "./configure"
2360 (string-append "--build-prefix=" (getcwd) "/build")
2361 (string-append "--prefix=" out)))))
2364 (lambda _ (chdir "ngs-sdk") #t)
2365 %standard-phases))))
2366 (native-inputs `(("perl" ,perl)))
2367 ;; According to the test
2368 ;; unless ($MARCH =~ /x86_64/i || $MARCH =~ /i?86/i)
2369 ;; in ngs-sdk/setup/konfigure.perl
2370 (supported-systems '("i686-linux" "x86_64-linux"))
2371 (home-page "https://github.com/ncbi/ngs")
2372 (synopsis "API for accessing Next Generation Sequencing data")
2374 "NGS is a domain-specific API for accessing reads, alignments and pileups
2375 produced from Next Generation Sequencing. The API itself is independent from
2376 any particular back-end implementation, and supports use of multiple back-ends
2378 (license license:public-domain)))
2380 (define-public ngs-java
2381 (package (inherit ngs-sdk)
2384 `(,@(substitute-keyword-arguments
2385 `(#:modules ((guix build gnu-build-system)
2389 ,@(package-arguments ngs-sdk))
2392 'enter-dir 'fix-java-symlink-installation
2394 ;; Only replace the version suffix, not the version number in
2395 ;; the directory name. Reported here:
2396 ;; https://github.com/ncbi/ngs/pull/4
2397 (substitute* "Makefile.java"
2398 (((string-append "\\$\\(subst "
2399 "(\\$\\(VERSION[^\\)]*\\)),"
2400 "(\\$\\([^\\)]+\\)),"
2401 "(\\$\\([^\\)]+\\)|\\$\\@)"
2403 _ pattern replacement target)
2404 (string-append "$(patsubst "
2409 'enter-dir (lambda _ (chdir "ngs-java") #t)
2412 `(("jdk" ,icedtea6 "jdk")
2413 ("ngs-sdk" ,ngs-sdk)))
2414 (synopsis "Java bindings for NGS SDK")))
2416 (define-public ncbi-vdb
2424 (string-append "https://github.com/ncbi/ncbi-vdb/archive/"
2426 (file-name (string-append name "-" version ".tar.gz"))
2429 "1cj8nk6if8sqagv20vx36v566fdvhcaadf0x1ycnbgql6chbs6vy"))))
2430 (build-system gnu-build-system)
2432 `(#:parallel-build? #f ; not supported
2433 #:tests? #f ; no "check" target
2437 (lambda* (#:key inputs outputs #:allow-other-keys)
2438 (let ((out (assoc-ref outputs "out")))
2439 ;; Only replace the version suffix, not the version number in the
2440 ;; directory name; fixed in commit 4dbba5c6a809 (no release yet).
2441 (substitute* "setup/konfigure.perl"
2442 (((string-append "\\$\\(subst "
2443 "(\\$\\(VERSION[^\\)]*\\)),"
2444 "(\\$\\([^\\)]+\\)),"
2445 "(\\$\\([^\\)]+\\)|\\$\\@)"
2447 _ pattern replacement target)
2448 (string-append "$(patsubst "
2453 ;; Override include path for libmagic
2454 (substitute* "setup/package.prl"
2455 (("name => 'magic', Include => '/usr/include'")
2456 (string-append "name=> 'magic', Include => '"
2457 (assoc-ref inputs "libmagic")
2460 ;; Install kdf5 library (needed by sra-tools)
2461 (substitute* "build/Makefile.install"
2462 (("LIBRARIES_TO_INSTALL =")
2463 "LIBRARIES_TO_INSTALL = kdf5.$(VERSION_LIBX) kdf5.$(VERSION_SHLX)"))
2465 ;; The 'configure' script doesn't recognize things like
2466 ;; '--enable-fast-install'.
2469 (string-append "--build-prefix=" (getcwd) "/build")
2470 (string-append "--prefix=" (assoc-ref outputs "out"))
2471 (string-append "--debug")
2472 (string-append "--with-xml2-prefix="
2473 (assoc-ref inputs "libxml2"))
2474 (string-append "--with-ngs-sdk-prefix="
2475 (assoc-ref inputs "ngs-sdk"))
2476 (string-append "--with-ngs-java-prefix="
2477 (assoc-ref inputs "ngs-java"))
2478 (string-append "--with-hdf5-prefix="
2479 (assoc-ref inputs "hdf5"))))))
2481 'install 'install-interfaces
2482 (lambda* (#:key outputs #:allow-other-keys)
2483 ;; Install interface libraries. On i686 the interface libraries
2484 ;; are installed to "linux/gcc/i386", so we need to use the Linux
2485 ;; architecture name ("i386") instead of the target system prefix
2487 (mkdir (string-append (assoc-ref outputs "out") "/ilib"))
2488 (copy-recursively (string-append "build/ncbi-vdb/linux/gcc/"
2489 ,(system->linux-architecture
2490 (or (%current-target-system)
2493 (string-append (assoc-ref outputs "out")
2495 ;; Install interface headers
2496 (copy-recursively "interfaces"
2497 (string-append (assoc-ref outputs "out")
2499 %standard-phases))))
2501 `(("libxml2" ,libxml2)
2502 ("ngs-sdk" ,ngs-sdk)
2503 ("ngs-java" ,ngs-java)
2506 (native-inputs `(("perl" ,perl)))
2507 (home-page "https://github.com/ncbi/ncbi-vdb")
2508 (synopsis "Database engine for genetic information")
2510 "The NCBI-VDB library implements a highly compressed columnar data
2511 warehousing engine that is most often used to store genetic information.
2512 Databases are stored in a portable image within the file system, and can be
2513 accessed/downloaded on demand across HTTP.")
2514 (license license:public-domain)))
2516 (define-public plink
2524 "http://pngu.mgh.harvard.edu/~purcell/plink/dist/plink-"
2525 version "-src.zip"))
2527 (base32 "0as8gxm4pjyc8dxmm1sl873rrd7wn5qs0l29nqfnl31x8i467xaa"))
2528 (patches (list (search-patch "plink-1.07-unclobber-i.patch")))))
2529 (build-system gnu-build-system)
2531 '(#:tests? #f ;no "check" target
2532 #:make-flags (list (string-append "LIB_LAPACK="
2533 (assoc-ref %build-inputs "lapack")
2534 "/lib/liblapack.so")
2537 ;; disable phoning home
2540 (modify-phases %standard-phases
2541 ;; no "configure" script
2544 (lambda* (#:key outputs #:allow-other-keys)
2545 (let ((bin (string-append (assoc-ref outputs "out")
2547 (install-file "plink" bin)
2551 ("lapack" ,lapack)))
2553 `(("unzip" ,unzip)))
2554 (home-page "http://pngu.mgh.harvard.edu/~purcell/plink/")
2555 (synopsis "Whole genome association analysis toolset")
2557 "PLINK is a whole genome association analysis toolset, designed to
2558 perform a range of basic, large-scale analyses in a computationally efficient
2559 manner. The focus of PLINK is purely on analysis of genotype/phenotype data,
2560 so there is no support for steps prior to this (e.g. study design and
2561 planning, generating genotype or CNV calls from raw data). Through
2562 integration with gPLINK and Haploview, there is some support for the
2563 subsequent visualization, annotation and storage of results.")
2564 ;; Code is released under GPLv2, except for fisher.h, which is under
2566 (license (list license:gpl2 license:lgpl2.1+))))
2568 (define-public preseq
2575 (string-append "http://smithlabresearch.org/downloads/preseq-"
2576 version ".tar.bz2"))
2578 (base32 "0r7sw07p6nv8ygvc17gd78lisbw5336v3vhs86b5wv8mw3pwqksc"))
2579 (patches (list (search-patch "preseq-1.0.2-install-to-PREFIX.patch")
2580 (search-patch "preseq-1.0.2-link-with-libbam.patch")))
2581 (modules '((guix build utils)))
2583 ;; Remove bundled samtools.
2584 '(delete-file-recursively "preseq-master/samtools"))))
2585 (build-system gnu-build-system)
2587 `(#:tests? #f ;no "check" target
2589 (modify-phases %standard-phases
2593 (chdir "preseq-master")
2596 'enter-dir 'use-samtools-headers
2598 (substitute* '("smithlab_cpp/SAM.cpp"
2599 "smithlab_cpp/SAM.hpp")
2600 (("sam.h") "samtools/sam.h"))
2602 (delete 'configure))
2603 #:make-flags (list (string-append "PREFIX="
2604 (assoc-ref %outputs "out"))
2605 (string-append "LIBBAM="
2606 (assoc-ref %build-inputs "samtools")
2610 ("samtools" ,samtools-0.1)
2612 (home-page "http://smithlabresearch.org/software/preseq/")
2613 (synopsis "Program for analyzing library complexity")
2615 "The preseq package is aimed at predicting and estimating the complexity
2616 of a genomic sequencing library, equivalent to predicting and estimating the
2617 number of redundant reads from a given sequencing depth and how many will be
2618 expected from additional sequencing using an initial sequencing experiment.
2619 The estimates can then be used to examine the utility of further sequencing,
2620 optimize the sequencing depth, or to screen multiple libraries to avoid low
2621 complexity samples.")
2622 (license license:gpl3+)))
2624 (define-public sra-tools
2632 (string-append "https://github.com/ncbi/sra-tools/archive/"
2634 (file-name (string-append name "-" version ".tar.gz"))
2637 "11nrnvz7a012f4iryf0wiwrid0h111grsfxbxa9j51h3f2xbvgns"))))
2638 (build-system gnu-build-system)
2640 `(#:parallel-build? #f ; not supported
2641 #:tests? #f ; no "check" target
2645 (lambda* (#:key inputs outputs #:allow-other-keys)
2646 ;; The build system expects a directory containing the sources and
2647 ;; raw build output of ncbi-vdb, including files that are not
2648 ;; installed. Since we are building against an installed version of
2649 ;; ncbi-vdb, the following modifications are needed.
2650 (substitute* "setup/konfigure.perl"
2651 ;; Make the configure script look for the "ilib" directory of
2652 ;; "ncbi-vdb" without first checking for the existence of a
2653 ;; matching library in its "lib" directory.
2654 (("^ my \\$f = File::Spec->catdir\\(\\$libdir, \\$lib\\);")
2655 "my $f = File::Spec->catdir($ilibdir, $ilib);")
2656 ;; Look for interface libraries in ncbi-vdb's "ilib" directory.
2657 (("my \\$ilibdir = File::Spec->catdir\\(\\$builddir, 'ilib'\\);")
2658 "my $ilibdir = File::Spec->catdir($dir, 'ilib');"))
2660 ;; The 'configure' script doesn't recognize things like
2661 ;; '--enable-fast-install'.
2664 (string-append "--build-prefix=" (getcwd) "/build")
2665 (string-append "--prefix=" (assoc-ref outputs "out"))
2666 (string-append "--debug")
2667 (string-append "--with-fuse-prefix="
2668 (assoc-ref inputs "fuse"))
2669 (string-append "--with-magic-prefix="
2670 (assoc-ref inputs "libmagic"))
2671 ;; TODO: building with libxml2 fails with linker errors
2672 ;; (string-append "--with-xml2-prefix="
2673 ;; (assoc-ref inputs "libxml2"))
2674 (string-append "--with-ncbi-vdb-sources="
2675 (assoc-ref inputs "ncbi-vdb"))
2676 (string-append "--with-ncbi-vdb-build="
2677 (assoc-ref inputs "ncbi-vdb"))
2678 (string-append "--with-ngs-sdk-prefix="
2679 (assoc-ref inputs "ngs-sdk"))
2680 (string-append "--with-hdf5-prefix="
2681 (assoc-ref inputs "hdf5")))))
2683 (native-inputs `(("perl" ,perl)))
2685 `(("ngs-sdk" ,ngs-sdk)
2686 ("ncbi-vdb" ,ncbi-vdb)
2691 (home-page "http://www.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=software")
2692 (synopsis "Tools and libraries for reading and writing sequencing data")
2694 "The SRA Toolkit from NCBI is a collection of tools and libraries for
2695 reading of sequencing files from the Sequence Read Archive (SRA) database and
2696 writing files into the .sra format.")
2697 (license license:public-domain)))
2699 (define-public seqan
2705 (uri (string-append "http://packages.seqan.de/seqan-library/"
2706 "seqan-library-" version ".tar.bz2"))
2709 "05s3wrrwn50f81aklfm65i4a749zag1vr8z03k21xm0pdxy47yvp"))))
2710 ;; The documentation is 7.8MB and the includes are 3.6MB heavy, so it
2711 ;; makes sense to split the outputs.
2712 (outputs '("out" "doc"))
2713 (build-system trivial-build-system)
2715 `(#:modules ((guix build utils))
2718 (use-modules (guix build utils))
2719 (let ((tar (assoc-ref %build-inputs "tar"))
2720 (bzip (assoc-ref %build-inputs "bzip2"))
2721 (out (assoc-ref %outputs "out"))
2722 (doc (assoc-ref %outputs "doc")))
2723 (setenv "PATH" (string-append tar "/bin:" bzip "/bin"))
2724 (system* "tar" "xvf" (assoc-ref %build-inputs "source"))
2725 (chdir (string-append "seqan-library-" ,version))
2726 (copy-recursively "include" (string-append out "/include"))
2727 (copy-recursively "share" (string-append doc "/share"))))))
2729 `(("source" ,source)
2732 (home-page "http://www.seqan.de")
2733 (synopsis "Library for nucleotide sequence analysis")
2735 "SeqAn is a C++ library of efficient algorithms and data structures for
2736 the analysis of sequences with the focus on biological data. It contains
2737 algorithms and data structures for string representation and their
2738 manipulation, online and indexed string search, efficient I/O of
2739 bioinformatics file formats, sequence alignment, and more.")
2740 (license license:bsd-3)))
2742 (define-public seqmagick
2750 "https://pypi.python.org/packages/source/s/seqmagick/seqmagick-"
2754 "0cgn477n74gsl4qdaakrrhi953kcsd4q3ivk2lr18x74s3g4ma1d"))))
2755 (build-system python-build-system)
2757 ;; python2 only, see https://github.com/fhcrc/seqmagick/issues/56
2758 `(#:python ,python-2
2760 (modify-phases %standard-phases
2761 ;; Current test in setup.py does not work as of 0.6.1,
2762 ;; so use nose to run tests instead for now. See
2763 ;; https://github.com/fhcrc/seqmagick/issues/55
2764 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
2766 `(("python-biopython" ,python2-biopython)))
2768 `(("python-setuptools" ,python2-setuptools)
2769 ("python-nose" ,python2-nose)))
2770 (home-page "http://github.com/fhcrc/seqmagick")
2771 (synopsis "Tools for converting and modifying sequence files")
2773 "Bioinformaticians often have to convert sequence files between formats
2774 and do little manipulations on them, and it's not worth writing scripts for
2775 that. Seqmagick is a utility to expose the file format conversion in
2776 BioPython in a convenient way. Instead of having a big mess of scripts, there
2777 is one that takes arguments.")
2778 (license license:gpl3)))
2787 "https://github.com/alexdobin/STAR/archive/STAR_"
2791 "1c3rnm7r5l0kl3d04gl1g7938xqf1c2l0mla87rlplqg1hcns5mc"))
2792 (modules '((guix build utils)))
2794 '(substitute* "source/Makefile"
2795 (("/bin/rm") "rm")))))
2796 (build-system gnu-build-system)
2798 '(#:tests? #f ;no check target
2799 #:make-flags '("STAR")
2802 'unpack 'enter-source-dir (lambda _ (chdir "source"))
2805 (lambda* (#:key outputs #:allow-other-keys)
2806 (let ((bin (string-append (assoc-ref outputs "out") "/bin/")))
2807 (install-file "STAR" bin)))
2809 'configure %standard-phases)))))
2811 `(("vim" ,vim))) ; for xxd
2814 (home-page "https://github.com/alexdobin/STAR")
2815 (synopsis "Universal RNA-seq aligner")
2817 "The Spliced Transcripts Alignment to a Reference (STAR) software is
2818 based on a previously undescribed RNA-seq alignment algorithm that uses
2819 sequential maximum mappable seed search in uncompressed suffix arrays followed
2820 by seed clustering and stitching procedure. In addition to unbiased de novo
2821 detection of canonical junctions, STAR can discover non-canonical splices and
2822 chimeric (fusion) transcripts, and is also capable of mapping full-length RNA
2824 ;; STAR is licensed under GPLv3 or later; htslib is MIT-licensed.
2825 (license license:gpl3+)))
2827 (define-public subread
2830 (version "1.4.6-p2")
2834 "mirror://sourceforge/subread/subread-"
2835 version "-source.tar.gz"))
2838 "06sv9mpcsdj6p68y15d6gi70lca3lxmzk0dn61hg0kfsa7rxmsr3"))))
2839 (build-system gnu-build-system)
2841 `(#:tests? #f ;no "check" target
2842 ;; The CC and CCFLAGS variables are set to contain a lot of x86_64
2843 ;; optimizations by default, so we override these flags such that x86_64
2844 ;; flags are only added when the build target is an x86_64 system.
2846 (list (let ((system ,(or (%current-target-system)
2848 (flags '("-ggdb" "-fomit-frame-pointer"
2849 "-ffast-math" "-funroll-loops"
2850 "-fmessage-length=0"
2851 "-O9" "-Wall" "-DMAKE_FOR_EXON"
2853 "-DSUBREAD_VERSION=\\\"${SUBREAD_VERSION}\\\""))
2854 (flags64 '("-mmmx" "-msse" "-msse2" "-msse3")))
2855 (if (string-prefix? "x86_64" system)
2856 (string-append "CCFLAGS=" (string-join (append flags flags64)))
2857 (string-append "CCFLAGS=" (string-join flags))))
2858 "-f" "Makefile.Linux"
2859 "CC=gcc ${CCFLAGS}")
2863 (lambda _ (chdir "src") #t)
2866 (lambda* (#:key outputs #:allow-other-keys)
2867 (let ((bin (string-append (assoc-ref outputs "out") "/bin/")))
2869 (copy-recursively "../bin" bin)))
2870 ;; no "configure" script
2871 (alist-delete 'configure %standard-phases)))))
2872 (inputs `(("zlib" ,zlib)))
2873 (home-page "http://bioinf.wehi.edu.au/subread-package/")
2874 (synopsis "Tool kit for processing next-gen sequencing data")
2876 "The subread package contains the following tools: subread aligner, a
2877 general-purpose read aligner; subjunc aligner: detecting exon-exon junctions
2878 and mapping RNA-seq reads; featureCounts: counting mapped reads for genomic
2879 features; exactSNP: a SNP caller that discovers SNPs by testing signals
2880 against local background noises.")
2881 (license license:gpl3+)))
2883 (define-public vcftools
2890 "mirror://sourceforge/vcftools/vcftools_"
2894 "148al9h7f8g8my2qdnpax51kdd2yjrivlx6frvakf4lz5r8j88wx"))))
2895 (build-system gnu-build-system)
2897 `(#:tests? #f ; no "check" target
2899 "CFLAGS=-O2" ; override "-m64" flag
2900 (string-append "PREFIX=" (assoc-ref %outputs "out"))
2901 (string-append "MANDIR=" (assoc-ref %outputs "out")
2905 'unpack 'patch-manpage-install
2907 (substitute* "Makefile"
2908 (("cp \\$\\{PREFIX\\}/cpp/vcftools.1") "cp ./cpp/vcftools.1")))
2909 (alist-delete 'configure %standard-phases))))
2913 (home-page "http://vcftools.sourceforge.net/")
2914 (synopsis "Tools for working with VCF files")
2916 "VCFtools is a program package designed for working with VCF files, such
2917 as those generated by the 1000 Genomes Project. The aim of VCFtools is to
2918 provide easily accessible methods for working with complex genetic variation
2919 data in the form of VCF files.")
2920 ;; The license is declared as LGPLv3 in the README and
2921 ;; at http://vcftools.sourceforge.net/license.html
2922 (license license:lgpl3)))
2924 (define-public vsearch
2932 "https://github.com/torognes/vsearch/archive/v"
2934 (file-name (string-append name "-" version ".tar.gz"))
2937 "0b1359wbzgb2cm04h7dq05v80vik88hnsv298xxd1q1f2q4ydni7"))
2938 (modules '((guix build utils)))
2941 ;; Remove bundled cityhash and '-mtune=native'.
2942 (substitute* "src/Makefile.am"
2943 (("^AM_CXXFLAGS=-I\\$\\{srcdir\\}/cityhash \
2944 -O3 -mtune=native -Wall -Wsign-compare")
2945 (string-append "AM_CXXFLAGS=-lcityhash"
2946 " -O3 -Wall -Wsign-compare"))
2947 (("^__top_builddir__bin_vsearch_SOURCES = cityhash/city.h \\\\")
2948 "__top_builddir__bin_vsearch_SOURCES = \\")
2949 (("^cityhash/config.h \\\\") "\\")
2950 (("^cityhash/city.cc \\\\") "\\"))
2951 (substitute* "src/vsearch.h"
2952 (("^\\#include \"cityhash/city.h\"")
2953 "#include <city.h>"))
2954 (delete-file-recursively "src/cityhash")
2956 (build-system gnu-build-system)
2959 (modify-phases %standard-phases
2960 (add-before 'configure 'autogen
2961 (lambda _ (zero? (system* "autoreconf" "-vif")))))))
2965 ("cityhash" ,cityhash)))
2967 `(("autoconf" ,autoconf)
2968 ("automake" ,automake)))
2969 (synopsis "Sequence search tools for metagenomics")
2971 "VSEARCH supports DNA sequence searching, clustering, chimera detection,
2972 dereplication, pairwise alignment, shuffling, subsampling, sorting and
2973 masking. The tool takes advantage of parallelism in the form of SIMD
2974 vectorization as well as multiple threads to perform accurate alignments at
2975 high speed. VSEARCH uses an optimal global aligner (full dynamic programming
2976 Needleman-Wunsch).")
2977 (home-page "https://github.com/torognes/vsearch")
2978 ;; vsearch uses non-portable SSE intrinsics so building fails on other
2980 (supported-systems '("x86_64-linux"))
2981 ;; Dual licensed; also includes public domain source.
2982 (license (list license:gpl3 license:bsd-2))))
2984 (define-public bio-locus
2991 (uri (rubygems-uri "bio-locus" version))
2994 "02vmrxyimkj9sahsp4zhfhnmbvz6dbbqz1y01vglf8cbwvkajfl0"))))
2995 (build-system ruby-build-system)
2997 `(("ruby-rspec" ,ruby-rspec)))
2998 (synopsis "Tool for fast querying of genome locations")
3000 "Bio-locus is a tabix-like tool for fast querying of genome
3001 locations. Many file formats in bioinformatics contain records that
3002 start with a chromosome name and a position for a SNP, or a start-end
3003 position for indels. Bio-locus allows users to store this chr+pos or
3004 chr+pos+alt information in a database.")
3005 (home-page "https://github.com/pjotrp/bio-locus")
3006 (license license:expat)))
3008 (define-public bio-blastxmlparser
3010 (name "bio-blastxmlparser")
3014 (uri (rubygems-uri "bio-blastxmlparser" version))
3017 "1wf4qygcmdjgcqm6flmvsagfr1gs9lf63mj32qv3z1f481zc5692"))))
3018 (build-system ruby-build-system)
3020 `(("ruby-bio-logger" ,ruby-bio-logger)
3021 ("ruby-nokogiri" ,ruby-nokogiri)))
3023 `(("ruby-rspec" ,ruby-rspec)))
3024 (synopsis "Fast big data BLAST XML parser and library")
3026 "Very fast parallel big-data BLAST XML file parser which can be used as
3027 command line utility. Use blastxmlparser to: Parse BLAST XML; filter output;
3028 generate FASTA, JSON, YAML, RDF, JSON-LD, HTML, CSV, tabular output etc.")
3029 (home-page "http://github.com/pjotrp/blastxmlparser")
3030 (license license:expat)))
3032 (define-public bioruby
3039 (uri (rubygems-uri "bio" version))
3042 "01k2fyjl5fpx4zn8g6gqiqvsg2j1fgixrs9p03vzxckynxdq3wmc"))))
3043 (build-system ruby-build-system)
3045 `(("ruby-libxml" ,ruby-libxml)))
3047 `(("which" ,which))) ; required for test phase
3050 (modify-phases %standard-phases
3051 (add-before 'build 'patch-test-command
3053 (substitute* '("test/functional/bio/test_command.rb")
3054 (("/bin/sh") (which "sh")))
3055 (substitute* '("test/functional/bio/test_command.rb")
3056 (("/bin/ls") (which "ls")))
3057 (substitute* '("test/functional/bio/test_command.rb")
3058 (("which") (which "which")))
3059 (substitute* '("test/functional/bio/test_command.rb",
3060 "test/data/command/echoarg2.sh")
3061 (("/bin/echo") (which "echo")))
3063 (synopsis "Ruby library, shell and utilities for bioinformatics")
3064 (description "BioRuby comes with a comprehensive set of Ruby development
3065 tools and libraries for bioinformatics and molecular biology. BioRuby has
3066 components for sequence analysis, pathway analysis, protein modelling and
3067 phylogenetic analysis; it supports many widely used data formats and provides
3068 easy access to databases, external programs and public web services, including
3069 BLAST, KEGG, GenBank, MEDLINE and GO.")
3070 (home-page "http://bioruby.org/")
3071 ;; Code is released under Ruby license, except for setup
3072 ;; (LGPLv2.1+) and scripts in samples (which have GPL2 and GPL2+)
3073 (license (list license:ruby license:lgpl2.1+ license:gpl2+ ))))
3075 (define-public r-qtl
3082 (uri (string-append "mirror://cran/src/contrib/qtl_"
3086 "0h20d36mww7ljp51pfs66xq33yq4b4fwq9nsh02dpmfhlaxgx1xi"))))
3087 (build-system r-build-system)
3088 (home-page "http://rqtl.org/")
3089 (synopsis "R package for analyzing QTL experiments in genetics")
3090 (description "R/qtl is an extension library for the R statistics
3091 system. It is used to analyze experimental crosses for identifying
3092 genes contributing to variation in quantitative traits (so-called
3093 quantitative trait loci, QTLs).
3095 Using a hidden Markov model, R/qtl allows to estimate genetic maps, to
3096 identify genotyping errors, and to perform single-QTL and two-QTL,
3097 two-dimensional genome scans.")
3098 (license license:gpl3)))