Mercurial > repos > ieguinoa > smap
view smap_delineate.xml @ 0:7d416d98d2c9 draft default tip
Uploaded
author | ieguinoa |
---|---|
date | Tue, 22 Mar 2022 13:49:39 +0000 |
parents | |
children |
line wrap: on
line source
<tool id="smap_delineate" name="SMAP delineate (BETA)" version="4.5.0"> <requirements> <requirement type="package">ngs-smap</requirement> </requirements> <command detect_errors="exit_code"><![CDATA[ ## delineate #set $name = 'smap_out' mkdir alignments_dir; #set $input_list = [] #import re #for $i, $input in enumerate($input_bams): #set $safename = re.sub('[^\w\-_]', '_', $input.element_identifier) #if $safename in $input_list: #set $safename = str($safename) + "." + str($i) #end if ln -sf '${input}' 'alignments_dir/${safename}.bam' && ln -sf '${input.metadata.bam_index}' 'alignments_dir/${safename}.bai' && #end for smap delineate alignments_dir -n $name -mapping_orientation $mapping_orientation -p "\${GALAXY_SLOTS:-1}" --plot_type png --plot $plot ## --name 2n_ind_GBS-SE --min_cluster_length $min_cluster_length --max_cluster_length $max_cluster_length --min_stack_depth $min_stack_depth --max_stack_depth $max_stack_depth --min_cluster_depth $min_cluster_depth --max_cluster_depth $max_cluster_depth --max_stack_number $max_stack_number --min_stack_depth_fraction $min_stack_depth_fraction --completeness $completeness --max_smap_number $max_smap_number ; ## output name is ##set $str_completeness = str(float($completeness)) ##set $str_max_smap_number = str($max_smap_number) ###set $out_name = 'final_stack_positions_$name_C$str_completeness\_SMAP$max_smap_number\_CL$min_cluster_length\_$max_stack_depth.bed' ##echo $out_name; mkdir stack_positions_out; mv *.bed stack_positions_out/; mkdir visualizations_out; mv *.png visualizations_out/; mkdir tsv_files_out; mv *.tsv tsv_files_out/; ]]></command> <inputs> <param name="input_bams" type="data" optional="false" label="GFF3 File" help="GFF3 file" format="bam" multiple="true"/> <param argument="--mapping_orientation" type="select" label="Should strandedness of read mapping be considered for haplotyping?"> <option value="ignore" selected="True">Ignore strandedness</option> <option value="stranded">Consider strandedness</option> </param> <param argument="--plot" type="select" label="Select which plots are to be generated."> <option value="summary" selected="True">Summary (plots with information for all samples)</option> <option value="all">All (per sample plots)</option> <option value="nothing">Nothing</option> </param> <param argument="--min_mapping_quality" type="integer" value="30" label="Minimum .bam mapping quality to retain reads for analysis"/> <param argument="--undefined_representation" label="Value to use for non-existing or masked data" type="text" value="NaN"/> <param argument="--min_stack_depth" type="integer" value="0" label="Minimum number of reads per Stack per sample. " help="Recommended value is 3"/> <param argument="--max_stack_depth" type="text" value="inf" label="Maximum number of reads per Stack per sample" help="Recommended value is 1500"/> <param argument="--min_cluster_length" type="integer" value="0" label="Minimum Stack and StackCluster length" help="Can be used to remove Stacks and StackClusters that are either too short compared to the original read length. For separately mapped and merged reads, the minimum length may be about one-third of the original read length (trimmed, before merging and mapping)."/> <param argument="--max_cluster_length" type="text" value="inf" label="Maximum Stack and StackCluster length" help="Can be used to remove Stacks and StackClusters that are either too long compared to the original read length. For separately mapped reads, the maximum mapped length may be about 1.5 times the original read length (trimmed, before mapping). For merged reads, the maximum mapped length may be about 2.2 times the original read length (trimmed, before merging and mapping)"/> <param argument="--max_stack_number" type="text" value="inf" label="Maximum number of Stacks per StackCluster" help="Recommended value is 2 for diploid individuals, 4 for tetraploid individuals, 20 for Pool-Seq"/> <param argument="--min_stack_depth_fraction" type="float" value="0.0" label="Threshold (%) for minimum relative Stack depth per StackCluster" help="Removes spuriously mapped reads from StackClusters, and controls for noise in the number of SMAPs per locus. The StackCluster total read depth and number of SMAPs is recalculated based on the retained Stacks per StackCluster per sample. Recommended values are 10.0 for individuals and 5.0 for Pool-Seq"/> <param argument="--min_cluster_depth" value="0" type="integer" label="Minimum total number of reads per StackCluster per sample." help="Sum of all Stacks per StackCluster calculated after filtering out the Stacks with Stack Depth Fraction smaller than min. relative stack depth . A good reference value is 10 for individual diploid samples, 20 for tetraploids, and 30 for Pool-Seq"/> <param argument="--max_cluster_depth" type="text" value="inf" label="Maximum total number of reads per StackCluster per sample." help="Sum of all Stacks per StackCluster calculated after filtering out the Stacks with Stack Depth Fraction smaller than min. relative stack dept. Used to filter out loci with excessively high read depth"/> <param argument="--completeness" type="float" value="0" label="Completeness" help="TODO"/> <param argument="--max_smap_number" type="text" value="inf" label="Max smap number" help="TODO"/> </inputs> <outputs> <collection name="final_stack_positions" type="list" label="${tool.name} on ${on_string}: Final stack positions"> <discover_datasets pattern="(?P<designation>.+)\.bed" ext="bed" directory="stack_positions_out/"/> </collection> <collection name="plots_generated" type="list" label="${tool.name} on ${on_string}: Plots generated"> <discover_datasets pattern="(?P<designation>.+)\.png" ext="png" directory="visualizations_out/"/> </collection> <collection name="stack_saturation" type="list" label="${tool.name} on ${on_string}: Stack saturation"> <discover_datasets pattern="(?P<designation>.+)\.tsv" ext="tsv" directory="tsv_files_out/"/> </collection> </outputs> <help><![CDATA[ TODO: Fill in help. ]]></help> </tool>