miga-base 0.7.23.0 → 0.7.25.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (320) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +3 -0
  3. data/Rakefile +1 -0
  4. data/lib/miga/cli/action/add.rb +10 -8
  5. data/lib/miga/cli/action/classify_wf.rb +12 -11
  6. data/lib/miga/cli/action/derep_wf.rb +3 -9
  7. data/lib/miga/cli/action/edit.rb +0 -1
  8. data/lib/miga/cli/action/find.rb +1 -1
  9. data/lib/miga/cli/action/generic.rb +1 -1
  10. data/lib/miga/cli/action/get.rb +7 -2
  11. data/lib/miga/cli/action/index_wf.rb +4 -2
  12. data/lib/miga/cli/action/init.rb +60 -59
  13. data/lib/miga/cli/action/init/files_helper.rb +2 -1
  14. data/lib/miga/cli/action/ncbi_get.rb +1 -1
  15. data/lib/miga/cli/action/new.rb +15 -9
  16. data/lib/miga/cli/action/option.rb +63 -0
  17. data/lib/miga/cli/action/preproc_wf.rb +7 -5
  18. data/lib/miga/cli/action/quality_wf.rb +3 -3
  19. data/lib/miga/cli/action/tax_dist.rb +1 -1
  20. data/lib/miga/cli/action/tax_test.rb +1 -1
  21. data/lib/miga/cli/action/wf.rb +72 -54
  22. data/lib/miga/cli/base.rb +17 -5
  23. data/lib/miga/cli/objects_helper.rb +23 -18
  24. data/lib/miga/common.rb +1 -1
  25. data/lib/miga/common/with_option.rb +83 -0
  26. data/lib/miga/common/with_result.rb +2 -1
  27. data/lib/miga/dataset/base.rb +20 -2
  28. data/lib/miga/dataset/result.rb +3 -2
  29. data/lib/miga/metadata.rb +25 -13
  30. data/lib/miga/project/base.rb +82 -2
  31. data/lib/miga/project/result.rb +4 -4
  32. data/lib/miga/result.rb +18 -15
  33. data/lib/miga/result/stats.rb +2 -2
  34. data/lib/miga/version.rb +2 -2
  35. data/scripts/essential_genes.bash +18 -3
  36. data/scripts/miga.bash +8 -2
  37. data/scripts/ogs.bash +2 -3
  38. data/test/dataset_test.rb +5 -5
  39. data/test/lair_test.rb +1 -2
  40. data/test/result_test.rb +22 -0
  41. data/test/with_option_test.rb +115 -0
  42. data/utils/cleanup-databases.rb +1 -2
  43. data/utils/distance/base.rb +9 -0
  44. data/utils/distance/commands.rb +183 -81
  45. data/utils/distance/database.rb +69 -10
  46. data/utils/distance/pipeline.rb +15 -21
  47. data/utils/distance/runner.rb +28 -49
  48. data/utils/distance/temporal.rb +4 -2
  49. data/utils/distances.rb +2 -2
  50. data/utils/index_metadata.rb +1 -2
  51. data/utils/requirements.txt +1 -1
  52. data/utils/subclade/runner.rb +9 -10
  53. metadata +9 -273
  54. data/utils/enveomics/Docs/recplot2.md +0 -244
  55. data/utils/enveomics/Examples/aai-matrix.bash +0 -66
  56. data/utils/enveomics/Examples/ani-matrix.bash +0 -66
  57. data/utils/enveomics/Examples/essential-phylogeny.bash +0 -105
  58. data/utils/enveomics/Examples/unus-genome-phylogeny.bash +0 -100
  59. data/utils/enveomics/LICENSE.txt +0 -73
  60. data/utils/enveomics/Makefile +0 -52
  61. data/utils/enveomics/Manifest/Tasks/aasubs.json +0 -103
  62. data/utils/enveomics/Manifest/Tasks/blasttab.json +0 -786
  63. data/utils/enveomics/Manifest/Tasks/distances.json +0 -161
  64. data/utils/enveomics/Manifest/Tasks/fasta.json +0 -766
  65. data/utils/enveomics/Manifest/Tasks/fastq.json +0 -243
  66. data/utils/enveomics/Manifest/Tasks/graphics.json +0 -126
  67. data/utils/enveomics/Manifest/Tasks/mapping.json +0 -67
  68. data/utils/enveomics/Manifest/Tasks/ogs.json +0 -382
  69. data/utils/enveomics/Manifest/Tasks/other.json +0 -829
  70. data/utils/enveomics/Manifest/Tasks/remote.json +0 -355
  71. data/utils/enveomics/Manifest/Tasks/sequence-identity.json +0 -501
  72. data/utils/enveomics/Manifest/Tasks/tables.json +0 -308
  73. data/utils/enveomics/Manifest/Tasks/trees.json +0 -68
  74. data/utils/enveomics/Manifest/Tasks/variants.json +0 -111
  75. data/utils/enveomics/Manifest/categories.json +0 -156
  76. data/utils/enveomics/Manifest/examples.json +0 -154
  77. data/utils/enveomics/Manifest/tasks.json +0 -4
  78. data/utils/enveomics/Pipelines/assembly.pbs/CONFIG.mock.bash +0 -69
  79. data/utils/enveomics/Pipelines/assembly.pbs/FastA.N50.pl +0 -1
  80. data/utils/enveomics/Pipelines/assembly.pbs/FastA.filterN.pl +0 -1
  81. data/utils/enveomics/Pipelines/assembly.pbs/FastA.length.pl +0 -1
  82. data/utils/enveomics/Pipelines/assembly.pbs/README.md +0 -189
  83. data/utils/enveomics/Pipelines/assembly.pbs/RUNME-2.bash +0 -112
  84. data/utils/enveomics/Pipelines/assembly.pbs/RUNME-3.bash +0 -23
  85. data/utils/enveomics/Pipelines/assembly.pbs/RUNME-4.bash +0 -44
  86. data/utils/enveomics/Pipelines/assembly.pbs/RUNME.bash +0 -50
  87. data/utils/enveomics/Pipelines/assembly.pbs/kSelector.R +0 -37
  88. data/utils/enveomics/Pipelines/assembly.pbs/newbler.pbs +0 -68
  89. data/utils/enveomics/Pipelines/assembly.pbs/newbler_preparator.pl +0 -49
  90. data/utils/enveomics/Pipelines/assembly.pbs/soap.pbs +0 -80
  91. data/utils/enveomics/Pipelines/assembly.pbs/stats.pbs +0 -57
  92. data/utils/enveomics/Pipelines/assembly.pbs/velvet.pbs +0 -63
  93. data/utils/enveomics/Pipelines/blast.pbs/01.pbs.bash +0 -38
  94. data/utils/enveomics/Pipelines/blast.pbs/02.pbs.bash +0 -73
  95. data/utils/enveomics/Pipelines/blast.pbs/03.pbs.bash +0 -21
  96. data/utils/enveomics/Pipelines/blast.pbs/BlastTab.recover_job.pl +0 -72
  97. data/utils/enveomics/Pipelines/blast.pbs/CONFIG.mock.bash +0 -98
  98. data/utils/enveomics/Pipelines/blast.pbs/FastA.split.pl +0 -1
  99. data/utils/enveomics/Pipelines/blast.pbs/README.md +0 -127
  100. data/utils/enveomics/Pipelines/blast.pbs/RUNME.bash +0 -109
  101. data/utils/enveomics/Pipelines/blast.pbs/TASK.check.bash +0 -128
  102. data/utils/enveomics/Pipelines/blast.pbs/TASK.dry.bash +0 -16
  103. data/utils/enveomics/Pipelines/blast.pbs/TASK.eo.bash +0 -22
  104. data/utils/enveomics/Pipelines/blast.pbs/TASK.pause.bash +0 -26
  105. data/utils/enveomics/Pipelines/blast.pbs/TASK.run.bash +0 -89
  106. data/utils/enveomics/Pipelines/blast.pbs/sentinel.pbs.bash +0 -29
  107. data/utils/enveomics/Pipelines/idba.pbs/README.md +0 -49
  108. data/utils/enveomics/Pipelines/idba.pbs/RUNME.bash +0 -95
  109. data/utils/enveomics/Pipelines/idba.pbs/run.pbs +0 -56
  110. data/utils/enveomics/Pipelines/trim.pbs/README.md +0 -54
  111. data/utils/enveomics/Pipelines/trim.pbs/RUNME.bash +0 -70
  112. data/utils/enveomics/Pipelines/trim.pbs/run.pbs +0 -130
  113. data/utils/enveomics/README.md +0 -42
  114. data/utils/enveomics/Scripts/AAsubs.log2ratio.rb +0 -171
  115. data/utils/enveomics/Scripts/Aln.cat.rb +0 -163
  116. data/utils/enveomics/Scripts/Aln.convert.pl +0 -35
  117. data/utils/enveomics/Scripts/AlphaDiversity.pl +0 -152
  118. data/utils/enveomics/Scripts/BedGraph.tad.rb +0 -93
  119. data/utils/enveomics/Scripts/BedGraph.window.rb +0 -71
  120. data/utils/enveomics/Scripts/BlastPairwise.AAsubs.pl +0 -102
  121. data/utils/enveomics/Scripts/BlastTab.addlen.rb +0 -63
  122. data/utils/enveomics/Scripts/BlastTab.advance.bash +0 -48
  123. data/utils/enveomics/Scripts/BlastTab.best_hit_sorted.pl +0 -55
  124. data/utils/enveomics/Scripts/BlastTab.catsbj.pl +0 -104
  125. data/utils/enveomics/Scripts/BlastTab.cogCat.rb +0 -76
  126. data/utils/enveomics/Scripts/BlastTab.filter.pl +0 -47
  127. data/utils/enveomics/Scripts/BlastTab.kegg_pep2path_rest.pl +0 -194
  128. data/utils/enveomics/Scripts/BlastTab.metaxaPrep.pl +0 -104
  129. data/utils/enveomics/Scripts/BlastTab.pairedHits.rb +0 -157
  130. data/utils/enveomics/Scripts/BlastTab.recplot2.R +0 -48
  131. data/utils/enveomics/Scripts/BlastTab.seqdepth.pl +0 -86
  132. data/utils/enveomics/Scripts/BlastTab.seqdepth_ZIP.pl +0 -119
  133. data/utils/enveomics/Scripts/BlastTab.seqdepth_nomedian.pl +0 -86
  134. data/utils/enveomics/Scripts/BlastTab.subsample.pl +0 -47
  135. data/utils/enveomics/Scripts/BlastTab.sumPerHit.pl +0 -114
  136. data/utils/enveomics/Scripts/BlastTab.taxid2taxrank.pl +0 -90
  137. data/utils/enveomics/Scripts/BlastTab.topHits_sorted.rb +0 -101
  138. data/utils/enveomics/Scripts/Chao1.pl +0 -97
  139. data/utils/enveomics/Scripts/CharTable.classify.rb +0 -234
  140. data/utils/enveomics/Scripts/EBIseq2tax.rb +0 -83
  141. data/utils/enveomics/Scripts/FastA.N50.pl +0 -56
  142. data/utils/enveomics/Scripts/FastA.extract.rb +0 -152
  143. data/utils/enveomics/Scripts/FastA.filter.pl +0 -52
  144. data/utils/enveomics/Scripts/FastA.filterLen.pl +0 -28
  145. data/utils/enveomics/Scripts/FastA.filterN.pl +0 -60
  146. data/utils/enveomics/Scripts/FastA.fragment.rb +0 -92
  147. data/utils/enveomics/Scripts/FastA.gc.pl +0 -42
  148. data/utils/enveomics/Scripts/FastA.interpose.pl +0 -93
  149. data/utils/enveomics/Scripts/FastA.length.pl +0 -38
  150. data/utils/enveomics/Scripts/FastA.mask.rb +0 -89
  151. data/utils/enveomics/Scripts/FastA.per_file.pl +0 -36
  152. data/utils/enveomics/Scripts/FastA.qlen.pl +0 -57
  153. data/utils/enveomics/Scripts/FastA.rename.pl +0 -65
  154. data/utils/enveomics/Scripts/FastA.revcom.pl +0 -23
  155. data/utils/enveomics/Scripts/FastA.sample.rb +0 -83
  156. data/utils/enveomics/Scripts/FastA.slider.pl +0 -85
  157. data/utils/enveomics/Scripts/FastA.split.pl +0 -55
  158. data/utils/enveomics/Scripts/FastA.split.rb +0 -79
  159. data/utils/enveomics/Scripts/FastA.subsample.pl +0 -131
  160. data/utils/enveomics/Scripts/FastA.tag.rb +0 -65
  161. data/utils/enveomics/Scripts/FastA.wrap.rb +0 -48
  162. data/utils/enveomics/Scripts/FastQ.filter.pl +0 -54
  163. data/utils/enveomics/Scripts/FastQ.interpose.pl +0 -90
  164. data/utils/enveomics/Scripts/FastQ.offset.pl +0 -90
  165. data/utils/enveomics/Scripts/FastQ.split.pl +0 -53
  166. data/utils/enveomics/Scripts/FastQ.tag.rb +0 -63
  167. data/utils/enveomics/Scripts/FastQ.test-error.rb +0 -81
  168. data/utils/enveomics/Scripts/FastQ.toFastA.awk +0 -24
  169. data/utils/enveomics/Scripts/GFF.catsbj.pl +0 -127
  170. data/utils/enveomics/Scripts/GenBank.add_fields.rb +0 -84
  171. data/utils/enveomics/Scripts/HMM.essential.rb +0 -351
  172. data/utils/enveomics/Scripts/HMM.haai.rb +0 -168
  173. data/utils/enveomics/Scripts/HMMsearch.extractIds.rb +0 -83
  174. data/utils/enveomics/Scripts/JPlace.distances.rb +0 -88
  175. data/utils/enveomics/Scripts/JPlace.to_iToL.rb +0 -320
  176. data/utils/enveomics/Scripts/M5nr.getSequences.rb +0 -81
  177. data/utils/enveomics/Scripts/MeTaxa.distribution.pl +0 -198
  178. data/utils/enveomics/Scripts/MyTaxa.fragsByTax.pl +0 -35
  179. data/utils/enveomics/Scripts/MyTaxa.seq-taxrank.rb +0 -49
  180. data/utils/enveomics/Scripts/NCBIacc2tax.rb +0 -92
  181. data/utils/enveomics/Scripts/Newick.autoprune.R +0 -27
  182. data/utils/enveomics/Scripts/RAxML-EPA.to_iToL.pl +0 -228
  183. data/utils/enveomics/Scripts/RecPlot2.compareIdentities.R +0 -32
  184. data/utils/enveomics/Scripts/RefSeq.download.bash +0 -48
  185. data/utils/enveomics/Scripts/SRA.download.bash +0 -57
  186. data/utils/enveomics/Scripts/TRIBS.plot-test.R +0 -36
  187. data/utils/enveomics/Scripts/TRIBS.test.R +0 -39
  188. data/utils/enveomics/Scripts/Table.barplot.R +0 -31
  189. data/utils/enveomics/Scripts/Table.df2dist.R +0 -30
  190. data/utils/enveomics/Scripts/Table.filter.pl +0 -61
  191. data/utils/enveomics/Scripts/Table.merge.pl +0 -77
  192. data/utils/enveomics/Scripts/Table.replace.rb +0 -69
  193. data/utils/enveomics/Scripts/Table.round.rb +0 -63
  194. data/utils/enveomics/Scripts/Table.split.pl +0 -57
  195. data/utils/enveomics/Scripts/Taxonomy.silva2ncbi.rb +0 -227
  196. data/utils/enveomics/Scripts/VCF.KaKs.rb +0 -147
  197. data/utils/enveomics/Scripts/VCF.SNPs.rb +0 -88
  198. data/utils/enveomics/Scripts/aai.rb +0 -418
  199. data/utils/enveomics/Scripts/ani.rb +0 -362
  200. data/utils/enveomics/Scripts/clust.rand.rb +0 -102
  201. data/utils/enveomics/Scripts/gi2tax.rb +0 -103
  202. data/utils/enveomics/Scripts/in_silico_GA_GI.pl +0 -96
  203. data/utils/enveomics/Scripts/lib/data/dupont_2012_essential.hmm.gz +0 -0
  204. data/utils/enveomics/Scripts/lib/data/lee_2019_essential.hmm.gz +0 -0
  205. data/utils/enveomics/Scripts/lib/enveomics.R +0 -1
  206. data/utils/enveomics/Scripts/lib/enveomics_rb/enveomics.rb +0 -24
  207. data/utils/enveomics/Scripts/lib/enveomics_rb/jplace.rb +0 -253
  208. data/utils/enveomics/Scripts/lib/enveomics_rb/og.rb +0 -182
  209. data/utils/enveomics/Scripts/lib/enveomics_rb/remote_data.rb +0 -74
  210. data/utils/enveomics/Scripts/lib/enveomics_rb/seq_range.rb +0 -237
  211. data/utils/enveomics/Scripts/lib/enveomics_rb/stat.rb +0 -30
  212. data/utils/enveomics/Scripts/lib/enveomics_rb/vcf.rb +0 -135
  213. data/utils/enveomics/Scripts/ogs.annotate.rb +0 -88
  214. data/utils/enveomics/Scripts/ogs.core-pan.rb +0 -160
  215. data/utils/enveomics/Scripts/ogs.extract.rb +0 -125
  216. data/utils/enveomics/Scripts/ogs.mcl.rb +0 -186
  217. data/utils/enveomics/Scripts/ogs.rb +0 -104
  218. data/utils/enveomics/Scripts/ogs.stats.rb +0 -131
  219. data/utils/enveomics/Scripts/rbm.rb +0 -146
  220. data/utils/enveomics/Tests/Makefile +0 -10
  221. data/utils/enveomics/Tests/Mgen_M2288.faa +0 -3189
  222. data/utils/enveomics/Tests/Mgen_M2288.fna +0 -8282
  223. data/utils/enveomics/Tests/Mgen_M2321.fna +0 -8288
  224. data/utils/enveomics/Tests/Nequ_Kin4M.faa +0 -2970
  225. data/utils/enveomics/Tests/Xanthomonas_oryzae-PilA.tribs.Rdata +0 -0
  226. data/utils/enveomics/Tests/Xanthomonas_oryzae-PilA.txt +0 -7
  227. data/utils/enveomics/Tests/Xanthomonas_oryzae.aai-mat.tsv +0 -17
  228. data/utils/enveomics/Tests/Xanthomonas_oryzae.aai.tsv +0 -137
  229. data/utils/enveomics/Tests/a_mg.cds-go.blast.tsv +0 -123
  230. data/utils/enveomics/Tests/a_mg.reads-cds.blast.tsv +0 -200
  231. data/utils/enveomics/Tests/a_mg.reads-cds.counts.tsv +0 -55
  232. data/utils/enveomics/Tests/alkB.nwk +0 -1
  233. data/utils/enveomics/Tests/anthrax-cansnp-data.tsv +0 -13
  234. data/utils/enveomics/Tests/anthrax-cansnp-key.tsv +0 -17
  235. data/utils/enveomics/Tests/hiv1.faa +0 -59
  236. data/utils/enveomics/Tests/hiv1.fna +0 -134
  237. data/utils/enveomics/Tests/hiv2.faa +0 -70
  238. data/utils/enveomics/Tests/hiv_mix-hiv1.blast.tsv +0 -233
  239. data/utils/enveomics/Tests/hiv_mix-hiv1.blast.tsv.lim +0 -1
  240. data/utils/enveomics/Tests/hiv_mix-hiv1.blast.tsv.rec +0 -233
  241. data/utils/enveomics/Tests/phyla_counts.tsv +0 -10
  242. data/utils/enveomics/Tests/primate_lentivirus.ogs +0 -11
  243. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv1-hiv1.rbm +0 -9
  244. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv1-hiv2.rbm +0 -8
  245. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv1-siv.rbm +0 -6
  246. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv2-hiv2.rbm +0 -9
  247. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv2-siv.rbm +0 -6
  248. data/utils/enveomics/Tests/primate_lentivirus.rbm/siv-siv.rbm +0 -6
  249. data/utils/enveomics/build_enveomics_r.bash +0 -45
  250. data/utils/enveomics/enveomics.R/DESCRIPTION +0 -31
  251. data/utils/enveomics/enveomics.R/NAMESPACE +0 -39
  252. data/utils/enveomics/enveomics.R/R/autoprune.R +0 -155
  253. data/utils/enveomics/enveomics.R/R/barplot.R +0 -184
  254. data/utils/enveomics/enveomics.R/R/cliopts.R +0 -135
  255. data/utils/enveomics/enveomics.R/R/df2dist.R +0 -154
  256. data/utils/enveomics/enveomics.R/R/growthcurve.R +0 -331
  257. data/utils/enveomics/enveomics.R/R/recplot.R +0 -354
  258. data/utils/enveomics/enveomics.R/R/recplot2.R +0 -1631
  259. data/utils/enveomics/enveomics.R/R/tribs.R +0 -583
  260. data/utils/enveomics/enveomics.R/R/utils.R +0 -50
  261. data/utils/enveomics/enveomics.R/README.md +0 -80
  262. data/utils/enveomics/enveomics.R/data/growth.curves.rda +0 -0
  263. data/utils/enveomics/enveomics.R/data/phyla.counts.rda +0 -0
  264. data/utils/enveomics/enveomics.R/man/cash-enve.GrowthCurve-method.Rd +0 -17
  265. data/utils/enveomics/enveomics.R/man/cash-enve.RecPlot2-method.Rd +0 -17
  266. data/utils/enveomics/enveomics.R/man/cash-enve.RecPlot2.Peak-method.Rd +0 -17
  267. data/utils/enveomics/enveomics.R/man/enve.GrowthCurve-class.Rd +0 -25
  268. data/utils/enveomics/enveomics.R/man/enve.TRIBS-class.Rd +0 -46
  269. data/utils/enveomics/enveomics.R/man/enve.TRIBS.merge.Rd +0 -23
  270. data/utils/enveomics/enveomics.R/man/enve.TRIBStest-class.Rd +0 -47
  271. data/utils/enveomics/enveomics.R/man/enve.__prune.iter.Rd +0 -23
  272. data/utils/enveomics/enveomics.R/man/enve.__prune.reduce.Rd +0 -23
  273. data/utils/enveomics/enveomics.R/man/enve.__tribs.Rd +0 -32
  274. data/utils/enveomics/enveomics.R/man/enve.barplot.Rd +0 -91
  275. data/utils/enveomics/enveomics.R/man/enve.cliopts.Rd +0 -57
  276. data/utils/enveomics/enveomics.R/man/enve.col.alpha.Rd +0 -24
  277. data/utils/enveomics/enveomics.R/man/enve.col2alpha.Rd +0 -19
  278. data/utils/enveomics/enveomics.R/man/enve.df2dist.Rd +0 -39
  279. data/utils/enveomics/enveomics.R/man/enve.df2dist.group.Rd +0 -38
  280. data/utils/enveomics/enveomics.R/man/enve.df2dist.list.Rd +0 -40
  281. data/utils/enveomics/enveomics.R/man/enve.growthcurve.Rd +0 -67
  282. data/utils/enveomics/enveomics.R/man/enve.prune.dist.Rd +0 -37
  283. data/utils/enveomics/enveomics.R/man/enve.recplot.Rd +0 -122
  284. data/utils/enveomics/enveomics.R/man/enve.recplot2-class.Rd +0 -45
  285. data/utils/enveomics/enveomics.R/man/enve.recplot2.ANIr.Rd +0 -24
  286. data/utils/enveomics/enveomics.R/man/enve.recplot2.Rd +0 -68
  287. data/utils/enveomics/enveomics.R/man/enve.recplot2.__counts.Rd +0 -25
  288. data/utils/enveomics/enveomics.R/man/enve.recplot2.__peakHist.Rd +0 -21
  289. data/utils/enveomics/enveomics.R/man/enve.recplot2.__whichClosestPeak.Rd +0 -19
  290. data/utils/enveomics/enveomics.R/man/enve.recplot2.changeCutoff.Rd +0 -19
  291. data/utils/enveomics/enveomics.R/man/enve.recplot2.compareIdentities.Rd +0 -41
  292. data/utils/enveomics/enveomics.R/man/enve.recplot2.coordinates.Rd +0 -29
  293. data/utils/enveomics/enveomics.R/man/enve.recplot2.corePeak.Rd +0 -18
  294. data/utils/enveomics/enveomics.R/man/enve.recplot2.extractWindows.Rd +0 -40
  295. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.Rd +0 -36
  296. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.__em_e.Rd +0 -19
  297. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.__em_m.Rd +0 -19
  298. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.__emauto_one.Rd +0 -27
  299. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.__mow_one.Rd +0 -41
  300. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.__mower.Rd +0 -17
  301. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.em.Rd +0 -43
  302. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.emauto.Rd +0 -37
  303. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.mower.Rd +0 -74
  304. data/utils/enveomics/enveomics.R/man/enve.recplot2.peak-class.Rd +0 -59
  305. data/utils/enveomics/enveomics.R/man/enve.recplot2.seqdepth.Rd +0 -27
  306. data/utils/enveomics/enveomics.R/man/enve.recplot2.windowDepthThreshold.Rd +0 -32
  307. data/utils/enveomics/enveomics.R/man/enve.tribs.Rd +0 -59
  308. data/utils/enveomics/enveomics.R/man/enve.tribs.test.Rd +0 -28
  309. data/utils/enveomics/enveomics.R/man/enve.truncate.Rd +0 -27
  310. data/utils/enveomics/enveomics.R/man/growth.curves.Rd +0 -14
  311. data/utils/enveomics/enveomics.R/man/phyla.counts.Rd +0 -13
  312. data/utils/enveomics/enveomics.R/man/plot.enve.GrowthCurve.Rd +0 -63
  313. data/utils/enveomics/enveomics.R/man/plot.enve.TRIBS.Rd +0 -38
  314. data/utils/enveomics/enveomics.R/man/plot.enve.TRIBStest.Rd +0 -38
  315. data/utils/enveomics/enveomics.R/man/plot.enve.recplot2.Rd +0 -111
  316. data/utils/enveomics/enveomics.R/man/summary.enve.GrowthCurve.Rd +0 -19
  317. data/utils/enveomics/enveomics.R/man/summary.enve.TRIBS.Rd +0 -19
  318. data/utils/enveomics/enveomics.R/man/summary.enve.TRIBStest.Rd +0 -19
  319. data/utils/enveomics/globals.mk +0 -8
  320. data/utils/enveomics/manifest.json +0 -9
@@ -1,50 +0,0 @@
1
- #' Enveomics: Color Alpha
2
- #'
3
- #' Modify alpha in a color (or vector of colors).
4
- #'
5
- #' @param col Color or vector of colors. It can be any value supported by
6
- #' \code{\link[grDevices]{col2rgb}}, such as \code{darkred} or \code{#009988}.
7
- #' @param alpha Alpha value to add to the color, from 0 to 1.
8
- #'
9
- #' @return Returns a color or a vector of colors in \emph{hex} notation,
10
- #' including \code{alpha}.
11
- #'
12
- #' @author Luis M. Rodriguez-R [aut, cre]
13
- #'
14
- #' @export
15
-
16
- enve.col.alpha <- function
17
- (col,
18
- alpha=1/2
19
- ){
20
- return(
21
- apply(col2rgb(col), 2,
22
- function(x) do.call(rgb, as.list(c(x[1:3]/256, alpha))) ) )
23
- }
24
-
25
- #' Enveomics: Truncate
26
- #'
27
- #' Removes the \code{n} highest and lowest values from a vector, and applies
28
- #' summary function. The value of \code{n} is determined such that the central
29
- #' range is used, corresponding to the \code{f} fraction of values.
30
- #'
31
- #' @param x A vector of numbers.
32
- #' @param f The fraction of values to retain.
33
- #' @param FUN Summary function to apply to the vectors. To obtain the
34
- #' truncated vector itself, use \code{c}.
35
- #'
36
- #' @return Returns the summary \code{(FUN)} of the truncated vector.
37
- #'
38
- #' @author Luis M. Rodriguez-R [aut, cre]
39
- #'
40
- #' @export
41
-
42
- enve.truncate <- function
43
- (x,
44
- f=0.95,
45
- FUN=mean
46
- ){
47
- n <- round(length(x)*(1-f)/2)
48
- y <- sort(x)[ -c(seq(1, n), seq(length(x)+1-n, length(x))) ]
49
- return(FUN(y))
50
- }
@@ -1,80 +0,0 @@
1
- # enveomics.R
2
-
3
- ## Installing `enveomics.R`
4
- To install the latest version of `enveomics.R` uploaded to CRAN, execute in R:
5
-
6
- ```R
7
- install.packages('enveomics.R')
8
- ```
9
-
10
- To install the current developer version of `enveomics.R`, execute in R:
11
-
12
- ```R
13
- install.packages('devtools')
14
- library('devtools')
15
- install_github('lmrodriguezr/enveomics', subdir='enveomics.R')
16
- ```
17
-
18
- ## Using `enveomics.R`
19
- To load enveomics.R, simply execute:
20
-
21
- ```R
22
- library(enveomics.R);
23
- ```
24
-
25
- And open help messages using any of the following commands:
26
-
27
- ```R
28
- ?enveomics.R
29
- ?enve.barplot
30
- ?enve.recplot2
31
- ?enve.recplot2.compareIdentities
32
- ?enve.recplot2.changeCutoff
33
- ?enve.recplot2.findPeaks
34
- ?enve.recplot2.corePeak
35
- ?enve.recplot2.windowDepthThreshold
36
- ?enve.recplot2.extractWindows
37
- ?enve.recplot2.coordinates
38
- ?enve.recplot2.seqdepth
39
- ?enve.recplot2.ANIr
40
- ?enve.prune.dist
41
- ?enve.tribs
42
- ?enve.tribs.test
43
- ?enve.growthcurve
44
- ?enve.col.alpha
45
- ?enve.truncate
46
- ```
47
-
48
- You can run some examples using these libraries in the
49
- [enveomics-GUI](https://github.com/lmrodriguezr/enveomics-gui).
50
-
51
- For additional information on recruitment plots, see the
52
- [Recruitment plots working document](https://github.com/lmrodriguezr/enveomics/blob/master/Docs/recplot2.md).
53
-
54
- ## Changelog
55
- * 1.7.1: Improved efficiency of `enve.df2dist` about five-fold.
56
- * 1.7.0: Uniformized output for `enve.recplot2.extractWindows` and
57
- `enve.recplot2.coordinates` to ease automation. Thanks to Tomeu Viver and
58
- Roth Conrad for troubleshooting.
59
- * 1.6.0: Speed up in recplot2 with proper structure manipulation
60
- (by: Kenji Gerhardt). Also, default value for `id.breaks` was changed from
61
- 300 to 60.
62
- * 1.5.0: Modernized documentation, now in ROxygen2 (by: Tatyana Kiryutina)
63
- * 1.4.4: Removes modeest library as requirement, and replaces mower peak-finder
64
- initialization to median (instead of mode).
65
- * 1.4.2: Solved bug #36.
66
- * 1.4.0: New option `pos.breaks.tsv` for `enve.recplot2`.
67
- * 1.3.4: Gracefully handles and plots recruitment plots with insufficient data
68
- to find peaks.
69
- * 1.3.3: New function `enve.recplot2.windowDepthThreshold`.
70
- * 1.3.2: New option `panel.fun` for `plot.enve.RecPlot2`.
71
- * 1.3.1: New function enve.truncate.
72
- * 1.3: Several bug fixes and new utilities for recruitment plots (recplot2).
73
- * 1.1.0: New function enve.growthcurve and related class enve.GrowthCurve
74
- with S3 methods plot and summary.
75
- * 1.0.2: Fine-tuned default parameters in enve.recplot2.findPeaks and
76
- solved a minor bug in enve.recplot2 that caused failures in low-coverage
77
- datasets when using too many threads.
78
- * 1.0.1: enve.recplot2 now supports pos.breaks=0 to define a
79
- bin per subject sequence.
80
-
@@ -1,17 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/growthcurve.R
3
- \docType{methods}
4
- \name{$,enve.GrowthCurve-method}
5
- \alias{$,enve.GrowthCurve-method}
6
- \title{Attribute accessor}
7
- \usage{
8
- \S4method{$}{enve.GrowthCurve}(x, name)
9
- }
10
- \arguments{
11
- \item{x}{Object}
12
-
13
- \item{name}{Attribute name}
14
- }
15
- \description{
16
- Attribute accessor
17
- }
@@ -1,17 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/recplot2.R
3
- \docType{methods}
4
- \name{$,enve.RecPlot2-method}
5
- \alias{$,enve.RecPlot2-method}
6
- \title{Attribute accessor}
7
- \usage{
8
- \S4method{$}{enve.RecPlot2}(x, name)
9
- }
10
- \arguments{
11
- \item{x}{Object}
12
-
13
- \item{name}{Attribute name}
14
- }
15
- \description{
16
- Attribute accessor
17
- }
@@ -1,17 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/recplot2.R
3
- \docType{methods}
4
- \name{$,enve.RecPlot2.Peak-method}
5
- \alias{$,enve.RecPlot2.Peak-method}
6
- \title{Attribute accessor}
7
- \usage{
8
- \S4method{$}{enve.RecPlot2.Peak}(x, name)
9
- }
10
- \arguments{
11
- \item{x}{Object}
12
-
13
- \item{name}{Attribute name}
14
- }
15
- \description{
16
- Attribute accessor
17
- }
@@ -1,25 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/growthcurve.R
3
- \docType{class}
4
- \name{enve.GrowthCurve-class}
5
- \alias{enve.GrowthCurve-class}
6
- \alias{enve.GrowthCurve}
7
- \title{Enveomics: Growth Curve S4 Class}
8
- \description{
9
- Enve-omics representation of fitted growth curves.
10
- }
11
- \section{Slots}{
12
-
13
- \describe{
14
- \item{\code{design}}{\code{(array)} Experimental design of the experiment.}
15
-
16
- \item{\code{models}}{\code{(list)} Fitted growth curve models.}
17
-
18
- \item{\code{predict}}{\code{(list)} Fitted growth curve values.}
19
-
20
- \item{\code{call}}{\code{(call)} Call producing this object.}
21
- }}
22
-
23
- \author{
24
- Luis M. Rodriguez-R [aut, cre]
25
- }
@@ -1,46 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/tribs.R
3
- \docType{class}
4
- \name{enve.TRIBS-class}
5
- \alias{enve.TRIBS-class}
6
- \alias{enve.TRIBS}
7
- \title{Enveomics: TRIBS S4 Class}
8
- \description{
9
- Enve-omics representation of "Transformed-space Resampling In Biased Sets
10
- (TRIBS)". This object represents sets of distances between objects,
11
- sampled nearly-uniformly at random in "distance space". Subsampling
12
- without selection is trivial, since both the distances space and the
13
- selection occur in the same transformed space. However, it's useful to
14
- compare randomly subsampled sets against a selected set of objects. This
15
- is intended to identify overdispersion or overclustering (see
16
- \code{\link{enve.TRIBStest}}) of a subset against the entire collection of objects
17
- with minimum impact of sampling biases. This object can be produced by
18
- \code{\link{enve.tribs}} and supports S4 methods \code{plot} and \code{summary}.
19
- }
20
- \section{Slots}{
21
-
22
- \describe{
23
- \item{\code{distance}}{\code{(numeric)} Centrality measurement of the distances
24
- between the selected objects (without subsampling).}
25
-
26
- \item{\code{points}}{\code{(matrix)} Position of the different objects in distance
27
- space.}
28
-
29
- \item{\code{distances}}{\code{(matrix)} Subsampled distances, where the rows are
30
- replicates and the columns are subsampling levels.}
31
-
32
- \item{\code{spaceSize}}{\code{(numeric)} Number of objects.}
33
-
34
- \item{\code{selSize}}{\code{(numeric)} Number of selected objects.}
35
-
36
- \item{\code{dimensions}}{\code{(numeric)} Number of dimensions in the distance space.}
37
-
38
- \item{\code{subsamples}}{\code{(numeric)} Subsampling levels (as fractions, from
39
- 0 to 1).}
40
-
41
- \item{\code{call}}{\code{(call)} Call producing this object.}
42
- }}
43
-
44
- \author{
45
- Luis M. Rodriguez-R [aut, cre]
46
- }
@@ -1,23 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/tribs.R
3
- \name{enve.TRIBS.merge}
4
- \alias{enve.TRIBS.merge}
5
- \title{Enveomics: TRIBS Merge}
6
- \usage{
7
- enve.TRIBS.merge(x, y)
8
- }
9
- \arguments{
10
- \item{x}{First \code{\link{enve.TRIBS}} object.}
11
-
12
- \item{y}{Second \code{\link{enve.TRIBS}} object.}
13
- }
14
- \value{
15
- Returns an \code{\link{enve.TRIBS}} object.
16
- }
17
- \description{
18
- Merges two \code{\link{enve.TRIBS}} objects generated from the same objects at
19
- different subsampling levels.
20
- }
21
- \author{
22
- Luis M. Rodriguez-R [aut, cre]
23
- }
@@ -1,47 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/tribs.R
3
- \docType{class}
4
- \name{enve.TRIBStest-class}
5
- \alias{enve.TRIBStest-class}
6
- \alias{enve.TRIBStest}
7
- \title{Enveomics: TRIBS Test S4 Class}
8
- \description{
9
- Test of significance of overclustering or overdispersion in a selected
10
- set of objects with respect to the entire set (see \code{\link{enve.TRIBS}}). This
11
- object can be produced by \code{\link{enve.tribs.test}} and supports S4 methods
12
- \code{plot} and \code{summary}.
13
- }
14
- \section{Slots}{
15
-
16
- \describe{
17
- \item{\code{pval.gt}}{\code{(numeric)}
18
- P-value for the overdispersion test.}
19
-
20
- \item{\code{pval.lt}}{\code{(numeric)}
21
- P-value for the overclustering test.}
22
-
23
- \item{\code{all.dist}}{\code{(numeric)}
24
- Empiric PDF of distances for the entire dataset (subsampled at selection
25
- size).}
26
-
27
- \item{\code{sel.dist}}{\code{(numeric)}
28
- Empiric PDF of distances for the selected objects (without subsampling).}
29
-
30
- \item{\code{diff.dist}}{\code{(numeric)}
31
- Empiric PDF of the difference between \code{all.dist} and \code{sel.dist}.
32
- The p-values are estimating by comparing areas in this PDF greater than and
33
- lesser than zero.}
34
-
35
- \item{\code{dist.mids}}{\code{(numeric)}
36
- Midpoints of the empiric PDFs of distances.}
37
-
38
- \item{\code{diff.mids}}{\code{(numeric)}
39
- Midpoints of the empiric PDF of difference of distances.}
40
-
41
- \item{\code{call}}{\code{(call)}
42
- Call producing this object.}
43
- }}
44
-
45
- \author{
46
- Luis M. Rodriguez-R [aut, cre]
47
- }
@@ -1,23 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/autoprune.R
3
- \name{enve.__prune.iter}
4
- \alias{enve.__prune.iter}
5
- \title{Enveomics: Prune Iter (Internal Function)}
6
- \usage{
7
- enve.__prune.iter(t, dist, min_dist, quiet)
8
- }
9
- \arguments{
10
- \item{t}{A \strong{phylo} object}
11
-
12
- \item{dist}{Cophenetic distance matrix}
13
-
14
- \item{min_dist}{Minimum distance}
15
-
16
- \item{quiet}{If running quietly}
17
- }
18
- \description{
19
- Internal function for \code{\link{enve.prune.dist}}.
20
- }
21
- \author{
22
- Luis M. Rodriguez-R [aut, cre]
23
- }
@@ -1,23 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/autoprune.R
3
- \name{enve.__prune.reduce}
4
- \alias{enve.__prune.reduce}
5
- \title{Enveomics: Prune Reduce (Internal Function)}
6
- \usage{
7
- enve.__prune.reduce(t, nodes, min_dist, quiet)
8
- }
9
- \arguments{
10
- \item{t}{A \strong{phylo} object}
11
-
12
- \item{nodes}{Vector of nodes}
13
-
14
- \item{min_dist}{Minimum distance}
15
-
16
- \item{quiet}{If running quietly}
17
- }
18
- \description{
19
- Internal function for \code{\link{enve.prune.dist}}.
20
- }
21
- \author{
22
- Luis M. Rodriguez-R [aut, cre]
23
- }
@@ -1,32 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/tribs.R
3
- \name{enve.__tribs}
4
- \alias{enve.__tribs}
5
- \title{Enveomics: TRIBS - Internal Ancillary Function}
6
- \usage{
7
- enve.__tribs(rep, frx, selection, dimensions, dots, dist.method,
8
- summary.fx, dist)
9
- }
10
- \arguments{
11
- \item{rep}{Replicates}
12
-
13
- \item{frx}{Fraction}
14
-
15
- \item{selection}{Selection}
16
-
17
- \item{dimensions}{Dimensions}
18
-
19
- \item{dots}{Sampling points}
20
-
21
- \item{dist.method}{Distance method}
22
-
23
- \item{summary.fx}{Summary function}
24
-
25
- \item{dist}{Distance}
26
- }
27
- \description{
28
- Internal ancillary function (see \code{\link{enve.tribs}}).
29
- }
30
- \author{
31
- Luis M. Rodriguez-R [aut, cre]
32
- }
@@ -1,91 +0,0 @@
1
- % Generated by roxygen2: do not edit by hand
2
- % Please edit documentation in R/barplot.R
3
- \name{enve.barplot}
4
- \alias{enve.barplot}
5
- \title{Enveomics: Barplot}
6
- \usage{
7
- enve.barplot(x, sizes, top = 25, colors.per.group = 9,
8
- bars.width = 4, legend.ncol = 1, other.col = "#000000",
9
- add.trend = FALSE, organic.trend = FALSE, sort.by = median,
10
- min.report = 101, order = NULL, col, ...)
11
- }
12
- \arguments{
13
- \item{x}{Can be either the input data or the path to the file containing
14
- the table.
15
- \itemize{
16
- \item{If it contains the data, it must be a data frame or an
17
- object coercible to a data frame.}
18
- \item{If it is a path, it must point to a
19
- tab-delimited file containing a header (first row) and row names
20
- (first column).}
21
- }}
22
-
23
- \item{sizes}{A numeric vector containing the real size of the samples
24
- (columns) in the same order of the input table. If set, the values are
25
- assumed to be 100\%. Otherwise, the sum of the columns is used.}
26
-
27
- \item{top}{Maximum number of categories to display. Any additional
28
- categories will be listed as "Others".}
29
-
30
- \item{colors.per.group}{Number of categories in the first two saturation
31
- groups of colors. The third group contains the remaining categories if
32
- needed.}
33
-
34
- \item{bars.width}{Width of the barplot with respect to the legend.}
35
-
36
- \item{legend.ncol}{Number of columns in the legend.}
37
-
38
- \item{other.col}{Color of the "Others" category.}
39
-
40
- \item{add.trend}{Controls if semi-transparent areas are to be plotted
41
- between the bars to connect the regions (trend regions).}
42
-
43
- \item{organic.trend}{Controls if the trend regions are to be smoothed
44
- (curves). By default, trend regions have straight edges. If \code{TRUE},
45
- forces \code{add.trend=TRUE}.}
46
-
47
- \item{sort.by}{Any function that takes a numeric vector and returns a
48
- numeric scalar. This function is applied to each row, and the resulting
49
- values are used to sort the rows (decreasingly). Good options include:
50
- \code{sd, min, max, mean, median}.}
51
-
52
- \item{min.report}{Minimum percentage to report the value in the plot.
53
- Any value above 100 indicates that no values are to be reported.}
54
-
55
- \item{order}{Controls how the rows should be ordered.
56
- \itemize{
57
- \item{If \code{NULL}
58
- (default), \code{sort.by} is applied per row and the results are
59
- sorted decreasingly.}
60
- \item{If \code{NA}, no sorting is performed, i.e., the original
61
- order is respected.}
62
- \item{If a vector is provided, it is assumed to be the
63
- custom order to be used (either by numeric index or by row names).}
64
- }}
65
-
66
- \item{col}{Colors to use. If provided, overrides the variables \code{top}
67
- and \code{colors.per.group}, but \code{other.col} is still used if the
68
- vector is insufficient for all the rows. An additional palette is available with
69
- \code{col='coto'} (contributed by Luis (Coto) Orellana).}
70
-
71
- \item{...}{Any additional parameters to be passed to barplot.}
72
- }
73
- \description{
74
- Creates nice barplots from tab-delimited tables.
75
- }
76
- \examples{
77
- # Load data
78
- data("phyla.counts", package="enveomics.R", envir=environment())
79
- # Create a barplot sorted by variance with organic trends
80
- enve.barplot(
81
- phyla.counts, # Counts of phyla in four sites
82
- sizes=c(250,100,75,200), # Total sizes of the datasets of each site
83
- bars.width=2, # Decrease from default, so the names are fully displayed
84
- organic.trend=TRUE, # Nice curvy background
85
- sort.by=var # Sort by variance across sites
86
- )
87
-
88
- }
89
- \author{
90
- Luis M. Rodriguez-R [aut, cre]
91
- }