changeset 5:b25b3518c2ce draft

planemo upload for repository https://github.com/TAMU-CPT/galaxy-circos-tool commit 7561690774be81155d79a3c38a77c098c59aa9a2
author eric-rasche
date Sat, 10 Jun 2017 12:55:28 -0400
parents 4ff5ff4c84fa
children 169adf243c0a
files README.rst circgraph.xml macros.xml macros_conffiles.xml unified-histogram.py unified-tiles.py
diffstat 6 files changed, 24 insertions(+), 14 deletions(-) [+]
line wrap: on
line diff
--- a/README.rst	Sun Mar 05 17:02:17 2017 -0500
+++ b/README.rst	Sat Jun 10 12:55:28 2017 -0400
@@ -31,13 +31,13 @@
    -  [x] Scatter Plots
    -  [x] Line Plots
 
--  [ ] Links
+-  [x] Links
 -  [x] Axes
 -  [x] Backgrounds
--  [ ] Highlights
+-  [x] Highlights
 
    -  [ ] Wedge
 
+-  [x] Test cases
 -  [ ] Grids?
--  [x] Test cases
 -  [ ] Fine grained Z-depth control
--- a/circgraph.xml	Sun Mar 05 17:02:17 2017 -0500
+++ b/circgraph.xml	Sat Jun 10 12:55:28 2017 -0400
@@ -106,7 +106,7 @@
                  help="When set to yes/true, labels will be perpendicular to the tangent of the circle at the location of the label. Otherwise, they will be parallel with the tangent of the circle"/>
         </section>
         <!-- TODO: multiple band files? -->
-        <param name="bands" type="data" format="bed6,bed12,gff3" optional="true" label="Cytogenetic Bands"
+        <param name="bands" type="data" format="bed6,bed12" optional="true" label="Cytogenetic Bands"
              help="If defined, will display cytogenetic bands as part of the karyotype configuration"/>
     </section>
 
--- a/macros.xml	Sun Mar 05 17:02:17 2017 -0500
+++ b/macros.xml	Sat Jun 10 12:55:28 2017 -0400
@@ -3,9 +3,11 @@
   <token name="@WRAPPER_VERSION@">0.9-RC1</token>
   <xml name="requirements">
       <requirements>
+        <requirement type="package" version="0.69.4">circos</requirement>
+        <requirement type="package" version="2.2.3">libgd</requirement>
         <requirement type="package" version="2.7">python</requirement>
-        <requirement type="package" version="0.6.2">bcbiogff</requirement>
-        <requirement type="package" version="0.69.2">circos</requirement>
+        <requirement type="package" version="0.6.4">bcbiogff</requirement>
+        <requirement type="package" version="1.67">biopython</requirement>
       </requirements>
   </xml>
 
@@ -165,6 +167,7 @@
                         <option value="fill_color">Change Fill Color for all points</option>
                         <option value="fill_color_value">Change Fill Color based on Value</option>
                         <option value="color">Change Stroke Color</option>
+                        <option value="color_value">Change Stroke Color based on Value</option>
                     </param>
                     <when value="show">
                         <param name="action_value" type="boolean" truevalue="yes" falsevalue="no" label="Show"/>
@@ -180,6 +183,11 @@
                         <param name="min_value" type="float" value="-1" label="Expected minimum value of dataset"/>
                         <param name="max_value" type="float" value="1" label="Expected maximum value of dataset"/>
                     </when>
+                    <when value="color_value">
+                        <expand macro="brewer_scale" name="action_value" label="Stroke Color"/>
+                        <param name="min_value" type="float" value="-1" label="Expected minimum value of dataset"/>
+                        <param name="max_value" type="float" value="1" label="Expected maximum value of dataset"/>
+                    </when>
                 </conditional>
             </repeat>
             <param name="continue_flow" type="boolean" truevalue="flow = continue" falsevalue="" label="Continue flow"
--- a/macros_conffiles.xml	Sun Mar 05 17:02:17 2017 -0500
+++ b/macros_conffiles.xml	Sat Jun 10 12:55:28 2017 -0400
@@ -170,7 +170,7 @@
                 #set x_fill_color_count = int(str($x_fill_color).split('-')[1]) + 1
                 #set x_fill_color_qw = ' '.join(["%s-%s" % ($action.action.action_value, $i) for i in range(1, $x_fill_color_count)])
 
-                #if str($action.action.action_select) == "fill_color_value":
+                #if str($action.action.action_select) == "fill_color_value" or str($action.action.action_select) == "color_value" :
                     fill_color = eval(qw(${x_fill_color_qw})[remap_int(var(value), ${action.action.min_value}, ${action.action.max_value}, 0, ${x_fill_color_count - 1})])
                 #else
                     $action.action.action_select = ${action.action.action_value}
@@ -328,7 +328,9 @@
     <configfile name="test_case_conf"><![CDATA[
 <!--
 mkdir -p test-data/my-test-case/;
-cp ${genome_fasta} test-data/my-test-case/input.fa;
+#if $reference_genome.reference_genome_source == 'history':
+    cp ${genome_fasta} test-data/my-test-case/input.fa;
+#end if
 #if $ideogram.bands:
 cp ${ideogram.bands} test-data/my-test-case/bands.${ideogram.bands.ext};
 #end if
--- a/unified-histogram.py	Sun Mar 05 17:02:17 2017 -0500
+++ b/unified-histogram.py	Sat Jun 10 12:55:28 2017 -0400
@@ -116,7 +116,7 @@
                     # histogram
                     # hs4 0 1999999 5.0000,3.0000,1.0000,19.0000
                     sys.stdout.write(' '.join(
-                        (genome, region_start, region_end, ','.join(values))
+                        (genome, str(region_start), str(region_end), ','.join(map(str, values)))
                     ) + '\n')
                 elif MODE == 'heatmap':
                     # heatmap
@@ -129,21 +129,21 @@
                     for x in max_idx:
                         if x in data[genome][position]:
                             sys.stdout.write(' '.join(
-                                (genome, region_start, region_end, data[genome][position][x], 'id=hm%s' % x)
+                                (genome, str(region_start), str(region_end), data[genome][position][x], 'id=hm%s' % x)
                             ) + '\n')
                         else:
                             sys.stdout.write(' '.join(
-                                (genome, region_start, region_end, 0.0, 'id=hm%s' % x)
+                                (genome, str(region_start), str(region_end), 0.0, 'id=hm%s' % x)
                             ) + '\n')
                 elif MODE == 'line':
                     # multiple=False
                     sys.stdout.write(' '.join(
-                        (genome, region_start, region_end, data[genome][position][0])
+                        (genome, str(region_start), str(region_end), data[genome][position][0])
                     ) + '\n')
                 elif MODE == 'scatter':
                     # multiple=False
                     sys.stdout.write(' '.join(
-                        (genome, region_start, region_end, data[genome][position][0])
+                        (genome, str(region_start), str(region_end), data[genome][position][0])
                     ) + '\n')
 
                 # Update start of next array
--- a/unified-tiles.py	Sun Mar 05 17:02:17 2017 -0500
+++ b/unified-tiles.py	Sat Jun 10 12:55:28 2017 -0400
@@ -68,4 +68,4 @@
                 if item[6] is not None:
                     lineExtra.append('color=%s' % item[6])
 
-                sys.stdout.write(' '.join((item[0], item[1], item[2], ','.join(lineExtra))) + '\n')
+                sys.stdout.write(' '.join((str(item[0]), str(item[1]), str(item[2]), ','.join(lineExtra))) + '\n')