Skip to content

Commit

Permalink
Make title and others visible in volcanoplot (#5977)
Browse files Browse the repository at this point in the history
* Make title and others visible in volcanoplot.xml

Current version is not considering inputs in plot title and other options.

* Bumps version

* Profile and citation

* Add homepage URL to .shed.yml

* Avoid element_blank for legend title

* Fix legend title handling

* Update test sizes

* Hopefully fixes last test

* Update test sizes
  • Loading branch information
pcm32 authored May 15, 2024
1 parent dbdc7c7 commit 589795c
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 16 deletions.
1 change: 1 addition & 0 deletions tools/volcanoplot/.shed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ long_description: |
name: volcanoplot
owner: iuc
remote_repository_url: https://github.com/galaxyproject/tools-iuc/tree/master/tools/volcanoplot
homepage_url: https://ggplot2.tidyverse.org/
type: unrestricted
33 changes: 17 additions & 16 deletions tools/volcanoplot/volcanoplot.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<tool id="volcanoplot" name="Volcano Plot" version="0.0.5">
<tool id="volcanoplot" name="Volcano Plot" version="0.0.6" profile="20.09">
<description>create a volcano plot</description>
<edam_topics>
<edam_topic>topic_0092</edam_topic>
Expand Down Expand Up @@ -145,29 +145,29 @@ p <- p + geom_text_repel(data = filter(results, labels != ""), aes(label = label
#end if
#end if
#if not '$plot_options.title'
#if $plot_options.title:
p <- p + ggtitle('$plot_options.title')
#end if
#if not '$plot_options.xlab'
#if $plot_options.xlab:
p <- p + xlab('$plot_options.xlab')
#end if
#if not '$plot_options.ylab'
#if $plot_options.ylab:
p <- p + ylab('$plot_options.ylab')
#end if
#if not '$plot_options.xmin' and '$plot_options.xmax'
p <- p + xlim('$plot_options.xmin', '$plot_options.xmax')
#if $plot_options.xmin and $plot_options.xmax:
p <- p + xlim($plot_options.xmin, $plot_options.xmax)
#end if
#if not '$plot_options.ymax'
p <- p + ylim(0, '$plot_options.ymax')
#if $plot_options.ymax:
p <- p + ylim(0, $plot_options.ymax)
#end if
# Set legend title
#if not '$plot_options.legend'
p <- p + theme(legend.title = '$plot_options.legend')
#if $plot_options.legend:
p <- p + guides(color = guide_legend(title = '$plot_options.legend'))
#else
p <- p + theme(legend.title = element_blank())
#end if
Expand All @@ -191,10 +191,10 @@ sessionInfo()
<option value="yes">Yes</option>
<option value="no">No</option>
</param>
<param name="fdr_col" type="data_column" data_ref="input" label="FDR (adjusted P value)" />
<param name="pval_col" type="data_column" data_ref="input" label="P value (raw)" />
<param name="lfc_col" type="data_column" data_ref="input" label="Log Fold Change" />
<param name="label_col" type="data_column" data_ref="input" label="Labels" />
<param name="fdr_col" type="data_column" data_ref="input" label="FDR (adjusted P value) column number" />
<param name="pval_col" type="data_column" data_ref="input" label="P value (raw) column number" />
<param name="lfc_col" type="data_column" data_ref="input" label="Log Fold Change column number" />
<param name="label_col" type="data_column" data_ref="input" label="Labels column number" />
<param name="signif_thresh" type="float" max="1" value="0.05" label="Significance threshold" help="Default: 0.05"/>
<param name="lfc_thresh" type="float" value="0" label="LogFC threshold to colour" help="Default: 0"/>
<conditional name="labels">
Expand Down Expand Up @@ -260,7 +260,7 @@ sessionInfo()
<param name="label_file" ftype="tabular" value="labels.tab" />
<output name="plot">
<assert_contents>
<has_size value= "933832" delta="1000" />
<has_size value= "933830" delta="1000" />
</assert_contents>
</output>
</test>
Expand Down Expand Up @@ -321,5 +321,6 @@ A PDF containing a Volcano plot like below. The R code can be output through *Ou
]]></help>
<citations>
<citation type="doi">doi.org/10.1007/978-3-319-24277-4</citation>
</citations>
</tool>
</tool>

0 comments on commit 589795c

Please sign in to comment.