1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
|
(define-module (gn packages gemma)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix utils)
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module (guix build-system gnu)
#:use-module (guix build-system ruby)
#:use-module (guix build-system trivial)
#:use-module (gnu packages algebra)
#:use-module (gnu packages base)
#:use-module (gnu packages check)
#:use-module (gnu packages compression)
#:use-module (gnu packages dlang)
#:use-module (gnu packages gcc)
#:use-module (gnu packages gdb)
#:use-module (gnu packages linux)
#:use-module (gnu packages maths)
#:use-module (gnu packages parallel)
#:use-module (gnu packages perl)
#:use-module (gnu packages web)
#:use-module (gn packages shell)
#:use-module (srfi srfi-1))
;; See also the recent gemma.scm in the GEMMA repo!
(define-public gemma-gn2 ; guix candidate - currently uses generic
; openblas version and genenetwork github repo
(let ((commit "71553f5e5626e1d791b5be24c84ea6b17ae81cc7"))
(package
(name "gemma-gn2")
(version (string-append "0.98.5-" (string-take commit 7)))
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/genenetwork/GEMMA")
(commit commit)))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"11farc7smvkrrkvkbvh26i3sycdzwxrbgj536s3478v8j6iiwijp"))))
(inputs `(
("gsl" ,gsl)
("shunit2-old" ,shunit2-old)
("openblas" ,openblas)
("zlib" ,zlib)
))
(native-inputs ; for running tests
`(("perl" ,perl)
("which" ,which)
))
(build-system gnu-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(delete 'configure)
(add-before 'build 'bin-mkdir
(lambda _
(mkdir-p "bin")
))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(install-file "bin/gemma" (string-append out "/bin"))))))
; #:tests? #f
#:parallel-tests? #f))
(home-page "https://github.com/genetics-statistics/GEMMA")
(synopsis "Tool for genome-wide efficient mixed model association")
(description "Genome-wide Efficient Mixed Model Association (GEMMA)
provides a standard linear mixed model resolver with application in
genome-wide association studies (GWAS).")
(license license:gpl3))))
(define-public gemma-gn2-git ; typically use latest for genenetwork,
; may switch off tests and (maybe)
; openblas optimized
(package
(inherit gemma-gn2)
(name "gemma-gn2-git")
(inputs `(
("gsl" ,gsl)
("shunit2-old" ,shunit2-old)
("openblas" ,openblas)
("zlib" ,zlib)
))
(arguments
`(
#:phases
(modify-phases %standard-phases
(delete 'configure)
(add-before 'build 'bin-mkdir
(lambda _
(mkdir-p "bin")
))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(install-file "bin/gemma" (string-append out "/bin"))))))
; #:tests? #f
#:parallel-tests? #f))
))
(define-public gemma-wrapper
(package
(name "gemma-wrapper")
(version "0.99.4")
(source
(origin
(method url-fetch)
(uri (rubygems-uri "bio-gemma-wrapper" version))
(sha256
(base32
"0nhi7mb4fri0mhlh4m2z4657n7s3s1rsdpgshgib24zzld09d0yg"))))
(build-system ruby-build-system)
(inputs `(
("gemma-gn2" ,gemma-gn2)
("parallel" ,parallel) ;; gnu parallel
))
(arguments
`(#:tests? #f
#:phases
(modify-phases %standard-phases
(add-before
'build 'set-gemma-path
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(substitute* "bin/gemma-wrapper"
; (("gemma_command = ENV['GEMMA_COMMAND']")
(("gemma_command = ENV.*")
(string-append "gemma_command = '" (which "gemma") "'")))
))))))
(synopsis
"Gemma wrapper for LOCO and caching")
(description "Gemma wrapper")
(home-page "https://rubygems.org/gems/bio-gemma-wrapper")
(license license:gpl3)))
|