annotate size_histogram.xml @ 7:fed53c74fb92 draft default tip

planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
author drosofff
date Thu, 10 Mar 2016 10:59:45 -0500
parents 51a70c8da2bd
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
1 <tool id="Size_histogram" name="Generate size histograms from alignment files" version="0.9.8">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
2 <description>from sRbowtie aligment</description>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
3 <requirements>
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
4 <requirement type="package" version="0.12.7">bowtie</requirement>
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
5 <requirement type="package" version="0.7.7">pysam</requirement>
6
51a70c8da2bd planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents: 5
diff changeset
6 <requirement type="package" version="3.1.2">R</requirement>
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
7 <requirement type="package" version="2.14">biocbasics</requirement>
1
6c72cf9a00df Uploaded
mvdbeek
parents: 0
diff changeset
8 <requirement type="package" version="1.9">numpy</requirement>
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
9 </requirements>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
10 <command interpreter="python">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
11 size_histogram.py
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
12 #if $refGenomeSource.genomeSource == "history":
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
13 --reference_fasta ## sys.argv[2]
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
14 $refGenomeSource.ownFile ## index source
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
15 #else:
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
16 #silent reference= filter( lambda x: str( x[0] ) == str( $refGenomeSource.series[0].input.dbkey ), $__app__.tool_data_tables[ 'bowtie_indexes' ].get_fields() )[0][-1]
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
17 --reference_bowtie_index
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
18 $reference
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
19 #end if
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
20 --rcode
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
21 $plotCode
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
22 --output_size_distribution
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
23 $size_distribution_dataframe
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
24 --minquery
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
25 $minquery
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
26 --maxquery
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
27 $maxquery
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
28 --input
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
29 #for $i in $refGenomeSource.series
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
30 $i.input
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
31 #end for
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
32 --ext
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
33 #for $i in $refGenomeSource.series
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
34 $i.input.ext
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
35 #end for
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
36 --label
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
37 #for $i in $refGenomeSource.series
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
38 "$i.input.name"
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
39 #end for
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
40 --normalization_factor
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
41 #for $i in $refGenomeSource.series
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
42 $i.norm
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
43 #end for
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
44 #if $gff:
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
45 --gff $gff
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
46 #end if
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
47 #if $global.value == 'yes':
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
48 --global_size
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
49 #end if
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
50 #if $collapsestrands.value == 'yes':
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
51 --collapse
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
52 #end if
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
53
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
54 </command>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
55 <inputs>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
56 <conditional name="refGenomeSource">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
57 <param name="genomeSource" type="select" label="Will you select a reference genome from your history or use a built-in index?" help="Built-ins were indexed using default options">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
58 <option value="indexed">Use a built-in index</option>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
59 <option value="history">Use one from the history</option>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
60 </param>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
61 <when value="indexed">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
62 <repeat name="series" title="Add alignment files">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
63 <param name="input" type="data" label="Select multiple alignments to parse" format="tabular,sam,bam">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
64 <validator type="dataset_metadata_in_data_table" table_name="bowtie_indexes" metadata_name="dbkey" metadata_column="0" message="database not set for this bowtie output. Select the database(=genome used for matching) manually, or select a reference fasta from your history."/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
65 </param>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
66 <param name="norm" type="float" value="1" label="Indicate a normalization factor to compare multiple aligments"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
67 </repeat>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
68 </when>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
69 <when value="history">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
70 <param name="ownFile" type="data" format="fasta" label="Select a fasta file, to serve as index reference" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
71 <repeat name="series" title="Add alignment files">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
72 <param name="input" type="data" label="Select multiple alignments to parse" format="tabular,sam,bam"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
73 <param name="norm" type="float" value="1" label="Indicate a normalization factor to compare multiple aligments"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
74 </repeat>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
75 </when>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
76 </conditional>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
77 <param name="gff" type="data" format="gff,gff3" optional="true" label="Optional: select a GFF to investigate regions of interest" help="GFF must match genome build"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
78 <!-- <validator type="dataset_metadata_in_data_table" table_name="bowtie_indexes" metadata_name="dbkey" metadata_column="0" message="GFF database and alignment file databse do not match!"/> -->
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
79 <param name="global" type="select" label="Generate size distribution for each item, or generate a global alignment">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
80 <option value="no">for each item</option>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
81 <option value="yes">global</option>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
82 </param>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
83 <param name="collapsestrands" type="select" label="Whether + and - reads should be collapsed or not">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
84 <option value="no">Do not collapse</option>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
85 <option value="yes">Collapse + and - reads</option>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
86 </param>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
87 <param name="minquery" type="integer" size="3" value="18" label="Min size of reads to plot" help="'15' = 15 nucleotides"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
88 <param name="maxquery" type="integer" size="3" value="28" label="Max size of reads to plot" help="'30' = 30 nucleotides"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
89 <param name="title" type="text" size="15" value="Size distribution" label="Main Titles"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
90 <param name="xlabel" type="text" size="15" value="Size in nucleotides" label="x axis label"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
91 <param name="ylabel" type="text" size="15" value="Number of reads" label="y axis label"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
92 <param name="yrange" type="integer" size="3" value="0" label="y axis range for size distributions. 0 means auto-scaling."/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
93 <param name="rows_per_page" type="text" size="9" value="8" label="How many items to display per page?">
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
94 <validator type="in_range" min="6" max="20" message="Select between 6 and 20 rows, as the readability will suffer otherwise."/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
95 </param>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
96 </inputs>
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
97 <configfiles>
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
98 <configfile name="plotCode">
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
99 ## Setup R error handling to go to stderr
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
100 options( show.error.messages=F,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
101 error = function () { cat( geterrmessage(), file=stderr() ); q( "no", 1, F ) } )
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
102 library(RColorBrewer)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
103 library(lattice)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
104 library(latticeExtra)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
105 library(grid)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
106 library(gridExtra)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
107
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
108 ##cheetahtemplate data frame implementation
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
109 size=read.delim("${size_distribution_dataframe}", header=T, row.names=NULL)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
110 n_samples = length(unique (size\$sample))
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
111 n_genes = length (unique (levels(size\$gene)))
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
112
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
113 if (${yrange} != 0) {
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
114 # This is used for specifying the y-axis limits
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
115 ylim=c(-${yrange}, ${yrange})
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
116 } else { ylim="" }
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
117
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
118 par.settings.size=list(layout.heights=list(top.padding=1, bottom.padding=1),
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
119 strip.background = list(col = c("lightblue", "lightgreen"))
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
120 )
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
121
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
122 smR.prepanel=function(x,y,...){; yscale=c(-max(abs(y)), max(abs(y)));list(ylim=yscale);} # use if one want y axis in the middle of the plot
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
123
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
124 plot_size_distribution= function(df, ...) {
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
125 bc= barchart(count~as.factor(size)|factor(sample, levels=unique(sample))+gene, data = df, origin = 0,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
126 horizontal=FALSE,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
127 group=polarity,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
128 stack=TRUE,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
129 col=c('red', 'blue'),
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
130 cex=0.75,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
131 scales=list(y=list(tick.number=4, rot=90, relation="free", cex=0.5, alternating=T), x=list(cex=.6 ) ),
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
132 xlab = "readsize in nucleotides",
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
133 ylab = "${ylabel}",
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
134 main="${title}" ,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
135 par.strip.text = list(cex=0.75),
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
136 as.table=TRUE,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
137 newpage = T,
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
138 ...)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
139
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
140 combineLimits(update(useOuterStrips(bc,
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
141 strip.left = strip.custom(par.strip.text = list(cex=0.5))
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
142 ),
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
143 layout=c(n_samples,${rows_per_page})),
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
144 margin.x=F, margin.y=1)
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
145 }
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
146
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
147 # per_gene_size=lapply(genes, function(x) subset(size, gene==x)) # no object in this script
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
148
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
149 global = "no"
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
150 #if $global.value == 'yes':
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
151 global = "yes"
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
152 #end if
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
153
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
154 if (global=="no") {
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
155 width = 8.2677*n_samples/4
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
156 } else { width = 8.2677 }
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
157
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
158 options(warn=-1)
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
159 pdf(file="${size_PDF}", paper="special", height=11.69, width=width)
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
160
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
161 if (ylim == "" &amp;&amp; global=="no") {
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
162 plot_size_distribution(size, par.settings=par.settings.size)
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
163 }
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
164 if (ylim != "" &amp;&amp; global=="no") { plot_size_distribution(size, par.settings=par.settings.size, ylim=ylim)
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
165 }
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
166 if (ylim == "" &amp;&amp; global=="yes") { bc= barchart(count~as.factor(size)|factor(sample, levels=unique(sample)), data = size, origin = 0,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
167 horizontal=FALSE,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
168 group=polarity,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
169 stack=TRUE,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
170 col=c('red', 'blue'),
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
171 scales=list(y=list(tick.number=4, rot=90, relation="same"), cex=1),
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
172 xlab = "readsize in nucleotides",
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
173 ylab = "${ylabel}",
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
174 main="${title}" , as.table=TRUE, newpage = T,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
175 aspect=0.5,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
176 strip = strip.custom(par.strip.text = list(cex = 1), which.given=1, bg="lightblue")
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
177 )
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
178 bc
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
179 }
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
180 if (ylim != "" &amp;&amp; global=="yes") { bc= barchart(count~as.factor(size)|factor(sample, levels=unique(sample)), data = size, origin = 0,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
181 horizontal=FALSE,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
182 group=polarity,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
183 stack=TRUE,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
184 col=c('red', 'blue'),
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
185 scales=list(y=list(tick.number=4, rot=90, relation="same"), cex=1),
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
186 xlab = "readsize in nucleotides",
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
187 ylab = "${ylabel}",
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
188 ylim = ylim,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
189 main="${title}" , as.table=TRUE, newpage = T,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
190 aspect=0.5,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
191 strip = strip.custom(par.strip.text = list(cex = 1), which.given=1, bg="lightblue")
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
192 )
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
193 bc
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
194 }
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
195
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
196 devname=dev.off()
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
197
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
198 </configfile>
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
199 </configfiles>
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
200 <outputs>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
201 <data format="tabular" name="size_distribution_dataframe" label="Size_distribution_dataframe.tab"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
202 <data format="pdf" name="size_PDF" label="Size_distribution.pdf"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
203 </outputs>
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
204 <help>
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
205
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
206 **What it does**
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
207
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
208 Takes one or more alignment files (BAM, SAM or tabular bowtie output) as input and produces a histogram of read sizes,
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
209 where by default for each "chromosome" a histogram of read sizes is drawn.
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
210 Reads that map in sense are on the top (red), reads that map antisense are on the bottom (blue).
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
211
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
212
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
213 .. class:: warningmark
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
214
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
215 '''TIP''' The input data can be produced using the sRbowtie tool.
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
216
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
217 ----
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
218
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
219 '''Example'''
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
220
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
221 Query sequence::
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
222 For a SAM file as the following:
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
223
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
224 5 16 2L_79 24393 255 17M * 0 0 CCTTCATCTTTTTTTTT IIIIIIIIIIIIIIIII XA:i:0 MD:Z:17 NM:i:0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
225
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
226 11 0 2R_1 12675 255 21M * 0 0 AAAAAAAACGCGTCCTTGTGC IIIIIIIIIIIIIIIIIIIII XA:i:0 MD:Z:21 NM:i:0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
227
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
228 2 16 2L_5 669 255 23M * 0 0 TGTTGCTGCATTTCTTTTTTTTT IIIIIIIIIIIIIIIIIIIIIII XA:i:0 MD:Z:23 NM:i:0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
229
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
230 produce a plot like this:
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
231
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
232 ----
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
233
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
234 .. image:: static/images/size_histogram.png
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
235 :height: 800
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
236 :width: 500
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
237
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
238 </help>
7
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
239 <tests>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
240 <test>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
241 <param name="genomeSource" value="history" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
242 <param name="ownFile" value="transposons.fasta" ftype="fasta" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
243 <param name="series_0|input" value="sample1.srbowtie_out" ftype="tabular"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
244 <param name="series_0|norm" value="1" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
245 <param name="series_1|input" value="sample2.srbowtie_out" ftype="tabular"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
246 <param name="series_1|norm" value="1" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
247 <param name="series_2|input" value="sample3.srbowtie_out" ftype="tabular"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
248 <param name="series_2|norm" value="1" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
249 <param name="global" value="no" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
250 <param name="collapsestrands" value="no" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
251 <param name="minquery" value="18"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
252 <param name="maxquery" value="30"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
253 <param name="title" value="Size distribution"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
254 <param name="xlabel" value="Size in nucleotides"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
255 <param name="ylabel" value="Number of reads"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
256 <param name="rows_per_page" value="10"/>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
257 <output name="size_distribution_dataframe" ftype="tabular" file="Size_distribution_dataframe.tab" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
258 <output name="size_PDF" ftype="pdf" file="Size_distribution.pdf" />
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
259 </test>
fed53c74fb92 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_size_histograms commit 89caea4594db1ae6d6bb9c651bc6019bb6dd3ce6
drosofff
parents: 6
diff changeset
260 </tests>
0
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
261 </tool>
63ff807752d7 Imported from capsule None
drosofff
parents:
diff changeset
262