Mercurial > repos > ppericard > mixomics_blocksplsda
annotate Integration_block_splsda_fonc.R @ 3:0a3c83f2197a draft
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
author | ppericard |
---|---|
date | Fri, 25 Oct 2019 07:10:59 -0400 |
parents | |
children |
rev | line source |
---|---|
3
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1 # La fonction meanSpotRepl remplace les valeurs des spots répliqués par la |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2 # moyenne de leurs intensités. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
4 meanSpotRepl <-function(mat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
5 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
6 ProbeName = colnames(mat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
7 isDup = duplicated(ProbeName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
8 dupNames = ProbeName[isDup] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
9 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
10 for (dups in unique(dupNames)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
11 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
12 mat[dups,] = apply(mat[which(colnames(mat) == dups), ], 2, mean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
13 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
14 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
15 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
16 res = mat[, -which(isDup)] # On retire de la matrice mat toutes les spots qui sont répliqués. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
17 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
18 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
19 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
20 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
21 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
22 # La fonction supprimerVaConst supprime de la matrice mat les variables constantes. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
23 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
24 supprimerVaConst <-function(mat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
25 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
26 name_mat = deparse(substitute(mat)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
27 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
28 cat(paste0("Pour ", name_mat, ", avant suppression des variables constantes, il y a ", dim(mat)[2], " variables."), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
29 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
30 indiceVaConst = sapply(1:dim(mat)[2], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
31 col_mat_i = mat[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
32 res = all(col_mat_i == col_mat_i[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
33 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
34 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
35 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
36 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
37 if(length(which(indiceVaConst == FALSE)) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
38 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
39 res = mat[, which(indiceVaConst == FALSE)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
40 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
41 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
42 res = mat |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
43 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
44 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
45 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
46 cat(paste0("Pour ", name_mat, ", après suppression des variables constantes, il reste ", dim(res)[2], " variables."), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
47 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
48 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
49 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
50 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
51 # La fonction supprimerVaNaInd supprime les variables contenant des NA |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
52 # (si on garde les NA dans ces variables, les composantes du bloc ne |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
53 # sont plus orthogonales). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
54 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
55 supprimerVaNaInd <-function(mat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
56 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
57 indiceVaNaInd = sapply(1:dim(mat)[2], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
58 col_mat_i = mat[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
59 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
60 indNA = length(which(is.na(col_mat_i) == TRUE)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
61 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
62 if(indNA >= 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
63 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
64 res = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
65 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
66 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
67 res = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
68 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
69 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
70 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
71 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
72 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
73 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
74 mat2 = mat[, which(indiceVaNaInd == TRUE)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
75 name_mat = deparse(substitute(mat)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
76 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
77 cat(paste0("Pour ", name_mat, ", après suppression des variables contenant des NA, il reste ", dim(mat2)[2], " variables."), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
78 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
79 return(mat2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
80 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
81 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
82 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
83 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
84 # La fonction varAnnotation permet de fournir des informations sur les variables |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
85 # sélectionnées pour un design. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
86 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
87 varAnnotation <-function(variablesSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
88 data_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
89 annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
90 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
91 res_variablesSelect = variablesSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
92 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
93 noms_blocks = sapply(1:length(variablesSelect), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
94 ch = strsplit(names(variablesSelect)[i], split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
95 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
96 if(ch[1] == "resBio") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
97 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
98 res = "resBio" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
99 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
100 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
101 res = paste(ch[1:2], collapse = "_") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
102 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
103 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
104 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
105 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
106 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
107 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
108 ind_transcripto_col = which(noms_blocks == "transcripto_col") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
109 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
110 if(length(variablesSelect[[ind_transcripto_col]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
111 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
112 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
113 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
114 varSelect_transcripto_colTemp = variablesSelect[[ind_transcripto_col]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
115 varSelect_transcripto_col = sapply(1:length(varSelect_transcripto_colTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
116 ch = strsplit(varSelect_transcripto_colTemp[i], split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
117 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
118 res = paste(ch[2:length(ch)], collapse = "_") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
119 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
120 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
121 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
122 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
123 dataframe_varSelect_transcripto_col = data.frame(ProbeName = varSelect_transcripto_col) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
124 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
125 dataframe_annot_transcripto_col = data.frame(ProbeName = data_transcripto_col$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
126 GeneName = data_transcripto_col$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
127 Description = data_transcripto_col$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
128 SystematicName = data_transcripto_col$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
129 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
130 tab_transcripto_col = join(x = dataframe_varSelect_transcripto_col, y = dataframe_annot_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
131 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
132 by = "ProbeName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
133 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
134 res_variablesSelect[[ind_transcripto_col]] = tab_transcripto_col |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
135 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
136 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
137 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
138 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
139 ind_metageno_caecum = which(noms_blocks == "metageno_caecum") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
140 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
141 if(length(variablesSelect[[ind_metageno_caecum]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
142 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
143 varSelect_metageno_caecum_Temp1 = variablesSelect[[ind_metageno_caecum]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
144 varSelect_metageno_caecum_Temp2 = sapply(1:length(varSelect_metageno_caecum_Temp1), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
145 ch = strsplit(varSelect_metageno_caecum_Temp1[i], split = "")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
146 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
147 if(ch[1] == "X") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
148 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
149 res = paste(ch[2:length(ch)], collapse = "") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
150 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
151 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
152 res = varSelect_metageno_caecum_Temp1[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
153 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
154 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
155 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
156 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
157 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
158 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
159 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
160 dataframe_varSelect_metageno_caecum = data.frame(taxon = varSelect_metageno_caecum_Temp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
161 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
162 dataframe_annot_metageno_caecum = data.frame(annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
163 colnames(dataframe_annot_metageno_caecum)[1] = "taxon" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
164 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
165 tab_metageno_caecum = join(x = dataframe_varSelect_metageno_caecum, y = dataframe_annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
166 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
167 by = "taxon") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
168 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
169 res_variablesSelect[[ind_metageno_caecum]] = tab_metageno_caecum |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
170 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
171 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
172 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
173 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
174 ind_metabo_S1 = which(noms_blocks == "metabo_S1") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
175 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
176 if(length(variablesSelect[[ind_metabo_S1]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
177 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
178 res_variablesSelect[[ind_metabo_S1]] = data.frame(variable = variablesSelect[[ind_metabo_S1]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
179 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
180 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
181 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
182 ind_resBio = which(noms_blocks == "resBio") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
183 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
184 if(length(variablesSelect[[ind_resBio]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
185 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
186 res_variablesSelect[[ind_resBio]] = data.frame(variable = variablesSelect[[ind_resBio]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
187 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
188 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
189 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
190 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
191 return(res_variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
192 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
193 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
194 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
195 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
196 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
197 # La fonction varAnnotation_gene_6blocks permet de fournir des informations sur les variables |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
198 # sélectionnées pour un design. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
199 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
200 varAnnotation_gene_6blocks <-function(variablesSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
201 data_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
202 data_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
203 annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
204 metavar_metaboLC_S1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
205 metavar_resBio, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
206 metavar_cyto) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
207 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
208 res_variablesSelect = variablesSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
209 noms_blocks = names(variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
210 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
211 ind_transcripto_col = which(noms_blocks == "transcripto_col") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
212 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
213 if(length(ind_transcripto_col) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
214 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
215 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
216 varSelect_transcripto_colTemp = variablesSelect[[ind_transcripto_col]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
217 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
218 if(length(varSelect_transcripto_colTemp) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
219 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
220 varSelect_transcripto_col = sapply(1:length(varSelect_transcripto_colTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
221 variable_i = varSelect_transcripto_colTemp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
222 res = gsub("Colon_", "", variable_i, fixed = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
223 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
224 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
225 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
226 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
227 dataframe_varSelect_transcripto_col = data.frame(GeneName = varSelect_transcripto_col) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
228 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
229 dataframe_annot_transcripto_col = data.frame(ProbeName = data_transcripto_col$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
230 GeneName = data_transcripto_col$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
231 Description = data_transcripto_col$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
232 SystematicName = data_transcripto_col$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
233 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
234 tab_transcripto_col = join(x = dataframe_varSelect_transcripto_col, y = dataframe_annot_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
235 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
236 by = "GeneName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
237 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
238 res_variablesSelect[[ind_transcripto_col]] = tab_transcripto_col |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
239 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
240 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
241 res_variablesSelect[[ind_transcripto_col]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
242 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
243 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
244 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
245 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
246 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
247 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
248 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
249 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
250 ind_transcripto_tae = which(noms_blocks == "transcripto_tae") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
251 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
252 if(length(ind_transcripto_tae) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
253 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
254 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
255 varSelect_transcripto_taeTemp = variablesSelect[[ind_transcripto_tae]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
256 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
257 if(length(varSelect_transcripto_taeTemp) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
258 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
259 varSelect_transcripto_tae = sapply(1:length(varSelect_transcripto_taeTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
260 variable_i = varSelect_transcripto_taeTemp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
261 res = gsub("TAE_", "", variable_i, fixed = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
262 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
263 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
264 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
265 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
266 dataframe_varSelect_transcripto_tae = data.frame(GeneName = varSelect_transcripto_tae) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
267 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
268 dataframe_annot_transcripto_tae = data.frame(ProbeName = data_transcripto_tae$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
269 GeneName = data_transcripto_tae$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
270 Description = data_transcripto_tae$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
271 SystematicName = data_transcripto_tae$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
272 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
273 tab_transcripto_tae = join(x = dataframe_varSelect_transcripto_tae, y = dataframe_annot_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
274 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
275 by = "GeneName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
276 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
277 res_variablesSelect[[ind_transcripto_tae]] = tab_transcripto_tae |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
278 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
279 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
280 res_variablesSelect[[ind_transcripto_tae]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
281 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
282 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
283 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
284 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
285 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
286 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
287 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
288 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
289 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
290 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
291 ind_metageno_caecum = which(noms_blocks == "metageno_caecum") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
292 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
293 if(length(ind_metageno_caecum) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
294 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
295 varSelect_metageno_caecum_Temp1 = variablesSelect[[ind_metageno_caecum]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
296 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
297 if(length(varSelect_metageno_caecum_Temp1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
298 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
299 varSelect_metageno_caecum_Temp2 = sapply(1:length(varSelect_metageno_caecum_Temp1), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
300 ch = strsplit(varSelect_metageno_caecum_Temp1[i], split = "")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
301 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
302 if(ch[1] == "X") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
303 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
304 res = paste(ch[2:length(ch)], collapse = "") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
305 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
306 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
307 res = varSelect_metageno_caecum_Temp1[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
308 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
309 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
310 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
311 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
312 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
313 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
314 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
315 dataframe_varSelect_metageno_caecum = data.frame(taxon = varSelect_metageno_caecum_Temp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
316 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
317 dataframe_annot_metageno_caecum = data.frame(annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
318 colnames(dataframe_annot_metageno_caecum)[1] = "taxon" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
319 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
320 tab_metageno_caecum = join(x = dataframe_varSelect_metageno_caecum, y = dataframe_annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
321 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
322 by = "taxon") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
323 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
324 res_variablesSelect[[ind_metageno_caecum]] = tab_metageno_caecum |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
325 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
326 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
327 res_variablesSelect[[ind_metageno_caecum]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
328 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
329 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
330 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
331 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
332 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
333 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
334 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
335 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
336 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
337 ind_metaboLC_S1 = which(noms_blocks == "metaboLC_S1") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
338 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
339 if(length(ind_metaboLC_S1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
340 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
341 if(length(variablesSelect[[ind_metaboLC_S1]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
342 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
343 res_variablesSelect[[ind_metaboLC_S1]] = data.frame(variable = variablesSelect[[ind_metaboLC_S1]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
344 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
345 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
346 res_variablesSelect[[ind_metaboLC_S1]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
347 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
348 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
349 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
350 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
351 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
352 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
353 ind_resBio = which(noms_blocks == "resBio") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
354 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
355 if(length(ind_resBio) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
356 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
357 if(length(variablesSelect[[ind_resBio]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
358 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
359 res_variablesSelect[[ind_resBio]] = data.frame(variable = variablesSelect[[ind_resBio]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
360 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
361 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
362 res_variablesSelect[[ind_resBio]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
363 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
364 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
365 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
366 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
367 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
368 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
369 ind_cyto = which(noms_blocks == "cyto") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
370 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
371 if(length(ind_cyto) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
372 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
373 if(length(variablesSelect[[ind_cyto]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
374 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
375 res_variablesSelect[[ind_cyto]] = data.frame(variable = variablesSelect[[ind_cyto]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
376 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
377 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
378 res_variablesSelect[[ind_cyto]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
379 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
380 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
381 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
382 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
383 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
384 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
385 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
386 return(res_variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
387 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
388 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
389 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
390 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
391 # La fonction varAnnotation_gene_6blocks permet de fournir des informations sur les variables |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
392 # sélectionnées pour un design. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
393 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
394 varAnnotation_gene_6blocks <-function(variablesSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
395 data_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
396 data_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
397 annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
398 metavar_metaboLC_S1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
399 metavar_resBio, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
400 metavar_cyto) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
401 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
402 res_variablesSelect = variablesSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
403 noms_blocks = names(variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
404 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
405 ind_transcripto_col = which(noms_blocks == "transcripto_col") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
406 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
407 if(length(ind_transcripto_col) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
408 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
409 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
410 varSelect_transcripto_colTemp = variablesSelect[[ind_transcripto_col]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
411 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
412 if(length(varSelect_transcripto_colTemp) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
413 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
414 varSelect_transcripto_col = sapply(1:length(varSelect_transcripto_colTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
415 variable_i = varSelect_transcripto_colTemp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
416 res = gsub("Colon_", "", variable_i, fixed = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
417 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
418 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
419 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
420 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
421 dataframe_varSelect_transcripto_col = data.frame(GeneName = varSelect_transcripto_col) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
422 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
423 dataframe_annot_transcripto_col = data.frame(ProbeName = data_transcripto_col$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
424 GeneName = data_transcripto_col$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
425 Description = data_transcripto_col$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
426 SystematicName = data_transcripto_col$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
427 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
428 tab_transcripto_col = join(x = dataframe_varSelect_transcripto_col, y = dataframe_annot_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
429 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
430 by = "GeneName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
431 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
432 res_variablesSelect[[ind_transcripto_col]] = tab_transcripto_col |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
433 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
434 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
435 res_variablesSelect[[ind_transcripto_col]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
436 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
437 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
438 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
439 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
440 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
441 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
442 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
443 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
444 ind_transcripto_tae = which(noms_blocks == "transcripto_tae") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
445 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
446 if(length(ind_transcripto_tae) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
447 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
448 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
449 varSelect_transcripto_taeTemp = variablesSelect[[ind_transcripto_tae]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
450 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
451 if(length(varSelect_transcripto_taeTemp) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
452 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
453 varSelect_transcripto_tae = sapply(1:length(varSelect_transcripto_taeTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
454 variable_i = varSelect_transcripto_taeTemp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
455 res = gsub("TAE_", "", variable_i, fixed = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
456 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
457 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
458 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
459 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
460 dataframe_varSelect_transcripto_tae = data.frame(GeneName = varSelect_transcripto_tae) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
461 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
462 dataframe_annot_transcripto_tae = data.frame(ProbeName = data_transcripto_tae$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
463 GeneName = data_transcripto_tae$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
464 Description = data_transcripto_tae$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
465 SystematicName = data_transcripto_tae$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
466 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
467 tab_transcripto_tae = join(x = dataframe_varSelect_transcripto_tae, y = dataframe_annot_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
468 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
469 by = "GeneName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
470 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
471 res_variablesSelect[[ind_transcripto_tae]] = tab_transcripto_tae |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
472 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
473 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
474 res_variablesSelect[[ind_transcripto_tae]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
475 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
476 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
477 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
478 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
479 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
480 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
481 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
482 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
483 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
484 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
485 ind_metageno_caecum = which(noms_blocks == "metageno_caecum") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
486 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
487 if(length(ind_metageno_caecum) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
488 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
489 varSelect_metageno_caecum_Temp1 = variablesSelect[[ind_metageno_caecum]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
490 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
491 if(length(varSelect_metageno_caecum_Temp1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
492 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
493 varSelect_metageno_caecum_Temp2 = sapply(1:length(varSelect_metageno_caecum_Temp1), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
494 ch = strsplit(varSelect_metageno_caecum_Temp1[i], split = "")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
495 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
496 if(ch[1] == "X") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
497 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
498 res = paste(ch[2:length(ch)], collapse = "") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
499 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
500 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
501 res = varSelect_metageno_caecum_Temp1[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
502 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
503 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
504 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
505 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
506 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
507 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
508 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
509 dataframe_varSelect_metageno_caecum = data.frame(taxon = varSelect_metageno_caecum_Temp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
510 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
511 dataframe_annot_metageno_caecum = data.frame(annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
512 colnames(dataframe_annot_metageno_caecum)[1] = "taxon" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
513 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
514 tab_metageno_caecum = join(x = dataframe_varSelect_metageno_caecum, y = dataframe_annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
515 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
516 by = "taxon") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
517 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
518 res_variablesSelect[[ind_metageno_caecum]] = tab_metageno_caecum |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
519 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
520 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
521 res_variablesSelect[[ind_metageno_caecum]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
522 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
523 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
524 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
525 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
526 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
527 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
528 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
529 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
530 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
531 ind_metaboLC_S1 = which(noms_blocks == "metaboLC_S1") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
532 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
533 if(length(ind_metaboLC_S1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
534 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
535 if(length(variablesSelect[[ind_metaboLC_S1]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
536 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
537 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
538 dataframe_varSelect_metaboLC_S1 = data.frame(Variable = variablesSelect[[ind_metaboLC_S1]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
539 dataframe_metavar_metaboLC_S1 = data.frame(metavar_metaboLC_S1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
540 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
541 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
542 dataframe_metavar_varSelect_metaboLC_S1 = join(x = dataframe_varSelect_metaboLC_S1, y = dataframe_metavar_metaboLC_S1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
543 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
544 by = "Variable") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
545 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
546 res_variablesSelect[[ind_metaboLC_S1]] = dataframe_metavar_varSelect_metaboLC_S1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
547 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
548 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
549 res_variablesSelect[[ind_metaboLC_S1]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
550 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
551 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
552 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
553 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
554 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
555 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
556 ind_resBio = which(noms_blocks == "resBio") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
557 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
558 if(length(ind_resBio) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
559 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
560 if(length(variablesSelect[[ind_resBio]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
561 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
562 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
563 dataframe_varSelect_resBio = data.frame(Variable = variablesSelect[[ind_resBio]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
564 dataframe_metavar_resBio = data.frame(metavar_resBio) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
565 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
566 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
567 dataframe_metavar_varSelect_resBio = join(x = dataframe_varSelect_resBio, y = dataframe_metavar_resBio, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
568 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
569 by = "Variable") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
570 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
571 res_variablesSelect[[ind_resBio]] = dataframe_metavar_varSelect_resBio |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
572 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
573 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
574 res_variablesSelect[[ind_resBio]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
575 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
576 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
577 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
578 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
579 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
580 ind_cyto = which(noms_blocks == "cyto") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
581 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
582 if(length(ind_cyto) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
583 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
584 if(length(variablesSelect[[ind_cyto]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
585 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
586 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
587 dataframe_varSelect_cyto = data.frame(Variable = variablesSelect[[ind_cyto]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
588 dataframe_metavar_cyto = data.frame(metavar_cyto) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
589 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
590 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
591 dataframe_metavar_varSelect_cyto = join(x = dataframe_varSelect_cyto, y = dataframe_metavar_cyto, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
592 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
593 by = "Variable") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
594 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
595 res_variablesSelect[[ind_cyto]] = dataframe_metavar_varSelect_cyto |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
596 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
597 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
598 res_variablesSelect[[ind_cyto]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
599 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
600 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
601 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
602 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
603 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
604 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
605 return(res_variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
606 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
607 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
608 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
609 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
610 # La fonction varAnnotation_gene_7blocks permet de fournir des informations sur les variables |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
611 # sélectionnées pour un design. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
612 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
613 varAnnotation_gene_7blocks <-function(variablesSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
614 data_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
615 data_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
616 annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
617 metavar_metaboLC_S1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
618 metavar_resBio, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
619 metavar_cyto) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
620 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
621 res_variablesSelect = variablesSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
622 noms_blocks = names(variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
623 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
624 ind_transcripto_col = which(noms_blocks == "transcripto_col") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
625 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
626 if(length(ind_transcripto_col) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
627 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
628 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
629 varSelect_transcripto_colTemp = variablesSelect[[ind_transcripto_col]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
630 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
631 if(length(varSelect_transcripto_colTemp) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
632 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
633 varSelect_transcripto_col = sapply(1:length(varSelect_transcripto_colTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
634 variable_i = varSelect_transcripto_colTemp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
635 res = gsub("Colon_", "", variable_i, fixed = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
636 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
637 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
638 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
639 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
640 dataframe_varSelect_transcripto_col = data.frame(GeneName = varSelect_transcripto_col) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
641 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
642 dataframe_annot_transcripto_col = data.frame(ProbeName = data_transcripto_col$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
643 GeneName = data_transcripto_col$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
644 Description = data_transcripto_col$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
645 SystematicName = data_transcripto_col$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
646 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
647 tab_transcripto_col = join(x = dataframe_varSelect_transcripto_col, y = dataframe_annot_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
648 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
649 by = "GeneName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
650 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
651 res_variablesSelect[[ind_transcripto_col]] = tab_transcripto_col |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
652 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
653 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
654 res_variablesSelect[[ind_transcripto_col]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
655 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
656 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
657 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
658 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
659 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
660 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
661 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
662 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
663 ind_transcripto_tae = which(noms_blocks == "transcripto_tae") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
664 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
665 if(length(ind_transcripto_tae) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
666 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
667 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
668 varSelect_transcripto_taeTemp = variablesSelect[[ind_transcripto_tae]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
669 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
670 if(length(varSelect_transcripto_taeTemp) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
671 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
672 varSelect_transcripto_tae = sapply(1:length(varSelect_transcripto_taeTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
673 variable_i = varSelect_transcripto_taeTemp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
674 res = gsub("TAE_", "", variable_i, fixed = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
675 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
676 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
677 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
678 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
679 dataframe_varSelect_transcripto_tae = data.frame(GeneName = varSelect_transcripto_tae) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
680 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
681 dataframe_annot_transcripto_tae = data.frame(ProbeName = data_transcripto_tae$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
682 GeneName = data_transcripto_tae$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
683 Description = data_transcripto_tae$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
684 SystematicName = data_transcripto_tae$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
685 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
686 tab_transcripto_tae = join(x = dataframe_varSelect_transcripto_tae, y = dataframe_annot_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
687 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
688 by = "GeneName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
689 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
690 res_variablesSelect[[ind_transcripto_tae]] = tab_transcripto_tae |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
691 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
692 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
693 res_variablesSelect[[ind_transcripto_tae]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
694 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
695 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
696 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
697 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
698 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
699 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
700 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
701 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
702 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
703 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
704 ind_metageno_caecum = which(noms_blocks == "metageno_caecum") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
705 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
706 if(length(ind_metageno_caecum) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
707 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
708 varSelect_metageno_caecum_Temp1 = variablesSelect[[ind_metageno_caecum]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
709 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
710 if(length(varSelect_metageno_caecum_Temp1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
711 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
712 varSelect_metageno_caecum_Temp2 = sapply(1:length(varSelect_metageno_caecum_Temp1), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
713 ch = strsplit(varSelect_metageno_caecum_Temp1[i], split = "")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
714 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
715 if(ch[1] == "X") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
716 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
717 res = paste(ch[2:length(ch)], collapse = "") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
718 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
719 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
720 res = varSelect_metageno_caecum_Temp1[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
721 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
722 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
723 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
724 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
725 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
726 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
727 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
728 dataframe_varSelect_metageno_caecum = data.frame(taxon = varSelect_metageno_caecum_Temp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
729 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
730 dataframe_annot_metageno_caecum = data.frame(annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
731 colnames(dataframe_annot_metageno_caecum)[1] = "taxon" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
732 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
733 tab_metageno_caecum = join(x = dataframe_varSelect_metageno_caecum, y = dataframe_annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
734 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
735 by = "taxon") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
736 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
737 res_variablesSelect[[ind_metageno_caecum]] = tab_metageno_caecum |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
738 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
739 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
740 res_variablesSelect[[ind_metageno_caecum]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
741 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
742 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
743 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
744 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
745 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
746 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
747 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
748 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
749 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
750 ind_metaboLC_S1 = which(noms_blocks == "metaboLC_S1") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
751 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
752 if(length(ind_metaboLC_S1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
753 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
754 if(length(variablesSelect[[ind_metaboLC_S1]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
755 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
756 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
757 dataframe_varSelect_metaboLC_S1 = data.frame(Variable = variablesSelect[[ind_metaboLC_S1]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
758 dataframe_metavar_metaboLC_S1 = data.frame(metavar_metaboLC_S1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
759 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
760 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
761 dataframe_metavar_varSelect_metaboLC_S1 = join(x = dataframe_varSelect_metaboLC_S1, y = dataframe_metavar_metaboLC_S1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
762 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
763 by = "Variable") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
764 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
765 res_variablesSelect[[ind_metaboLC_S1]] = dataframe_metavar_varSelect_metaboLC_S1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
766 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
767 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
768 res_variablesSelect[[ind_metaboLC_S1]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
769 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
770 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
771 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
772 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
773 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
774 ind_metaboGC_S1 = which(noms_blocks == "metaboGC_S1") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
775 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
776 if(length(ind_metaboGC_S1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
777 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
778 if(length(variablesSelect[[ind_metaboGC_S1]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
779 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
780 res_variablesSelect[[ind_metaboGC_S1]] = data.frame(Variable = variablesSelect[[ind_metaboGC_S1]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
781 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
782 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
783 res_variablesSelect[[ind_metaboGC_S1]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
784 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
785 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
786 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
787 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
788 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
789 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
790 ind_resBio = which(noms_blocks == "resBio") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
791 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
792 if(length(ind_resBio) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
793 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
794 if(length(variablesSelect[[ind_resBio]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
795 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
796 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
797 dataframe_varSelect_resBio = data.frame(Variable = variablesSelect[[ind_resBio]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
798 dataframe_metavar_resBio = data.frame(metavar_resBio) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
799 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
800 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
801 dataframe_metavar_varSelect_resBio = join(x = dataframe_varSelect_resBio, y = dataframe_metavar_resBio, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
802 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
803 by = "Variable") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
804 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
805 res_variablesSelect[[ind_resBio]] = dataframe_metavar_varSelect_resBio |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
806 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
807 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
808 res_variablesSelect[[ind_resBio]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
809 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
810 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
811 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
812 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
813 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
814 ind_cyto = which(noms_blocks == "cyto") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
815 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
816 if(length(ind_cyto) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
817 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
818 if(length(variablesSelect[[ind_cyto]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
819 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
820 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
821 dataframe_varSelect_cyto = data.frame(Variable = variablesSelect[[ind_cyto]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
822 dataframe_metavar_cyto = data.frame(metavar_cyto) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
823 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
824 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
825 dataframe_metavar_varSelect_cyto = join(x = dataframe_varSelect_cyto, y = dataframe_metavar_cyto, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
826 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
827 by = "Variable") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
828 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
829 res_variablesSelect[[ind_cyto]] = dataframe_metavar_varSelect_cyto |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
830 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
831 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
832 res_variablesSelect[[ind_cyto]] = "" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
833 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
834 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
835 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
836 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
837 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
838 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
839 return(res_variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
840 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
841 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
842 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
843 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
844 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
845 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
846 # Integration 6 blocs norm sonde ------------------------------------------ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
847 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
848 # La fonction plotVarZoom permet de zoomer sur le cercle de corrélation et de récupérer les variables |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
849 # contenues dans ce rectangle. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
850 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
851 plotVarZoom <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
852 comp = 1:2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
853 blocks, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
854 block_Y = NULL, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
855 vec_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
856 cutoff, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
857 rad.in = 0.5, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
858 min.X = -1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
859 max.X = 1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
860 min.Y = -1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
861 max.Y = 1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
862 cex = 0.7, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
863 cex_legend = 0.8, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
864 pos = c(1.2, 0), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
865 pch = 20, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
866 inset = c(-0.25, 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
867 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
868 if(class(res_block_splsda)[1] == "block.splsda") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
869 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
870 circle = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
871 circle[[1]] = ellipse(0, levels = 1, t = 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
872 circle[[2]] = ellipse(0, levels = 1, t = rad.in) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
873 circle = data.frame(do.call("rbind", circle), "Circle" = c(rep("Main circle", 100), rep("Inner circle", 100))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
874 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
875 MainCircle = circle[grep("Main circle", circle[, 3]), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
876 InnerCircle = circle[grep("Inner circle", circle[, 3]), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
877 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
878 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
879 if(length(blocks) > 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
880 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
881 noms_bloc = names(res_block_splsda$variates) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
882 mat_comp1 = sapply(blocks, FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
883 res = res_block_splsda$variates[[i]][, 1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
884 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
885 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
886 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
887 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
888 colnames(mat_comp1) = noms_bloc[blocks] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
889 mat_cor_comp1 = cor(mat_comp1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
890 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
891 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
892 mat_comp2 = sapply(blocks, FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
893 res = res_block_splsda$variates[[i]][, 2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
894 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
895 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
896 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
897 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
898 colnames(mat_comp2) = noms_bloc[blocks] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
899 mat_cor_comp2 = cor(mat_comp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
900 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
901 } # Fin if(length(blocks) > 1). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
902 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
903 # Pour chaque bloc, calcul des corrélations entre la première |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
904 # composante et les variables sélectionnées et les corrélations entre |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
905 # la deuxième composante et les variables sélectionnées. Pour la réponse, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
906 # calcul de la corrélation entre les variables de la réponse et la première composante |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
907 # du premier bloc sélectionné et de la corrélation entre les variables de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
908 # la réponse et la deuxième composante du premier bloc sélectionné. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
909 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
910 liste_matCor_comp_var = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
911 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
912 varSelect_comp1 = selectVar(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
913 comp = comp[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
914 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
915 varSelect_comp2 = selectVar(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
916 comp = comp[2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
917 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
918 vec_nom_blockEtReponse = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
919 blocksEtReponse = c(blocks, which(res_block_splsda$names$blocks == "Y")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
920 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
921 for(i in 1:length(blocksEtReponse)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
922 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
923 indice_block_i = blocksEtReponse[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
924 nom_blockEtReponse_i = res_block_splsda$names$blocks[indice_block_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
925 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
926 if(nom_blockEtReponse_i == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
927 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
928 if(!is.null(block_Y)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
929 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
930 block_i = block_Y |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
931 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
932 comp1 = res_block_splsda$variates[[blocks[1]]][, comp[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
933 comp2 = res_block_splsda$variates[[blocks[1]]][, comp[2]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
934 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
935 vecCor_comp1_var = sapply(1:dim(block_i)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
936 cor(comp1, block_i[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
937 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
938 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
939 vecCor_comp2_var = sapply(1:dim(block_i)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
940 cor(comp2, block_i[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
941 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
942 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
943 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
944 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
945 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
946 cat("La réponse n'est pas saisie comme paramètre d'entrée", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
947 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
948 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
949 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
950 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
951 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
952 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
953 comp1 = res_block_splsda$variates[[indice_block_i]][, comp[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
954 comp2 = res_block_splsda$variates[[indice_block_i]][, comp[2]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
955 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
956 varSelect_comp1_i = varSelect_comp1[[indice_block_i]][[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
957 varSelect_comp2_i = varSelect_comp2[[indice_block_i]][[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
958 varSelect_i = unique(c(varSelect_comp1_i, varSelect_comp2_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
959 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
960 block_i = res_block_splsda$X[[indice_block_i]][, varSelect_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
961 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
962 if(i == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
963 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
964 vecCor_comp1_var = sapply(1:dim(block_i)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
965 cor(comp1, block_i[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
966 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
967 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
968 vecCor_comp2_var = sapply(1:dim(block_i)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
969 cor(comp2, block_i[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
970 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
971 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
972 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
973 signeCor_comp1 = sign(mat_cor_comp1[1, indice_block_i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
974 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
975 vecCor_comp1_var = sapply(1:dim(block_i)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
976 res = signeCor_comp1*cor(comp1, block_i[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
977 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
978 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
979 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
980 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
981 signeCor_comp2 = sign(mat_cor_comp2[1, indice_block_i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
982 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
983 vecCor_comp2_var = sapply(1:dim(block_i)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
984 res = signeCor_comp2*cor(comp2, block_i[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
985 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
986 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
987 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
988 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
989 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
990 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
991 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
992 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
993 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
994 matCor_comp_var = rbind(vecCor_comp1_var, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
995 vecCor_comp2_var) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
996 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
997 colnames(matCor_comp_var) = colnames(block_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
998 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
999 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1000 liste_matCor_comp_var[[i]] = matCor_comp_var |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1001 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1002 vec_nom_blockEtReponse_i = rep(nom_blockEtReponse_i, dim(block_i)[2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1003 vec_nom_blockEtReponse = c(vec_nom_blockEtReponse, vec_nom_blockEtReponse_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1004 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1005 } # Fin for(i in 1:length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1006 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1007 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1008 matCor_Allcomp_Allvar = t(Reduce(cbind, liste_matCor_comp_var)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1009 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1010 # indice permet de récupérer les variables de chaque bloc fortement corrélées avec soit |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1011 # la première composante ou la deuxième composante dans une partie du cercle de corrélation |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1012 # et de récupérer la variable réponse dans une partie du cercle de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1013 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1014 indice = sapply(1:dim(matCor_Allcomp_Allvar)[1], FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1015 cor1 = matCor_Allcomp_Allvar[k, 1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1016 cor2 = matCor_Allcomp_Allvar[k, 2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1017 blockEtReponse_k = vec_nom_blockEtReponse[k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1018 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1019 if(blockEtReponse_k == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1020 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1021 cond2 = cor1 > min.X & cor1 < max.X & cor2 > min.Y & cor2 < max.Y |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1022 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1023 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1024 cond1 = abs(cor1) > cutoff | abs(cor2) > cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1025 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1026 cond2 = cor1 > min.X & cor1 < max.X & cor2 > min.Y & cor2 < max.Y & cond1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1027 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1028 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1029 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1030 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1031 return(cond2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1032 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1033 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1034 matCor_Allcomp_AllvarSelect = matCor_Allcomp_Allvar[indice, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1035 varSelect = rownames(matCor_Allcomp_AllvarSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1036 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1037 dataframe_Cor_Allcomp_Allvar = data.frame(cbind(rownames(matCor_Allcomp_Allvar), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1038 vec_nom_blockEtReponse, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1039 matCor_Allcomp_Allvar)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1040 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1041 colnames(dataframe_Cor_Allcomp_Allvar) = c("variable", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1042 "bloc", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1043 "cor_comp1_var", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1044 "cor_comp2_var") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1045 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1046 dataframe_Cor_Allcomp_Allvar[, 1:2] = apply(dataframe_Cor_Allcomp_Allvar[, 1:2], 2, as.character) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1047 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1048 dataframe_Cor_Allcomp_AllvarSelect = dataframe_Cor_Allcomp_Allvar[indice, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1049 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1050 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1051 # Tracé de la superposition des cerles de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1052 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1053 plot(MainCircle[, 1], MainCircle[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1054 type = "l", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1055 xlab = paste0("composante ", comp[1]), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1056 ylab = paste0("composante ", comp[2])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1057 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1058 points(InnerCircle[, 1], InnerCircle[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1059 type = "l") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1060 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1061 if(dim(matCor_Allcomp_AllvarSelect)[1] != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1062 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1063 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1064 nom_blockEtReponseSelect = unique(dataframe_Cor_Allcomp_AllvarSelect[, 2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1065 indice_blockEtReponseSelect = sapply(1:length(nom_blockEtReponseSelect), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1066 ind = which(res_block_splsda$names$blocks == nom_blockEtReponseSelect[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1067 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1068 if(length(ind) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1069 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1070 res = ind |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1071 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1072 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1073 res = which(res_block_splsda$names$blocks == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1074 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1075 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1076 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1077 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1078 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1079 vec_colSelect = vec_col[indice_blockEtReponseSelect] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1080 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1081 if(length(blocksEtReponse) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1082 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1083 points(matCor_Allcomp_AllvarSelect[, 1], matCor_Allcomp_AllvarSelect[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1084 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1085 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1086 text(matCor_Allcomp_AllvarSelect[, 1], matCor_Allcomp_AllvarSelect[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1087 labels = rownames(matCor_Allcomp_AllvarSelect), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1088 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1089 col = vec_colSelect[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1090 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1091 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1092 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1093 nbVarSelect_bloc = cumsum(sapply(1:length(nom_blockEtReponseSelect), FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1094 res = length(which(dataframe_Cor_Allcomp_AllvarSelect[, 2] == nom_blockEtReponseSelect[j])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1095 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1096 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1097 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1098 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1099 for(i in 1:length(nbVarSelect_bloc)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1100 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1101 if(i == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1102 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1103 indice1 = 1:nbVarSelect_bloc[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1104 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1105 if(length(indice1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1106 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1107 matCor_Allcomp_AllvarSelect2 = matCor_Allcomp_AllvarSelect[indice1, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1108 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1109 points(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1110 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1111 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1112 text(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1113 labels = rownames(matCor_Allcomp_AllvarSelect2), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1114 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1115 col = rep(vec_colSelect[i], dim(matCor_Allcomp_AllvarSelect2)[1])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1116 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1117 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1118 cat(paste0("Il n'y a de variables dans cette zone du cercle de corrélation pour le bloc ", nom_blockEtReponseSelect[i]), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1119 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1120 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1121 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1122 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1123 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1124 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1125 indice2 = (nbVarSelect_bloc[i - 1] + 1):nbVarSelect_bloc[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1126 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1127 if(length(indice2) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1128 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1129 matCor_Allcomp_AllvarSelect2 = matCor_Allcomp_AllvarSelect[indice2, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1130 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1131 points(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1132 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1133 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1134 text(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1135 labels = rownames(matCor_Allcomp_AllvarSelect2), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1136 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1137 col = rep(vec_colSelect[i], dim(matCor_Allcomp_AllvarSelect2)[1])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1138 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1139 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1140 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1141 cat(paste0("Il n'y a de variables dans cette zone du cercle de corrélation pour le bloc ", nom_blockEtReponseSelect[i]), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1142 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1143 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1144 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1145 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1146 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1147 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1148 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1149 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1150 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1151 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1152 par(xpd = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1153 legend(x = pos[1], y = pos[2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1154 legend = nom_blockEtReponseSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1155 pch = pch, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1156 col = vec_colSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1157 cex = cex_legend, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1158 inset = inset) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1159 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1160 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1161 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1162 cat("Il n'y a de variables dans cette zone du cercle de corrélation", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1163 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1164 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1165 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1166 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1167 # Suppression de dataframe_Cor_Allcomp_Allvar, dataframe_Cor_Allcomp_AllvarSelect et varSelect de la variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1168 # réponse. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1169 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1170 if(!is.null(block_Y)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1171 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1172 for(i in 1:dim(block_Y)[2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1173 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1174 variableReponse = colnames(block_Y)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1175 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1176 # dataframe_Cor_Allcomp_Allvar |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1177 if(dim(dataframe_Cor_Allcomp_Allvar)[1] != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1178 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1179 ind_Allvar = which(dataframe_Cor_Allcomp_Allvar$variable == variableReponse) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1180 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1181 if(length(ind_Allvar) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1182 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1183 dataframe_Cor_Allcomp_Allvar = dataframe_Cor_Allcomp_Allvar[- ind_Allvar, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1184 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1185 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1186 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1187 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1188 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1189 # dataframe_Cor_Allcomp_AllvarSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1190 if(dim(dataframe_Cor_Allcomp_AllvarSelect)[1] != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1191 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1192 ind_AllvarSelect = which(dataframe_Cor_Allcomp_AllvarSelect$variable == variableReponse) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1193 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1194 if(length(ind_AllvarSelect) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1195 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1196 dataframe_Cor_Allcomp_AllvarSelect = dataframe_Cor_Allcomp_AllvarSelect[- ind_AllvarSelect, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1197 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1198 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1199 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1200 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1201 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1202 # varSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1203 if(length(varSelect) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1204 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1205 ind_varSelect = which(varSelect == variableReponse) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1206 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1207 if(length(ind_varSelect) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1208 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1209 varSelect = varSelect[- ind_varSelect] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1210 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1211 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1212 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1213 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1214 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1215 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1216 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1217 } # Fin for(i in 1:dim(block_Y)[2]). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1218 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1219 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1220 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1221 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1222 res = list(dataframe_Cor_Allcomp_Allvar = dataframe_Cor_Allcomp_Allvar, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1223 dataframe_Cor_Allcomp_AllvarSelect = dataframe_Cor_Allcomp_AllvarSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1224 varSelect = varSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1225 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1226 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1227 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1228 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1229 cat("Erreur : il ne s'agit pas de la sortie de la fonction block.splsda", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1230 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1231 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1232 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1233 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1234 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1235 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1236 # La fonction networkVarSelect permet de tracer un réseau pour les variables de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1237 # certains blocs. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1238 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1239 networkVarSelect <-function(object, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1240 mat_Y, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1241 comp = 1:2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1242 listeVar, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1243 blocks, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1244 cutoff = 0 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1245 ) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1246 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1247 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1248 if(class(object)[1] == "block.splsda") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1249 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1250 nomBlocs = names(listeVar) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1251 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1252 liste_XSelect = lapply(1:length(listeVar), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1253 nomBloc_i = names(listeVar)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1254 ind1 = which(object$names$blocks == nomBloc_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1255 ind2 = colnames(object$X[[ind1]])%in%listeVar[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1256 res = object$X[[ind1]][, ind2, drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1257 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1258 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1259 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1260 names(liste_XSelect) = nomBlocs |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1261 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1262 liste_matSelect = liste_XSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1263 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1264 if(!is.null(mat_Y)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1265 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1266 liste_matSelect = c(liste_matSelect, list(mat_Y)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1267 names(liste_matSelect)[length(liste_matSelect)] = "Y" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1268 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1269 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1270 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1271 # compute the similarity between var1 of block1 and var2 of block2. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1272 coord = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1273 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1274 for(k in 1:length(blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1275 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1276 nomBloc_k = names(liste_matSelect)[k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1277 mat_k = liste_matSelect[[k]][, ,drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1278 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1279 if(nomBloc_k == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1280 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1281 coord[[k]] = cor(mat_k, object$variates[[blocks[1]]][, comp]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1282 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1283 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1284 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1285 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1286 coord[[k]] = cor(mat_k, object$variates[[blocks[k]]][, comp]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1287 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1288 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1289 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1290 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1291 if(dim(mat_k)[2] == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1292 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1293 coord[[k]] = as.matrix(coord[[k]], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1294 nrow = 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1295 rownames(coord[[k]]) = colnames(mat_k) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1296 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1297 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1298 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1299 } # Fin for(k in 1:length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1300 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1301 l = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1302 M_block = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1303 node.X1 = node.X2 = w = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1304 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1305 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1306 for(j in 1:(length(blocks) - 1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1307 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1308 for(k in (j + 1):length(blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1309 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1310 M_block[[l]] = coord[[j]][, comp, drop = FALSE] %*% t(coord[[k]][, comp, drop = FALSE]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1311 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1312 X1 = rownames(coord[[j]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1313 X2 = rownames(coord[[k]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1314 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1315 rep.X1 = rep(X1, each = length(X2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1316 rep.X2 = rep(X2, length(X1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1317 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1318 node.X1= c(node.X1, rep.X1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1319 node.X2 = c(node.X2, rep.X2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1320 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1321 w = c(w, as.vector(t(M_block[[l]]))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1322 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1323 l = l + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1324 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1325 } # Fin for(k in (j + 1):length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1326 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1327 } # Fin for(j in 1:(length(blocks) - 1)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1328 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1329 # nodes |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1330 group = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1331 temp = lapply(liste_matSelect, function(x) colnames(x)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1332 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1333 for (i in 1:length(temp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1334 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1335 group = c(group, rep(names(temp)[i], length(temp[[i]]))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1336 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1337 } # Fin for (i in 1:length(temp)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1338 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1339 # nodes |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1340 nodes = data.frame(name = unlist(temp), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1341 group = group) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1342 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1343 # gR |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1344 relations = data.frame(from = node.X1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1345 to = node.X2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1346 weight = w) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1347 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1348 idx = (abs(w) >= cutoff) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1349 relations = relations[idx, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1350 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1351 gR = graph.data.frame(relations, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1352 directed = FALSE, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1353 vertices = nodes) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1354 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1355 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1356 block.var.names = sapply(1:length(liste_matSelect), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1357 res = colnames(liste_matSelect[[i]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1358 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1359 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1360 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1361 V(gR)$label = unlist(block.var.names) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1362 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1363 gR = delete.vertices(gR, which(degree(gR) == 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1364 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1365 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1366 res = list(gR = gR) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1367 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1368 l = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1369 for (i in 1:(length(blocks)-1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1370 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1371 for (j in (i + 1):length(blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1372 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1373 res[paste("M", names(liste_matSelect)[i], names(liste_matSelect)[j], sep="_")] = list(M_block[[l]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1374 l = l + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1375 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1376 } # Fin for (j in (i + 1):length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1377 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1378 } # Fin for (i in 1:(length(blocks)-1). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1379 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1380 res$cutoff = cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1381 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1382 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1383 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1384 } # Fin if(class(object)[1] == "block.splsda"). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1385 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1386 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1387 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1388 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1389 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1390 # La fonction varAnnotation_6blocks permet de fournir des informations sur les variables |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1391 # sélectionnées pour un design. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1392 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1393 varAnnotation_6blocks <-function(variablesSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1394 data_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1395 data_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1396 annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1397 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1398 res_variablesSelect = variablesSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1399 noms_blocks = names(variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1400 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1401 ind_transcripto_col = which(noms_blocks == "transcripto_col") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1402 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1403 if(length(variablesSelect[[ind_transcripto_col]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1404 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1405 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1406 varSelect_transcripto_colTemp = variablesSelect[[ind_transcripto_col]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1407 varSelect_transcripto_col = sapply(1:length(varSelect_transcripto_colTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1408 ch = strsplit(varSelect_transcripto_colTemp[i], split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1409 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1410 res = paste(ch[2:length(ch)], collapse = "_") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1411 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1412 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1413 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1414 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1415 dataframe_varSelect_transcripto_col = data.frame(ProbeName = varSelect_transcripto_col) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1416 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1417 dataframe_annot_transcripto_col = data.frame(ProbeName = data_transcripto_col$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1418 GeneName = data_transcripto_col$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1419 Description = data_transcripto_col$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1420 SystematicName = data_transcripto_col$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1421 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1422 tab_transcripto_col = join(x = dataframe_varSelect_transcripto_col, y = dataframe_annot_transcripto_col, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1423 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1424 by = "ProbeName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1425 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1426 res_variablesSelect[[ind_transcripto_col]] = tab_transcripto_col |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1427 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1428 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1429 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1430 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1431 ind_transcripto_tae = which(noms_blocks == "transcripto_tae") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1432 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1433 if(length(variablesSelect[[ind_transcripto_tae]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1434 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1435 varSelect_transcripto_taeTemp = variablesSelect[[ind_transcripto_tae]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1436 varSelect_transcripto_tae = sapply(1:length(varSelect_transcripto_taeTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1437 ch = strsplit(varSelect_transcripto_taeTemp[i], split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1438 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1439 res = paste(ch[2:length(ch)], collapse = "_") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1440 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1441 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1442 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1443 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1444 dataframe_varSelect_transcripto_tae = data.frame(ProbeName = varSelect_transcripto_tae) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1445 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1446 dataframe_annot_transcripto_tae = data.frame(ProbeName = data_transcripto_tae$genes$ProbeName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1447 GeneName = data_transcripto_tae$genes$GeneName, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1448 Description = data_transcripto_tae$genes$Description, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1449 SystematicName = data_transcripto_tae$genes$SystematicName) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1450 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1451 tab_transcripto_tae = join(x = dataframe_varSelect_transcripto_tae, y = dataframe_annot_transcripto_tae, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1452 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1453 by = "ProbeName") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1454 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1455 res_variablesSelect[[ind_transcripto_tae]] = tab_transcripto_tae |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1456 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1457 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1458 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1459 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1460 ind_metageno_caecum = which(noms_blocks == "metageno_caecum") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1461 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1462 if(length(variablesSelect[[ind_metageno_caecum]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1463 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1464 varSelect_metageno_caecum_Temp1 = variablesSelect[[ind_metageno_caecum]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1465 varSelect_metageno_caecum_Temp2 = sapply(1:length(varSelect_metageno_caecum_Temp1), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1466 ch = strsplit(varSelect_metageno_caecum_Temp1[i], split = "")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1467 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1468 if(ch[1] == "X") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1469 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1470 res = paste(ch[2:length(ch)], collapse = "") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1471 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1472 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1473 res = varSelect_metageno_caecum_Temp1[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1474 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1475 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1476 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1477 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1478 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1479 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1480 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1481 dataframe_varSelect_metageno_caecum = data.frame(taxon = varSelect_metageno_caecum_Temp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1482 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1483 dataframe_annot_metageno_caecum = data.frame(annot_metageno_caecum) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1484 colnames(dataframe_annot_metageno_caecum)[1] = "taxon" |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1485 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1486 tab_metageno_caecum = join(x = dataframe_varSelect_metageno_caecum, y = dataframe_annot_metageno_caecum, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1487 type = "inner", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1488 by = "taxon") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1489 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1490 res_variablesSelect[[ind_metageno_caecum]] = tab_metageno_caecum |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1491 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1492 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1493 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1494 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1495 ind_metaboLC_S1 = which(noms_blocks == "metaboLC_S1") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1496 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1497 if(length(variablesSelect[[ind_metaboLC_S1]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1498 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1499 res_variablesSelect[[ind_metaboLC_S1]] = data.frame(variable = variablesSelect[[ind_metaboLC_S1]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1500 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1501 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1502 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1503 ind_resBio = which(noms_blocks == "resBio") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1504 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1505 if(length(variablesSelect[[ind_resBio]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1506 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1507 res_variablesSelect[[ind_resBio]] = data.frame(variable = variablesSelect[[ind_resBio]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1508 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1509 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1510 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1511 ind_cyto = which(noms_blocks == "cyto") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1512 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1513 if(length(variablesSelect[[ind_cyto]]) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1514 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1515 res_variablesSelect[[ind_cyto]] = data.frame(variable = variablesSelect[[ind_cyto]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1516 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1517 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1518 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1519 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1520 return(res_variablesSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1521 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1522 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1523 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1524 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1525 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1526 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1527 # Integration 6 blocs norm gene ------------------------------------------- |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1528 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1529 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1530 # La fonction matriceCorrelation_comp calcule la matrice de corrélation entre les comp[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1531 # composantes de chaque bloc et la matrice de corrélation entre les comp[2] composantes de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1532 # chaque bloc. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1533 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1534 matriceCorrelation_comp <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1535 comp = 1:2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1536 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1537 vec_blocksTemp = res_block_splsda$names$blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1538 ind_Y = which(vec_blocksTemp == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1539 vec_blocks = vec_blocksTemp[- ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1540 vec_indice_blocks = sapply(1:length(vec_blocks), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1541 res = which(res_block_splsda$names$blocks == vec_blocks[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1542 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1543 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1544 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1545 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1546 # Calcul de la matrice de corrélations entre les comp[1] composantes de chaque bloc |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1547 # et de la matrice de corrélation entre les comp[2] composantes de chaque bloc. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1548 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1549 mat_comp1 = sapply(1:length(vec_indice_blocks), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1550 res = res_block_splsda$variates[[vec_indice_blocks[i]]][, comp[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1551 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1552 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1553 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1554 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1555 colnames(mat_comp1) = vec_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1556 mat_cor_comp1 = cor(mat_comp1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1557 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1558 mat_comp2 = sapply(1:length(vec_indice_blocks), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1559 res = res_block_splsda$variates[[vec_indice_blocks[i]]][, comp[2]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1560 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1561 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1562 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1563 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1564 colnames(mat_comp2) = vec_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1565 mat_cor_comp2 = cor(mat_comp2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1566 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1567 return(list(mat_cor_comp1 = mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1568 mat_cor_comp2 = mat_cor_comp2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1569 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1570 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1571 # La fonction matCor détermine toutes les combinaisons possibles des blocs |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1572 # dont nous pouvons superposer les cercles de corrélation. Cette fonction calcule, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1573 # pour chaque variable (variable d'un bloc ou une variable réponse), la corrélation de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1574 # cette variable avec la première composante et la corrélation de cette variable avec la |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1575 # deuxième composante. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1576 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1577 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1578 matCor <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1579 mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1580 mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1581 block_Y, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1582 comp = 1:2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1583 cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1584 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1585 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1586 noms_blocTemp = res_block_splsda$names$blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1587 ind_Y = which(noms_blocTemp == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1588 noms_bloc = noms_blocTemp[- ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1589 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1590 # Détermination de toutes les combinaisons possibles de blocs dont nous pouvons superposer |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1591 # les cercles de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1592 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1593 blockSelect = unique(lapply(1:dim(mat_cor_comp1)[1], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1594 col_mat_cor_comp1_i = mat_cor_comp1[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1595 col_mat_cor_comp2_i = mat_cor_comp2[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1596 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1597 resultat = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1598 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1599 for(j in 1:length(col_mat_cor_comp1_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1600 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1601 cond = abs(col_mat_cor_comp1_i[j]) > cutoff_comp & abs(col_mat_cor_comp2_i[j]) > cutoff_comp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1602 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1603 if(cond) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1604 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1605 resultat = c(resultat, j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1606 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1607 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1608 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1609 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1610 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1611 return(resultat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1612 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1613 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1614 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1615 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1616 liste_noms_blocks = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1617 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1618 for(i in 1:length(blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1619 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1620 blockSelect_i = blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1621 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1622 for(k in 1:length(blockSelect_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1623 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1624 matComb = combn(blockSelect_i, m = k) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1625 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1626 res = lapply(1:dim(matComb)[2], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1627 comb_i = matComb[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1628 resultat = noms_bloc[comb_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1629 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1630 return(resultat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1631 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1632 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1633 for(j in 1:length(res)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1634 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1635 liste_noms_blocks = c(liste_noms_blocks, list(res[[j]])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1636 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1637 } # Fin for(j in 1:length(liste_noms_blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1638 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1639 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1640 } # Fin for(k in 1:length(blockSelect_i)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1641 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1642 } # Fin for(i in 1:length(blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1643 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1644 liste_noms_blocks = unique(liste_noms_blocks) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1645 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1646 # Pour chaque bloc, calcul des corrélations entre la première |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1647 # composante et les variables sélectionnées et les corrélations entre |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1648 # la deuxième composante et les variables sélectionnées. Pour la réponse, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1649 # calcul de la corrélation entre les variables de la réponse et la première composante |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1650 # du premier bloc sélectionné et de la corrélation entre les variables de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1651 # la réponse et la deuxième composante du premier bloc sélectionné. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1652 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1653 liste_matCor_comp_var_all = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1654 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1655 varSelect_comp1 = selectVar(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1656 comp = comp[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1657 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1658 varSelect_comp2 = selectVar(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1659 comp = comp[2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1660 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1661 blockSelectEtReponse = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1662 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1663 for(i in 1:length(blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1664 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1665 blockSelectEtReponse[[i]] = c(blockSelect[[i]], which(res_block_splsda$names$blocks == "Y")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1666 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1667 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1668 } # Fin for(i in 1:length(blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1669 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1670 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1671 for(i in 1:length(blockSelectEtReponse)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1672 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1673 blockSelectEtReponse_i = blockSelectEtReponse[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1674 vec_nom_blockEtReponse = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1675 liste_matCor_comp_var = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1676 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1677 for(j in 1:length(blockSelectEtReponse_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1678 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1679 indice_block_i_j = blockSelectEtReponse_i[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1680 nom_blockEtReponse_i_j = res_block_splsda$names$blocks[indice_block_i_j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1681 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1682 if(nom_blockEtReponse_i_j == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1683 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1684 if(!is.null(block_Y)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1685 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1686 block_i_j = block_Y |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1687 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1688 comp1 = res_block_splsda$variates[[blockSelectEtReponse_i[1]]][, comp[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1689 comp2 = res_block_splsda$variates[[blockSelectEtReponse_i[1]]][, comp[2]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1690 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1691 vecCor_comp1_var = sapply(1:dim(block_Y)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1692 cor(comp1, block_Y[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1693 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1694 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1695 vecCor_comp2_var = sapply(1:dim(block_Y)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1696 cor(comp2, block_Y[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1697 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1698 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1699 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1700 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1701 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1702 cat("La réponse n'est pas saisie comme paramètre d'entrée", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1703 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1704 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1705 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1706 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1707 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1708 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1709 comp1 = res_block_splsda$variates[[indice_block_i_j]][, comp[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1710 comp2 = res_block_splsda$variates[[indice_block_i_j]][, comp[2]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1711 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1712 varSelect_comp1_i_j = varSelect_comp1[[indice_block_i_j]][[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1713 varSelect_comp2_i_j = varSelect_comp2[[indice_block_i_j]][[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1714 varSelect_i_j = unique(c(varSelect_comp1_i_j, varSelect_comp2_i_j)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1715 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1716 block_i_j = res_block_splsda$X[[indice_block_i_j]][, varSelect_i_j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1717 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1718 if(i == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1719 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1720 vecCor_comp1_var = sapply(1:dim(block_i_j)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1721 cor(comp1, block_i_j[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1722 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1723 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1724 vecCor_comp2_var = sapply(1:dim(block_i_j)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1725 cor(comp2, block_i_j[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1726 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1727 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1728 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1729 signeCor_comp1 = sign(mat_cor_comp1[1, indice_block_i_j]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1730 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1731 vecCor_comp1_var = sapply(1:dim(block_i_j)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1732 res = signeCor_comp1*cor(comp1, block_i_j[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1733 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1734 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1735 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1736 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1737 signeCor_comp2 = sign(mat_cor_comp2[1, indice_block_i_j]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1738 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1739 vecCor_comp2_var = sapply(1:dim(block_i_j)[2], FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1740 res = signeCor_comp2*cor(comp2, block_i_j[, j], use = "complete.obs") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1741 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1742 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1743 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1744 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1745 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1746 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1747 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1748 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1749 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1750 matCor_comp_var = rbind(vecCor_comp1_var, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1751 vecCor_comp2_var) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1752 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1753 colnames(matCor_comp_var) = colnames(block_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1754 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1755 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1756 liste_matCor_comp_var[[j]] = matCor_comp_var |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1757 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1758 vec_nom_blockEtReponse_i_j = rep(nom_blockEtReponse_i_j, dim(block_i_j)[2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1759 vec_nom_blockEtReponse = c(vec_nom_blockEtReponse, vec_nom_blockEtReponse_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1760 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1761 } # Fin for(j in 1:length(blockSelectEtReponse_i)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1762 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1763 matCor_Allcomp_Allvar = t(Reduce(cbind, liste_matCor_comp_var)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1764 dataframe_Cor_Allcomp_Allvar = data.frame(cbind(rownames(matCor_Allcomp_Allvar), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1765 vec_nom_blockEtReponse, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1766 matCor_Allcomp_Allvar)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1767 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1768 colnames(dataframe_Cor_Allcomp_Allvar) = c("variable", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1769 "bloc", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1770 "cor_comp1_var", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1771 "cor_comp2_var") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1772 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1773 liste_matCor_comp_var_all[[i]] = dataframe_Cor_Allcomp_Allvar |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1774 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1775 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1776 } # Fin for(i in 1:length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1777 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1778 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1779 names(liste_matCor_comp_var_all) = sapply(1:length(blockSelectEtReponse), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1780 blockSelectEtReponse_i = blockSelectEtReponse[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1781 blocks_i = blockSelectEtReponse_i[blockSelectEtReponse_i != ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1782 nomsBlocks = paste(res_block_splsda$names$blocks[blocks_i], collapse = "_") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1783 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1784 return(nomsBlocks) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1785 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1786 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1787 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1788 return(list(liste_matCor_comp_var_all = liste_matCor_comp_var_all, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1789 liste_noms_blocks = liste_noms_blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1790 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1791 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1792 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1793 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1794 # La fonction circleCorZoom permet superposer des cercles de corrélations et de zoomer un rectangle du cercle de corrélations. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1795 # Cette fonction permet de récupérer les variables contenues dans ce rectangle. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1796 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1797 circleCorZoom <-function(dataframe_Cor_Allcomp_Allvar, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1798 mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1799 mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1800 nomsBlock, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1801 comp = 1:2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1802 cutoff = 0.85, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1803 cutoff_comp = 0.8, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1804 min.X = -1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1805 max.X = 1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1806 min.Y = -1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1807 max.Y = 1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1808 vec_col = colorRampPalette(brewer.pal(9, "Spectral"))(length(unique(dataframe_Cor_Allcomp_Allvar$bloc))), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1809 rad.in = 0.5, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1810 cex = 0.7, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1811 cex_legend = 0.8, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1812 pos = c(1.2, 0), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1813 pch = 20, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1814 inset = c(-0.25, 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1815 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1816 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1817 # Nous vérifions que nous pouvons superposer les cercles de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1818 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1819 blockSelect = unique(lapply(1:dim(mat_cor_comp1)[1], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1820 col_mat_cor_comp1_i = mat_cor_comp1[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1821 col_mat_cor_comp2_i = mat_cor_comp2[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1822 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1823 resultat = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1824 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1825 for(j in 1:length(col_mat_cor_comp1_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1826 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1827 cond = abs(col_mat_cor_comp1_i[j]) > cutoff_comp & abs(col_mat_cor_comp2_i[j]) > cutoff_comp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1828 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1829 if(cond) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1830 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1831 resultat = c(resultat, j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1832 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1833 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1834 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1835 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1836 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1837 return(resultat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1838 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1839 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1840 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1841 indice_block_nomsBlock = sapply(1:length(nomsBlock), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1842 res = which(colnames(mat_cor_comp1) == nomsBlock[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1843 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1844 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1845 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1846 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1847 boolean = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1848 i = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1849 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1850 while(i <=length(blockSelect) & !boolean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1851 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1852 blockSelect_i = blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1853 cond = length(which(blockSelect_i%in%indice_block_nomsBlock == TRUE)) == length(nomsBlock) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1854 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1855 if(cond) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1856 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1857 boolean = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1858 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1859 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1860 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1861 i = i + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1862 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1863 } # Fin while(i <=length(blockSelect) & !boolean). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1864 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1865 varSelect = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1866 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1867 if(!boolean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1868 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1869 cat(paste0("Erreur : les blocs : ", paste(nomsBlock, collapse = ", "), " ne peuvent pas être superposés.", "\n")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1870 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1871 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1872 nomsBlockEtReponse = c(nomsBlock, "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1873 indice1 = dataframe_Cor_Allcomp_Allvar$bloc%in%nomsBlockEtReponse |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1874 dataframe_Cor_Allcomp_Allvar2 = dataframe_Cor_Allcomp_Allvar[indice1, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1875 matCor_Allcomp_Allvar = apply(dataframe_Cor_Allcomp_Allvar2[, 3:4], 2, as.numeric) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1876 rownames(matCor_Allcomp_Allvar) = dataframe_Cor_Allcomp_Allvar2$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1877 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1878 # indice permet de récupérer les variables de chaque bloc fortement corrélées avec soit |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1879 # la première composante ou la deuxième composante dans une partie du cercle de corrélation |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1880 # et de récupérer la variable réponse. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1881 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1882 indice = sapply(1:dim(dataframe_Cor_Allcomp_Allvar2)[1], FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1883 cor1 = matCor_Allcomp_Allvar[k, 1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1884 cor2 = matCor_Allcomp_Allvar[k, 2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1885 blockEtReponse_k = dataframe_Cor_Allcomp_Allvar2[k, 2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1886 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1887 if(blockEtReponse_k == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1888 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1889 cond2 = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1890 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1891 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1892 cond1 = abs(cor1) > cutoff | abs(cor2) > cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1893 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1894 cond2 = cor1 > min.X & cor1 < max.X & cor2 > min.Y & cor2 < max.Y & cond1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1895 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1896 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1897 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1898 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1899 return(cond2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1900 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1901 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1902 dataframe_Cor_Allcomp_Allvar2[, 1:2] = apply(dataframe_Cor_Allcomp_Allvar2[, 1:2], 2, as.character) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1903 dataframe_Cor_Allcomp_Allvar2Select = dataframe_Cor_Allcomp_Allvar2[indice, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1904 varSelectTemp = dataframe_Cor_Allcomp_Allvar2Select$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1905 ind_Y = which(dataframe_Cor_Allcomp_Allvar2Select$bloc == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1906 if(length(ind_Y) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1907 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1908 varSelect = varSelectTemp[- ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1909 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1910 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1911 varSelect = varSelectTemp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1912 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1913 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1914 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1915 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1916 matCor_Allcomp_AllvarSelect = matCor_Allcomp_Allvar[indice, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1917 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1918 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1919 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1920 # Tracé de la superposition des cerles de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1921 circle = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1922 circle[[1]] = ellipse(0, levels = 1, t = 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1923 circle[[2]] = ellipse(0, levels = 1, t = rad.in) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1924 circle = data.frame(do.call("rbind", circle), "Circle" = c(rep("Main circle", 100), rep("Inner circle", 100))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1925 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1926 MainCircle = circle[grep("Main circle", circle[, 3]), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1927 InnerCircle = circle[grep("Inner circle", circle[, 3]), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1928 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1929 plot(MainCircle[, 1], MainCircle[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1930 type = "l", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1931 xlab = paste0("composante ", comp[1]), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1932 ylab = paste0("composante ", comp[2])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1933 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1934 points(InnerCircle[, 1], InnerCircle[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1935 type = "l") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1936 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1937 if(dim(matCor_Allcomp_AllvarSelect)[1] != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1938 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1939 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1940 nom_blockEtReponseSelect = unique(dataframe_Cor_Allcomp_Allvar2Select$bloc) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1941 indice_blockEtReponseSelect = sapply(1:length(nom_blockEtReponseSelect), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1942 ind = which(colnames(mat_cor_comp1) == nom_blockEtReponseSelect[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1943 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1944 if(length(ind) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1945 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1946 res = ind |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1947 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1948 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1949 res = dim(mat_cor_comp1)[1] + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1950 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1951 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1952 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1953 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1954 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1955 vec_colSelect = vec_col[indice_blockEtReponseSelect] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1956 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1957 if(length(nom_blockEtReponseSelect) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1958 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1959 points(matCor_Allcomp_AllvarSelect[, 1], matCor_Allcomp_AllvarSelect[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1960 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1961 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1962 text(matCor_Allcomp_AllvarSelect[, 1], matCor_Allcomp_AllvarSelect[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1963 labels = rownames(matCor_Allcomp_AllvarSelect), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1964 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1965 col = vec_colSelect[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1966 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1967 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1968 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1969 nbVarSelect_bloc = cumsum(sapply(1:length(nom_blockEtReponseSelect), FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1970 res = length(which(dataframe_Cor_Allcomp_Allvar2Select$bloc == nom_blockEtReponseSelect[j])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1971 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1972 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1973 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1974 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1975 for(i in 1:length(nbVarSelect_bloc)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1976 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1977 if(i == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1978 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1979 indice1 = 1:nbVarSelect_bloc[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1980 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1981 if(length(indice1) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1982 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1983 matCor_Allcomp_AllvarSelect2 = matCor_Allcomp_AllvarSelect[indice1, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1984 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1985 points(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1986 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1987 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1988 text(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1989 labels = rownames(matCor_Allcomp_AllvarSelect2), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1990 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1991 col = rep(vec_colSelect[i], dim(matCor_Allcomp_AllvarSelect2)[1])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1992 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1993 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1994 cat(paste0("Il n'y a de variables dans cette zone du cercle de corrélation pour le bloc ", nom_blockEtReponseSelect[i]), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1995 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1996 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1997 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1998 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
1999 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2000 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2001 indice2 = (nbVarSelect_bloc[i - 1] + 1):nbVarSelect_bloc[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2002 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2003 if(length(indice2) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2004 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2005 matCor_Allcomp_AllvarSelect2 = matCor_Allcomp_AllvarSelect[indice2, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2006 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2007 points(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2008 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2009 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2010 text(matCor_Allcomp_AllvarSelect2[, 1], matCor_Allcomp_AllvarSelect2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2011 labels = rownames(matCor_Allcomp_AllvarSelect2), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2012 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2013 col = rep(vec_colSelect[i], dim(matCor_Allcomp_AllvarSelect2)[1])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2014 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2015 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2016 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2017 cat(paste0("Il n'y a de variables dans cette zone du cercle de corrélation pour le bloc ", nom_blockEtReponseSelect[i]), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2018 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2019 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2020 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2021 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2022 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2023 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2024 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2025 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2026 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2027 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2028 par(xpd = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2029 legend(x = pos[1], y = pos[2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2030 legend = nom_blockEtReponseSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2031 pch = pch, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2032 col = vec_colSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2033 cex = cex_legend, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2034 inset = inset) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2035 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2036 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2037 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2038 cat("Il n'y a de variables dans cette zone du cercle de corrélation", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2039 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2040 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2041 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2042 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2043 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2044 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2045 return(varSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2046 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2047 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2048 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2049 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2050 # La fonction networkVariable permet de tracer un réseau pour les variables de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2051 # certains blocs et une variable réponse. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2052 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2053 networkVariable <-function(dataframe_Cor_Allcomp_Allvar, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2054 vec_Var, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2055 nomVar_block_Y, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2056 comp = 1:2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2057 cutoff = 0 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2058 ) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2059 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2060 # Pour chaque variable de vec_Var et la variable réponse, nous récupérons les noms des blocs, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2061 # les corrélations entre la variable et chaque composante. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2062 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2063 ind = which(dataframe_Cor_Allcomp_Allvar$variable%in%vec_Var == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2064 ind_Var_block_Y = which(dataframe_Cor_Allcomp_Allvar$variable == nomVar_block_Y) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2065 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2066 dataframe_Cor_Allcomp_AllvarSelect = dataframe_Cor_Allcomp_Allvar[c(ind, ind_Var_block_Y), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2067 nomBlocs = unique(dataframe_Cor_Allcomp_AllvarSelect$bloc) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2068 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2069 if((length(ind) == length(vec_Var)) & length(ind_Var_block_Y) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2070 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2071 if(length(nomBlocs) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2072 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2073 cat("Erreur : il n'y a des variables d'un seul bloc dans listeVar", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2074 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2075 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2076 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2077 liste_Cor_Allcomp_Allvar_bloc = lapply(1:length(nomBlocs), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2078 nomBloc_i = nomBlocs[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2079 indice = which(dataframe_Cor_Allcomp_AllvarSelect$bloc == nomBloc_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2080 resTemp = dataframe_Cor_Allcomp_AllvarSelect[indice, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2081 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2082 if(length(indice) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2083 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2084 res = resTemp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2085 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2086 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2087 res = resTemp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2088 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2089 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2090 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2091 rownames(res) = resTemp$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2092 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2093 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2094 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2095 names(liste_Cor_Allcomp_Allvar_bloc) = nomBlocs |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2096 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2097 coord = lapply(1:length(liste_Cor_Allcomp_Allvar_bloc), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2098 resTemp = liste_Cor_Allcomp_Allvar_bloc[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2099 res = apply(resTemp[, comp + 2, drop = FALSE], 2, as.numeric) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2100 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2101 if(dim(resTemp)[1] == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2102 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2103 res = matrix(res, nrow = 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2104 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2105 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2106 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2107 rownames(res) = resTemp$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2108 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2109 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2110 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2111 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2112 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2113 l = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2114 M_block = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2115 node.X1 = node.X2 = w = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2116 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2117 # Calcul de la similarité. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2118 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2119 for(j in 1:(length(nomBlocs) - 1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2120 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2121 for(k in (j + 1):length(nomBlocs)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2122 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2123 M_block[[l]] = coord[[j]][, drop = FALSE] %*% t(coord[[k]][, drop = FALSE]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2124 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2125 X1 = rownames(coord[[j]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2126 X2 = rownames(coord[[k]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2127 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2128 rep.X1 = rep(X1, each = length(X2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2129 rep.X2 = rep(X2, length(X1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2130 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2131 node.X1= c(node.X1, rep.X1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2132 node.X2 = c(node.X2, rep.X2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2133 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2134 w = c(w, as.vector(t(M_block[[l]]))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2135 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2136 l = l + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2137 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2138 } # Fin for(k in (j + 1):length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2139 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2140 } # Fin for(j in 1:(length(blocks) - 1)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2141 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2142 # nodes |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2143 group = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2144 temp = lapply(1:length(liste_Cor_Allcomp_Allvar_bloc), function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2145 res = liste_Cor_Allcomp_Allvar_bloc[[i]]$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2146 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2147 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2148 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2149 names(temp) = names(liste_Cor_Allcomp_Allvar_bloc) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2150 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2151 for (i in 1:length(temp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2152 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2153 group = c(group, rep(names(temp)[i], length(temp[[i]]))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2154 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2155 } # Fin for (i in 1:length(temp)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2156 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2157 nodes = data.frame(name = unlist(temp), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2158 group = group) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2159 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2160 # gR |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2161 relations = data.frame(from = node.X1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2162 to = node.X2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2163 weight = w) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2164 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2165 idx = (abs(w) >= cutoff) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2166 relations = relations[idx, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2167 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2168 gR = graph.data.frame(relations, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2169 directed = FALSE, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2170 vertices = nodes) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2171 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2172 gR = delete.vertices(gR, which(degree(gR) == 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2173 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2174 res = list(gR = gR) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2175 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2176 l = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2177 for (i in 1:(length(nomBlocs)-1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2178 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2179 for (j in (i + 1):length(nomBlocs)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2180 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2181 res[paste("M", names(liste_Cor_Allcomp_Allvar_bloc)[i], names(liste_Cor_Allcomp_Allvar_bloc)[j], sep="_")] = list(M_block[[l]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2182 l = l + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2183 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2184 } # Fin for (j in (i + 1):length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2185 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2186 } # Fin for (i in 1:(length(blocks)-1). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2187 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2188 res$cutoff = cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2189 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2190 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2191 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2192 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2193 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2194 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2195 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2196 # Fin if((length(which(ind))= length(listeVar)) & length(ind_Var_block_Y) == 1). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2197 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2198 if(length(ind) != length(vec_Var)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2199 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2200 cat("Erreur : les variables de vec_Var ne sont pas contenues dans dataframe_Cor_Allcomp_Allvar$variable.", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2201 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2202 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2203 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2204 if(length(ind_Var_block_Y) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2205 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2206 cat(paste0("Erreur : la variable réponse ", nomVar_block_Y," n'est pas contenue dans dataframe_Cor_Allcomp_Allvar$variable."), "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2207 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2208 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2209 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2210 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2211 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2212 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2213 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2214 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2215 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2216 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2217 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2218 # Integration 7 blocs norm gene ------------------------------------------- |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2219 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2220 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2221 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2222 # La fonction compute_cor_comp_var calcule, pour chaque variable d'un bloc, les corrélations |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2223 # entre la variable et les composantes sélectionnées par comp. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2224 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2225 compute_cor_comp_var <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2226 comp = c(1:2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2227 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2228 vec_blocksTemp = res_block_splsda$names$blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2229 ind_Y = which(vec_blocksTemp == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2230 vec_blocks1 = vec_blocksTemp[- ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2231 vec_indice_blocks = sapply(1:length(vec_blocks1), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2232 res = which(res_block_splsda$names$blocks == vec_blocks1[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2233 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2234 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2235 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2236 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2237 # Calcul, pour chaque variable d'un bloc, des corrélations de cette variable avec |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2238 # les composantes dont les indices sont indiqués dans le vecteur comp. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2239 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2240 vec_blocks2 = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2241 liste_cor_comp_var_global = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2242 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2243 for(i in 1:length(vec_indice_blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2244 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2245 indice_blocks_i = vec_indice_blocks[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2246 block_i = res_block_splsda$names$blocks[indice_blocks_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2247 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2248 vec_varSelect_i = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2249 liste_comp_i = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2250 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2251 for(j in 1:length(comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2252 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2253 indice_comp_j = comp[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2254 liste_comp_i[[j]] = res_block_splsda$variates[[indice_blocks_i]][, indice_comp_j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2255 vec_varSelect_comp_j = selectVar(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2256 comp = indice_comp_j)[[indice_blocks_i]][[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2257 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2258 vec_varSelect_i = c(vec_varSelect_i, vec_varSelect_comp_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2259 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2260 } # Fin for(j in 1:length(comp)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2261 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2262 vec_varSelect_i = unique(vec_varSelect_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2263 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2264 mat_block_i = res_block_splsda$X[[indice_blocks_i]][, vec_varSelect_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2265 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2266 liste_cor_comp_var = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2267 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2268 for(j in 1:length(liste_comp_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2269 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2270 liste_cor_comp_var[[j]] = sapply(1:dim(mat_block_i)[2], FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2271 cor(liste_comp_i[[j]], mat_block_i[, k]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2272 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2273 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2274 } # Fin for(j in 1:length(liste_comp_i)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2275 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2276 mat_cor_Allcomp_Allvar = Reduce(cbind, liste_cor_comp_var) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2277 rownames(mat_cor_Allcomp_Allvar) = colnames(mat_block_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2278 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2279 vec_blocks_i = rep(block_i, dim(mat_block_i)[2]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2280 vec_blocks2 = c(vec_blocks2, vec_blocks_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2281 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2282 liste_cor_comp_var_global[[i]] = mat_cor_Allcomp_Allvar |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2283 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2284 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2285 } # Fin for(i in 1:length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2286 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2287 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2288 mat_cor_comp_var_global = Reduce(rbind, liste_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2289 dataframe_cor_comp_var_global = data.frame(cbind(rownames(mat_cor_comp_var_global), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2290 vec_blocks2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2291 mat_cor_comp_var_global)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2292 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2293 colnames(dataframe_cor_comp_var_global) = c("variable", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2294 "bloc", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2295 paste0("cor_var_comp", comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2296 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2297 dataframe_cor_comp_var_global[, 1:2] = apply(dataframe_cor_comp_var_global[, 1:2], 2, as.character) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2298 dataframe_cor_comp_var_global[, 3:dim(dataframe_cor_comp_var_global)[2]] = apply(dataframe_cor_comp_var_global[, 3:dim(dataframe_cor_comp_var_global)[2]], 2, as.numeric) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2299 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2300 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2301 return(dataframe_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2302 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2303 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2304 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2305 # La fonction composanteColin renvoie une liste. Le ième élément de cette liste |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2306 # contient les indices des blocs tels que, pour chaque paire de ces blocs, la |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2307 # première composante du bloc 1 est fortement corrélée à la première composante |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2308 # du bloc2 en valeur absolue et la deuxième composante du bloc 1 est fortement |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2309 # corrélée à la deuxième composante du bloc2 en valeur absolue. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2310 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2311 composanteColin <-function(mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2312 mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2313 cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2314 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2315 res = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2316 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2317 index = 1:dim(mat_cor_comp1)[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2318 i = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2319 compt = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2320 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2321 while(length(index) != 0 & compt <= dim(mat_cor_comp1)[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2322 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2323 index_i = index[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2324 res[[compt]] = c(index_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2325 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2326 index2 = index[-i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2327 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2328 if(length(index2) != 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2329 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2330 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2331 for(j in index2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2332 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2333 if(length(res[[compt]]) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2334 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2335 if(abs(mat_cor_comp1[j, index_i]) > cutoff_comp & abs(mat_cor_comp2[j, index_i]) > cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2336 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2337 res[[compt]] = c(res[[compt]], j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2338 index = index[- c(which(index == j))] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2339 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2340 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2341 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2342 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2343 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2344 indice = sapply(1:length(res[[compt]]), FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2345 index_k = res[[compt]][k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2346 cond = abs(mat_cor_comp1[index_k, j]) > cutoff_comp & abs(mat_cor_comp2[index_k, j]) > cutoff_comp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2347 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2348 return(cond) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2349 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2350 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2351 if(all(indice)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2352 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2353 res[[compt]] = c(res[[compt]], j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2354 index = index[- c(which(index == j))] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2355 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2356 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2357 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2358 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2359 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2360 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2361 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2362 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2363 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2364 res[[compt]] = index_i |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2365 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2366 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2367 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2368 index = index[- c(which(index == index_i))] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2369 compt = compt + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2370 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2371 } # Fin for(i in 1:dim(mat_cor_comp1)[2]). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2372 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2373 if(length(index) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2374 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2375 for(i in 1:length(index)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2376 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2377 res = c(res, list(index[i])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2378 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2379 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2380 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2381 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2382 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2383 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2384 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2385 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2386 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2387 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2388 # La fonction compute_blockSelect permet de déterminer toutes les combinaisons |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2389 # possibles des blocs qui peuvent être superposés dans le cercle de corrélations |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2390 # et dont les variables peuvent être présentes dans le réseau. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2391 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2392 compute_blockSelect <-function(mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2393 mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2394 cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2395 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2396 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2397 liste_vec_indice_blockSelect = composanteColin(mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2398 mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2399 cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2400 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2401 vec_blocks = colnames(mat_cor_comp1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2402 liste_vec_blocks = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2403 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2404 # liste_blocks est une liste contenant toutes les combinaisons possibles de blocs dont |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2405 # on peut superposer les cercles de corrélations et dont les variables peuvent être |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2406 # présentes dans le réseau. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2407 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2408 for(i in 1:length(liste_vec_indice_blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2409 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2410 vec_indice_blockSelect_i = liste_vec_indice_blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2411 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2412 for(k in 1:length(vec_indice_blockSelect_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2413 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2414 matComb = combn(vec_indice_blockSelect_i, m = k) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2415 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2416 liste_vec_blocks_i = lapply(1:dim(matComb)[2], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2417 comb_i = matComb[, i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2418 resultat = vec_blocks[comb_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2419 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2420 return(resultat) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2421 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2422 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2423 for(j in 1:length(liste_vec_blocks_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2424 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2425 liste_vec_blocks = c(liste_vec_blocks, list(liste_vec_blocks_i[[j]])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2426 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2427 } # Fin for(j in 1:length(liste_noms_blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2428 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2429 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2430 } # Fin for(k in 1:length(blockSelect_i)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2431 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2432 } # Fin for(i in 1:length(blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2433 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2434 liste_vec_blocks = unique(liste_vec_blocks) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2435 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2436 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2437 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2438 return(list(liste_vec_indice_blockSelect = liste_vec_indice_blockSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2439 liste_vec_blocks = liste_vec_blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2440 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2441 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2442 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2443 # La fonction matCorEtBlockSelect permet de calculer la matrice de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2444 # corrélation entre les comp[1] composantes de chaque bloc et la |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2445 # matrice de corrélation entre les comp[2] composantes de chaque |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2446 # bloc. Elle permet aussi de calculer, pour chaque variable d'un bloc, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2447 # les corrélations entre les composantes comp[1] et comp[2] et cette variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2448 # et de calculer toutes les combinaisons possibles des blocs pour lesquels nous |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2449 # pouvons superposer les cercles de corrélations. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2450 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2451 matCorEtBlockSelect <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2452 cutoff_comp, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2453 comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2454 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2455 liste_mat_cor_comp = matriceCorrelation_comp(res_block_splsda = res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2456 comp = comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2457 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2458 mat_cor_comp1 = liste_mat_cor_comp$mat_cor_comp1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2459 mat_cor_comp2 = liste_mat_cor_comp$mat_cor_comp2 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2460 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2461 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2462 dataframe_cor_comp_var_global = compute_cor_comp_var(res_block_splsda = res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2463 comp = comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2464 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2465 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2466 liste_blockSelect = compute_blockSelect(mat_cor_comp1 = mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2467 mat_cor_comp2 = mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2468 cutoff_comp = cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2469 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2470 liste_vec_indice_blockSelect = liste_blockSelect$liste_vec_indice_blockSelect |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2471 liste_vec_blocks = liste_blockSelect$liste_vec_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2472 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2473 return(list(mat_cor_comp1 = mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2474 mat_cor_comp2 = mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2475 dataframe_cor_comp_var_global = dataframe_cor_comp_var_global, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2476 liste_vec_indice_blockSelect = liste_vec_indice_blockSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2477 liste_vec_blocks = liste_vec_blocks)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2478 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2479 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2480 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2481 # La fonction addVariablesReponses permet de calculer, pour chaque |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2482 # variable réponse, la corrélation entre cette variable et la |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2483 # comp[1] composante et la corrélation entre cette variable et la comp[2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2484 # composante pour chaque groupe de blocs. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2485 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2486 addVariablesReponses <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2487 dataframe_cor_comp_var_global, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2488 liste_vec_indice_blockSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2489 mat_block_Y) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2490 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2491 # On récupère les indices des composantes utilisées pour calculer les |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2492 # corrélations entre les variables des blocs et les composantes. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2493 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2494 comp = as.numeric(sapply(3:4, FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2495 col_i = colnames(dataframe_cor_comp_var_global)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2496 ch = strsplit(col_i, split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2497 resTemp = ch[length(ch)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2498 res = substring(resTemp, nchar(resTemp), nchar(resTemp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2499 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2500 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2501 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2502 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2503 # On calcule, pour chaque variable réponse, pour chaque composante du premier |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2504 # bloc du groupe de blocs, la corrélation entre cette variable réponse et la composante. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2505 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2506 liste_dataframe_cor_allcomp_varReponses = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2507 vec_groupe_blocks = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2508 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2509 for(i in 1:length(liste_vec_indice_blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2510 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2511 vec_indice_blockSelect_i = liste_vec_indice_blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2512 indice_first_block_i = vec_indice_blockSelect_i[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2513 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2514 liste_comp_i = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2515 liste_cor_comp_var = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2516 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2517 for(j in 1:length(comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2518 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2519 indice_comp_j = comp[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2520 comp_j = res_block_splsda$variates[[indice_first_block_i]][, indice_comp_j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2521 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2522 liste_cor_comp_var[[j]] = sapply(1:dim(mat_block_Y)[2], FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2523 cor(comp_j, mat_block_Y[, k]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2524 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2525 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2526 } # Fin for(j in 1:length(liste_comp_i)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2527 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2528 mat_cor_allcomp_varReponses = Reduce(cbind, liste_cor_comp_var) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2529 rownames(mat_cor_allcomp_varReponses) = colnames(mat_block_Y) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2530 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2531 dataframe_allcomp_varReponses = data.frame(colnames(mat_block_Y), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2532 rep("Y", dim(mat_block_Y)[2]), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2533 mat_cor_allcomp_varReponses) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2534 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2535 colnames(dataframe_allcomp_varReponses) = c("variable", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2536 "bloc", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2537 paste0("cor_var_comp", comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2538 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2539 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2540 liste_dataframe_cor_allcomp_varReponses[[i]] = dataframe_allcomp_varReponses |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2541 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2542 groupe_blocks_i = res_block_splsda$names$blocks[vec_indice_blockSelect_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2543 vec_groupe_blocks = c(vec_groupe_blocks, paste(groupe_blocks_i, collapse = "-")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2544 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2545 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2546 } # Fin for(in in 1:length(blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2547 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2548 names(liste_dataframe_cor_allcomp_varReponses) = vec_groupe_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2549 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2550 liste_dataframe_cor_comp_var_global = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2551 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2552 for(i in 1:length(liste_vec_indice_blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2553 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2554 vec_indice_blockSelect_i = liste_vec_indice_blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2555 groupe_blocks_i = res_block_splsda$names$blocks[vec_indice_blockSelect_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2556 indice_i = which(dataframe_cor_comp_var_global$bloc%in%groupe_blocks_i == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2557 dataframe_cor_comp_var_global_indice_i = dataframe_cor_comp_var_global[indice_i, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2558 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2559 dataframe_cor_comp_varBlockEtVarRep_global = rbind(dataframe_cor_comp_var_global_indice_i, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2560 liste_dataframe_cor_allcomp_varReponses[[i]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2561 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2562 dataframe_cor_comp_varBlockEtVarRep_global[, 1:2] = apply(dataframe_cor_comp_varBlockEtVarRep_global[, 1:2], 2, as.character) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2563 dataframe_cor_comp_varBlockEtVarRep_global[, 3:dim(dataframe_cor_comp_varBlockEtVarRep_global)[2]] = apply(dataframe_cor_comp_varBlockEtVarRep_global[, 3:dim(dataframe_cor_comp_varBlockEtVarRep_global)[2]], 2, as.numeric) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2564 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2565 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2566 liste_dataframe_cor_comp_var_global[[i]] = dataframe_cor_comp_varBlockEtVarRep_global |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2567 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2568 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2569 } # Fin for(i in 1:length(indice_blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2570 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2571 names(liste_dataframe_cor_comp_var_global) = vec_groupe_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2572 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2573 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2574 return(liste_dataframe_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2575 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2576 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2577 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2578 # La fonction addVariablesReponsesModified permet de calculer, pour chaque |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2579 # variable réponse, la corrélation entre cette variable et la |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2580 # comp[1] composante et la corrélation entre cette variable et la comp[2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2581 # composante pour chaque groupe de blocs. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2582 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2583 addVariablesReponsesModified <-function(res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2584 dataframe_cor_comp_var_global, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2585 liste_vec_indice_blockSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2586 mat_block_Y) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2587 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2588 # On récupère les indices des composantes utilisées pour calculer les |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2589 # corrélations entre les variables des blocs et les composantes. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2590 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2591 comp = as.numeric(sapply(3:4, FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2592 col_i = colnames(dataframe_cor_comp_var_global)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2593 ch = strsplit(col_i, split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2594 resTemp = ch[length(ch)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2595 res = substring(resTemp, nchar(resTemp), nchar(resTemp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2596 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2597 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2598 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2599 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2600 # On calcule, pour chaque variable réponse, pour chaque composante du premier |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2601 # bloc du groupe de blocs, la corrélation entre cette variable réponse et la composante. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2602 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2603 liste_dataframe_cor_allcomp_varReponses = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2604 vec_groupe_blocks = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2605 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2606 for(i in 1:length(liste_vec_indice_blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2607 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2608 vec_indice_blockSelect_i = liste_vec_indice_blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2609 indice_first_block_i = vec_indice_blockSelect_i[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2610 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2611 liste_comp_i = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2612 liste_cor_comp_var = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2613 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2614 for(j in 1:length(comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2615 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2616 indice_comp_j = comp[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2617 comp_j = res_block_splsda$variates[[indice_first_block_i]][, indice_comp_j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2618 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2619 liste_cor_comp_var[[j]] = sapply(1:dim(mat_block_Y)[2], FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2620 resTemp = comp_j%*%mat_block_Y[, k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2621 res = resTemp/(norm(comp_j - mean(comp_j), "2")*norm(mat_block_Y[, k], "2")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2622 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2623 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2624 } # Fin for(j in 1:length(liste_comp_i)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2625 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2626 mat_cor_allcomp_varReponses = Reduce(cbind, liste_cor_comp_var) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2627 rownames(mat_cor_allcomp_varReponses) = colnames(mat_block_Y) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2628 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2629 dataframe_allcomp_varReponses = data.frame(colnames(mat_block_Y), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2630 rep("Y", dim(mat_block_Y)[2]), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2631 mat_cor_allcomp_varReponses) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2632 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2633 colnames(dataframe_allcomp_varReponses) = c("variable", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2634 "bloc", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2635 paste0("cor_var_comp", comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2636 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2637 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2638 liste_dataframe_cor_allcomp_varReponses[[i]] = dataframe_allcomp_varReponses |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2639 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2640 groupe_blocks_i = res_block_splsda$names$blocks[vec_indice_blockSelect_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2641 vec_groupe_blocks = c(vec_groupe_blocks, paste(groupe_blocks_i, collapse = "-")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2642 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2643 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2644 } # Fin for(in in 1:length(blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2645 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2646 names(liste_dataframe_cor_allcomp_varReponses) = vec_groupe_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2647 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2648 liste_dataframe_cor_comp_var_global = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2649 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2650 for(i in 1:length(liste_vec_indice_blockSelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2651 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2652 vec_indice_blockSelect_i = liste_vec_indice_blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2653 groupe_blocks_i = res_block_splsda$names$blocks[vec_indice_blockSelect_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2654 indice_i = which(dataframe_cor_comp_var_global$bloc%in%groupe_blocks_i == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2655 dataframe_cor_comp_var_global_indice_i = dataframe_cor_comp_var_global[indice_i, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2656 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2657 dataframe_cor_comp_varBlockEtVarRep_global = rbind(dataframe_cor_comp_var_global_indice_i, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2658 liste_dataframe_cor_allcomp_varReponses[[i]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2659 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2660 dataframe_cor_comp_varBlockEtVarRep_global[, 1:2] = apply(dataframe_cor_comp_varBlockEtVarRep_global[, 1:2], 2, as.character) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2661 dataframe_cor_comp_varBlockEtVarRep_global[, 3:dim(dataframe_cor_comp_varBlockEtVarRep_global)[2]] = apply(dataframe_cor_comp_varBlockEtVarRep_global[, 3:dim(dataframe_cor_comp_varBlockEtVarRep_global)[2]], 2, as.numeric) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2662 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2663 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2664 liste_dataframe_cor_comp_var_global[[i]] = dataframe_cor_comp_varBlockEtVarRep_global |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2665 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2666 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2667 } # Fin for(i in 1:length(indice_blockSelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2668 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2669 names(liste_dataframe_cor_comp_var_global) = vec_groupe_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2670 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2671 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2672 return(liste_dataframe_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2673 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2674 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2675 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2676 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2677 # La fonction circleCor permet de zoomer sur un rectangle du cercle de corrélations |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2678 # et de récupérer les variables des blocs dans cette partie zoomée du cercle de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2679 # corrélations. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2680 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2681 circleCor <-function(liste_dataframe_cor_comp_var_global, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2682 liste_vec_indice_blockSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2683 mat_cor_comp1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2684 mat_cor_comp2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2685 vec_blocks, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2686 nomsVarReponses, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2687 cutoff = 0.85, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2688 min.X = -1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2689 max.X = 1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2690 min.Y = -1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2691 max.Y = 1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2692 vec_col = colorRampPalette(brewer.pal(9, "Spectral"))(dim(mat_cor_comp1)[1] + 1), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2693 rad.in = 0.5, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2694 cex = 0.7, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2695 cex_legend = 0.8, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2696 pos = c(1.2, 0), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2697 pch = 20, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2698 inset = c(-0.25, 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2699 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2700 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2701 # On vérifie que nous pouvons superposer les cercles de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2702 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2703 vec_indice_blocks = sapply(1:length(vec_blocks), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2704 res = which(colnames(mat_cor_comp1) == vec_blocks[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2705 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2706 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2707 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2708 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2709 boolean = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2710 i = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2711 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2712 while(i <= length(liste_vec_indice_blockSelect) & !boolean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2713 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2714 vec_indice_blockSelect_i = liste_vec_indice_blockSelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2715 cond = length(which(vec_indice_blockSelect_i%in%vec_indice_blocks == TRUE)) == length(vec_blocks) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2716 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2717 if(cond) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2718 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2719 boolean = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2720 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2721 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2722 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2723 i = i + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2724 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2725 } # Fin while(i <= length(liste_vec_indice_blockSelect) & !boolean). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2726 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2727 varSelect = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2728 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2729 if(!boolean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2730 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2731 stop(paste0("The blocks : ", paste(vec_blocks, collapse = ", "), " can not be superimposed.")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2732 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2733 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2734 # On récupère le groupe de blocs auxquels appartient vec_blocks. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2735 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2736 indice_nomsBlock = sapply(1:length(liste_dataframe_cor_comp_var_global), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2737 name_iTemp = names(liste_dataframe_cor_comp_var_global)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2738 name_i = strsplit(name_iTemp, split = "-")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2739 res = all(vec_blocks%in%name_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2740 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2741 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2742 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2743 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2744 dataframe_cor_comp_var_global = liste_dataframe_cor_comp_var_global[[which(indice_nomsBlock == TRUE)]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2745 dataframe_cor_comp_var_globalTemp1 = dataframe_cor_comp_var_global |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2746 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2747 indice_nomsVarReponses = all(nomsVarReponses%in%dataframe_cor_comp_var_globalTemp1$variable) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2748 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2749 if(!indice_nomsVarReponses) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2750 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2751 stop("All the correlations between the response variables and the first component and the correlations |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2752 between the responses variables and the second component have not been computed.") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2753 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2754 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2755 comp = as.numeric(sapply(3:4, FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2756 col_i = colnames(dataframe_cor_comp_var_globalTemp1)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2757 ch = strsplit(col_i, split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2758 resTemp = ch[length(ch)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2759 res = substring(resTemp, nchar(resTemp), nchar(resTemp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2760 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2761 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2762 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2763 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2764 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2765 mat_cor_comp_var_globalTemp1 = t(sapply(1:dim(dataframe_cor_comp_var_globalTemp1)[1], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2766 dataframe_cor_comp_var_globalTemp1_i = dataframe_cor_comp_var_globalTemp1[i, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2767 block_i = dataframe_cor_comp_var_globalTemp1_i$bloc |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2768 cor1 = dataframe_cor_comp_var_globalTemp1_i[paste0("cor_var_comp", comp[1])] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2769 cor2 = dataframe_cor_comp_var_globalTemp1_i[paste0("cor_var_comp", comp[2])] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2770 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2771 if(block_i == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2772 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2773 cor1_sign = cor1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2774 cor2_sign = cor2 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2775 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2776 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2777 indice_block_comp1_i = which(colnames(mat_cor_comp1) == block_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2778 indice_block_comp2_i = which(colnames(mat_cor_comp2) == block_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2779 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2780 cor1_sign = sign(mat_cor_comp1[vec_indice_blocks[1], indice_block_comp1_i])*cor1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2781 cor2_sign = sign(mat_cor_comp2[vec_indice_blocks[1], indice_block_comp2_i])*cor2 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2782 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2783 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2784 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2785 res = c(dataframe_cor_comp_var_globalTemp1_i[1:2], cor1_sign, cor2_sign) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2786 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2787 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2788 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2789 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2790 dataframe_cor_comp_var_globalTemp2 = as.data.frame(mat_cor_comp_var_globalTemp1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2791 dataframe_cor_comp_var_globalTemp2[, 1:2] = apply(dataframe_cor_comp_var_globalTemp2[, 1:2], 2, as.character) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2792 colnames(dataframe_cor_comp_var_globalTemp2) = colnames(dataframe_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2793 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2794 # Pour les variables de vec_blocks et les variables réponses nomsVarReponses, on récupère les corrélations |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2795 # entre ces variables et les composantes. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2796 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2797 indice1 = sapply(1:dim(dataframe_cor_comp_var_globalTemp2)[1], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2798 block_i = dataframe_cor_comp_var_globalTemp2$bloc[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2799 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2800 if(block_i == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2801 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2802 res = dataframe_cor_comp_var_globalTemp2$variable[i]%in%nomsVarReponses |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2803 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2804 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2805 res = block_i%in%vec_blocks |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2806 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2807 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2808 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2809 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2810 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2811 dataframe_cor_comp_var_global2 = dataframe_cor_comp_var_globalTemp2[indice1, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2812 mat_cor_comp_var_global2 = apply(dataframe_cor_comp_var_global2[ , 3:4], 2, as.numeric) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2813 rownames(mat_cor_comp_var_global2) = dataframe_cor_comp_var_global2$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2814 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2815 # indice permet de récupérer les variables de chaque bloc fortement corrélées avec soit |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2816 # la première composante ou la deuxième composante dans un rectangle du cercle de corrélations |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2817 # et de récupérer les variables réponses. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2818 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2819 indice2 = sapply(1:dim(dataframe_cor_comp_var_global2)[1], FUN = function(k){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2820 cor1 = mat_cor_comp_var_global2[k, 1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2821 cor2 = mat_cor_comp_var_global2[k, 2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2822 blockEtReponse_k = dataframe_cor_comp_var_global2[k, 2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2823 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2824 if(blockEtReponse_k == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2825 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2826 cond2 = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2827 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2828 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2829 cond1 = abs(cor1) > cutoff | abs(cor2) > cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2830 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2831 cond2 = cor1 > min.X & cor1 < max.X & cor2 > min.Y & cor2 < max.Y & cond1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2832 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2833 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2834 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2835 return(cond2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2836 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2837 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2838 dataframe_cor_comp_var_global2Select = dataframe_cor_comp_var_global2[indice2, ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2839 varSelectTemp = dataframe_cor_comp_var_global2Select$variable |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2840 ind_Y = which(dataframe_cor_comp_var_global2Select$bloc == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2841 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2842 if(length(ind_Y) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2843 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2844 varSelect = varSelectTemp[- ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2845 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2846 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2847 varSelect = varSelectTemp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2848 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2849 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2850 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2851 mat_cor_comp_var_global2Select = mat_cor_comp_var_global2[indice2, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2852 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2853 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2854 # Tracé de la superposition des cerles de corrélation. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2855 circle = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2856 circle[[1]] = ellipse(0, levels = 1, t = 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2857 circle[[2]] = ellipse(0, levels = 1, t = rad.in) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2858 circle = data.frame(do.call("rbind", circle), "Circle" = c(rep("Main circle", 100), rep("Inner circle", 100))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2859 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2860 MainCircle = circle[grep("Main circle", circle[, 3]), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2861 InnerCircle = circle[grep("Inner circle", circle[, 3]), ] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2862 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2863 plot(MainCircle[, 1], MainCircle[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2864 type = "l", |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2865 xlab = paste0("composante ", comp[1]), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2866 ylab = paste0("composante ", comp[2])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2867 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2868 points(InnerCircle[, 1], InnerCircle[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2869 type = "l") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2870 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2871 if(dim(mat_cor_comp_var_global2Select)[1] != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2872 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2873 vec_blockEtReponseSelect = unique(dataframe_cor_comp_var_global2Select$bloc) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2874 indice_blockEtReponseSelect = sapply(1:length(vec_blockEtReponseSelect), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2875 ind = which(colnames(mat_cor_comp1) == vec_blockEtReponseSelect[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2876 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2877 if(length(ind) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2878 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2879 res = ind |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2880 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2881 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2882 res = dim(mat_cor_comp1)[1] + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2883 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2884 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2885 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2886 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2887 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2888 vec_colSelect = vec_col[indice_blockEtReponseSelect] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2889 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2890 if(length(vec_blockEtReponseSelect) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2891 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2892 points(mat_cor_comp_var_global2Select[, 1], mat_cor_comp_var_global2Select[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2893 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2894 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2895 text(mat_cor_comp_var_global2Select[, 1], mat_cor_comp_var_global2Select[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2896 labels = rownames(mat_cor_comp_var_global2Select), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2897 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2898 col = vec_colSelect[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2899 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2900 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2901 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2902 nbVarSelect_bloc = cumsum(sapply(1:length(vec_blockEtReponseSelect), FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2903 res = length(which(dataframe_cor_comp_var_global2Select$bloc == vec_blockEtReponseSelect[j])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2904 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2905 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2906 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2907 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2908 for(i in 1:length(nbVarSelect_bloc)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2909 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2910 if(i == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2911 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2912 indice_nbVar1 = 1:nbVarSelect_bloc[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2913 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2914 mat_cor_comp_var_global2Select2 = mat_cor_comp_var_global2Select[indice_nbVar1, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2915 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2916 points(mat_cor_comp_var_global2Select2[, 1], mat_cor_comp_var_global2Select2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2917 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2918 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2919 text(mat_cor_comp_var_global2Select2[, 1], mat_cor_comp_var_global2Select2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2920 labels = rownames(mat_cor_comp_var_global2Select2), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2921 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2922 col = rep(vec_colSelect[i], dim(mat_cor_comp_var_global2Select2)[1])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2923 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2924 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2925 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2926 indice_nbVar2 = (nbVarSelect_bloc[i - 1] + 1):nbVarSelect_bloc[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2927 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2928 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2929 mat_cor_comp_var_global2Select2 = mat_cor_comp_var_global2Select[indice_nbVar2, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2930 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2931 points(mat_cor_comp_var_global2Select2[, 1], mat_cor_comp_var_global2Select2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2932 col = NULL) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2933 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2934 text(mat_cor_comp_var_global2Select2[, 1], mat_cor_comp_var_global2Select2[, 2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2935 labels = rownames(mat_cor_comp_var_global2Select2), |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2936 cex = cex, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2937 col = rep(vec_colSelect[i], dim(mat_cor_comp_var_global2Select2)[1])) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2938 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2939 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2940 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2941 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2942 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2943 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2944 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2945 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2946 par(xpd = TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2947 legend(x = pos[1], y = pos[2], |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2948 legend = vec_blockEtReponseSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2949 pch = pch, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2950 col = vec_colSelect, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2951 cex = cex_legend, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2952 inset = inset) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2953 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2954 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2955 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2956 warning("There is no variables in this rectangle of the correlation circle.") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2957 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2958 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2959 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2960 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2961 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2962 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2963 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2964 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2965 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2966 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2967 return(varSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2968 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2969 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2970 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2971 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2972 tabVarSelect <-function(varSelect) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2973 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2974 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2975 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2976 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2977 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2978 # La fonction compute_matSimilarity calcule, pour chaque groupe de blocs, les |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2979 # similarités entre le bloc1 et le bloc2 et entre les blocs et la réponse. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2980 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2981 compute_matSimilarity <-function(liste_dataframe_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2982 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2983 comp = as.numeric(sapply(3:4, FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2984 col_i = colnames(liste_dataframe_cor_comp_var_global[[1]])[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2985 ch = strsplit(col_i, split = "_")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2986 resTemp = ch[length(ch)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2987 res = substring(resTemp, nchar(resTemp), nchar(resTemp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2988 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2989 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2990 })) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2991 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2992 liste_matSimilarity_group = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2993 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2994 # On calcule, pour chaque groupe de blocs, les matrices de similarités entre |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2995 # chaque paire de blocs. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2996 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2997 for(i in 1:length(liste_dataframe_cor_comp_var_global)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2998 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
2999 dataframe_cor_comp_var_global_i = liste_dataframe_cor_comp_var_global[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3000 blocks_i = unique(dataframe_cor_comp_var_global_i$bloc) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3001 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3002 coord = lapply(1:length(blocks_i), FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3003 ind_j = which(dataframe_cor_comp_var_global_i$bloc == blocks_i[j]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3004 dataframe_cor_comp_var_global_i_j = dataframe_cor_comp_var_global_i[ind_j, paste0("cor_var_comp", comp)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3005 res = as.matrix(dataframe_cor_comp_var_global_i_j, drop = FALSE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3006 rownames(res) = rownames(dataframe_cor_comp_var_global_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3007 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3008 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3009 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3010 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3011 M_block = list() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3012 l = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3013 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3014 vec_blocks_i = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3015 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3016 for(j in 1:(length(blocks_i) - 1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3017 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3018 blocks_i_j = blocks_i[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3019 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3020 for(k in (j + 1):length(blocks_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3021 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3022 blocks_i_k = blocks_i[k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3023 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3024 M_block[[l]] = coord[[j]][, drop = FALSE] %*% t(coord[[k]][, drop = FALSE]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3025 rownames(M_block[[l]]) = rownames(coord[[j]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3026 colnames(M_block[[l]]) = rownames(coord[[k]]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3027 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3028 blocks_j_k = paste(c(blocks_i_j, blocks_i_k), collapse = "-") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3029 vec_blocks_i = c(vec_blocks_i, blocks_j_k) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3030 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3031 l = l + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3032 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3033 } # Fin for(k in (j + 1):length(blocks)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3034 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3035 } # Fin for(j in 1:(length(blocks) - 1)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3036 names(M_block) = vec_blocks_i |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3037 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3038 liste_matSimilarity_group[[i]] = M_block |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3039 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3040 } # Fin for(i in 1:length(liste_dataframe_Cor_comp_var_global)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3041 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3042 names(liste_matSimilarity_group) = names(liste_dataframe_cor_comp_var_global) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3043 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3044 return(list(liste_matSimilarity_group = liste_matSimilarity_group, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3045 comp = comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3046 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3047 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3048 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3049 # La fonction networkVariableSelect permet de tracer un réseau pour les variables de |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3050 # certains blocs et des variables réponses. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3051 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3052 networkVariableSelect <-function(liste_matSimilarity_group, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3053 comp, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3054 res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3055 cutoff_comp = 0.8, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3056 vec_varBlock, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3057 vec_varRep, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3058 cutoff = 0 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3059 ) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3060 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3061 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3062 vec_varBlockEtReponse = c(vec_varBlock, vec_varRep) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3063 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3064 # Nous vérifions que nous pouvons créer un réseau pour les variables des |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3065 # blocs vec_Var_blockEtReponse. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3066 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3067 # Nous recherchons le groupe de blocs associé à vec_varBlock. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3068 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3069 indice_group_vecVar = sapply(1:length(liste_matSimilarity_group), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3070 liste_matSimilarity_group_i = liste_matSimilarity_group[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3071 boolean = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3072 j = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3073 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3074 while((j <= length(liste_matSimilarity_group_i))&!boolean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3075 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3076 matSimilarity_group_i_j = liste_matSimilarity_group_i[[j]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3077 vec_var_block1 = rownames(matSimilarity_group_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3078 vec_var_block2 = colnames(matSimilarity_group_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3079 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3080 vec_var_block = c(vec_var_block1, vec_var_block2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3081 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3082 if(any(vec_var_block%in%vec_varBlock)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3083 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3084 boolean = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3085 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3086 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3087 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3088 j = j + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3089 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3090 } # Fin while((j <= length(liste_matSimilarity_group_i))&!boolean). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3091 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3092 res = boolean |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3093 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3094 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3095 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3096 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3097 res = NULL |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3098 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3099 if(length(which(indice_group_vecVar == TRUE)) >= 2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3100 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3101 cat("Erreur : les variables de vec_varBlock. doivent appartenir à un seul élément de la liste |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3102 liste_res_matSimilarity_group$liste_matSimilarity_group.", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3103 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3104 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3105 liste_matSimilarity = liste_matSimilarity_group[[which(indice_group_vecVar == TRUE)]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3106 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3107 blocks_liste_matSimilarityTemp1 = sapply(1:length(liste_matSimilarity), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3108 noms_block1_block2_i = names(liste_matSimilarity)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3109 ch = strsplit(noms_block1_block2_i, split = "-")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3110 block1 = ch[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3111 block2 = ch[2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3112 res = c(block1, block2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3113 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3114 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3115 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3116 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3117 blocks_liste_matSimilarity = unique(as.vector(blocks_liste_matSimilarityTemp1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3118 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3119 indice_blocks_liste_matSimilarityTemp = sapply(1:length(blocks_liste_matSimilarity), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3120 res = which(res_block_splsda$names$blocks == blocks_liste_matSimilarity[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3121 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3122 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3123 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3124 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3125 ind_Y = which(res_block_splsda$names$blocks == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3126 indice_blocks_liste_matSimilarity = indice_blocks_liste_matSimilarityTemp[indice_blocks_liste_matSimilarityTemp != ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3127 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3128 boolean_pos_cor = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3129 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3130 # Nous vérifions que les ièmes composantes de chaque bloc sont fortement corrélées positivement. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3131 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3132 if(length(indice_blocks_liste_matSimilarity) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3133 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3134 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3135 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3136 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3137 for(i in 1:length(comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3138 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3139 comp_i = comp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3140 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3141 for(j in 1:(length(indice_blocks_liste_matSimilarity) - 1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3142 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3143 indice_blocks_liste_matSimilarity_j = indice_blocks_liste_matSimilarity[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3144 comp_indice_blocks_liste_matSimilarity_j = res_block_splsda$variates[[indice_blocks_liste_matSimilarity_j]][, comp_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3145 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3146 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3147 for(k in (j + 1):length(indice_blocks_liste_matSimilarity)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3148 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3149 indice_blocks_liste_matSimilarity_k = indice_blocks_liste_matSimilarity[k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3150 comp_indice_blocks_liste_matSimilarity_k = res_block_splsda$variates[[indice_blocks_liste_matSimilarity_k]][, comp_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3151 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3152 cor = cor(comp_indice_blocks_liste_matSimilarity_j, comp_indice_blocks_liste_matSimilarity_k) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3153 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3154 boolean_pos_cor = boolean_pos_cor & all(cor > cutoff_comp) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3155 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3156 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3157 } # Fin for(k in (j + 1):length(indice_blocks_liste_matSimilarity)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3158 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3159 } # Fin for(j in 1:(length(indice_blocks_liste_matSimilarity) - 1)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3160 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3161 } # Fin for(i in 1:length(comp)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3162 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3163 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3164 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3165 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3166 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3167 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3168 if(!boolean_pos_cor) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3169 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3170 cat("Erreur : pour chaque paire de bloc, la ième composante de chaque bloc doivent être corrélées positivement afin de pouvoir créer |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3171 un réseau.", "\n") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3172 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3173 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3174 # Nous récupérons les matrices de similarités associés aux variables de vec_varBlockEtReponse . |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3175 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3176 liste_matSimilaritySelectTemp = lapply(1:length(liste_matSimilarity), FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3177 matSimilarity_j = liste_matSimilarity[[j]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3178 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3179 indice_row_matSimilarity_j = which(rownames(matSimilarity_j)%in%vec_varBlockEtReponse == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3180 indice_col_matSimilarity_j = which(colnames(matSimilarity_j)%in%vec_varBlockEtReponse == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3181 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3182 if((length(indice_row_matSimilarity_j) != 0) &(length(indice_col_matSimilarity_j) != 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3183 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3184 res = matSimilarity_j[indice_row_matSimilarity_j, indice_col_matSimilarity_j, drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3185 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3186 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3187 res = NA |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3188 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3189 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3190 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3191 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3192 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3193 names(liste_matSimilaritySelectTemp) = names(liste_matSimilarity) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3194 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3195 indice_NA_liste_matSimilaritySelectTemp = sapply(1:length(liste_matSimilaritySelectTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3196 liste_matSimilaritySelectTemp_i = liste_matSimilaritySelectTemp[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3197 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3198 if(is.matrix(liste_matSimilaritySelectTemp_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3199 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3200 res = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3201 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3202 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3203 if(is.na(liste_matSimilaritySelectTemp_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3204 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3205 res = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3206 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3207 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3208 res = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3209 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3210 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3211 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3212 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3213 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3214 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3215 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3216 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3217 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3218 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3219 liste_matSimilaritySelect = liste_matSimilaritySelectTemp[!indice_NA_liste_matSimilaritySelectTemp] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3220 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3221 # Nous créons le réseau. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3222 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3223 w = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3224 node.X1 = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3225 node.X2 = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3226 vec_group = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3227 vec_nomsVar = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3228 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3229 for(i in 1:length(liste_matSimilaritySelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3230 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3231 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3232 noms_bloc1_bloc2 = names(liste_matSimilaritySelect)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3233 matSimilaritySelect_i = liste_matSimilaritySelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3234 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3235 X1 = rownames(matSimilaritySelect_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3236 X2 = colnames(matSimilaritySelect_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3237 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3238 rep.X1 = rep(X1, each = length(X2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3239 rep.X2 = rep(X2, length(X1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3240 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3241 node.X1= c(node.X1, rep.X1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3242 node.X2 = c(node.X2, rep.X2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3243 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3244 ch = strsplit(noms_bloc1_bloc2, split = "-")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3245 nom_bloc1 = ch[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3246 nom_bloc2 = ch[2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3247 vec_group = c(vec_group, c(rep(nom_bloc1, length(X1)), rep(nom_bloc2, length(X2)))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3248 vec_nomsVar = c(vec_nomsVar, c(X1, X2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3249 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3250 w = c(w, as.vector(t(matSimilaritySelect_i))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3251 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3252 } # Fin for(i in 1:length(liste_matSimilaritySelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3253 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3254 dup = duplicated(vec_nomsVar) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3255 vec_nomsVar = vec_nomsVar[!dup] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3256 vec_group = vec_group[!dup] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3257 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3258 nodes = data.frame(name = vec_nomsVar, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3259 group = vec_group) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3260 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3261 # gR |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3262 relations = data.frame(from = node.X1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3263 to = node.X2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3264 weight = w) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3265 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3266 idx = (abs(w) >= cutoff) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3267 relations = relations[idx, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3268 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3269 gR = graph.data.frame(relations, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3270 directed = FALSE, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3271 vertices = nodes) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3272 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3273 # On supprime les noeuds qui n'ont pas d'arêtes. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3274 gR = delete.vertices(gR, which(degree(gR) == 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3275 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3276 res = list(gR = gR) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3277 res$cutoff = cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3278 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3279 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3280 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3281 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3282 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3283 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3284 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3285 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3286 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3287 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3288 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3289 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3290 # La fonction networkVar permet de tracer un réseau pour certaines variables des |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3291 # blocs et des variables réponses. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3292 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3293 networkVar <-function(liste_matSimilarity_group = liste_matSimilarity_group, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3294 comp = comp, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3295 res_block_splsda, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3296 cutoff_comp = 0.8, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3297 vec_varBlock, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3298 vec_varRep, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3299 vec_varBlockInteret = NULL, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3300 cutoff = 0 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3301 ) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3302 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3303 # Nous vérifions que nous pouvons créer un réseau pour les variables des |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3304 # blocs vec_VarBlock. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3305 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3306 # Nous recherchons le groupe de blocs associé à vec_Var. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3307 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3308 indice_group_vecVar = sapply(1:length(liste_matSimilarity_group), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3309 liste_matSimilarity_group_i = liste_matSimilarity_group[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3310 boolean = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3311 j = 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3312 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3313 while((j <= length(liste_matSimilarity_group_i))&!boolean) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3314 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3315 matSimilarity_group_i_j = liste_matSimilarity_group_i[[j]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3316 vec_var_block1 = rownames(matSimilarity_group_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3317 vec_var_block2 = colnames(matSimilarity_group_i_j) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3318 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3319 vec_var_block1_block2 = c(vec_var_block1, vec_var_block2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3320 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3321 if(any(vec_var_block1_block2%in%vec_varBlock)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3322 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3323 boolean = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3324 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3325 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3326 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3327 j = j + 1 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3328 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3329 } # Fin while((j <= length(liste_matSimilarity_group_i))&!boolean). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3330 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3331 res = boolean |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3332 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3333 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3334 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3335 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3336 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3337 if(length(which(indice_group_vecVar == TRUE)) >= 2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3338 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3339 stop("The variables of vec_var have to belong to only one element of |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3340 liste_res_matSimilarity_group$liste_matSimilarity_group.") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3341 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3342 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3343 liste_matSimilarity = liste_matSimilarity_group[[which(indice_group_vecVar == TRUE)]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3344 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3345 if(!is.null(vec_varBlockInteret)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3346 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3347 AllVariables_vec = sapply(1:length(liste_matSimilarity), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3348 matSimilarity_i = liste_matSimilarity[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3349 res = c(rownames(matSimilarity_i), colnames(matSimilarity_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3350 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3351 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3352 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3353 AllVariables_vec = unique(unlist(AllVariables_vec)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3354 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3355 index_variableInterestNotInAllVariables_vec = vec_varBlockInteret%in%AllVariables_vec |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3356 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3357 if(length(which(index_variableInterestNotInAllVariables_vec == FALSE)) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3358 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3359 InterestVariableNotIn = vec_varBlockInteret[which(index_variableInterestNotInAllVariables_vec == FALSE)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3360 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3361 warning(paste0("The variables of interest ", paste(InterestVariableNotIn, collapse = ","), " do not belong |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3362 to the variables of the blocks for which the network can be created. These variables will |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3363 be not in the network.")) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3364 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3365 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3366 vec_varBlockInteret2 = vec_varBlockInteret[which(index_variableInterestNotInAllVariables_vec == TRUE)] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3367 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3368 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3369 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3370 vec_varBlockInteret2 = vec_varBlockInteret |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3371 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3372 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3373 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3374 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3375 if(!is.null(vec_varBlock) & !is.null(vec_varBlockInteret2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3376 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3377 varCom = intersect(vec_varBlock, vec_varBlockInteret2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3378 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3379 if(length(varCom) != 0) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3380 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3381 index_varCom = sapply(1:length(varCom), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3382 res = which(vec_varBlock == varCom[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3383 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3384 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3385 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3386 vec_varBlock2 = vec_varBlock[- index_varCom] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3387 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3388 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3389 vec_varBlock2 = vec_varBlock |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3390 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3391 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3392 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3393 vec_varBlock3 = c(vec_varBlock2, vec_varBlockInteret2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3394 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3395 }else if(!is.null(vec_varBlock) & is.null(vec_varBlockInteret2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3396 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3397 vec_varBlock3 = vec_varBlock |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3398 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3399 }else if(is.null(vec_varBlock) & !is.null(vec_varBlockInteret2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3400 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3401 vec_varBlock3 = vec_varBlockInteret2 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3402 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3403 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3404 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3405 vec_var = c(vec_varBlock3, vec_varRep) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3406 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3407 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3408 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3409 blocks_liste_matSimilarityTemp1 = sapply(1:length(liste_matSimilarity), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3410 noms_block1_block2_i = names(liste_matSimilarity)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3411 ch = strsplit(noms_block1_block2_i, split = "-")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3412 block1 = ch[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3413 block2 = ch[2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3414 res = c(block1, block2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3415 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3416 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3417 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3418 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3419 blocks_liste_matSimilarity = unique(as.vector(blocks_liste_matSimilarityTemp1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3420 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3421 indice_blocks_liste_matSimilarityTemp = sapply(1:length(blocks_liste_matSimilarity), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3422 res = which(res_block_splsda$names$blocks == blocks_liste_matSimilarity[i]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3423 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3424 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3425 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3426 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3427 ind_Y = which(res_block_splsda$names$blocks == "Y") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3428 indice_blocks_liste_matSimilarity = indice_blocks_liste_matSimilarityTemp[indice_blocks_liste_matSimilarityTemp != ind_Y] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3429 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3430 boolean_pos_cor = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3431 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3432 if(length(indice_blocks_liste_matSimilarity) == 1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3433 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3434 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3435 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3436 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3437 for(i in 1:length(comp)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3438 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3439 comp_i = comp[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3440 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3441 for(j in 1:(length(indice_blocks_liste_matSimilarity) - 1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3442 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3443 indice_blocks_liste_matSimilarity_j = indice_blocks_liste_matSimilarity[j] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3444 comp_indice_blocks_liste_matSimilarity_j = res_block_splsda$variates[[indice_blocks_liste_matSimilarity_j]][, comp_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3445 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3446 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3447 for(k in (j + 1):length(indice_blocks_liste_matSimilarity)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3448 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3449 indice_blocks_liste_matSimilarity_k = indice_blocks_liste_matSimilarity[k] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3450 comp_indice_blocks_liste_matSimilarity_k = res_block_splsda$variates[[indice_blocks_liste_matSimilarity_k]][, comp_i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3451 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3452 cor = cor(comp_indice_blocks_liste_matSimilarity_j, comp_indice_blocks_liste_matSimilarity_k) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3453 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3454 boolean_pos_cor = boolean_pos_cor & cor > cutoff_comp |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3455 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3456 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3457 } # Fin for(k in (j + 1):length(indice_blocks_vec_VarBlock)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3458 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3459 } # Fin for(j in 1:(length(indice_blocks_vec_VarBlock)) - 1). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3460 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3461 } # Fin for(i in 1:length(comp)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3462 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3463 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3464 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3465 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3466 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3467 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3468 if(!boolean_pos_cor) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3469 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3470 stop("For each pair of blocks, the ith component of the first block |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3471 and the ith component of the second block have to be positively correlated in order |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3472 to create a network.") |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3473 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3474 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3475 liste_matSimilaritySelectTemp = lapply(1:length(liste_matSimilarity), FUN = function(j){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3476 matSimilarity_j = liste_matSimilarity[[j]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3477 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3478 indice_row_matSimilarity_j = which(rownames(matSimilarity_j)%in%vec_var == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3479 indice_col_matSimilarity_j = which(colnames(matSimilarity_j)%in%vec_var == TRUE) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3480 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3481 if((length(indice_row_matSimilarity_j) != 0) &(length(indice_col_matSimilarity_j) != 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3482 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3483 res = matSimilarity_j[indice_row_matSimilarity_j, indice_col_matSimilarity_j, drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3484 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3485 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3486 res = NA |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3487 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3488 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3489 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3490 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3491 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3492 names(liste_matSimilaritySelectTemp) = names(liste_matSimilarity) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3493 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3494 indice_NA_liste_matSimilaritySelectTemp = sapply(1:length(liste_matSimilaritySelectTemp), FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3495 liste_matSimilaritySelectTemp_i = liste_matSimilaritySelectTemp[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3496 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3497 if(is.matrix(liste_matSimilaritySelectTemp_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3498 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3499 res = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3500 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3501 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3502 if(is.na(liste_matSimilaritySelectTemp_i)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3503 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3504 res = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3505 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3506 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3507 res = FALSE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3508 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3509 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3510 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3511 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3512 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3513 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3514 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3515 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3516 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3517 liste_matSimilaritySelect = liste_matSimilaritySelectTemp[!indice_NA_liste_matSimilaritySelectTemp] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3518 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3519 w = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3520 node.X1 = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3521 node.X2 = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3522 vec_group = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3523 vec_nomsVar = c() |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3524 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3525 for(i in 1:length(liste_matSimilaritySelect)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3526 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3527 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3528 noms_block1_block2 = names(liste_matSimilaritySelect)[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3529 matSimilaritySelect_i = liste_matSimilaritySelect[[i]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3530 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3531 X1 = rownames(matSimilaritySelect_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3532 X2 = colnames(matSimilaritySelect_i) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3533 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3534 rep.X1 = rep(X1, each = length(X2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3535 rep.X2 = rep(X2, length(X1)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3536 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3537 node.X1 = c(node.X1, rep.X1) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3538 node.X2 = c(node.X2, rep.X2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3539 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3540 ch = strsplit(noms_block1_block2, split = "-")[[1]] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3541 nom_block1 = ch[1] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3542 nom_block2 = ch[2] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3543 vec_group = c(vec_group, c(rep(nom_block1, length(X1)), rep(nom_block2, length(X2)))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3544 vec_nomsVar = c(vec_nomsVar, c(X1, X2)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3545 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3546 w = c(w, as.vector(t(matSimilaritySelect_i))) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3547 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3548 } # Fin for(i in 1:length(liste_matSimilaritySelect)). |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3549 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3550 dup = duplicated(vec_nomsVar) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3551 vec_nomsVar = vec_nomsVar[!dup] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3552 vec_group = vec_group[!dup] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3553 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3554 nodes = data.frame(name = vec_nomsVar, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3555 group = vec_group) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3556 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3557 # gR |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3558 relations = data.frame(from = node.X1, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3559 to = node.X2, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3560 weight = w) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3561 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3562 # idx |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3563 if(!is.null(vec_varBlock) & !is.null(vec_varBlockInteret2) & !is.null(vec_varRep)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3564 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3565 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3566 idx = sapply(1:dim(relations)[1], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3567 node.X1_i = relations$from[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3568 node.X2_i = relations$to[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3569 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3570 if(node.X1_i%in%vec_varBlockInteret2 | node.X2_i%in%vec_varBlockInteret2) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3571 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3572 res = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3573 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3574 }else if(node.X1_i%in%vec_varRep | node.X2_i%in%vec_varRep){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3575 res = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3576 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3577 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3578 res = abs(w)[i] >= cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3579 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3580 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3581 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3582 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3583 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3584 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3585 }else if(!is.null(vec_varBlock) & is.null(vec_varBlockInteret2) & !is.null(vec_varRep)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3586 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3587 idx = sapply(1:dim(relations)[1], FUN = function(i){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3588 node.X1_i = relations$from[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3589 node.X2_i = relations$to[i] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3590 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3591 if(node.X1_i%in%vec_varRep | node.X2_i%in%vec_varRep){ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3592 res = TRUE |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3593 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3594 }else{ |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3595 res = abs(w)[i] >= cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3596 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3597 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3598 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3599 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3600 }) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3601 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3602 }else if(is.null(vec_varBlockEtReponse) & !is.null(vec_varBlockInteret2) & !is.null(vec_varRep)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3603 { |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3604 idx = rep(TRUE, dim(relations)[1]) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3605 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3606 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3607 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3608 relations = relations[idx, , drop = FALSE] |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3609 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3610 gR = graph.data.frame(relations, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3611 directed = FALSE, |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3612 vertices = nodes) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3613 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3614 # On supprime les noeuds qui n'ont pas d'arêtes. |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3615 gR = delete.vertices(gR, which(degree(gR) == 0)) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3616 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3617 res = list(gR = gR) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3618 res$cutoff = cutoff |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3619 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3620 return(res) |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3621 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3622 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3623 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3624 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3625 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3626 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3627 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3628 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3629 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3630 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3631 } |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3632 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3633 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3634 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3635 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3636 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3637 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3638 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3639 |
0a3c83f2197a
planemo upload for repository https://github.com/bilille/galaxy-mixomics-blocksplsda commit 24b8259494ac7ab10cbd1f9ee991f455a7507590-dirty
ppericard
parents:
diff
changeset
|
3640 |