miga-base 0.3.0.0 → 0.3.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (260) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +21 -4
  3. data/actions/init.rb +258 -0
  4. data/actions/run_local.rb +1 -2
  5. data/actions/test_taxonomy.rb +4 -1
  6. data/bin/miga +8 -1
  7. data/lib/miga/dataset.rb +4 -4
  8. data/lib/miga/dataset_result.rb +7 -4
  9. data/lib/miga/version.rb +2 -2
  10. data/scripts/_distances_noref_nomulti.bash +3 -1
  11. data/scripts/clade_finding.bash +1 -1
  12. data/scripts/init.bash +1 -1
  13. data/scripts/miga.bash +1 -1
  14. data/scripts/mytaxa.bash +78 -72
  15. data/scripts/mytaxa_scan.bash +67 -62
  16. data/scripts/ogs.bash +1 -1
  17. data/scripts/trimmed_fasta.bash +4 -3
  18. data/utils/enveomics/Examples/aai-matrix.bash +66 -0
  19. data/utils/enveomics/Examples/ani-matrix.bash +66 -0
  20. data/utils/enveomics/Examples/essential-phylogeny.bash +105 -0
  21. data/utils/enveomics/Examples/unus-genome-phylogeny.bash +100 -0
  22. data/utils/enveomics/LICENSE.txt +73 -0
  23. data/utils/enveomics/Makefile +52 -0
  24. data/utils/enveomics/Manifest/Tasks/aasubs.json +103 -0
  25. data/utils/enveomics/Manifest/Tasks/blasttab.json +703 -0
  26. data/utils/enveomics/Manifest/Tasks/distances.json +161 -0
  27. data/utils/enveomics/Manifest/Tasks/fasta.json +571 -0
  28. data/utils/enveomics/Manifest/Tasks/fastq.json +208 -0
  29. data/utils/enveomics/Manifest/Tasks/graphics.json +126 -0
  30. data/utils/enveomics/Manifest/Tasks/ogs.json +339 -0
  31. data/utils/enveomics/Manifest/Tasks/other.json +746 -0
  32. data/utils/enveomics/Manifest/Tasks/remote.json +355 -0
  33. data/utils/enveomics/Manifest/Tasks/sequence-identity.json +454 -0
  34. data/utils/enveomics/Manifest/Tasks/tables.json +308 -0
  35. data/utils/enveomics/Manifest/Tasks/trees.json +68 -0
  36. data/utils/enveomics/Manifest/Tasks/variants.json +111 -0
  37. data/utils/enveomics/Manifest/categories.json +132 -0
  38. data/utils/enveomics/Manifest/examples.json +154 -0
  39. data/utils/enveomics/Manifest/tasks.json +4 -0
  40. data/utils/enveomics/Pipelines/assembly.pbs/CONFIG.mock.bash +69 -0
  41. data/utils/enveomics/Pipelines/assembly.pbs/FastA.N50.pl +56 -0
  42. data/utils/enveomics/Pipelines/assembly.pbs/FastA.filterN.pl +60 -0
  43. data/utils/enveomics/Pipelines/assembly.pbs/FastA.length.pl +38 -0
  44. data/utils/enveomics/Pipelines/assembly.pbs/README.md +189 -0
  45. data/utils/enveomics/Pipelines/assembly.pbs/RUNME-2.bash +112 -0
  46. data/utils/enveomics/Pipelines/assembly.pbs/RUNME-3.bash +23 -0
  47. data/utils/enveomics/Pipelines/assembly.pbs/RUNME-4.bash +44 -0
  48. data/utils/enveomics/Pipelines/assembly.pbs/RUNME.bash +50 -0
  49. data/utils/enveomics/Pipelines/assembly.pbs/kSelector.R +37 -0
  50. data/utils/enveomics/Pipelines/assembly.pbs/newbler.pbs +68 -0
  51. data/utils/enveomics/Pipelines/assembly.pbs/newbler_preparator.pl +49 -0
  52. data/utils/enveomics/Pipelines/assembly.pbs/soap.pbs +80 -0
  53. data/utils/enveomics/Pipelines/assembly.pbs/stats.pbs +57 -0
  54. data/utils/enveomics/Pipelines/assembly.pbs/velvet.pbs +63 -0
  55. data/utils/enveomics/Pipelines/blast.pbs/01.pbs.bash +38 -0
  56. data/utils/enveomics/Pipelines/blast.pbs/02.pbs.bash +73 -0
  57. data/utils/enveomics/Pipelines/blast.pbs/03.pbs.bash +21 -0
  58. data/utils/enveomics/Pipelines/blast.pbs/BlastTab.recover_job.pl +72 -0
  59. data/utils/enveomics/Pipelines/blast.pbs/CONFIG.mock.bash +98 -0
  60. data/utils/enveomics/Pipelines/blast.pbs/FastA.split.pl +55 -0
  61. data/utils/enveomics/Pipelines/blast.pbs/README.md +127 -0
  62. data/utils/enveomics/Pipelines/blast.pbs/RUNME.bash +109 -0
  63. data/utils/enveomics/Pipelines/blast.pbs/TASK.check.bash +128 -0
  64. data/utils/enveomics/Pipelines/blast.pbs/TASK.dry.bash +16 -0
  65. data/utils/enveomics/Pipelines/blast.pbs/TASK.eo.bash +22 -0
  66. data/utils/enveomics/Pipelines/blast.pbs/TASK.pause.bash +26 -0
  67. data/utils/enveomics/Pipelines/blast.pbs/TASK.run.bash +89 -0
  68. data/utils/enveomics/Pipelines/blast.pbs/sentinel.pbs.bash +29 -0
  69. data/utils/enveomics/Pipelines/idba.pbs/README.md +49 -0
  70. data/utils/enveomics/Pipelines/idba.pbs/RUNME.bash +95 -0
  71. data/utils/enveomics/Pipelines/idba.pbs/run.pbs +56 -0
  72. data/utils/enveomics/Pipelines/trim.pbs/README.md +54 -0
  73. data/utils/enveomics/Pipelines/trim.pbs/RUNME.bash +70 -0
  74. data/utils/enveomics/Pipelines/trim.pbs/run.pbs +130 -0
  75. data/utils/enveomics/README.md +40 -0
  76. data/utils/enveomics/Scripts/AAsubs.log2ratio.rb +171 -0
  77. data/utils/enveomics/Scripts/Aln.cat.rb +162 -0
  78. data/utils/enveomics/Scripts/Aln.convert.pl +35 -0
  79. data/utils/enveomics/Scripts/AlphaDiversity.pl +152 -0
  80. data/utils/enveomics/Scripts/BlastPairwise.AAsubs.pl +102 -0
  81. data/utils/enveomics/Scripts/BlastTab.addlen.rb +61 -0
  82. data/utils/enveomics/Scripts/BlastTab.advance.bash +48 -0
  83. data/utils/enveomics/Scripts/BlastTab.best_hit_sorted.pl +55 -0
  84. data/utils/enveomics/Scripts/BlastTab.catsbj.pl +106 -0
  85. data/utils/enveomics/Scripts/BlastTab.cogCat.rb +76 -0
  86. data/utils/enveomics/Scripts/BlastTab.filter.pl +47 -0
  87. data/utils/enveomics/Scripts/BlastTab.kegg_pep2path_rest.pl +194 -0
  88. data/utils/enveomics/Scripts/BlastTab.metaxaPrep.pl +104 -0
  89. data/utils/enveomics/Scripts/BlastTab.pairedHits.rb +157 -0
  90. data/utils/enveomics/Scripts/BlastTab.recplot2.R +40 -0
  91. data/utils/enveomics/Scripts/BlastTab.seqdepth.pl +86 -0
  92. data/utils/enveomics/Scripts/BlastTab.seqdepth_ZIP.pl +119 -0
  93. data/utils/enveomics/Scripts/BlastTab.seqdepth_nomedian.pl +86 -0
  94. data/utils/enveomics/Scripts/BlastTab.subsample.pl +47 -0
  95. data/utils/enveomics/Scripts/BlastTab.sumPerHit.pl +114 -0
  96. data/utils/enveomics/Scripts/BlastTab.taxid2taxrank.pl +90 -0
  97. data/utils/enveomics/Scripts/BlastTab.topHits_sorted.rb +101 -0
  98. data/utils/enveomics/Scripts/Chao1.pl +97 -0
  99. data/utils/enveomics/Scripts/CharTable.classify.rb +234 -0
  100. data/utils/enveomics/Scripts/EBIseq2tax.rb +83 -0
  101. data/utils/enveomics/Scripts/FastA.N50.pl +56 -0
  102. data/utils/enveomics/Scripts/FastA.filter.pl +52 -0
  103. data/utils/enveomics/Scripts/FastA.filterLen.pl +28 -0
  104. data/utils/enveomics/Scripts/FastA.filterN.pl +60 -0
  105. data/utils/enveomics/Scripts/FastA.fragment.rb +92 -0
  106. data/utils/enveomics/Scripts/FastA.gc.pl +42 -0
  107. data/utils/enveomics/Scripts/FastA.interpose.pl +87 -0
  108. data/utils/enveomics/Scripts/FastA.length.pl +38 -0
  109. data/utils/enveomics/Scripts/FastA.per_file.pl +36 -0
  110. data/utils/enveomics/Scripts/FastA.qlen.pl +57 -0
  111. data/utils/enveomics/Scripts/FastA.rename.pl +65 -0
  112. data/utils/enveomics/Scripts/FastA.revcom.pl +23 -0
  113. data/utils/enveomics/Scripts/FastA.slider.pl +85 -0
  114. data/utils/enveomics/Scripts/FastA.split.pl +55 -0
  115. data/utils/enveomics/Scripts/FastA.subsample.pl +131 -0
  116. data/utils/enveomics/Scripts/FastA.tag.rb +64 -0
  117. data/utils/enveomics/Scripts/FastA.wrap.rb +48 -0
  118. data/utils/enveomics/Scripts/FastQ.filter.pl +54 -0
  119. data/utils/enveomics/Scripts/FastQ.interpose.pl +90 -0
  120. data/utils/enveomics/Scripts/FastQ.offset.pl +90 -0
  121. data/utils/enveomics/Scripts/FastQ.split.pl +53 -0
  122. data/utils/enveomics/Scripts/FastQ.tag.rb +63 -0
  123. data/utils/enveomics/Scripts/FastQ.toFastA.awk +24 -0
  124. data/utils/enveomics/Scripts/GenBank.add_fields.rb +84 -0
  125. data/utils/enveomics/Scripts/HMM.essential.rb +254 -0
  126. data/utils/enveomics/Scripts/HMMsearch.extractIds.rb +83 -0
  127. data/utils/enveomics/Scripts/JPlace.distances.rb +88 -0
  128. data/utils/enveomics/Scripts/JPlace.to_iToL.rb +306 -0
  129. data/utils/enveomics/Scripts/M5nr.getSequences.rb +81 -0
  130. data/utils/enveomics/Scripts/MeTaxa.distribution.pl +198 -0
  131. data/utils/enveomics/Scripts/MyTaxa.fragsByTax.pl +35 -0
  132. data/utils/enveomics/Scripts/MyTaxa.seq-taxrank.rb +49 -0
  133. data/utils/enveomics/Scripts/NCBIacc2tax.rb +92 -0
  134. data/utils/enveomics/Scripts/Newick.autoprune.R +27 -0
  135. data/utils/enveomics/Scripts/RAxML-EPA.to_iToL.pl +228 -0
  136. data/utils/enveomics/Scripts/RefSeq.download.bash +48 -0
  137. data/utils/enveomics/Scripts/SRA.download.bash +50 -0
  138. data/utils/enveomics/Scripts/TRIBS.plot-test.R +36 -0
  139. data/utils/enveomics/Scripts/TRIBS.test.R +39 -0
  140. data/utils/enveomics/Scripts/Table.barplot.R +30 -0
  141. data/utils/enveomics/Scripts/Table.df2dist.R +30 -0
  142. data/utils/enveomics/Scripts/Table.filter.pl +61 -0
  143. data/utils/enveomics/Scripts/Table.merge.pl +77 -0
  144. data/utils/enveomics/Scripts/Table.replace.rb +69 -0
  145. data/utils/enveomics/Scripts/Table.round.rb +63 -0
  146. data/utils/enveomics/Scripts/Table.split.pl +57 -0
  147. data/utils/enveomics/Scripts/Taxonomy.silva2ncbi.rb +227 -0
  148. data/utils/enveomics/Scripts/VCF.KaKs.rb +147 -0
  149. data/utils/enveomics/Scripts/VCF.SNPs.rb +88 -0
  150. data/utils/enveomics/Scripts/aai.rb +373 -0
  151. data/utils/enveomics/Scripts/ani.rb +362 -0
  152. data/utils/enveomics/Scripts/gi2tax.rb +103 -0
  153. data/utils/enveomics/Scripts/in_silico_GA_GI.pl +96 -0
  154. data/utils/enveomics/Scripts/lib/data/essential.hmm.gz +0 -0
  155. data/utils/enveomics/Scripts/lib/enveomics_rb/enveomics.rb +26 -0
  156. data/utils/enveomics/Scripts/lib/enveomics_rb/jplace.rb +253 -0
  157. data/utils/enveomics/Scripts/lib/enveomics_rb/og.rb +182 -0
  158. data/utils/enveomics/Scripts/lib/enveomics_rb/remote_data.rb +74 -0
  159. data/utils/enveomics/Scripts/lib/enveomics_rb/seq_range.rb +237 -0
  160. data/utils/enveomics/Scripts/lib/enveomics_rb/stat.rb +30 -0
  161. data/utils/enveomics/Scripts/lib/enveomics_rb/vcf.rb +135 -0
  162. data/utils/enveomics/Scripts/ogs.annotate.rb +88 -0
  163. data/utils/enveomics/Scripts/ogs.core-pan.rb +160 -0
  164. data/utils/enveomics/Scripts/ogs.extract.rb +125 -0
  165. data/utils/enveomics/Scripts/ogs.mcl.rb +186 -0
  166. data/utils/enveomics/Scripts/ogs.rb +104 -0
  167. data/utils/enveomics/Scripts/ogs.stats.rb +131 -0
  168. data/utils/enveomics/Scripts/rbm.rb +137 -0
  169. data/utils/enveomics/Tests/Makefile +10 -0
  170. data/utils/enveomics/Tests/Mgen_M2288.faa +3189 -0
  171. data/utils/enveomics/Tests/Mgen_M2288.fna +8282 -0
  172. data/utils/enveomics/Tests/Mgen_M2321.fna +8288 -0
  173. data/utils/enveomics/Tests/Nequ_Kin4M.faa +2970 -0
  174. data/utils/enveomics/Tests/Xanthomonas_oryzae-PilA.tribs.Rdata +0 -0
  175. data/utils/enveomics/Tests/Xanthomonas_oryzae-PilA.txt +7 -0
  176. data/utils/enveomics/Tests/Xanthomonas_oryzae.aai-mat.tsv +17 -0
  177. data/utils/enveomics/Tests/Xanthomonas_oryzae.aai.tsv +137 -0
  178. data/utils/enveomics/Tests/a_mg.cds-go.blast.tsv +123 -0
  179. data/utils/enveomics/Tests/a_mg.reads-cds.blast.tsv +200 -0
  180. data/utils/enveomics/Tests/a_mg.reads-cds.counts.tsv +55 -0
  181. data/utils/enveomics/Tests/alkB.nwk +1 -0
  182. data/utils/enveomics/Tests/anthrax-cansnp-data.tsv +13 -0
  183. data/utils/enveomics/Tests/anthrax-cansnp-key.tsv +17 -0
  184. data/utils/enveomics/Tests/hiv1.faa +59 -0
  185. data/utils/enveomics/Tests/hiv1.fna +134 -0
  186. data/utils/enveomics/Tests/hiv2.faa +70 -0
  187. data/utils/enveomics/Tests/hiv_mix-hiv1.blast.tsv +233 -0
  188. data/utils/enveomics/Tests/hiv_mix-hiv1.blast.tsv.lim +1 -0
  189. data/utils/enveomics/Tests/hiv_mix-hiv1.blast.tsv.rec +233 -0
  190. data/utils/enveomics/Tests/phyla_counts.tsv +10 -0
  191. data/utils/enveomics/Tests/primate_lentivirus.ogs +11 -0
  192. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv1-hiv1.rbm +9 -0
  193. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv1-hiv2.rbm +8 -0
  194. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv1-siv.rbm +6 -0
  195. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv2-hiv2.rbm +9 -0
  196. data/utils/enveomics/Tests/primate_lentivirus.rbm/hiv2-siv.rbm +6 -0
  197. data/utils/enveomics/Tests/primate_lentivirus.rbm/siv-siv.rbm +6 -0
  198. data/utils/enveomics/build_enveomics_r.bash +44 -0
  199. data/utils/enveomics/enveomics.R/DESCRIPTION +31 -0
  200. data/utils/enveomics/enveomics.R/NAMESPACE +35 -0
  201. data/utils/enveomics/enveomics.R/R/autoprune.R +121 -0
  202. data/utils/enveomics/enveomics.R/R/barplot.R +165 -0
  203. data/utils/enveomics/enveomics.R/R/cliopts.R +119 -0
  204. data/utils/enveomics/enveomics.R/R/df2dist.R +117 -0
  205. data/utils/enveomics/enveomics.R/R/growthcurve.R +263 -0
  206. data/utils/enveomics/enveomics.R/R/recplot.R +320 -0
  207. data/utils/enveomics/enveomics.R/R/recplot2.R +745 -0
  208. data/utils/enveomics/enveomics.R/R/tribs.R +423 -0
  209. data/utils/enveomics/enveomics.R/R/utils.R +16 -0
  210. data/utils/enveomics/enveomics.R/README.md +52 -0
  211. data/utils/enveomics/enveomics.R/data/growth.curves.rda +0 -0
  212. data/utils/enveomics/enveomics.R/data/phyla.counts.rda +0 -0
  213. data/utils/enveomics/enveomics.R/man/enve.GrowthCurve-class.Rd +30 -0
  214. data/utils/enveomics/enveomics.R/man/enve.TRIBS-class.Rd +43 -0
  215. data/utils/enveomics/enveomics.R/man/enve.TRIBS.merge.Rd +19 -0
  216. data/utils/enveomics/enveomics.R/man/enve.TRIBStest-class.Rd +37 -0
  217. data/utils/enveomics/enveomics.R/man/enve.__prune.iter.Rd +24 -0
  218. data/utils/enveomics/enveomics.R/man/enve.__prune.reduce.Rd +24 -0
  219. data/utils/enveomics/enveomics.R/man/enve.__tribs.Rd +33 -0
  220. data/utils/enveomics/enveomics.R/man/enve.barplot.Rd +64 -0
  221. data/utils/enveomics/enveomics.R/man/enve.cliopts.Rd +37 -0
  222. data/utils/enveomics/enveomics.R/man/enve.col.alpha.Rd +19 -0
  223. data/utils/enveomics/enveomics.R/man/enve.col2alpha.Rd +18 -0
  224. data/utils/enveomics/enveomics.R/man/enve.df2dist.Rd +26 -0
  225. data/utils/enveomics/enveomics.R/man/enve.df2dist.group.Rd +25 -0
  226. data/utils/enveomics/enveomics.R/man/enve.df2dist.list.Rd +26 -0
  227. data/utils/enveomics/enveomics.R/man/enve.growthcurve.Rd +49 -0
  228. data/utils/enveomics/enveomics.R/man/enve.prune.dist.Rd +28 -0
  229. data/utils/enveomics/enveomics.R/man/enve.recplot.Rd +97 -0
  230. data/utils/enveomics/enveomics.R/man/enve.recplot2-class.Rd +40 -0
  231. data/utils/enveomics/enveomics.R/man/enve.recplot2.Rd +40 -0
  232. data/utils/enveomics/enveomics.R/man/enve.recplot2.__counts.Rd +24 -0
  233. data/utils/enveomics/enveomics.R/man/enve.recplot2.__findPeak.Rd +40 -0
  234. data/utils/enveomics/enveomics.R/man/enve.recplot2.__findPeaks.Rd +18 -0
  235. data/utils/enveomics/enveomics.R/man/enve.recplot2.__peakHist.Rd +22 -0
  236. data/utils/enveomics/enveomics.R/man/enve.recplot2.__whichClosestPeak.Rd +20 -0
  237. data/utils/enveomics/enveomics.R/man/enve.recplot2.changeCutoff.Rd +18 -0
  238. data/utils/enveomics/enveomics.R/man/enve.recplot2.corePeak.Rd +18 -0
  239. data/utils/enveomics/enveomics.R/man/enve.recplot2.extractWindows.Rd +27 -0
  240. data/utils/enveomics/enveomics.R/man/enve.recplot2.findPeaks.Rd +53 -0
  241. data/utils/enveomics/enveomics.R/man/enve.recplot2.peak-class.Rd +44 -0
  242. data/utils/enveomics/enveomics.R/man/enve.tribs.Rd +44 -0
  243. data/utils/enveomics/enveomics.R/man/enve.tribs.test.Rd +21 -0
  244. data/utils/enveomics/enveomics.R/man/enveomics.R-package.Rd +15 -0
  245. data/utils/enveomics/enveomics.R/man/growth.curves.Rd +14 -0
  246. data/utils/enveomics/enveomics.R/man/phyla.counts.Rd +13 -0
  247. data/utils/enveomics/enveomics.R/man/plot.enve.GrowthCurve.Rd +43 -0
  248. data/utils/enveomics/enveomics.R/man/plot.enve.TRIBS.Rd +29 -0
  249. data/utils/enveomics/enveomics.R/man/plot.enve.TRIBStest.Rd +30 -0
  250. data/utils/enveomics/enveomics.R/man/plot.enve.recplot2.Rd +71 -0
  251. data/utils/enveomics/enveomics.R/man/summary.enve.GrowthCurve.Rd +18 -0
  252. data/utils/enveomics/enveomics.R/man/summary.enve.TRIBS.Rd +18 -0
  253. data/utils/enveomics/enveomics.R/man/summary.enve.TRIBStest.Rd +18 -0
  254. data/utils/enveomics/enveomics.R/man/z$-methods.Rd +27 -0
  255. data/utils/enveomics/globals.mk +8 -0
  256. data/utils/enveomics/manifest.json +9 -0
  257. data/utils/index_metadata.rb +0 -0
  258. data/utils/plot-taxdist.R +0 -0
  259. data/utils/requirements.txt +19 -19
  260. metadata +242 -2
@@ -0,0 +1,53 @@
1
+ \name{enve.recplot2.findPeaks}
2
+ \alias{enve.recplot2.findPeaks}
3
+ \title{enve recplot2 findPeaks}
4
+ \description{Identifies peaks in the population histogram potentially indicating
5
+ sub-population mixtures.}
6
+ \usage{enve.recplot2.findPeaks(x, min.points = 10, quant.est = c(0.002,
7
+ 0.998), mlv.opts = list(method = "parzen"), fitdist.opts.sn = list(distr = "sn",
8
+ method = "qme", probs = c(0.1, 0.5, 0.8), start = list(omega = 1,
9
+ alpha = -1), lower = c(1e-06, -Inf, 0), upper = c(Inf,
10
+ 0, Inf)), fitdist.opts.norm = list(distr = "norm", method = "qme",
11
+ probs = c(0.4, 0.6), start = list(sd = 1), lower = c(1e-08,
12
+ 0)), rm.top = 0.05, with.skewness = TRUE, optim.rounds = 200,
13
+ optim.epsilon = 1e-08, merge.logdist = log(1.75), verbose = FALSE)}
14
+ \arguments{
15
+ \item{x}{An `enve.RecPlot2` object.}
16
+ \item{min.points}{Minimum number of points in the quantile-estimation-range
17
+ (`quant.est`) to estimate a peak.}
18
+ \item{quant.est}{Range of quantiles to be used in the estimation of a peak's
19
+ parameters.}
20
+ \item{mlv.opts}{Options passed to `mlv` to estimate the mode.}
21
+ \item{fitdist.opts.sn}{
22
+ }
23
+ \item{fitdist.opts.norm}{
24
+ }
25
+ \item{rm.top}{Top-values to remove before finding peaks, as a quantile probability.
26
+ This step is useful to remove highly conserved regions, but can be
27
+ turned off by setting rm.top=0. The quantile is determined *after*
28
+ removing zero-coverage windows.}
29
+ \item{with.skewness}{Allow skewness correction of the peaks. Typically, the
30
+ sequencing-depth distribution for a single peak is left-skewed, due
31
+ partly (but not exclusively) to fragmentation and mapping sensitivity.
32
+ See Lindner et al 2013, Bioinformatics 29(10):1260-7 for an
33
+ alternative solution for the first problem (fragmentation) called
34
+ "tail distribution".}
35
+ \item{optim.rounds}{Maximum rounds of peak optimization.}
36
+ \item{optim.epsilon}{Trace change at which optimization stops (unless `optim.rounds` is
37
+ reached first). The trace change is estimated as the sum of square
38
+ differences between parameters in one round and those from two rounds
39
+ earlier (to avoid infinite loops from approximation).}
40
+ \item{merge.logdist}{Maximum value of |log-ratio| between centrality parameters in peaks to
41
+ attempt merging. The default of ~0.22 corresponds to a maximum
42
+ difference of 25\%.}
43
+ \item{verbose}{Display (mostly debugging) information.}
44
+ }
45
+
46
+ \value{Returns a list of `enve.RecPlot2.Peak` objects.}
47
+
48
+ \author{Luis M. Rodriguez-R [aut, cre]}
49
+
50
+
51
+
52
+
53
+
@@ -0,0 +1,44 @@
1
+ \name{enve.RecPlot2.Peak-class}
2
+ \Rdversion{1.1}
3
+ \docType{class}
4
+ \alias{enve.RecPlot2.Peak-class}
5
+ \alias{enve.RecPlot2.Peak}
6
+ %% \alias{$}
7
+
8
+ \title{enve.RecPlot2.Peak S4 class}
9
+ \description{Enve-omics representation of a peak in the sequencing depth histogram
10
+ of a Recruitment plot (see `enve.recplot2.findPeaks`).}
11
+ \section{Objects from the Class}{Objects can be created by calls of the form \code{new(enve.RecPlot2.Peak ...)}}
12
+ \section{Slots}{
13
+ \describe{
14
+ \item{\code{dist}:}{(\code{character}) Distribution of the peak. Currently supported: 'norm' (normal) and 'sn'
15
+ (skew-normal).}
16
+ \item{\code{values}:}{(\code{numeric}) Sequencing depth values predicted to conform the peak.}
17
+ \item{\code{values.res}:}{(\code{numeric}) Sequencing depth values not explained by this or previously identified
18
+ peaks.}
19
+ \item{\code{mode}:}{(\code{numeric}) Seed-value of mode anchoring the peak.}
20
+ \item{\code{param.hat}:}{(\code{list}) Parameters of the distribution. A list of two values if dist='norm' (sd
21
+ and mean), or three values if dist='sn' (omega=scale, alpha=shape, and
22
+ xi=location). Note that the "dispersion" parameter is always first and
23
+ the "location" parameter is always last.}
24
+ \item{\code{n.hat}:}{(\code{numeric}) Number of bins estimated to be explained by this peak. This should
25
+ ideally be equal to the length of `values`, but it's not and integer.}
26
+ \item{\code{n.total}:}{(\code{numeric}) Total number of bins from which the peak was extracted. I.e., total
27
+ number of position bins with non-zero sequencing depth in the recruitment
28
+ plot (regardless of peak count).}
29
+ \item{\code{err.res}:}{(\code{numeric}) Error left after adding the peak.}
30
+ \item{\code{merge.logdist}:}{(\code{numeric}) Attempted `merge.logdist` parameter.}
31
+ }
32
+ }
33
+ \section{Methods}{
34
+ \describe{
35
+ \item{$}{\code{signature(x = "enve.RecPlot2.Peak")}: ... }
36
+ }
37
+ }
38
+
39
+ \author{Luis M. Rodriguez-R [aut, cre]}
40
+
41
+
42
+
43
+
44
+
@@ -0,0 +1,44 @@
1
+ \name{enve.tribs}
2
+ \alias{enve.tribs}
3
+ \title{enve tribs}
4
+ \description{Subsample any objects in "distance space" to reduce the effect of
5
+ sample-clustering. This function was originally designed to subsample
6
+ genomes in "phylogenetic distance space", a clear case of strong
7
+ clustering bias in sampling, by Luis M. Rodriguez-R and Michael R
8
+ Weigand.}
9
+ \usage{enve.tribs(dist, selection = labels(dist), replicates = 1000,
10
+ summary.fx = median, dist.method = "euclidean", subsamples = seq(0,
11
+ 1, by = 0.01), dimensions = ceiling(length(selection) *
12
+ 0.05), metaMDS.opts = list(), threads = 2, verbosity = 1,
13
+ points, pre.tribs)}
14
+ \arguments{
15
+ \item{dist}{Distances as a `dist` object.}
16
+ \item{selection}{Objects to include in the subsample. By default, all objects are
17
+ selected.}
18
+ \item{replicates}{Number of replications per point}
19
+ \item{summary.fx}{Function to summarize the distance distributions in a given replicate. By
20
+ default, the median distance is estimated.}
21
+ \item{dist.method}{Distance method between random points and samples in the transformed
22
+ space. See `dist`.}
23
+ \item{subsamples}{Subsampling fractions}
24
+ \item{dimensions}{Dimensions to use in the NMDS. By default, 5\% of the selection length.}
25
+ \item{metaMDS.opts}{Any additional options to pass to metaMDS, as `list`.}
26
+ \item{threads}{Number of threads to use.}
27
+ \item{verbosity}{Verbosity. Use 0 to run quietly, increase for additional information.}
28
+ \item{points}{Optional. If passed, the MDS step is skipped and this object is used
29
+ instead. It can be the `$points` slot of class `metaMDS` (from `vegan`).
30
+ It must be a matrix or matrix-coercible object, with samples as rows and
31
+ dimensions as columns.}
32
+ \item{pre.tribs}{Optional. If passed, the points are recovered from this object (except if
33
+ `points` is also passed. This should be an `enve.TRIBS` object estimated
34
+ on the same objects (the selection is unimportant).}
35
+ }
36
+
37
+ \value{Returns an `enve.TRIBS` object.}
38
+
39
+ \author{Luis M. Rodriguez-R [aut, cre]}
40
+
41
+
42
+
43
+
44
+
@@ -0,0 +1,21 @@
1
+ \name{enve.tribs.test}
2
+ \alias{enve.tribs.test}
3
+ \title{enve tribs test}
4
+ \description{Estimates the empirical difference between all the distances in a set of
5
+ objects and a subset, together with its statistical significance.}
6
+ \usage{enve.tribs.test(dist, selection, bins = 50, ...)}
7
+ \arguments{
8
+ \item{dist}{Distances as `dist` object.}
9
+ \item{selection}{Selection defining the subset.}
10
+ \item{bins}{Number of bins to evaluate in the range of distances.}
11
+ \item{\dots}{Any other parameters supported by `enve.tribs`, except `subsamples`.}
12
+ }
13
+
14
+ \value{Returns an `enve.TRIBStest` object.}
15
+
16
+ \author{Luis M. Rodriguez-R [aut, cre]}
17
+
18
+
19
+
20
+
21
+
@@ -0,0 +1,15 @@
1
+ \name{enveomics.R-package}
2
+ \alias{enveomics.R-package}
3
+ \alias{enveomics.R}
4
+ \docType{package}
5
+ \title{Various Utilities for Microbial Genomics and Metagenomics}
6
+ \description{A collection of functions for microbial ecology and other
7
+ applications of genomics and metagenomics. Companion package for the
8
+ Enveomics Collection (Rodriguez-R, L.M. and Konstantinidis, K.T., 2016
9
+ <DOI:10.7287/peerj.preprints.1900v1>).}
10
+ \author{Luis M. Rodriguez-R <lmrodriguezr@gmail.com> [aut, cre]}
11
+
12
+ \keyword{ package }
13
+
14
+
15
+
@@ -0,0 +1,14 @@
1
+
2
+ \name{growth.curves}
3
+ \docType{data}
4
+ \alias{growth.curves}
5
+ \title{Bacterial growth curves for three Escherichia coli mutants}
6
+ \description{
7
+ This data set provides time (first column) and three triplicated growth
8
+ curves as optical density at 600nm (OD_600nm) for different mutants of E.
9
+ coli.
10
+ }
11
+ \usage{growth.curves}
12
+ \format{A data frame with 16 rows (times) and 10 rows (times and OD_600nm).}
13
+ \keyword{datasets}
14
+
@@ -0,0 +1,13 @@
1
+
2
+ \name{phyla.counts}
3
+ \docType{data}
4
+ \alias{phyla.counts}
5
+ \title{Counts of microbial phyla in four sites}
6
+ \description{
7
+ This data set gives the counts of phyla in three different
8
+ sites.
9
+ }
10
+ \usage{phyla.counts}
11
+ \format{A data frame with 9 rows (phyla) and 4 rows (sites).}
12
+ \keyword{datasets}
13
+
@@ -0,0 +1,43 @@
1
+ \name{plot.enve.GrowthCurve}
2
+ \alias{plot.enve.GrowthCurve}
3
+ \title{plot enve GrowthCurve}
4
+ \description{Plots an `enve.GrowthCurve` object.}
5
+ \usage{\method{plot}{enve.GrowthCurve}(x, col, pt.alpha = 0.9, ln.alpha = 1, ln.lwd = 1,
6
+ ln.lty = 1, band.alpha = 0.4, band.density = NULL, band.angle = 45,
7
+ xp.alpha = 0.5, xp.lwd = 1, xp.lty = 1, pch = 19, new = TRUE,
8
+ legend = new, add.params = FALSE, ...)}
9
+ \arguments{
10
+ \item{x}{`enve.GrowthCurve` object to plot.}
11
+ \item{col}{Base colors to use for the different samples. Can be recycled. By
12
+ default, grey for one sample or rainbow colors for more than one.}
13
+ \item{pt.alpha}{Color alpha for the observed data points, using `col` as a base.}
14
+ \item{ln.alpha}{Color alpha for the fitted growth curve, using `col` as a base.}
15
+ \item{ln.lwd}{Line width for the fitted curve.}
16
+ \item{ln.lty}{Line type for the fitted curve.}
17
+ \item{band.alpha}{Color alpha for the confidence interval band of the fitted growth curve,
18
+ using `col` as a base.}
19
+ \item{band.density}{Density of the filling pattern in the interval band. If NULL, a solid
20
+ color is used.}
21
+ \item{band.angle}{Angle of the density filling pattern in the interval band. Ignored if
22
+ `band.density` is NULL.}
23
+ \item{xp.alpha}{Color alpha for the line connecting individual experiments, using `col`
24
+ as a base.}
25
+ \item{xp.lwd}{Width of line for the experiments.}
26
+ \item{xp.lty}{Type of line for the experiments.}
27
+ \item{pch}{Point character for observed data points.}
28
+ \item{new}{Should a new plot be generated? If FALSE, the existing canvas is used.}
29
+ \item{legend}{Should the plot include a legend? If FALSE, no legend is added. If TRUE,
30
+ a legend is added in the bottom-right corner. Otherwise, a legend is
31
+ added in the position specified as `xy.coords`. }
32
+ \item{add.params}{Should the legend include the parameters of the fitted model?}
33
+ \item{\dots}{Any other graphic parameters.}
34
+ }
35
+
36
+
37
+
38
+ \author{Luis M. Rodriguez-R [aut, cre]}
39
+
40
+
41
+
42
+
43
+
@@ -0,0 +1,29 @@
1
+ \name{plot.enve.TRIBS}
2
+ \alias{plot.enve.TRIBS}
3
+ \title{plot enve TRIBS}
4
+ \description{Plot an `enve.TRIBS` object.}
5
+ \usage{\method{plot}{enve.TRIBS}(x, new = TRUE, type = c("boxplot", "points"),
6
+ col = "#00000044", pt.cex = 1/2, pt.pch = 19, pt.col = col,
7
+ ln.col = col, ...)}
8
+ \arguments{
9
+ \item{x}{`enve.TRIBS` object to plot.}
10
+ \item{new}{Should a new canvas be drawn?}
11
+ \item{type}{Type of plot. The 'points' plot shows all the replicates, the 'boxplot'
12
+ plot represents the values found by `boxplot.stats` as areas, and plots
13
+ the outliers as points.}
14
+ \item{col}{Color of the areas and/or the points.}
15
+ \item{pt.cex}{Size of the points.}
16
+ \item{pt.pch}{Points character.}
17
+ \item{pt.col}{Color of the points.}
18
+ \item{ln.col}{Color of the lines.}
19
+ \item{\dots}{Any additional parameters supported by `plot`.}
20
+ }
21
+
22
+
23
+
24
+ \author{Luis M. Rodriguez-R [aut, cre]}
25
+
26
+
27
+
28
+
29
+
@@ -0,0 +1,30 @@
1
+ \name{plot.enve.TRIBStest}
2
+ \alias{plot.enve.TRIBStest}
3
+ \title{plot enve TRIBStest}
4
+ \description{Plots an `enve.TRIBStest` object.}
5
+ \usage{\method{plot}{enve.TRIBStest}(x, type = c("overlap", "difference"), col = "#00000044",
6
+ col1 = col, col2 = "#44001144", ylab = "Probability", xlim = range(attr(x,
7
+ "dist.mids")), ylim = c(0, max(c(attr(x, "all.dist"),
8
+ attr(x, "sel.dist")))), ...)}
9
+ \arguments{
10
+ \item{x}{`enve.TRIBStest` object to plot.}
11
+ \item{type}{What to plot. 'overlap' generates a plot of the two contrasting empirical
12
+ PDFs (to compare against each other), 'difference' produces a plot of the
13
+ differences between the empirical PDFs (to compare against zero).}
14
+ \item{col}{Main color of the plot if type='difference'.}
15
+ \item{col1}{First color of the plot if type='overlap'.}
16
+ \item{col2}{Second color of the plot if type='overlap'.}
17
+ \item{ylab}{Y-axis label.}
18
+ \item{xlim}{X-axis limits.}
19
+ \item{ylim}{Y-axis limits.}
20
+ \item{\dots}{Any other graphical arguments.}
21
+ }
22
+
23
+
24
+
25
+ \author{Luis M. Rodriguez-R [aut, cre]}
26
+
27
+
28
+
29
+
30
+
@@ -0,0 +1,71 @@
1
+ \name{plot.enve.RecPlot2}
2
+ \alias{plot.enve.RecPlot2}
3
+ \title{plot enve RecPlot2}
4
+ \description{Plots an `enve.RecPlot2` object.}
5
+ \usage{\method{plot}{enve.RecPlot2}(x, layout = matrix(c(5, 5, 2, 1, 4, 3), nrow = 2),
6
+ widths = c(1, 7, 2), heights = c(1, 2), palette = grey((100:0)/100),
7
+ underlay.group = TRUE, peaks.col = "darkred", id.lim = range(x$id.breaks),
8
+ pos.lim = range(x$pos.breaks), pos.units = c("Mbp", "Kbp",
9
+ "bp"), mar = list(`1` = c(5, 4, 1, 1) + 0.1, `2` = c(ifelse(any(layout ==
10
+ 1), 1, 5), 4, 4, 1) + 0.1, `3` = c(5, ifelse(any(layout ==
11
+ 1), 1, 4), 1, 2) + 0.1, `4` = c(ifelse(any(layout ==
12
+ 1), 1, 5), ifelse(any(layout == 2), 1, 4), 4, 2) + 0.1,
13
+ `5` = c(5, 3, 4, 1) + 0.1, `6` = c(5, 4, 4, 2) + 0.1),
14
+ pos.splines = 0, id.splines = 1/2, in.lwd = ifelse(pos.splines >
15
+ 0, 1/2, 2), out.lwd = ifelse(pos.splines > 0, 1/2, 2),
16
+ id.lwd = ifelse(id.splines > 0, 1/2, 2), in.col = "darkblue",
17
+ out.col = "lightblue", id.col = "black", breaks.col = "#AAAAAA40",
18
+ peaks.opts = list(), ...)}
19
+ \arguments{
20
+ \item{x}{`enve.RecPlot2` object to plot.}
21
+ \item{layout}{Matrix indicating the position of the different panels in the layout,
22
+ where:
23
+ 0: Empty space,
24
+ 1: Counts matrix,
25
+ 2: position histogram (sequencing depth),
26
+ 3: identity histogram,
27
+ 4: Populations histogram (histogram of sequencing depths),
28
+ 5: Color scale for the counts matrix (vertical),
29
+ 6: Color scale of the counts
30
+ matrix (horizontal). Only panels indicated here will be plotted. To
31
+ plot only one panel simply set this to the number of the panel you
32
+ want to plot.}
33
+ \item{widths}{Relative widths of the columns of `layout`.}
34
+ \item{heights}{Relative heights of the rows of `layout`.}
35
+ \item{palette}{Colors to be used to represent the counts matrix, sorted from no hits
36
+ to the maximum sequencing depth.}
37
+ \item{underlay.group}{If TRUE, it indicates the in-group and out-group areas couloured based
38
+ on `in.col` and `out.col`. Requires support for semi-transparency.}
39
+ \item{peaks.col}{If not NA, it attempts to represent peaks in the population histogram
40
+ in the specified color. Set to NA to avoid peak-finding.}
41
+ \item{id.lim}{Limits of identities to represent.}
42
+ \item{pos.lim}{Limits of positions to represent (in bp, regardless of `pos.units`).}
43
+ \item{pos.units}{Units in which the positions should be represented (powers of 1,000
44
+ base pairs).}
45
+ \item{mar}{
46
+ }
47
+ \item{pos.splines}{Smoothing parameter for the splines in the position histogram. Zero
48
+ (0) for no splines. If non-zero, requires the stats package.}
49
+ \item{id.splines}{Smoothing parameter for the splines in the identity histogram. Zero
50
+ (0) for no splines. If non-zero, requires the stats package.}
51
+ \item{in.lwd}{Line width for the sequencing depth of in-group matches.}
52
+ \item{out.lwd}{Line width for the sequencing depth of out-group matches.}
53
+ \item{id.lwd}{Line width for the identity histogram.}
54
+ \item{in.col}{Color associated to in-group matches.}
55
+ \item{out.col}{Color associated to out-group matches.}
56
+ \item{id.col}{Color for the identity histogram.}
57
+ \item{breaks.col}{Color of the vertical lines indicating sequence breaks.}
58
+ \item{peaks.opts}{Options passed to `enve.recplot2.findPeaks`, if `peaks.col` is not NA.}
59
+ \item{\dots}{Any other graphic parameters (currently ignored).}
60
+ }
61
+
62
+ \value{Returns a list of `enve.RecPlot2.Peak` objects (see
63
+ `enve.recplot2.findPeaks`). If `peaks.col`=NA or `layout` doesn't include
64
+ 4, returns NA.}
65
+
66
+ \author{Luis M. Rodriguez-R [aut, cre]}
67
+
68
+
69
+
70
+
71
+
@@ -0,0 +1,18 @@
1
+ \name{summary.enve.GrowthCurve}
2
+ \alias{summary.enve.GrowthCurve}
3
+ \title{summary enve GrowthCurve}
4
+ \description{Summary of an `enve.GrowthCurve` object.}
5
+ \usage{\method{summary}{enve.GrowthCurve}(object, ...)}
6
+ \arguments{
7
+ \item{object}{`enve.GrowthCurve` object.}
8
+ \item{\dots}{No additional parameters are currently supported.}
9
+ }
10
+
11
+
12
+
13
+ \author{Luis M. Rodriguez-R [aut, cre]}
14
+
15
+
16
+
17
+
18
+
@@ -0,0 +1,18 @@
1
+ \name{summary.enve.TRIBS}
2
+ \alias{summary.enve.TRIBS}
3
+ \title{summary enve TRIBS}
4
+ \description{Summary of an `enve.TRIBS` object.}
5
+ \usage{\method{summary}{enve.TRIBS}(object, ...)}
6
+ \arguments{
7
+ \item{object}{`enve.TRIBS` object.}
8
+ \item{\dots}{No additional parameters are currently supported.}
9
+ }
10
+
11
+
12
+
13
+ \author{Luis M. Rodriguez-R [aut, cre]}
14
+
15
+
16
+
17
+
18
+
@@ -0,0 +1,18 @@
1
+ \name{summary.enve.TRIBStest}
2
+ \alias{summary.enve.TRIBStest}
3
+ \title{summary enve TRIBStest}
4
+ \description{Summary of an `enve.TRIBStest` object.}
5
+ \usage{\method{summary}{enve.TRIBStest}(object, ...)}
6
+ \arguments{
7
+ \item{object}{`enve.TRIBStest` object.}
8
+ \item{\dots}{No additional parameters are currently supported.}
9
+ }
10
+
11
+
12
+
13
+ \author{Luis M. Rodriguez-R [aut, cre]}
14
+
15
+
16
+
17
+
18
+