Mercurial > repos > iuc > ggplot2_point
diff ggplot_point.xml @ 4:52b8083a6159 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/ggplot2 commit d1da3cf72a15d88fc265edc5d64e6b820b6a2b2f
author | iuc |
---|---|
date | Sun, 24 Mar 2019 13:21:18 -0400 |
parents | 9a482995958c |
children | 9cec81e1b90e |
line wrap: on
line diff
--- a/ggplot_point.xml Mon Feb 11 17:28:38 2019 -0500 +++ b/ggplot_point.xml Sun Mar 24 13:21:18 2019 -0400 @@ -1,4 +1,4 @@ -<tool id="ggplot2_point" name="Scatterplot w ggplot2" version="@VERSION@+galaxy0"> +<tool id="ggplot2_point" name="Scatterplot w ggplot2" version="@VERSION@+galaxy1"> <macros> <import>macros.xml</import> </macros> @@ -35,8 +35,10 @@ color_scale = NULL #if $adv.points.pointoptions == "Default" gg_point = geom_point(size=1, alpha=1, gg_factor) + gg_line = geom_line(size=1, alpha=1, gg_factor) #else gg_point = geom_point(size='$adv.points.size', alpha='$adv.points.alpha', colour='$adv.points.pointcolor') + gg_line = geom_line(size='$adv.points.size', alpha='$adv.points.alpha', colour='$adv.points.pointcolor') #end if names(input)[$adv.factor.factorcol] <- "factor" @@ -47,14 +49,16 @@ #if $adv.points.pointoptions == "default" gg_point = geom_point(size=1, alpha=1, gg_factor) + gg_line = geom_line(size=1, alpha=1, gg_factor) #else gg_point = geom_point(size=$adv.points.size, alpha='$adv.points.alpha', gg_factor) + gg_line = geom_line(size=$adv.points.size, alpha='$adv.points.alpha', gg_factor) #end if - #if $adv.colors == "Default" + #if $adv.factor.colororder == 1 color_scale = scale_colour_hue(direction='$adv.factor.colororder') #else - color_scale = scale_color_brewer(palette='$adv.colors', direction='$adv.factor.colororder') + color_scale = scale_color_brewer(palette='$adv.factor.colors', direction='$adv.factor.colororder') #end if names(input)[$adv.factor.factorcol] <- "factor" @@ -65,8 +69,10 @@ #if $adv.points.pointoptions == "default" gg_point = geom_point(size=1, alpha=1, gg_factor) + gg_line = geom_line(size=1, alpha=1, gg_factor) #else gg_point = geom_point(size=$adv.points.size, alpha='$adv.points.alpha', colour='$adv.points.pointcolor') + gg_line = geom_line(size=$adv.points.size, alpha='$adv.points.alpha', colour='$adv.points.pointcolor') #end if #end if @@ -104,8 +110,15 @@ gg_gridline = theme(panel.grid.minor = element_blank(), panel.grid.major = element_blank()) #end if +## choose between graph types (points/lines/both) +#if $adv.type == "points" + gg_line = NULL +#elif $adv.type == "lines" + gg_point = NULL +#end if + #this is the actual ggplot command to make the final plot(s) -plot_out <- ggplot(input, aes(xcol, ycol)) + gg_point + gg_facet + +plot_out <- ggplot(input, aes(xcol, ycol)) + gg_point + gg_line + gg_facet + gg_theme + gg_scalex + gg_scaley + color_scale + gg_legend + ggtitle('$title') + xlab('$xlab') + ylab('$ylab')+ gg_axistitle + gg_axistext + gg_plottitle + gg_gridline @@ -120,6 +133,11 @@ <expand macro="title" /> <expand macro="xy_lab" /> <section name="adv" title="Advanced Options" expanded="false"> + <param name="type" type="select" label="Type of plot" > + <option value="points">Points only (default)</option> + <option value="lines">Lines only </option> + <option value="pointslines">Points and Lines</option> + </param> <conditional name="points"> <param name="pointoptions" type="select" label="Data point options"> <option value="default" selected="true">Default</option>