Mercurial > repos > ethevenot > transformation
annotate transformation_wrapper.R @ 0:eacea1349a7c draft
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
| author | ethevenot |
|---|---|
| date | Fri, 29 Jul 2016 12:11:01 -0400 |
| parents | |
| children | d9e05021553c |
| rev | line source |
|---|---|
|
0
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
1 #!/usr/bin/Rscript --vanilla --slave --no-site-file |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
2 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
3 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
4 library(batch) ## parseCommandArgs |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
5 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
6 source_local <- function(fname){ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
7 argv <- commandArgs(trailingOnly = FALSE) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
8 base_dir <- dirname(substring(argv[grep("--file=", argv)], 8)) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
9 source(paste(base_dir, fname, sep="/")) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
10 } |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
11 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
12 source_local("transformation_script.R") |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
13 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
14 argVc <- unlist(parseCommandArgs(evaluate=FALSE)) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
15 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
16 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
17 #### Start_of_tested_code <- function() {} |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
18 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
19 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
20 ##------------------------------ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
21 ## Initializing |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
22 ##------------------------------ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
23 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
24 ## options |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
25 ##-------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
26 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
27 strAsFacL <- options()[["stringsAsFactors"]] |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
28 options(stringsAsFactors=FALSE) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
29 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
30 ## constants |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
31 ##---------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
32 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
33 modNamC <- "Transformation" ## module name |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
34 metVc <- c("log2", "log10") ## available methods |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
35 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
36 topEnvC <- environment() |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
37 flagC <- "\n" |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
38 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
39 ## functions |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
40 ##---------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
41 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
42 flgF <- function(tesC, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
43 envC = topEnvC, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
44 txtC = NA) { ## management of warning and error messages |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
45 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
46 tesL <- eval(parse(text = tesC), envir = envC) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
47 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
48 if(!tesL) { |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
49 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
50 sink(NULL) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
51 stpTxtC <- ifelse(is.na(txtC), |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
52 paste0(tesC, " is FALSE"), |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
53 txtC) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
54 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
55 stop(stpTxtC, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
56 call. = FALSE) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
57 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
58 } |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
59 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
60 } ## flgF |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
61 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
62 ## log file |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
63 ##--------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
64 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
65 sink(argVc[["information"]]) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
66 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
67 cat("\nStart of the '", modNamC, "' module: ", |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
68 format(Sys.time(), "%a %d %b %Y %X"), "\n", sep="") |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
69 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
70 ## loading |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
71 ##-------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
72 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
73 datMN <- t(as.matrix(read.table(argVc[["dataMatrix_in"]], |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
74 check.names = FALSE, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
75 header = TRUE, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
76 row.names = 1, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
77 sep = "\t"))) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
78 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
79 metC <- argVc[["method"]] |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
80 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
81 ## checking |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
82 ##--------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
83 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
84 flgF("metC %in% metVc", txtC = paste0("Transformation method must be either '", paste(metVc, collapse = "', '"), "'")) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
85 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
86 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
87 ##------------------------------ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
88 ## Computation |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
89 ##------------------------------ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
90 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
91 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
92 datMN <- transformF(datMN = datMN, ## dataMatrix |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
93 metC = metC) ## transformation method |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
94 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
95 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
96 ##------------------------------ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
97 ## Ending |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
98 ##------------------------------ |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
99 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
100 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
101 ## saving |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
102 ##------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
103 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
104 datDF <- cbind.data.frame(dataMatrix = colnames(datMN), |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
105 as.data.frame(t(datMN))) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
106 write.table(datDF, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
107 file = argVc[["dataMatrix_out"]], |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
108 quote = FALSE, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
109 row.names = FALSE, |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
110 sep = "\t") |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
111 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
112 ## ending |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
113 ##------- |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
114 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
115 cat("\nEnd of the '", modNamC, "' Galaxy module call: ", |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
116 format(Sys.time(), "%a %d %b %Y %X"), "\n", sep = "") |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
117 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
118 sink() |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
119 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
120 options(stringsAsFactors = strAsFacL) |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
121 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
122 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
123 #### End_of_tested_code <- function() {} |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
124 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
125 |
|
eacea1349a7c
planemo upload for repository https://github.com/workflow4metabolomics/transformation.git commit 83f2d1045c0bf086bbe2de5204cd5c1d8354116f
ethevenot
parents:
diff
changeset
|
126 rm(list = ls()) |
