aboutsummaryrefslogtreecommitdiff
path: root/gn
diff options
context:
space:
mode:
Diffstat (limited to 'gn')
-rw-r--r--gn/data/dataset.scm11
-rw-r--r--gn/data/genotype.scm2
-rw-r--r--gn/runner/gemma.scm5
3 files changed, 10 insertions, 8 deletions
diff --git a/gn/data/dataset.scm b/gn/data/dataset.scm
index 3d96663..c28cf25 100644
--- a/gn/data/dataset.scm
+++ b/gn/data/dataset.scm
@@ -1,11 +1,9 @@
(define-module (gn data dataset)
- ;; #:use-module (json)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:use-module (ice-9 iconv)
#:use-module (ice-9 receive)
#:use-module (ice-9 string-fun)
- ;; #:use-module (gn db sparql)
#:use-module (dbi dbi)
#:use-module (gn db mysql)
#:use-module (gn data group)
@@ -16,8 +14,11 @@
dataset-name
))
-(define (dataset-name db probesetfreeze-id)
+(define (get-dataset db probesetfreeze-id)
(dbi-query db
(string-append
- "select Name2 from ProbeSetFreeze where Id=" (int-to-string probesetfreeze-id) " limit 1;"))
- (assoc-ref (get-row db) "Name2"))
+ "select Name,Name2,FullName from ProbeSetFreeze where Id=" (int-to-string probesetfreeze-id) " limit 1;"))
+ (get-row db))
+
+(define (dataset-name db probesetfreeze-id)
+ (assoc-ref (get-dataset db probesetfreeze-id) "Name"))
diff --git a/gn/data/genotype.scm b/gn/data/genotype.scm
index a12deee..c7cb63c 100644
--- a/gn/data/genotype.scm
+++ b/gn/data/genotype.scm
@@ -1,5 +1,5 @@
(define-module (gn data genotype)
- ;; #:use-module (json)
+ #:use-module (json)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:use-module (ice-9 iconv)
diff --git a/gn/runner/gemma.scm b/gn/runner/gemma.scm
index ff70f57..067800e 100644
--- a/gn/runner/gemma.scm
+++ b/gn/runner/gemma.scm
@@ -39,6 +39,7 @@
;; ---- to start GEMMA precompute inside container
;; env TMPDIR=. LD_LIBRARY_PATH=$GUIX_ENVIRONMENT/lib/ guile -L . -s ./scripts/precompute/precompute-hits.scm
- ;; --- First we compute K
- (system (string-append "env GEMMA_COMMAND=gemma /gemma-wrapper/bin/gemma-wrapper --verbose --loco --json --debug --parallel -- -gk -g BXD.8_geno.txt.gz -p pheno.txt -a BXD.8_snps.txt" ))
+ ;; --- First we compute K - control output goes to K.json
+ (system (string-append "env GEMMA_COMMAND=gemma /gemma-wrapper/bin/gemma-wrapper --name " name " --trait " trait-name " --verbose --loco --json --debug --parallel -- -gk -g BXD.8_geno.txt.gz -p pheno.txt -a BXD.8_snps.txt > K.json" ))
+ (system (string-append "env GEMMA_COMMAND=gemma /gemma-wrapper/bin/gemma-wrapper --name " name " --trait " trait-name " --verbose --loco --json --debug --parallel --input K.json -- -g BXD.8_geno.txt.gz -p pheno.txt -a BXD.8_snps.txt -lmm 2 -maf 0.1 > GWA.json"))
)