view plotCorrelation.xml @ 3:e556e34fc12a draft

planemo upload for repository https://github.com/fidelram/deepTools/tree/master/galaxy/wrapper/ commit a92b8557d0985038d24daaab2996fbf8e4cd323f
author bgruening
date Mon, 21 Dec 2015 07:24:37 -0500
parents c5634baf9bf9
children ae54e08b15d7
line wrap: on
line source

<tool id="deeptools_plot_correlation" name="plotCorrelation" version="@WRAPPER_VERSION@.0">
    <description>creates a heatmap of correlation scores between different samples </description>
    <macros>
        <token name="@BINARY@">plotCorrelation</token>
        <import>deepTools_macros.xml</import>
    </macros>
    <expand macro="requirements"/>
    <command>
<![CDATA[
        @BINARY@
            --corData "$corData"
            --plotFile "$outFileName"
            --corMethod "$corMethod"
            --whatToPlot "$plotting_type.whatToPlot"
            #if str($plotting_type.whatToPlot) == 'heatmap':
                @HEATMAP_OPTIONS@
            #else:
                --plotTitle '$plotting_type.plotTitle'
            #end if
            $skipZeros
            --plotFileFormat "$outFileFormat"
            $removeOutliers
            #if $outFileCorMatrix:
                --outFileCorMatrix "$matrix"
            #end if

]]>
    </command>
    <inputs>
        <param name="corData" format="deeptools_coverage_matrix" type="data" label="Matrix file from the bamCorrelate tool"/>
        <expand macro="corMethod" />

        <conditional name="plotting_type" >
            <param argument="--whatToPlot" type="select" label="Plotting type">
                <option value="heatmap" selected="True">Heatmap</option>
                <option value="scatterplot">Scatterplot</option>
            </param>
            <when value="heatmap">
                <expand macro="heatmap_options" />
            </when>
            <when value="scatterplot">
                <expand macro="plotTitle" />
            </when>
        </conditional>

        <expand macro="skipZeros" />

        <expand macro="input_image_file_format" />

        <param argument="--removeOutliers" type="boolean"
            truevalue="--removeOutliers" falsevalue="" label="Remove regions with very large counts"
            help="If set, bins with very large counts are removed. Bins
                with abnormally high reads counts artificially
                increase pearson correlation; that's why, by default,
                bamCorrelate tries to remove outliers using the median
                absolute deviation (MAD) method applying a threshold
                of 200 to only consider extremely large deviations
                from the median. ENCODE blacklist page (https://sites.
                google.com/site/anshulkundaje/projects/blacklists)
                contains useful information about regions with
                unusually high counts."/>

        <param name="outFileCorMatrix" type="boolean" label="Save the matrix of values underlying the heatmap"/>

    </inputs>
    <outputs>
        <expand macro="output_image_file_format_not_nested" />
        <data format="tabular" name="matrix" label="${tool.name} on ${on_string}: Correlation matrix">
            <filter>outFileCorMatrix is True</filter>
        </data>
    </outputs>
    <tests>
        <test>
            <param name="corData" value="bamCorrelate_result1.npz" ftype="deeptools_coverage_matrix" />
            <param name="outFileFormat" value="png" />
            <param name="outFileCorMatrix" value="True" />
            <output name="matrix" file="plotCorrelation_result1.tabular" ftype="tabular" />
            <output name="outFileName" file="plotCorrelation_result1.png" ftype="png" compare="sim_size" delta="100" />
        </test>
        <test>
            <param name="corData" value="bamCorrelate_result1.npz" ftype="deeptools_coverage_matrix" />
            <param name="outFileFormat" value="png" />
            <param name="whatToPlot" value="scatterplot" />
            <param name="removeOutliers" value="True" />
            <param name="plotTitle" value="Test Plot" />
            <output name="outFileName" file="plotCorrelation_result2.png" ftpye="png" compare="sim_size" delta="100" />
        </test>
    </tests>
    <help>
<![CDATA[
**What it does**

This tools takes a compressed matrix of scores (such as read coverages) for a number of genomic regions
and different samples. It can visualize the correlation among samples as scatterplots or as 
heatmap of correlation coefficients. Further output files are optional.
The compressed input matrices are easily generated using the "bamCorrelate" and "bigwigCorrelate" modules of deeptools.


.. image:: $PATH_TO_IMAGES/QC_bamCorrelate_humanSamples.png
   :alt: Heatmap of RNA Polymerase II ChIP-seq


You can find more details on plotCorrelation here http://deeptools.readthedocs.org/en/release-1.6/content/tools/plotCorrelation.html


**Output files**:

- **correlation structure**: a scatterplot of all mutual correlations between all samples in matrix
- **diagnostic plot**: clustered heatmap displaying the values for each pair-wise correlation, see below for an example
- data matrix (optional): if you want to analyze or plot the correlation values using a different program, e.g. R, this matrix can be used

-----

@REFERENCES@
]]>
    </help>
    <expand macro="citations" />
</tool>