Mercurial > repos > artbio > ez_histograms
comparison ez_histograms.xml @ 0:bdf40b0924cb draft
planemo upload for repository https://github.com/artbio/tools-artbio/tree/main/tools/ez_histograms commit 443759a746f78d67dc4ffcafdc6610d09d278846
author | artbio |
---|---|
date | Wed, 07 Feb 2024 19:49:56 +0000 |
parents | |
children | fbedb212982d |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:bdf40b0924cb |
---|---|
1 <tool id="ez_histograms" name="ez_histograms" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="@PROFILE@"> | |
2 <macros> | |
3 <token name="@TOOL_VERSION@">3.4.4</token> | |
4 <token name="@VERSION_SUFFIX@">0</token> | |
5 <token name="@PROFILE@">23.0</token> | |
6 </macros> | |
7 <requirements> | |
8 <requirement type="package" version="3.4.4">r-ggplot2</requirement> | |
9 <requirement type="package" version="1.4.4">r-reshape2</requirement> | |
10 <requirement type="package" version="1.1.4">r-dplyr</requirement> | |
11 <requirement type="package" version="1.3.0">r-scales</requirement> | |
12 <requirement type="package" version="1.4.6">r-vtable</requirement> | |
13 <requirement type="package" version="1.7.4">r-optparse</requirement> | |
14 </requirements> | |
15 | |
16 <stdio> | |
17 <exit_code range="1:" level="fatal" /> | |
18 </stdio> | |
19 | |
20 <command detect_errors="exit_code"><![CDATA[ | |
21 Rscript $__tool_directory__/ez_histograms.R | |
22 --file '$file' | |
23 --profile '$plot_options.plot_options_selector' | |
24 --xscale '$plot_options.xscale' | |
25 #if str($plot_options.plot_options_selector) == "count": | |
26 --yscale '$plot_options.yscale' | |
27 #end if | |
28 --pdf '$pdf' | |
29 --summary '$summary' | |
30 ]]></command> | |
31 | |
32 <inputs> | |
33 <param name="file" type="data" format="tabular" label="Input tabular dataset" | |
34 help="Only numeric columns will be plotted"/> | |
35 <conditional name="plot_options"> | |
36 <param name="plot_options_selector" type="select" label="Set plot types"> | |
37 <option value="count" selected="true">Count Histograms</option> | |
38 <option value="density">Density Plots</option> | |
39 </param> | |
40 <when value="density"> | |
41 <param name="xscale" type="select" label="Set x-axis scale"> | |
42 <option value="cartesian" selected="true">Cartesian</option> | |
43 <option value="log2">log2</option> | |
44 <option value="log10">log10</option> | |
45 </param> | |
46 </when> | |
47 <when value="count"> | |
48 <param name="xscale" type="select" label="Set x-axis scale"> | |
49 <option value="cartesian" selected="true">Cartesian</option> | |
50 <option value="log2">log2</option> | |
51 <option value="log10">log10</option> | |
52 </param> | |
53 <param name="yscale" type="select" label="Set y-axis scale"> | |
54 <option value="cartesian" selected="true">Cartesian</option> | |
55 <option value="log2">log2</option> | |
56 <option value="log10">log10</option> | |
57 </param> | |
58 </when> | |
59 </conditional> | |
60 </inputs> | |
61 <outputs> | |
62 <data name="pdf" format="pdf" label="${tool.name} plots from ${on_string}"/> | |
63 <data name="summary" format="tabular" label="Statistics Summary from ${on_string}"/> | |
64 </outputs> | |
65 <tests> | |
66 <test expect_num_outputs="2"> | |
67 <param name="file" value="classic.tsv"/> | |
68 <param name="plot_options_selector" value="count"/> | |
69 <param name="xscale" value="cartesian"/> | |
70 <param name="yscale" value="cartesian"/> | |
71 <output name="pdf" file="classic.pdf"/> | |
72 <output name="summary" file="summary_1.tsv"/> | |
73 </test> | |
74 <test expect_num_outputs="2"> | |
75 <param name="file" value="counts.tsv"/> | |
76 <param name="plot_options_selector" value="count"/> | |
77 <param name="xscale" value="log2"/> | |
78 <param name="yscale" value="cartesian"/> | |
79 <output name="pdf" file="count.pdf"/> | |
80 <output name="summary" file="summary_2.tsv"/> | |
81 </test> | |
82 <test expect_num_outputs="2"> | |
83 <param name="file" value="headless.tsv"/> | |
84 <param name="plot_options_selector" value="count"/> | |
85 <param name="xscale" value="log10"/> | |
86 <param name="yscale" value="log2"/> | |
87 <output name="pdf" file="headless.pdf"/> | |
88 <output name="summary" file="summary_3.tsv"/> | |
89 </test> | |
90 <test expect_num_outputs="2"> | |
91 <param name="file" value="large.tsv"/> | |
92 <param name="plot_options_selector" value="density"/> | |
93 <param name="xscale" value="log2"/> | |
94 <output name="pdf" file="large.pdf"/> | |
95 <output name="summary" file="summary_4.tsv"/> | |
96 </test> | |
97 <test expect_num_outputs="2"> | |
98 <param name="file" value="rowheadless.tsv"/> | |
99 <param name="plot_options_selector" value="density"/> | |
100 <param name="xscale" value="cartesian"/> | |
101 <output name="pdf" file="rowheadless.pdf"/> | |
102 <output name="summary" file="summary_5.tsv"/> | |
103 </test> | |
104 <test expect_num_outputs="2"> | |
105 <param name="file" value="single_headed_col.tsv"/> | |
106 <param name="plot_options_selector" value="density"/> | |
107 <param name="xscale" value="log10"/> | |
108 <output name="pdf" file="single_headed_col.pdf"/> | |
109 <output name="summary" file="summary_6.tsv"/> | |
110 </test> | |
111 </tests> | |
112 <help><![CDATA[ | |
113 **What it does** | |
114 | |
115 The tool generates faceted histograms or density plots using the ggplot2 functions | |
116 geom_histogram() or geom_density(), respectively. | |
117 | |
118 **Inputs** | |
119 | |
120 Any regular tabular data, provided that the number of columns (tabulations) is unchanged | |
121 for any row. | |
122 | |
123 Except for the first one, any column will be considered as one variable with n_rows | |
124 observations. However, non-numeric columns will be filtered and will not be considered | |
125 variables. | |
126 | |
127 If the first column is not numeric, it will be taken as row names (ie observation identifiers), | |
128 otherwise, it will be considered as the first numerical variable of the table. | |
129 | |
130 If the first row is not numerical, it will be considered as a header, ie as describing the | |
131 variable names. | |
132 | |
133 If you provide a table without header, variable names will be assigned to each column | |
134 following the R default rule: (V1), V2, ..., Vn | |
135 | |
136 **Parameters** | |
137 | |
138 For Count Histograms, both x- and y-axis can have linear (cartesian), log2 or log10 scales. | |
139 | |
140 For Density Plots, only x-axis can be customized with linear (cartesian), log2, or log10 | |
141 scales | |
142 | |
143 **Outputs** | |
144 | |
145 The ez_histograms Galaxy tool returns | |
146 | |
147 - A pdf file with plots faceted on three columns | |
148 - A tsv file with statistics summary of the variables generated by the R package vtables | |
149 | |
150 ]]></help> | |
151 <citations> | |
152 <citation type="bibtex"> | |
153 @BOOK{Wickham2016-ic, | |
154 title = "Ggplot2: Elegant graphics for data analysis", | |
155 author = "Wickham, Hadley", | |
156 publisher = "Springer International Publishing", | |
157 series = "Use R!", | |
158 edition = 2, | |
159 month = jun, | |
160 year = 2016, | |
161 address = "Cham, Switzerland", | |
162 language = "en", | |
163 isbn = "9783319242774" | |
164 } </citation> | |
165 </citations> | |
166 </tool> |