Repository 'anova'
hg clone https://toolshed.g2.bx.psu.edu/repos/lecorguille/anova

Changeset 1:e646ad125f2d (2015-08-04)
Previous changeset 0:8dd2a438bfba (2015-06-30) Next changeset 2:b6298c38e53f (2016-03-28)
Commit message:
Add test
modified:
abims_anova.xml
added:
static/images/anova_workflow.png
test-data/dataMatrix.tsv
test-data/dataMatrix.tsv_anova_filtered.tabular
test-data/dataMatrix.tsv_anova_pvalue.tabular
test-data/sampleMetadata.tsv
removed:
static/images/hclust.png
static/images/pca_abims_Rplots.png
static/images/pca_abims_Rplots1.png
static/images/pca_abims_eigenvalue.png
static/images/pca_abims_percentage_of_variance.png
b
diff -r 8dd2a438bfba -r e646ad125f2d abims_anova.xml
--- a/abims_anova.xml Tue Jun 30 06:02:46 2015 -0400
+++ b/abims_anova.xml Tue Aug 04 09:46:07 2015 -0400
b
b'@@ -1,14 +1,17 @@\n-<tool id="abims_anova" name="Anova" version="1.1">\n-\t\n-    <requirements>\n-\t<requirement type="binary">Rscript</requirement>\n-\t<requirement type="binary">batch</requirement>\n-    </requirements>\n+<tool id="abims_anova" name="Anova" version="1.1.3">\n     \n     <description>N-way anova. With ou Without interactions</description>\n+    \n+    <requirements>\n+        <requirement type="binary">Rscript</requirement>\n+    </requirements>\n+\n+    <stdio>\n+        <exit_code range="1:" level="fatal" />\n+    </stdio>\n \n     <command interpreter="Rscript">\n-        abims_anova.r file "$input" sampleinfo "$sampleinfo" mode "$mode" \n+abims_anova.r file "$input" sampleinfo "$sampleinfo" mode "$mode" \n condition "c(\'$condition_1\'\n #for $i, $s in enumerate( $conditions )\n ,\'${s.condition}\'\n@@ -21,58 +24,72 @@\n         <param name="input" type="data" label="Data Matrix file" format="tabular" help="Matrix of numeric data with headers." />\n         <param name="sampleinfo" type="data" label="Sample Metadata file" format="tabular" help="Tabular file with the data metadata : one sample per line and at least two columns : ids and one condition" />\n         \n-         <param name="mode" type="select" help="Perform the anova tests on column/row" format="text" optional="true">\n-\t\t<label>Mode</label>\n-\t\t<option value="row">row</option>\n-\t\t<option value="column">column</option>\n-\t</param>\n-\t\n-\t<param name="condition_1" type="text" label="Condition" value="" help="The column name of the condition. ex: hour or treatment" optional="false" />\n-\t<repeat name="conditions" title="Conditions for N-ways anova">\n-\t    <param name="condition" type="text" label="Condition" value="" help="The column name of the condition. ex: hour or treatment" />\n-\t</repeat>\n+        <param name="mode" type="select" help="Perform the anova tests on column/row" format="text" optional="true">\n+            <label>Mode</label>\n+            <option value="row">row</option>\n+            <option value="column">column</option>\n+        </param>\n+    \n+        <param name="condition_1" type="text" label="Condition" value="" help="The column name of the condition. ex: hour or treatment" optional="false" />\n+        <repeat name="conditions" title="Conditions for N-ways anova">\n+            <param name="condition" type="text" label="Condition" value="" help="The column name of the condition. ex: hour or treatment" />\n+        </repeat>\n \n-\t<param name="interaction" type="boolean" label="Enable interaction response p-values" truevalue="T" falsevalue="F" help="Used if more than 1 conditon. The anova will produse p-value according to the interaction between your condition (ex: condition1:conditions2, condition1:conditions3, condition2:conditions3 and condition1:condition2:conditions3)" />\n-        \n-\t<param name="method" type="select" help="Method used to apply a correction on the pvalue because of the number of test" format="text" optional="true">\n-\t\t<label>PValue adjusted method</label>\n-\t\t<option value="BH">BH</option>\n-\t\t<option value="holm">holm</option>\n-\t\t<option value="bonferroni">bonferroni</option>\n-\t\t<option value="hochberg">hochberg</option>\n-\t\t<option value="hommel">hommel</option>\n-\t\t<option value="BY">BY</option>\n-\t\t<option value="fdr">fdr</option>\n-\t\t<option value="none">none</option>\t\t\n-\t</param>        \n+        <param name="interaction" type="boolean" label="Enable interaction response p-values" truevalue="T" falsevalue="F" help="Used if more than 1 conditon. The anova will produse p-value according to the interaction between your condition (ex: condition1:conditions2, condition1:conditions3, condition2:conditions3 and condition1:condition2:conditions3)" />\n+            \n+        <param name="method" type="select" help="Method used to apply a correction on the pvalue because of the number of test" format="text" optional="true">\n+            <label>PValue adjusted method</label>\n+            <option value="BH">BH</option>\n+            <option value="holm">holm'..b'>\n+            <option value="tabulation">tabulation</option>\n+            <option value="semicolon">;</option>\n+            <option value="comma">,</option>\n+        </param>\n         \n         <param name="dec" type="text" label="Decimal separator" value="." help="" />\n \n     </inputs>\n \n     <outputs>\n-        <data name="dataMatrixPValue" format="input" label="${input.name}_anova_pvalue.${input.ext}"/>\n-        <data name="dataMatrixFiltered" format="input" label="${input.name}_anova_filtered.${input.ext}"/>\n+        <data name="dataMatrixPValue" format_source="input" label="${input.name}_anova_pvalue.${input.ext}"/>\n+        <data name="dataMatrixFiltered" format_source="input" label="${input.name}_anova_filtered.${input.ext}"/>\n     </outputs>\n-\n-    <stdio>\n-        <exit_code range="1:" level="fatal" />\n-    </stdio>\n+    \n+    <tests>\n+        <test>\n+            <param name="input" value="dataMatrix.tsv"/>\n+            <param name="sampleinfo" value="sampleMetadata.tsv"/>\n+            <param name="mode" value="row"/>\n+            <param name="condition_1" value="age"/>\n+            <param name="conditions_0|condition" value="gender"/>\n+            <param name="interaction" value="F"/>\n+            <param name="method" value="BH"/>\n+            <param name="threshold" value="0.05"/>\n+            <param name="selection_method" value="union"/>\n+            <param name="sep" value="tabulation"/>\n+            <param name="dev" value="."/>\n+            <output name="dataMatrixPValue" file="dataMatrix.tsv_anova_pvalue.tabular" />\n+            <output name="dataMatrixFiltered" file="dataMatrix.tsv_anova_filtered.tabular" />\n+        </test>\n+    </tests>\n \n     <help>\n \n@@ -117,23 +134,23 @@\n \n ***.anova_pvalue.tabular**\n \n-\t| A tabular file which represents for each metabolite (row), the value of the intensity in each sample (column) + two columns (aovPValue and aovAdjPValue).\n+    | A tabular file which represents for each metabolite (row), the value of the intensity in each sample (column) + two columns (aovPValue and aovAdjPValue).\n \n ***.anova_filtered.tabular**\n \n-\t| The tabular file xset.anova_pvalue.tabular containing only the metabolites that have been filtered by aovAdjPValue.\n-\t\n-\t\n+    | The tabular file xset.anova_pvalue.tabular containing only the metabolites that have been filtered by aovAdjPValue.\n+    \n+    \n ------\n \n .. class:: infomark \n \n The outputs ***.anova_filtered.tabular** or ***.anova_pvalue.tabular** are tabular files. You can continue your analysis using it in the following tools:\n-\t| PCA\n-\t| Hierarchical Clustering\n+    | PCA\n+    | Hierarchical Clustering\n \n-\t\n-\t\n+    \n+    \n ---------------------------------------------------\n \n ---------------\n@@ -145,7 +162,7 @@\n -----------\n \n **>A part of an example of Data Matrix file input**\n-\t\n+    \n \n +--------+------------------+----------------+\n | Name   | Bur-eH_FSP_12    | Bur-eH_FSP_24  |\t                                       \n@@ -156,8 +173,8 @@\n +--------+------------------+----------------+       \n \n **>A part of an example of Sample Metadata file input**\n-\t\n-\t\n+    \n+    \n +---------------------------+------------+------------+------------+\n | Sample name               |   class    |   time     |   batch    |\n +===========================+============+============+============+\n@@ -173,13 +190,13 @@\n Parameters\n ----------\n \n-\t| Mode -> **row**\n-\t| column name of condition -> **class**\n-\t| Separator of columns: -> **tabulation**\n-\t| Decimal separator -> **.**\n-\t| PValue adjusted method -> **BH**\n-\t| Threshold -> **0.001**\n-\t\n+    | Mode -> **row**\n+    | column name of condition -> **class**\n+    | Separator of columns: -> **tabulation**\n+    | Decimal separator -> **.**\n+    | PValue adjusted method -> **BH**\n+    | Threshold -> **0.001**\n+    \n \n \n Output files\n@@ -194,6 +211,11 @@\n .. image:: anova_filtered.png\n \n \n+\n     </help>\n \n+    <citations>\n+        <citation>Ronald A. Fisher in the 1930s</citation>\n+    </citations>\n+\n </tool>\n'
b
diff -r 8dd2a438bfba -r e646ad125f2d static/images/anova_workflow.png
b
Binary file static/images/anova_workflow.png has changed
b
diff -r 8dd2a438bfba -r e646ad125f2d static/images/hclust.png
b
Binary file static/images/hclust.png has changed
b
diff -r 8dd2a438bfba -r e646ad125f2d static/images/pca_abims_Rplots.png
b
Binary file static/images/pca_abims_Rplots.png has changed
b
diff -r 8dd2a438bfba -r e646ad125f2d static/images/pca_abims_Rplots1.png
b
Binary file static/images/pca_abims_Rplots1.png has changed
b
diff -r 8dd2a438bfba -r e646ad125f2d static/images/pca_abims_eigenvalue.png
b
Binary file static/images/pca_abims_eigenvalue.png has changed
b
diff -r 8dd2a438bfba -r e646ad125f2d static/images/pca_abims_percentage_of_variance.png
b
Binary file static/images/pca_abims_percentage_of_variance.png has changed
b
diff -r 8dd2a438bfba -r e646ad125f2d test-data/dataMatrix.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/dataMatrix.tsv Tue Aug 04 09:46:07 2015 -0400
b
@@ -0,0 +1,16 @@
+dataMatrix HU_017 HU_028 HU_034 HU_051 HU_060 HU_078 HU_091 HU_093 HU_099 HU_110 HU_130 HU_134 HU_138 HU_149 HU_152 HU_175 HU_178 HU_185 HU_204 HU_208
+HMDB03193 76043 412165 44943 27242 436566 173175 242549 57066 559869 3732 339188 471368 262271 127285 451270 212500 79673 NA 891129 43907
+HMDB01101 30689 6877586 52217 3158 10789748 229568 4763576 3878773 976436 831937 608298 1605075 72021 442510 1107705 1464339 31250 2724553 72900 32742
+HMDB10348 47259 544877 60885 34582 529874 168264 176500 76457 610110 16262 279156 524468 451573 591487 433529 161069 214392 13781 1580343 39315
+HMDB59717 357351 1030464 301983 67604 306862 1028110 1530493 270027 1378535 289677 808334 1132813 871209 895435 715190 1563158 784738 146195 994336 239030
+HMDB00822 483755 579287 1132413 157113 1577570 1469735 1085454 477909 814755 245417 610681 763706 2406336 827531 992508 569605 355321 150259 1334200 271010
+HMDB13189 2644620 727587 1661412 619181 136278 2755434 593863 837865 3526136 2003278 1608814 3446611 1941527 113937 3132404 2893445 2092753 1034666 1517319 841661
+HMDB00299 250551 1046138 456162 159386 1013302 808657 614370 250403 768004 242085 504108 1014041 1362408 1057660 1110050 566050 411886 142233 1992420 284775
+HMDB00191 560002 771533 575790 392284 888498 785428 645785 591569 960658 910201 639437 1092885 1409045 2292023 1246459 1945577 710519 773384 1061418 622898
+HMDB00518 34236 58249 85944 NA 342102 129886 175800 13154 230242 NA 440223 315368 10657 419508 48673 28361 514579 23108 867108 73831
+HMDB00715 1252089 2547452 905408 371059 4983588 5140022 2658555 814523 2558923 859466 4184204 3865723 3236644 2615560 3820724 3577833 2295288 625924 7517724 1341900
+HMDB01032 2569205 26023086 1604999 430453 8103558 26222916 257139 675754 59906109 263055 31151730 18648127 14989438 1554658 20249262 5588731 871010 15920 9120781 44276
+HMDB00208 747080 13420742 595872 1172376 7172632 3143654 4059767 1433702 5593888 5402629 2477288 3346077 4230072 7621236 8960828 10335722 7037373 1574738 3359238 2540044
+HMDB04824 374028 1144386 539206 178517 1046190 959381 605191 310260 1253319 477259 477995 825691 1157093 1089284 1411802 1020206 782673 346761 1824553 387811
+HMDB00512 53304 319783 280560 85009 1333877 556003 590779 209285 342532 198512 569970 525240 246282 1140422 542345 1171008 827723 222953 438839 85554
+HMDB00251 368600 616555 94936 622468 180988 293988 352855 767894 268331 167246 310918 1248919 577184 10985 335711 403815 80614 63393 454489 616061
b
diff -r 8dd2a438bfba -r e646ad125f2d test-data/dataMatrix.tsv_anova_filtered.tabular
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/dataMatrix.tsv_anova_filtered.tabular Tue Aug 04 09:46:07 2015 -0400
b
@@ -0,0 +1,3 @@
+ HU_017 HU_028 HU_034 HU_051 HU_060 HU_078 HU_091 HU_093 HU_099 HU_110 HU_130 HU_134 HU_138 HU_149 HU_152 HU_175 HU_178 HU_185 HU_204 HU_208
+HMDB00208 747080 13420742 595872 1172376 7172632 3143654 4059767 1433702 5593888 5402629 2477288 3346077 4230072 7621236 8960828 10335722 7037373 1574738 3359238 2540044
+HMDB00512 53304 319783 280560 85009 1333877 556003 590779 209285 342532 198512 569970 525240 246282 1140422 542345 1171008 827723 222953 438839 85554
b
diff -r 8dd2a438bfba -r e646ad125f2d test-data/dataMatrix.tsv_anova_pvalue.tabular
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/dataMatrix.tsv_anova_pvalue.tabular Tue Aug 04 09:46:07 2015 -0400
b
@@ -0,0 +1,16 @@
+ HU_017 HU_028 HU_034 HU_051 HU_060 HU_078 HU_091 HU_093 HU_099 HU_110 HU_130 HU_134 HU_138 HU_149 HU_152 HU_175 HU_178 HU_185 HU_204 HU_208 pvalueadjusted.BH.age pvalueadjusted.BH.gender
+HMDB03193 76043 412165 44943 27242 436566 173175 242549 57066 559869 3732 339188 471368 262271 127285 451270 212500 79673 NA 891129 43907 0.740856975457218 0.740856975457218
+HMDB01101 30689 6877586 52217 3158 10789748 229568 4763576 3878773 976436 831937 608298 1605075 72021 442510 1107705 1464339 31250 2724553 72900 32742 0.347623051099051 0.234554902330543
+HMDB10348 47259 544877 60885 34582 529874 168264 176500 76457 610110 16262 279156 524468 451573 591487 433529 161069 214392 13781 1580343 39315 0.720303175717481 0.720303175717481
+HMDB59717 357351 1030464 301983 67604 306862 1028110 1530493 270027 1378535 289677 808334 1132813 871209 895435 715190 1563158 784738 146195 994336 239030 0.252979062487671 0.517822514350462
+HMDB00822 483755 579287 1132413 157113 1577570 1469735 1085454 477909 814755 245417 610681 763706 2406336 827531 992508 569605 355321 150259 1334200 271010 0.808532959173048 0.808532959173048
+HMDB13189 2644620 727587 1661412 619181 136278 2755434 593863 837865 3526136 2003278 1608814 3446611 1941527 113937 3132404 2893445 2092753 1034666 1517319 841661 0.329174238111018 0.329174238111018
+HMDB00299 250551 1046138 456162 159386 1013302 808657 614370 250403 768004 242085 504108 1014041 1362408 1057660 1110050 566050 411886 142233 1992420 284775 0.995859884733937 0.995859884733937
+HMDB00191 560002 771533 575790 392284 888498 785428 645785 591569 960658 910201 639437 1092885 1409045 2292023 1246459 1945577 710519 773384 1061418 622898 0.15341384456659 0.15341384456659
+HMDB00518 34236 58249 85944 NA 342102 129886 175800 13154 230242 NA 440223 315368 10657 419508 48673 28361 514579 23108 867108 73831 0.439012867631325 0.596200901535843
+HMDB00715 1252089 2547452 905408 371059 4983588 5140022 2658555 814523 2558923 859466 4184204 3865723 3236644 2615560 3820724 3577833 2295288 625924 7517724 1341900 0.814406453193777 0.814406453193777
+HMDB01032 2569205 26023086 1604999 430453 8103558 26222916 257139 675754 59906109 263055 31151730 18648127 14989438 1554658 20249262 5588731 871010 15920 9120781 44276 0.288354536353544 0.288354536353544
+HMDB00208 747080 13420742 595872 1172376 7172632 3143654 4059767 1433702 5593888 5402629 2477288 3346077 4230072 7621236 8960828 10335722 7037373 1574738 3359238 2540044 0.659785284053633 0.00376251274734483
+HMDB04824 374028 1144386 539206 178517 1046190 959381 605191 310260 1253319 477259 477995 825691 1157093 1089284 1411802 1020206 782673 346761 1824553 387811 0.646714644805001 0.646714644805001
+HMDB00512 53304 319783 280560 85009 1333877 556003 590779 209285 342532 198512 569970 525240 246282 1140422 542345 1171008 827723 222953 438839 85554 0.13976111393526 0.0491480895853803
+HMDB00251 368600 616555 94936 622468 180988 293988 352855 767894 268331 167246 310918 1248919 577184 10985 335711 403815 80614 63393 454489 616061 0.565910223149305 0.565910223149305
b
diff -r 8dd2a438bfba -r e646ad125f2d test-data/sampleMetadata.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/sampleMetadata.tsv Tue Aug 04 09:46:07 2015 -0400
b
@@ -0,0 +1,21 @@
+sampleMetadata injectionOrder mode age bmi gender
+HU_017 2 pos 40-50 23.03 M
+HU_028 7 pos 40-50 23.92 F
+HU_034 9 pos 50-60 23.37 M
+HU_051 20 pos 20-30 23.23 F
+HU_060 24 pos 50-60 28.72 F
+HU_078 34 pos 40-50 25.18 M
+HU_091 42 pos 60-70 26.12 M
+HU_093 43 pos 50-60 21.71 M
+HU_099 46 pos 20-30 21.3 M
+HU_110 53 pos 50-60 20.9 F
+HU_130 63 pos 30-40 26.06 M
+HU_134 67 pos 40-50 22.89 M
+HU_138 68 pos 40-50 21.88 M
+HU_149 72 pos 30-40 19.49 F
+HU_152 75 pos 20-30 17.58 F
+HU_175 87 pos 30-40 21.26 F
+HU_178 88 pos 60-70 32.87 F
+HU_185 95 pos 40-50 21.09 F
+HU_204 104 pos 30-40 29.06 M
+HU_208 106 pos 20-30 18.61 F