annotate launcher.R @ 1:4e73ea176c34 draft default tip

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
author iuc
date Sun, 18 Jul 2021 18:03:12 +0000
parents 067d45e6caa9
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
1 #!/usr/bin/env Rscript
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
2
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
3 # Author: Etienne CAMENEN
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
4 # Date: 2021
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
5 # Contact: etienne.camenen@gmail.com
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
6 # Key-words: omics, RGCCA, multi-block
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
7 # EDAM operation: analysis, correlation, visualisation
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
8 #
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
9 # Abstract: Performs multi-variate analysis (PCA, CCA, PLS, R/SGCCA, etc.)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
10 # and produces textual and graphical outputs (e.g. variables and individuals
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
11 # plots).
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
12
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
13 rm(list = ls())
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
14 graphics.off()
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
15 separator <- NULL
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
16
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
17 ########## Arguments ##########
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
18
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
19 # Parse the arguments from a command line launch
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
20 get_args <- function() {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
21 option_list <- list(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
22 # File parameters
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
23 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
24 opt_str = c("-d", "--datasets"),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
25 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
26 metavar = "path list",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
27 help = "List of comma-separated file paths corresponding to the
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
28 blocks to be analyzed (one per block and without spaces between
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
29 them; e.g., path/file1.txt,path/file2.txt) [required]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
30 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
31 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
32 opt_str = c("-c", "--connection"),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
33 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
34 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
35 help = "Path of the file defining the connections between the blocks
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
36 [if not used, activates the superblock mode]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
37 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
38 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
39 opt_str = "--group",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
40 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
41 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
42 help = "Path of the file coloring the individuals in the ad hoc
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
43 plot"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
44 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
45 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
46 opt_str = c("-r", "--response"),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
47 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
48 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
49 help = "Position of the response file for the supervised mode within
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
50 the block path list [actives the supervised mode]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
51 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
52 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
53 opt_str = "--names",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
54 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
55 metavar = "character list",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
56 help = "List of comma-separated block names to rename them (one per
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
57 block; without spaces between them) [default: the block file names]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
58 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
59 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
60 opt_str = c("-H", "--header"),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
61 type = "logical",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
62 action = "store_false",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
63 help = "DO NOT consider the first row as the column header"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
64 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
65 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
66 opt_str = "--separator",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
67 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
68 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
69 default = opt[1],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
70 help = "Character used to separate columns (1: tabulation,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
71 2: semicolon, 3: comma) [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
72 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
73 # Analysis parameter
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
74 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
75 opt_str = "--type",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
76 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
77 metavar = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
78 default = opt[2],
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
79 help = "Type of analysis [default: %default] (among: rgcca, sgcca,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
80 pca, spca, pls, spls, cca, ifa, ra, gcca, maxvar, maxvar-b,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
81 maxvar-a, mcoa,cpca-1, cpca-2, cpca-4, hpca, maxbet-b, maxbet,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
82 maxdiff-b, maxdiff, maxvar-a, sabscor, ssqcor, ssqcov-1, ssqcov-2,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
83 ssqcov, sumcor, sumcov-1, sumcov-2, sumcov, sabscov, sabscov-1,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
84 sabscov-2)"
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
85 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
86 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
87 opt_str = "--ncomp",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
88 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
89 metavar = "integer list",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
90 default = opt[3],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
91 help = "Number of components in the analysis for each block
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
92 [default: %default]. The number should be higher than 1 and lower
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
93 than the minimum number of variables among the blocks. It can be a
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
94 single values or a comma-separated list (e.g 2,2,3,2)."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
95 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
96 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
97 opt_str = "--penalty",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
98 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
99 metavar = "float list",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
100 default = opt[4],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
101 help = "For RGCCA, a regularization parameter for each block (i.e., tau)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
102 [default: %default]. Tau varies from 0 (maximizing the correlation)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
103 to 1 (maximizing the covariance). For SGCCA, tau is automatically
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
104 set to 1 and shrinkage parameter can be defined instead for
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
105 automatic variable selection, varying from the square root of the
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
106 variable number (the fewest selected variables) to 1 (all the
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
107 variables are included). It can be a single value or a
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
108 comma-separated list (e.g. 0,1,0.75,1)."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
109 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
110 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
111 opt_str = "--scheme",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
112 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
113 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
114 default = opt[5],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
115 help = "Link (i.e. scheme) function for covariance maximization
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
116 (1: x, 2: x^2, 3: |x|, 4: x^4) [default: %default]. Onnly, the x
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
117 function ('horst scheme') penalizes structural negative correlation.
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
118 The x^2 function ('factorial scheme') discriminates more strongly
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
119 the blocks than the |x| ('centroid scheme') one."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
120 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
121 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
122 opt_str = "--scale",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
123 type = "logical",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
124 action = "store_false",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
125 help = "DO NOT scale the blocks (i.e., a data centering step is
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
126 always performed). Otherwise, each block is normalised and divided
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
127 by the squareroot of its number of variables."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
128 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
129 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
130 opt_str = "--superblock",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
131 type = "logical",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
132 action = "store_false",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
133 help = "DO NOT use a superblock (i.e. a concatenation of all the
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
134 blocks to visualize them all together in a consensus space). In
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
135 this case, all blocks are assumed to be connected or a connection
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
136 file could be used."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
137 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
138 # Graphical parameters
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
139 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
140 opt_str = "--text",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
141 type = "logical",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
142 action = "store_false",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
143 help = "DO NOT display the name of the points instead of shapes when
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
144 plotting"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
145 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
146 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
147 opt_str = "--block",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
148 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
149 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
150 default = opt[6],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
151 help = "Position in the path list of the plotted block (0: the
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
152 superblock or, if not activated, the last one, 1: the fist one,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
153 2: the 2nd, etc.)[default: the last one]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
154 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
155 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
156 opt_str = "--block_y",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
157 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
158 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
159 help = "Position in the path list of the plotted block for the
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
160 Y-axis in the individual plot (0: the superblock or, if not
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
161 activated, the last one, 1: the fist one, 2: the 2nd, etc.)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
162 [default: the last one]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
163 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
164 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
165 opt_str = "--compx",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
166 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
167 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
168 default = opt[7],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
169 help = "Component used in the X-axis for biplots and the only
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
170 component used for histograms [default: %default] (should not be
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
171 higher than the number of components of the analysis)"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
172 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
173 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
174 opt_str = "--compy",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
175 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
176 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
177 default = opt[8],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
178 help = "Component used in the Y-axis for biplots
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
179 [default: %default] (should not be higher than the number of
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
180 components of the analysis)"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
181 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
182 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
183 opt_str = "--nmark",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
184 type = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
185 metavar = "integer",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
186 default = opt[9],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
187 help = "Number maximum of top variables in ad hoc plot
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
188 [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
189 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
190 # output parameters
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
191 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
192 opt_str = "--o1",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
193 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
194 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
195 default = opt[10],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
196 help = "Path for the individual plot [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
197 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
198 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
199 opt_str = "--o2",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
200 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
201 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
202 default = opt[11],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
203 help = "Path for the variable plot [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
204 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
205 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
206 opt_str = "--o3",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
207 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
208 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
209 default = opt[12],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
210 help = "Path for the top variables plot [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
211 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
212 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
213 opt_str = "--o4",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
214 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
215 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
216 default = opt[13],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
217 help = "Path for the explained variance plot [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
218 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
219 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
220 opt_str = "--o5",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
221 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
222 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
223 default = opt[14],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
224 help = "Path for the design plot [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
225 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
226 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
227 opt_str = "--o6",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
228 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
229 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
230 default = opt[15],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
231 help = "Path for the individual table [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
232 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
233 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
234 opt_str = "--o7",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
235 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
236 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
237 default = opt[16],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
238 help = "Path for the variable table [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
239 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
240 make_option(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
241 opt_str = "--o8",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
242 type = "character",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
243 metavar = "path",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
244 default = opt[17],
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
245 help = "Path for the analysis results in RData [default: %default]"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
246 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
247 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
248 return(optparse::OptionParser(option_list = option_list))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
249 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
250
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
251 check_arg <- function(opt) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
252 # Check the validity of the arguments opt : an optionParser object
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
253
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
254 if (is.null(opt$datasets))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
255 stop_rgcca(paste0("datasets is required."), exit_code = 121)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
256
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
257 if (is.null(opt$scheme))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
258 opt$scheme <- "factorial"
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
259 else if (!opt$scheme %in% seq(4)) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
260 stop_rgcca(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
261 paste0(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
262 "scheme should be comprise between 1 and 4 [by default: 2], not be equal to ",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
263 opt$scheme,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
264 "."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
265 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
266 exit_code = 122
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
267 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
268 } else {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
269 schemes <- c("horst", "factorial", "centroid")
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
270 if (opt$scheme == 4)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
271 opt$scheme <- function(x) x ^ 4
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
272 else
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
273 opt$scheme <- schemes[opt$scheme]
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
274 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
275
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
276 if (!opt$separator %in% seq(3)) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
277 stop_rgcca(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
278 paste0(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
279 "separator should be comprise between 1 and 3 (1: Tabulation, 2: Semicolon, 3: Comma) [by default: 2], not be equal to ",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
280 opt$separator,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
281 "."
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
282 ),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
283 exit_code = 123
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
284 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
285 } else {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
286 separators <- c("\t", ";", ",")
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
287 opt$separator <- separators[opt$separator]
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
288 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
289
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
290 nmark <- NULL
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
291 RGCCA:::check_integer("nmark", opt$nmark, min = 2)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
292
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
293 for (x in c("ncomp", "penalty"))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
294 opt[[x]] <- char_to_list(opt[[x]])
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
295
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
296 return(opt)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
297 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
298
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
299 post_check_arg <- function(opt, rgcca) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
300 # Check the validity of the arguments after loading the blocks opt : an
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
301 # optionParser object blocks : a list of matrix
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
302 blocks <- NULL
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
303 for (x in c("block", "block_y")) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
304 if (!is.null(opt[[x]])) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
305 if (opt[[x]] == 0)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
306 opt[[x]] <- length(rgcca$call$blocks)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
307 opt[[x]] <- RGCCA:::check_blockx(x, opt[[x]], rgcca$call$blocks)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
308 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
309 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
310
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
311 if (any(opt$ncomp == 1))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
312 opt$compy <- 1
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
313
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
314 for (x in c("compx", "compy"))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
315 opt[[x]] <- check_compx(x, opt[[x]], rgcca$call$ncomp, opt$block)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
316
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
317 return(opt)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
318 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
319
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
320 ########## Main ##########
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
321
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
322 # Get arguments : R packaging install, need an opt variable with associated
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
323 # arguments
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
324 opt <- list(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
325 separator = 1,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
326 type = "rgcca",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
327 ncomp = 2,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
328 penalty = 1,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
329 scheme = 2,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
330 block = 0,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
331 compx = 1,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
332 compy = 2,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
333 nmark = 100,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
334 o1 = "individuals.pdf",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
335 o2 = "corcircle.pdf",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
336 o3 = "top_variables.pdf",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
337 o4 = "ave.pdf",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
338 o5 = "design.pdf",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
339 o6 = "individuals.tsv",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
340 o7 = "variables.tsv",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
341 o8 = "rgcca_result.RData",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
342 datasets = paste0("inst/extdata/",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
343 c("agriculture", "industry", "politic"),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
344 ".tsv",
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
345 collapse = ",")
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
346 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
347
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
348 # Load functions
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
349 all_funcs <- unclass(lsf.str(envir = asNamespace("RGCCA"), all = TRUE))
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
350 for (i in all_funcs)
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
351 eval(parse(text = paste0(i, "<-RGCCA:::", i)))
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
352
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
353 load_libraries(c("ggplot2", "optparse", "scales", "igraph", "MASS", "Deriv"))
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
354 try(load_libraries("ggrepel"), silent = TRUE)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
355
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
356 tryCatch(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
357 opt <- check_arg(optparse::parse_args(get_args())),
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
358 error = function(e) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
359 if (length(grep("nextArg", e[[1]])) != 1)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
360 stop_rgcca(e[[1]], exit_code = 140)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
361 }, warning = function(w)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
362 stop_rgcca(w[[1]], exit_code = 141)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
363 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
364
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
365 # Set missing parameters by default
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
366 opt$header <- !("header" %in% names(opt))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
367 opt$superblock <- !("superblock" %in% names(opt))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
368 opt$scale <- !("scale" %in% names(opt))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
369 opt$text <- !("text" %in% names(opt))
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
370 cex_lab <- 20
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
371 cex_main <- 25
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
372 cex_point <- 3
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
373 cex_sub <- 20
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
374 cex_axis <- 10
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
375 cex <- 1.25
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
376
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
377 status <- 0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
378 tryCatch({
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
379
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
380 blocks <- load_blocks(opt$datasets, opt$names, opt$separator)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
381 group <- load_response(blocks, opt$group, opt$separator, opt$header)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
382 connection <- load_connection(file = opt$connection, separator = opt$separator)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
383
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
384 func <- quote(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
385 rgcca(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
386 blocks = blocks,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
387 connection = connection,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
388 response = opt$response,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
389 superblock = opt$superblock,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
390 ncomp = opt$ncomp,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
391 scheme = opt$scheme,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
392 scale = opt$scale,
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
393 method = opt$type
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
394 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
395 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
396 if (tolower(opt$type) %in% c("sgcca", "spca", "spls")) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
397 func[["sparsity"]] <- opt$penalty
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
398 }else {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
399 func[["tau"]] <- opt$penalty
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
400 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
401
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
402 rgcca_out <- eval(as.call(func))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
403
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
404 opt <- post_check_arg(opt, rgcca_out)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
405
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
406 ########## Plot ##########
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
407
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
408 if (rgcca_out$call$ncomp[opt$block] == 1 && is.null(opt$block_y)) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
409 warning("With a number of component of 1, a second block should be chosen to perform an individual plot")
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
410 } else {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
411 (
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
412 individual_plot <- plot_ind(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
413 rgcca_out,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
414 group,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
415 opt$compx,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
416 opt$compy,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
417 opt$block,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
418 opt$text,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
419 opt$block_y,
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
420 "Response",
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
421 cex_lab = cex_lab,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
422 cex_point = cex_point,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
423 cex_main = cex_main,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
424 cex = cex
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
425 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
426 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
427 save_plot(opt$o1, individual_plot)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
428 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
429
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
430 if (rgcca_out$call$ncomp[opt$block] > 1) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
431 (
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
432 corcircle <- plot_var_2D(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
433 rgcca_out,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
434 opt$compx,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
435 opt$compy,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
436 opt$block,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
437 opt$text,
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
438 n_mark = opt$nmark,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
439 cex_lab = cex_lab,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
440 cex_point = cex_point,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
441 cex_main = cex_main,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
442 cex = cex
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
443 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
444 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
445 save_plot(opt$o2, corcircle)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
446 }
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
447
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
448 top_variables <- plot_var_1D(
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
449 rgcca_out,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
450 opt$compx,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
451 opt$nmark,
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
452 opt$block,
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
453 type = "loadings",
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
454 title = paste0("Variable correlations", ": ", names(rgcca_out$call$blocks)[opt$block], " with "),
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
455 cex_sub = cex_sub,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
456 cex_main = cex_main,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
457 cex_axis = cex_axis,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
458 cex = cex
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
459 )
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
460 save_plot(opt$o3, top_variables)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
461
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
462 # Average Variance Explained
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
463 (ave <- plot_ave(
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
464 rgcca_out,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
465 cex_main = cex_main,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
466 cex_sub = cex_sub,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
467 cex_axis = cex_axis,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
468 cex = cex))
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
469 save_plot(opt$o4, ave)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
470
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
471 # Creates design scheme
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
472 design <- function() plot_network(
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
473 rgcca_out,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
474 cex_main = cex_main,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
475 cex_point = cex_point,
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
476 cex = cex)
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
477 save_plot(opt$o5, design)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
478
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
479 save_ind(rgcca_out, opt$o6)
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
480 save_var(rgcca_out, opt$o7)
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
481 save(rgcca_out, file = opt$o8)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
482
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
483 }, error = function(e) {
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
484 if (class(e)[1] %in% c("simpleError", "error", "condition"))
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
485 status <<- 1
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
486 else
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
487 status <<- class(e)[1]
1
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
488 msg <- "The design matrix C"
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
489 if (grepl(msg, e$message)) {
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
490 e$message <- gsub(msg, "The connection file", e$message)
4e73ea176c34 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit ce05b5eb018ae1c4d580ab5ce1a33896c1aa8c5b"
iuc
parents: 0
diff changeset
491 }
0
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
492 message(e$message)
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
493 })
067d45e6caa9 "planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rgcca commit 00f9e92845737e05a4afb1c93043f35b7e4ea771"
iuc
parents:
diff changeset
494 quit(status = status)