annotate signature.xml @ 3:22af95e451e1 draft

planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit a0ce81ec2c12e7f635b1a1056772ec306c4fb364
author drosofff
date Wed, 07 Jun 2017 18:14:41 -0400
parents 229645380cb9
children e77c0b28e9a2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3
22af95e451e1 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit a0ce81ec2c12e7f635b1a1056772ec306c4fb364
drosofff
parents: 2
diff changeset
1 <tool id="signature" name="Small RNA Signatures" version="2.1.2">
0
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
2 <description />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
3 <requirements>
1
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
4 <requirement type="package" version="1.1.2">bowtie</requirement>
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
5 <requirement type="package" version="1.11.2=py27_0">numpy</requirement>
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
6 <requirement type="package" version="0.11.2.1=py27_0">pysam</requirement>
2
229645380cb9 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08-dirty
drosofff
parents: 1
diff changeset
7 <requirement type="package" version="0.20_33=r3.3.1_0">r-lattice</requirement>
0
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
8 </requirements>
1
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
9 <command><![CDATA[
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
10 python '$__tool_directory__'/signature.py
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
11 --input '$refGenomeSource.input'
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
12 --inputFormat '$refGenomeSource.input.ext'
0
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
13 --minquery $minquery
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
14 --maxquery $maxquery
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
15 --mintarget $mintarget
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
16 --maxtarget $maxtarget
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
17 --minscope $minscope
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
18 --maxscope $maxscope
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
19 --outputOverlapDataframe $output
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
20 #if $refGenomeSource.genomeSource == "history":
1
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
21 --referenceGenome '$refGenomeSource.ownFile'
0
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
22 #else:
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
23 #silent reference= filter( lambda x: str( x[0] ) == str( $input.dbkey ), $__app__.tool_data_tables[ 'bowtie_indexes' ].get_fields() )[0][-1]
1
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
24 --referenceGenome '$reference'
0
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
25 --extract_index
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
26 #end if
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
27 --graph $graph_type
1
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
28 --rcode '$sigplotter'
6218b518cd16 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit 062e78aef14c4655d1b32d5f29ca543a50389b08
drosofff
parents: 0
diff changeset
29 ]]></command>
0
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
30 <inputs>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
31 <conditional name="refGenomeSource">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
32 <param help="Built-ins were indexed using default options" label="Will you select a reference genome from your history or use a built-in index?" name="genomeSource" type="select">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
33 <option value="indexed">Use a built-in index</option>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
34 <option value="history">Use one from the history</option>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
35 </param>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
36 <when value="indexed">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
37 <param format="tabular,sam,bam" label="Compute signature from this bowtie standard output" name="input" type="data">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
38 <validator message="database not set for this bowtie output. Select the database(=genome used for matching) manually, or select a reference fasta from your history." metadata_column="0" metadata_name="dbkey" table_name="bowtie_indexes" type="dataset_metadata_in_data_table" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
39 </param>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
40 </when>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
41 <when value="history">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
42 <param format="fasta" label="Select the fasta reference" name="ownFile" type="data" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
43 <param format="tabular,sam,bam" label="Compute signature from this bowtie standard output" name="input" type="data" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
44 </when>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
45 </conditional>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
46 <param help="'23' = 23 nucleotides" label="Min size of query small RNAs" name="minquery" size="3" type="integer" value="23" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
47 <param help="'29' = 29 nucleotides" label="Max size of query small RNAs" name="maxquery" size="3" type="integer" value="29" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
48 <param help="'23' = 23 nucleotides" label="Min size of target small RNAs" name="mintarget" size="3" type="integer" value="23" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
49 <param help="'29' = 29 nucleotides" label="Max size of target small RNAs" name="maxtarget" size="3" type="integer" value="29" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
50 <param help="'1' = 1 nucleotide overlap" label="Minimal relative overlap analyzed" name="minscope" size="3" type="integer" value="1" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
51 <param help="'1' = 1 nucleotide overlap" label="Maximal relative overlap analyzed" name="maxscope" size="3" type="integer" value="26" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
52 <param help="Signature can be computed globally or by item present in the alignment file" label="Graph type" name="graph_type" type="select">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
53 <option selected="True" value="global">Global</option>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
54 <option value="lattice">Lattice</option>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
55 </param>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
56 </inputs>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
57 <outputs>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
58 <data format="tabular" label="signature data frame" name="output" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
59 <data format="pdf" label="Overlap probabilities" name="output2" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
60 </outputs>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
61 <tests>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
62 <test>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
63 <param name="genomeSource" value="history" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
64 <param ftype="fasta" name="ownFile" value="ensembl.fa" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
65 <param ftype="bam" name="input" value="sr_bowtie.bam" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
66 <param name="minquery" value="23" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
67 <param name="maxquery" value="29" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
68 <param name="mintarget" value="23" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
69 <param name="maxtarget" value="29" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
70 <param name="minscope" value="5" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
71 <param name="maxscope" value="15" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
72 <param name="graph_type" value="global" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
73 <output file="signature.tab" ftype="tabular" name="output" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
74 <output file="signature.pdf" ftype="pdf" name="output2" />
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
75 </test>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
76 </tests>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
77 <help>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
78
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
79 **What it does**
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
80
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
81 This tool computes the number of pairs by overlap classes (in nt) from a bowtie output file, the z-score calculated from these numbers of pairs, and the ping-pong signal as described in Brennecke et al (2009) Science.
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
82 The numerical options set the min and max size of both the query small rna class and the target small rna class.
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
83 Three type of signals are plotted in separate pdf files, the number of pairs founds, the z-score calculated from these numbers of pairs, and the ping-pong signal as described in Brennecke et al (2009) Science.
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
84
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
85 </help>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
86 <citations>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
87 <citation type="doi">10.1007/978-1-4939-0931-5_12</citation>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
88 </citations>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
89 <configfiles>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
90 <configfile name="sigplotter">
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
91 graph_type = "${graph_type}"
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
92
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
93 globalgraph = function () {
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
94 ## Setup R error handling to go to stderr
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
95 options( show.error.messages=F,
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
96 error = function () { cat( geterrmessage(), file=stderr() ); q( "no", 1, F ) } )
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
97 signature = read.delim("${output}", header=TRUE)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
98 signaturez=data.frame(signature[,1], (signature[,2] -mean(signature[,2]))/sd(signature[,2]))
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
99 overlap_prob_z=data.frame(signature[,1], (signature[,3] -mean(signature[,3]))/sd(signature[,3]))
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
100 YLIM=max(signature[,2])
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
101
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
102
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
103 ## Open output2 PDF file
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
104 pdf( "${output2}" )
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
105 if (YLIM!=0) {
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
106 par(mfrow=c(2,2),oma = c(0, 0, 3, 0))
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
107
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
108 plot(signature[,1:2], type = "h", main="Numbers of pairs", cex.main=1, xlab="overlap (nt)", ylim=c(0,YLIM), ylab="Numbers of pairs", col="darkslateblue", lwd=4)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
109
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
110 plot(signaturez, type = "l", main="Number of pairs Z-scores", cex.main=1, xlab="overlap (nt)", ylab="z-score", pch=19, cex=0.2, col="darkslateblue", lwd=2)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
111
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
112 plot(signature[,1], signature[,3]*100, type = "l", main="Overlap probabilities",
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
113 cex.main=1, xlab="overlap (nt)", ylab="Probability [%]", ylim=c(0,50),
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
114 pch=19, col="darkslateblue", lwd=2)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
115
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
116 plot(overlap_prob_z, type = "l", main="Overlap Probability Z-scores", cex.main=1, xlab="overlap (nt)", ylab="z-score", pch=19, cex=0.2, col="darkslateblue", lwd=2)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
117
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
118 mtext("Overlap Signatures of ${minquery}-${maxquery} against ${mintarget}-${maxtarget}nt small RNAs", outer = TRUE, cex=1)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
119 }
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
120 devname = dev.off()
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
121 ## Close the PDF file
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
122 }
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
123
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
124 treillisgraph = function () {
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
125 ## Open output2 PDF file
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
126 pdf( "${output2}", paper="special", height=11.69, width=8.2677 )
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
127 signature = read.delim("${output}", header=TRUE)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
128 options( show.error.messages=F,
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
129 error = function () { cat( geterrmessage(), file=stderr() ); q( "no", 1, F ) } )
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
130 library(lattice)
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
131 print (xyplot(signature[,3]*100~signature[,1]|signature[,4], type = "l", xlim=c(${minscope},${maxscope}), main="ping-pong Signature of ${minquery}-${maxquery} against ${mintarget}-${maxtarget}nt small RNAs",
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
132 par.strip.text=list(cex=.5), strip=strip.custom(which.given=1, bg="lightblue"), scales=list(cex=0.5),
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
133 cex.main=1, cex=.5, xlab="overlap (nt)", ylab="ping-pong signal [%]",
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
134 pch=19, col="darkslateblue", lwd =1.5, cex.lab=1.2, cex.axis=1.2,
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
135 layout=c(4,12), as.table=TRUE, newpage = T) )
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
136 devnname = dev.off()
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
137 }
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
138
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
139 if (graph_type=="global") {
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
140 globalgraph()
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
141
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
142 }
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
143 if(graph_type=="lattice") {
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
144 treillisgraph()
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
145 }
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
146 </configfile>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
147 </configfiles>
a2f293717ce3 planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_sr_signature commit fe40dec87779c1fcfbd03330e653aa886f4a2cda
drosofff
parents:
diff changeset
148 </tool>