Mercurial > repos > bgruening > deeptools
diff heatmapper.xml @ 0:d957e25e18a3 draft
Uploaded
author | bgruening |
---|---|
date | Thu, 14 Nov 2013 16:39:18 -0500 |
parents | |
children | 135f3bae5c56 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/heatmapper.xml Thu Nov 14 16:39:18 2013 -0500 @@ -0,0 +1,212 @@ +<tool id="deeptools_heatmapper" name="heatmapper" version="1.0"> + <description>creates a heatmap for a score associated to genomic regions</description> + <expand macro="requirements"> + <requirement type="package" version="1.7.1">numpy</requirement> + <requirement type="package" version="1.2.1">matplotlib</requirement> + <requirement type="package" version="0.12.0">scipy</requirement> + </expand> + <macros> + <import>deepTools_macros.xml</import> + </macros> + <command> + heatmapper + + --matrixFile $matrixFile + #if $output.showOutputSettings == "yes" + #set newoutFileName=str($outFileName)+"."+str($output.outFileFormat) + --outFileName $newoutFileName + #if $outFileNameData: + --outFileNameData '$outFileNameData' + #end if + + #if $outFileNameMatrix: + --outFileNameMatrix '$outFileNameMatrix' + #end if + + #if $outFileSortedRegions: + --outFileSortedRegions '$outFileSortedRegions' + #end if + #else + #set newoutFileName=str($outFileName)+".png" + --outFileName $newoutFileName + #end if + + #if $advancedOpt.showAdvancedOpt == "yes" + #if $advancedOpt.sortRegions: + --sortRegions '$advancedOpt.sortRegions' + #end if + + #if $advancedOpt.sortUsing: + --sortUsing '$advancedOpt.sortUsing' + #end if + + #if $advancedOpt.averageTypeSummaryPlot: + --averageTypeSummaryPlot '$advancedOpt.averageTypeSummaryPlot' + #end if + + #if str($advancedOpt.missingDataColor.value) != "None": + --missingDataColor '$advancedOpt.missingDataColor' + #end if + + --colorMap '$advancedOpt.colorMap' + + #if $advancedOpt.zMin: + --zMin $advancedOpt.zMin + #end if + #if $advancedOpt.zMax: + --zMax $advancedOpt.zMax + #end if + + #if $advancedOpt.yMin: + --yMin $advancedOpt.yMin + #end if + #if $advancedOpt.yMax: + --yMax $advancedOpt.yMax + #end if + + --xAxisLabel '$advancedOpt.xAxisLabel' + --yAxisLabel '$advancedOpt.yAxisLabel' + + --heatmapWidth $advancedOpt.heatmapWidth + --heatmapHeight $advancedOpt.heatmapHeight + + --whatToShow '$advancedOpt.whatToShow' + + --startLabel '$advancedOpt.startLabel' + --endLabel '$advancedOpt.endLabel' + --refPointLabel '$advancedOpt.referencePointLabel' + --regionsLabel '$advancedOpt.regionsLabel' + + #if str($advancedOpt.plotTitle.value) != "None": + --plotTitle '$advancedOpt.plotTitle' + #end if + + $advancedOpt.onePlotPerGroup + #end if + + ; mv $newoutFileName $outFileName + </command> + <inputs> + <param name="matrixFile" format="bgzip" type="data" label="Matrix file from the computeMatrix tool"/> + + <expand macro="graphic_output_settings" /> + + <conditional name="advancedOpt" > + <param name="showAdvancedOpt" type="select" label="Show advanced options" > + <option value="no" selected="true">no</option> + <option value="yes">yes</option> + </param> + <when value="no" /> + <when value="yes"> + <param name="sortRegions" type="select" label="Sort regions" + help="Whether the heatmap should present the regions sorted. The default is to sort in descending order based on the mean value per region."> + <option value="no">no ordering</option> + <option value="descend" selected="true">descending order</option> + <option value="ascend">ascending order</option> + </param> + + <param name="sortUsing" type="select" label="Method used for sorting" help="For each row the method is computed." > + <option value="mean" selected="true">mean</option> + <option value="median">median</option> + <option value="min">min</option> + <option value="max">max</option> + <option value="sum">sum</option> + <option value="region_length">region length</option> + </param> + + <param name="averageTypeSummaryPlot" type="select" label="Type of statistic that should be plotted in the summary image above the heatmap"> + <option value="mean" selected="true">mean</option> + <option value="median">median</option> + <option value="min">min</option> + <option value="max">max</option> + <option value="sum">sum</option> + <option value="std">std</option> + </param> + + <param name="missingDataColor" type="text" label="Missing data color" value="black" optional="true" help="If 'Represent missing data as zero' is not set, such cases will be colored in black by default. By using this parameter a different color can be set. A value between 0 and 1 will be used for a gray scale (black is 0). Also color names can be used, see a list here: http://packages.python.org/ete2/reference/reference_svgcolors.html. Alternatively colors can be specified using the #rrggbb notation." /> + + <expand macro="colormap" /> + + <param name="zMin" type="float" value="" size="3" label="Minimum value for the heatmap intensities. Leave empty for automatic values" optional="true"/> + <param name="zMax" type="float" value="" size="3" label="Maximum value for the heatmap intensities. Leave empty for automatic values" optional="true"/> + <param name="yMin" type="float" value="" size="3" label="Minimum value for the Y-axis of the summary plot. Leave empty for automatic values" optional="true"/> + <param name="yMax" type="float" value="" size="3" label="Maximum value for Y-axis of the summary plot. Leave empty for automatic values" optional="true"/> + + <param name="xAxisLabel" type="text" value="distance from TSS (bp)" size="200" label="Description for the x-axis label" /> + <param name="yAxisLabel" type="text" value="genes" size="30" label="Description for the y-axis label for the top panel" /> + + <param name="heatmapWidth" type="float" value="7.5" min="1" max="100" label="Heatmap width in cm" help="The minimum value is 1 and the maximum is 100."/> + <param name="heatmapHeight" type="float" value="25" min="3" max="100" label="Heatmap height in cm" help="The minimum value is 3 and the maximum is 100."/> + + <param name="whatToShow" type="select" label="What to show" help ="The default is to include a summary or profile plot on top of the heatmap and a heatmap colorbar."> + <option value="plot, heatmap and colorbar" selected="true">summary plot, heatmap and colorbar</option> + <option value="plot only">summary plot only</option> + <option value="plot and heatmap">summary plot and heatmap (no colorbar)</option> + <option value="heatmap only">heatmap only</option> + <option value="heatmap and colorbar">heatmap and colorbar</option> + <option value="colorbar only">colorbar only</option> + </param> + + <param name="startLabel" type="text" value="TSS" size="10" label="Label for the region start" help ="[only for scale-regions mode] Label shown in the plot for the start of the region. Default is TSS (transcription start site), but could be changed to anything, e.g. "peak start"." /> + <param name="endLabel" type="text" value="TES" size="10" label="Label for the region end" help="[only for scale-regions mode] Label shown in the plot for the region end. Default is TES (transcription end site)."/> + + <param name="referencePointLabel" type="text" value="TSS" size="10" label="Reference point label" help ="[only for scale-regions mode] Label shown in the plot for the reference-point. Default is the same as the reference point selected (e.g. TSS), but could be anything, e.g. "peak start" etc." /> + <param name="regionsLabel" type="text" value="genes" size="30" label="Labels for the regions plotted in the heatmap" help="If more than one region is being plotted a list of labels separated by comma and limited by quotes, is required. For example, "label1, label2"."/> + <param name="plotTitle" type="text" value="" size="30" label="Title of the plot" help="Title of the plot, to be printed on top of the generated image. Leave blank for no title." /> + <param name="onePlotPerGroup" type="boolean" truevalue="--onePlotPerGroup" falsevalue="" label="Do one plot per group" help="When the region file contains groups separated by "#", the default is to plot the averages for the distinct plots in one plot. If this option is set, each group will get its own plot, stacked on top of each other."/> + + + </when> + </conditional> + + </inputs> + <outputs> + <data format="png" name="outFileName" label="${tool.name} image"> + <change_format> + <when input="output.outFileFormat" value="pdf" format="pdf" /> + <when input="output.outFileFormat" value="svg" format="svg" /> + <when input="output.outFileFormat" value="eps" format="eps" /> + <when input="output.outFileFormat" value="emf" format="emf" /> + </change_format> + </data> + <data format="tabular" name="outFileNameData" label="${tool.name} raw plot data"> + <filter>(output['showOutputSettings'] == 'yes' and output['saveData'] == True)</filter> + </data> + <data format="tabular" name="outFileNameMatrix" label="${tool.name} matrix of heatmap values"> + <filter>(output['showOutputSettings'] == 'yes' and output['saveMatrix'] == True)</filter> + </data> + <data format="bed" name="outFileSortedRegions" label="${tool.name} sorted/filtered regions"> + <filter>(output['showOutputSettings'] == 'yes' and output['saveSortedRegions'] == True)</filter> + </data> + </outputs> + <tests> + <test> + <param name="matrixFile" value="master.mat.gz" ftype="bgzip" /> + <output name="outFileName" file="master.png" ftype="png" compare="sim_size" delta="100" /> + </test> + </tests> + <help> + +**What it does** + +The heatmapper visualizes scores associated with genomic regions, for example ChIP enrichment values around the TSS of genes. +Those values can be visualized individually along each of the regions provided by the user in INTERVAL or BED format. +In addition to the heatmap, an average profile plot is plotted on top of the heatmap (can be turned off by the user; +it can also be generated separately by the tool profiler). +We implemented vast optional parameters and we encourage you to play around with the min/max values displayed in the heatmap as well as +with the different coloring options. If you would like to plot heatmaps for different groups of genomic regions individually, +e.g. one plot per chromosome, simply supply each group as an individual BED file. + + +.. image:: $PATH_TO_IMAGES/visual_hm_DmelPolII.png + :alt: Heatmap of RNA Polymerase II ChIP-seq + + +----- + +.. class:: infomark + +@REFERENCES@ + + </help> +</tool>