Repository 'macs2'
hg clone https://toolshed.g2.bx.psu.edu/repos/iuc/macs2

Changeset 2:bfe57d6e0c4c (2015-10-12)
Previous changeset 1:859c982b1f7f (2015-02-12) Next changeset 3:6d4babad010f (2016-01-27)
Commit message:
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/macs2 commit 63955994af5090ec444c03c221df0012d5ae4e74
modified:
macs2_bdgbroadcall.xml
macs2_bdgcmp.xml
macs2_bdgdiff.xml
macs2_bdgpeakcall.xml
macs2_callpeak.xml
macs2_filterdup.xml
macs2_macros.xml
macs2_predictd.xml
macs2_randsample.xml
macs2_refinepeak.xml
tool_dependencies.xml
added:
test-data/magic.pdf
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_bdgbroadcall.xml
--- a/macs2_bdgbroadcall.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_bdgbroadcall.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,12 +1,13 @@
 <tool id="macs2_bdgbroadcall" name="MACS2 bdgbroadcall" version="@VERSION_STRING@.0">
     <description>Call broad peaks from bedGraph output</description>
+    <macros>
+        <import>macs2_macros.xml</import>
+    </macros>
     <expand macro="requirements">
         <requirement type="package" version="4.1.0">gnu_awk</requirement>
     </expand>
+    <expand macro="stdio" />
     <expand macro="version_command" />
-    <macros>
-        <import>macs2_macros.xml</import>
-    </macros>
     <command>
         macs2 bdgbroadcall
             --ifile "${ infile }"
@@ -19,18 +20,17 @@
         &amp;&amp;
         awk '!/^track name/' "macs2_bdgbroadcall.bdg" > "${ outfile }"
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile" type="data" format="bedgraph" label="MACS score in bedGraph" />
-        <param name="cutoffpeak" type="float" label="Cutoff for peaks" value="2.0" 
+        <param name="cutoffpeak" type="float" label="Cutoff for peaks" value="2.0"
             help="Cutoff for peaks depending on which method you used for score track. If the file contains qvalue scores from MACS2, score 2 means qvalue 0.01. default: 2.0 (--cutoff-peak)"/>
-        <param name="cutofflink" type="float" label="Cutoff for peaks" value="1.0" 
+        <param name="cutofflink" type="float" label="Cutoff for peaks" value="1.0"
             help=" Cutoff for linking regions/low abundance regions depending on which method you used for score track. If the file contains qvalue scores from MACS2, score 1 means qvalue 0.1, and score 0.3 means qvalue 0.5. default: 1 (--cutoff-link)"/>
-        <param name="minlen" type="integer" label="Minimum length of peak" value="200" 
+        <param name="minlen" type="integer" label="Minimum length of peak" value="200"
             help="It is recommended to set it as d value." />
-        <param name="LVL1MAXGAP" type="integer" label="Maximum gap between significant peaks" value="30" 
+        <param name="LVL1MAXGAP" type="integer" label="Maximum gap between significant peaks" value="30"
             help="It is recommended to set it to tag size" />
-        <param name="LVL2MAXGAP" type="integer" label="Maximum linking between significant peaks" value="800" 
+        <param name="LVL2MAXGAP" type="integer" label="Maximum linking between significant peaks" value="800"
             help="It is recommended to set it to 4 times of d value" />
     </inputs>
     <outputs>
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_bdgcmp.xml
--- a/macs2_bdgcmp.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_bdgcmp.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,10 +1,11 @@
 <tool id="macs2_bdgcmp" name="MACS2 bdgcmp" version="@VERSION_STRING@.0">
     <description>Deduct noise by comparing two signal tracks in bedGraph</description>
-    <expand macro="requirements" />
-    <expand macro="version_command" />
     <macros>
         <import>macs2_macros.xml</import>
     </macros>
+    <expand macro="requirements" />
+    <expand macro="stdio" />
+    <expand macro="version_command" />
     <command>
         macs2 bdgcmp
             -t "${ infile_treatment }"
@@ -17,7 +18,6 @@
             -o "${ outfile }"
 
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile_treatment" type="data" format="bedgraph" label="Treatment bedGraph file" />
         <param name="infile_control" type="data" format="bedgraph" label="Control bedGraph file" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_bdgdiff.xml
--- a/macs2_bdgdiff.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_bdgdiff.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,10 +1,11 @@
 <tool id="macs2_bdgdiff" name="MACS2 bdgdiff" version="@VERSION_STRING@.0">
     <description>Differential peak detection based on paired four bedgraph files</description>
-    <expand macro="requirements" />
-    <expand macro="version_command" />
     <macros>
         <import>macs2_macros.xml</import>
     </macros>
+    <expand macro="requirements" />
+    <expand macro="stdio" />
+    <expand macro="version_command" />
     <command>
         macs2 bdgdiff
             --t1 "${ infile_pileup_cond1 }"
@@ -19,7 +20,6 @@
             --o-prefix MACS2
 
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile_pileup_cond1" type="data" format="bedgraph" label="MACS pileup bedGraph for condition 1" />
         <param name="infile_pileup_cond2" type="data" format="bedgraph" label="MACS pileup bedGraph for condition 2" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_bdgpeakcall.xml
--- a/macs2_bdgpeakcall.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_bdgpeakcall.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,12 +1,13 @@
 <tool id="macs2_bdgpeakcall" name="MACS2 bdgpeakcall" version="@VERSION_STRING@.0">
     <description>Call peaks from bedGraph output</description>
+    <macros>
+        <import>macs2_macros.xml</import>
+    </macros>
     <expand macro="requirements">
         <requirement type="package" version="4.1.0">gnu_awk</requirement>
     </expand>
+    <expand macro="stdio" />
     <expand macro="version_command" />
-    <macros>
-        <import>macs2_macros.xml</import>
-    </macros>
     <command>
         macs2 bdgpeakcall
         --ifile "${ infile }"
@@ -19,19 +20,18 @@
         &amp;&amp;
         awk '!/^track name/' "macs2_bdgpeakcall.bdg" > "${ outfile }"
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile" type="data" format="bedgraph" label="MACS score in bedGraph" />
 
-        <param name="cutoff" type="float" label="Cutoff for peaks" value="5.0" 
+        <param name="cutoff" type="float" label="Cutoff for peaks" value="5.0"
             help="Cutoff depends on which method you used for score track. If the file contains pvalue scores from MACS2, score 5 means pvalue 1e-5. DEFAULT: 5.0 (--cutoff)"/>
         <param name="minlen" type="integer" value="200" label="Minimum length of peak" help="better to set it as d value (--min-length)"/>
         <param name="maxgap" type="integer" value="30" label="Maximum gap between significant points in a peak" help="better to set it as tag size DEFAULT: 30 (--max-gap)"/>
 
-        <param name="callsummits" type="boolean" truevalue="--call-summits" falsevalue="" checked="False" 
+        <param name="callsummits" type="boolean" truevalue="--call-summits" falsevalue="" checked="False"
             label="If set, MACS will use a more sophisticated approach to find all summits in each enriched peak region."
             help="(-call-summits)"/>
-        <param name="notrackline" type="boolean" truevalue="" falsevalue="--no-trackline" checked="False" 
+        <param name="notrackline" type="boolean" truevalue="" falsevalue="--no-trackline" checked="False"
             label="Include trackline into bedGraph output"
             help="required by USCS (--no-trackline)"/>
     </inputs>
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_callpeak.xml
--- a/macs2_callpeak.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_callpeak.xml Mon Oct 12 11:24:39 2015 -0400
[
@@ -1,14 +1,15 @@
 <tool id="macs2_callpeak" name="MACS2 callpeak" version="@VERSION_STRING@.0">
     <description>Call peaks from alignment results</description>
+    <macros>
+        <import>macs2_macros.xml</import>
+    </macros>
     <expand macro="requirements">
         <requirement type="package" version="3.0.1">R_3_0_1</requirement>
         <requirement type="package" version="4.1.0">gnu_awk</requirement>
         <requirement type="set_environment">MACS2_SCRIPT_PATH</requirement>
     </expand>
+    <expand macro="stdio" />
     <expand macro="version_command" />
-    <macros>
-        <import>macs2_macros.xml</import>
-    </macros>
     <command>
         #set $temp_stderr = 'macs2_stderr'
         (macs2 callpeak
@@ -84,7 +85,7 @@
         #end if
 
         ## run R to create pdf from model script
-        #if 'pdf' in str($outputs).split(','):
+        #if $nomodel_type.nomodel_type_selector == 'create_model' and 'pdf' in str($outputs).split(','):
             &amp;&amp;
             Rscript MACS2_model.r > MACS2_model.r.log
         #end if
@@ -95,7 +96,7 @@
             (
             count=`ls -1 MACS2* 2>/dev/null | wc -l`;
             if [ \$count != 0 ];
-            then 
+            then
                 mkdir "${ output_extra_files.files_path }";
                 cp MACS2* "${ output_extra_files.files_path }";
                 python "\$MACS2_SCRIPT_PATH/dir2html.py" "${ output_extra_files.files_path }" $temp_stderr > "${ output_extra_files }";
@@ -107,7 +108,6 @@
         cat $temp_stderr 2&gt;&amp;1;
         (exit \$exit_code_for_galaxy)
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="input_treatment_file" type="data" format="bam,sam,bed" multiple="True" label="ChIP-Seq Treatment File" />
         <param name="input_control_file" type="data" format="bam,sam,bed" multiple="True" optional="True" label="ChIP-Seq Control File" />
@@ -146,12 +146,12 @@
             <when value="create_model"/>
             <when value="nomodel">
                 <!--<param name="shiftsize" type="integer" label="Arbitrary shift size in bp" value="100" help="(shiftsize)"/>-->
-                <param name="extsize" type="integer" value="100" label="The arbitrary extension size in bp" 
+                <param name="extsize" type="integer" value="100" label="The arbitrary extension size in bp"
                     help="MACS will use this value as fragment size to extend each read towards 3' end, then pile them up. It's exactly twice the number of legacy shiftsize. In previous language, each read is moved 3' direction to middle of fragment by 1/2 d, then extended to both direction with 1/2 d. This is equivalent to say each read is extended towards 3' into a d size fragment. DEFAULT: 200 (--extsize)"/>
             </when>
         </conditional>
 
-        <param name="outputs" type="select" display="checkboxes" multiple="True" label="Outputs">
+        <param name="outputs" type="select" display="checkboxes" multiple="True" label="Outputs" help="PDF only created when model is build">
             <option value="peaks_bed" selected="True">Peaks as BED file</option>
             <!--<option value="narrow">narrow Peaks</option>-->
             <option value="summits" selected="true">summits</option>
@@ -167,10 +167,10 @@
                 <option value="on">Display advanced options</option>
             </param>
             <when value="on">
-                <param name="to_large" type="boolean" truevalue="--to-large" falsevalue="" checked="False" 
+                <param name="to_large" type="boolean" truevalue="--to-large" falsevalue="" checked="False"
                     label="When set, scale the small sample up to the bigger sample"
                     help="By default, the bigger dataset will be scaled down towards the smaller dataset, which will lead to smaller p/qvalues and more specific results. Keep in mind that scaling down will bring down background noise more. (--to-large)"/>
-                <param name="nolambda" type="boolean" truevalue="--nolambda" falsevalue="" checked="False" 
+                <param name="nolambda" type="boolean" truevalue="--nolambda" falsevalue="" checked="False"
                     label="Use fixed background lambda as local lambda for every peak region" help="up to 9X more time consuming (--nolambda)"/>
                 <param name="ratio" type="float" value="1.0"
                     label="When set, use a custom scaling ratio of ChIP/control (e.g. calculated using NCIS) for linear scaling"
@@ -186,12 +186,12 @@
                         <option value="broad">broad regions</option>
                     </param>
                     <when value="broad">
-                        <param name="broad_cutoff" type="float" label="Cutoff for broad region" value="0.1" 
+                        <param name="broad_cutoff" type="float" label="Cutoff for broad region" value="0.1"
                             help="value is either p-value or q-value as specified above (--broad-cutoff)"/>
                     </when>
                     <when value="nobroad">
-                        <param name="call_summits" type="boolean" truevalue="--call-summits" falsevalue="" checked="False" 
-                            label="Use a more sophisticated signal processing approach to find subpeak summits in each enriched peak region" 
+                        <param name="call_summits" type="boolean" truevalue="--call-summits" falsevalue="" checked="False"
+                            label="Use a more sophisticated signal processing approach to find subpeak summits in each enriched peak region"
                             help="(--call-summits)"/>
                     </when>
                 </conditional>
@@ -235,7 +235,12 @@
             <filter>'summits' in outputs</filter>
         </data>
         <data name="output_plot" format="pdf" from_work_dir="MACS2_model.pdf" label="${tool.name} on ${on_string} (plot)">
-            <filter>'pdf' in outputs</filter>
+            <filter>
+            ((
+              'pdf' in outputs and
+              nomodel_type['nomodel_type_selector'] == "create_model"
+            ))
+            </filter>
         </data>
         <data name="output_treat_pileup" format="bedgraph" from_work_dir="MACS2_treat_pileup.bdg" label="${tool.name} on ${on_string} (Bedgraph Treatment)">
             <filter>'bdg' in outputs</filter>
@@ -262,6 +267,17 @@
             <output name="output_bed" compare="contains" file="callpeak_part.bed"/>
             <output name="output_summits" compare="contains" file="callpeak_summits_part.bed"/>
         </test>
+        <test>
+            <param name="input_control_file" value="Control_200K.bed" ftype="bed"/>
+            <param name="input_treatment_file" value="ChIP_200K.bed" ftype="bed"/>
+            <param name="cutoff_options_selector" value="qvalue"/>
+            <param name="qvalue" value="0.05"/>
+            <param name="band_width" value="300"/>
+            <param name="outputs" value="pdf"/>
+            <param name="effective_genome_size_options_selector" value="user_defined" />
+            <param name="gsize" value="3300000000" />
+            <output name="output_plot" file="magic.pdf" ftype="pdf" compare="contains" />
+        </test>
     </tests>
     <help>
 **What it does**
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_filterdup.xml
--- a/macs2_filterdup.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_filterdup.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,10 +1,11 @@
 <tool id="macs2_filterdup" name="MACS2 filterdup" version="@VERSION_STRING@.0">
     <description>Remove duplicate reads at the same position</description>
-    <expand macro="requirements" />
-    <expand macro="version_command" />
     <macros>
         <import>macs2_macros.xml</import>
     </macros>
+    <expand macro="requirements" />
+    <expand macro="stdio" />
+    <expand macro="version_command" />
     <command>
         macs2 filterdup
             -i "${ infile }"
@@ -22,7 +23,6 @@
  ;
  mv temp_outfile "${ outfile }"
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile" type="data" format="sam,bam,bed" label="Sequencing alignment file" />
         <expand macro="conditional_effective_genome_size" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_macros.xml
--- a/macs2_macros.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_macros.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -22,8 +22,12 @@
                 <option value="93260000">Worm (93,260,000)</option>
                 <option value="user_defined">User defined</option>
             </param>
+            <when value="2451960000" />
+            <when value="2150570000" />
+            <when value="121400000" />
+            <when value="93260000" />
             <when value="user_defined">
-                <param name="gsize" type="integer" size="12" label="Effective genome size" value=""/>
+                <param name="gsize" type="integer" label="Effective genome size" value=""/>
             </when>
         </conditional>
     </xml>
@@ -38,7 +42,7 @@
                 <option value="user">user defined</option>
             </param>
             <when value="user">
-                <param name="user_keepdup" type="integer" value="1" label="Keep at most this number of tags at the exact same location" 
+                <param name="user_keepdup" type="integer" value="1" label="Keep at most this number of tags at the exact same location"
                     help=""/>
             </when>
             <when value="1" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_predictd.xml
--- a/macs2_predictd.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_predictd.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,13 +1,14 @@
 <tool id="macs2_predictd" name="MACS2 predictd" version="@VERSION_STRING@.0">
     <description>Predict 'd' or fragment size from alignment results</description>
+    <macros>
+        <import>macs2_macros.xml</import>
+    </macros>
     <expand macro="requirements">
         <requirement type="package" version="3.0.1">R_3_0_1</requirement>
         <requirement type="package" version="4.1.0">gnu_awk</requirement>
     </expand>
+    <expand macro="stdio" />
     <expand macro="version_command" />
-    <macros>
-        <import>macs2_macros.xml</import>
-    </macros>
     <command>
         macs2 predictd
             -i ${ ' '.join( map( lambda x:'"%s"' % ( x ), $infiles ) ) }
@@ -20,12 +21,11 @@
             2>&amp;1 | awk -F: '{print $4}' | awk '{$1=$1}1'
 
             &gt; "${ outfile }"
-            
+
         &amp;&amp;
 
         Rscript predictd
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infiles" type="data" format="bam,sam,bed" multiple="True" label="ChIP-seq alignment file" help="If multiple files are given, then they will all be read and combined. Note that pair-end data is not supposed to work with this command. (-i)" />
         <expand macro="conditional_effective_genome_size" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_randsample.xml
--- a/macs2_randsample.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_randsample.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,10 +1,11 @@
 <tool id="macs2_randsample" name="MACS2 randsample" version="@VERSION_STRING@.0">
     <description>Randomly sample number or percentage of total reads</description>
-    <expand macro="requirements" />
-    <expand macro="version_command" />
     <macros>
         <import>macs2_macros.xml</import>
     </macros>
+    <expand macro="requirements" />
+    <expand macro="stdio" />
+    <expand macro="version_command" />
     <command>
         macs2 randsample
             -t "${ infile }"
@@ -19,7 +20,6 @@
             --number "${ method_options.number }"
         #end if
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile" type="data" format="sam,bam,bed" label="Sequencing alignment file" />
         <expand macro="tag_size" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c macs2_refinepeak.xml
--- a/macs2_refinepeak.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/macs2_refinepeak.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,10 +1,11 @@
 <tool id="macs2_refinepeak" name="MACS2 refinepeak" version="@VERSION_STRING@.0">
     <description>Refine peak summits and give scores measuring balance of forward- backward tags (Experimental)</description>
-    <expand macro="requirements" />
-    <expand macro="version_command" />
     <macros>
         <import>macs2_macros.xml</import>
     </macros>
+    <expand macro="requirements" />
+    <expand macro="stdio" />
+    <expand macro="version_command" />
     <command>
         macs2 refinepeak
             -b "${ bed_infile }"
@@ -14,7 +15,6 @@
             --window-size "${ winsize }"
             --ofile "${ outfile }"
     </command>
-    <expand macro="stdio" />
     <inputs>
         <param name="infile" type="data" format="sam,bam,bed" label="Sequencing alignment file" />
         <param name="bed_infile" type="data" format="bed" label="Candidate peak file in BED format" />
b
diff -r 859c982b1f7f -r bfe57d6e0c4c test-data/magic.pdf
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/magic.pdf Mon Oct 12 11:24:39 2015 -0400
b
@@ -0,0 +1,1 @@
+%PDF-1.4
b
diff -r 859c982b1f7f -r bfe57d6e0c4c tool_dependencies.xml
--- a/tool_dependencies.xml Thu Feb 12 10:40:25 2015 -0500
+++ b/tool_dependencies.xml Mon Oct 12 11:24:39 2015 -0400
b
@@ -1,13 +1,13 @@
 <?xml version="1.0"?>
 <tool_dependency>
     <package name="numpy" version="1.7.1">
-       <repository changeset_revision="692ae723f63e" name="package_numpy_1_7" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
+       <repository changeset_revision="300877695495" name="package_numpy_1_7" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
     </package>
     <package name="scipy" version="0.12.0">
-       <repository changeset_revision="91ad926d7d36" name="package_scipy_0_12" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
+       <repository changeset_revision="cfbbe183f8a7" name="package_scipy_0_12" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
     </package>
     <package name="R_3_0_1" version="3.0.1">
-        <repository changeset_revision="c5ff6dd33c79" name="package_r_3_0_1" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
+        <repository changeset_revision="59b82e6e0801" name="package_r_3_0_1" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
     </package>
     <package name="gnu_awk" version="4.1.0">
        <repository changeset_revision="52a8268bb49f" name="package_gnu_awk_4_1_0" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />