Mercurial > repos > jjohnson > find_in_reference
comparison find_in_reference.xml @ 0:fe0327a3ba81
Uploaded
| author | jjohnson |
|---|---|
| date | Sat, 04 Jan 2014 09:03:57 -0500 |
| parents | |
| children | 856033fb26e8 |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:fe0327a3ba81 |
|---|---|
| 1 <?xml version="1.0"?> | |
| 2 <tool id="find_in_reference" name="find in reference" version="0.0.1"> | |
| 3 <description>filter peptides that are present in proteins</description> | |
| 4 <command interpreter="python">find_in_reference.py --input "$input" | |
| 5 --reference "$reference" | |
| 6 #if $column.set == 'yes': | |
| 7 --input_column $column.input_column | |
| 8 --reference_column $column.reference_column | |
| 9 #end if | |
| 10 #if 'novel' in $outputs.__str__ or not 'found' in $outputs.__str__: | |
| 11 --output "$novel" | |
| 12 #end if | |
| 13 #if 'found' in $outputs.__str__: | |
| 14 --filtered "$found" | |
| 15 #end if | |
| 16 </command> | |
| 17 <inputs> | |
| 18 <param name="input" type="data" format="tabular" label="Input file to be filtered" | |
| 19 help="e.g. tophat junctions.bed run without GTF option or no-novel-junctions"/> | |
| 20 <param name="reference" type="data" format="tabular" label="reference file to search" | |
| 21 help="e.g. tophat junctions.bed run with GTF option and no-novel-junctions"/> | |
| 22 <conditional name="column"> | |
| 23 <param name="set" type="select" label="select columns to compare"> | |
| 24 <option value="no" selected="true">Use last column of input and reference</option> | |
| 25 <option value="yes">Choose the column of input and reference to compare</option> | |
| 26 </param> | |
| 27 <when value="no"/> | |
| 28 <when value="yes"> | |
| 29 <param name="input_column" type="data_column" data_ref="input" label="column in input (defaults to last column)" | |
| 30 help=""/> | |
| 31 <param name="reference_column" type="data_column" data_ref="reference" label="column in reference (defaults to last column)" | |
| 32 help=""/> | |
| 33 </when> | |
| 34 </conditional> | |
| 35 <param name="outputs" type="select" multiple="true" display="checkboxes" label="Choose outputs"> | |
| 36 <option value="novel" selected="true">lines with no match in reference</option> | |
| 37 <option value="found">lines with match in reference</option> | |
| 38 </param> | |
| 39 </inputs> | |
| 40 <stdio> | |
| 41 <exit_code range="1:" level="fatal" description="Error" /> | |
| 42 </stdio> | |
| 43 <outputs> | |
| 44 <data name="found" metadata_source="input" format_source="input" label="${tool.name} on ${on_string}: found"> | |
| 45 <filter>'found' in str(outputs)</filter> | |
| 46 </data> | |
| 47 <data name="novel" metadata_source="input" format_source="input" label="${tool.name} on ${on_string}: novel"> | |
| 48 <filter>'novel' in str(outputs) or not 'found' in str(outputs)</filter> | |
| 49 </data> | |
| 50 </outputs> | |
| 51 <tests> | |
| 52 <test> | |
| 53 <param name="input" value="human_peptides.tabular" ftype="tabular" dbkey="hg19"/> | |
| 54 <param name="reference" value="human_proteins.tabular" ftype="tabular" dbkey="hg19"/> | |
| 55 <output name="novel" file="novel_peptides.tabular"/> | |
| 56 </test> | |
| 57 </tests> | |
| 58 <help> | |
| 59 **Find in Reference** | |
| 60 | |
| 61 Filters lines of a tabular input file by checking if the selected input column | |
| 62 is a substring of the selected column of any line in the reference file. | |
| 63 | |
| 64 This can be used to check if peptides sequences are present in a set of reference proteins, | |
| 65 as a means of filtering out uninteresting peptide sequences. | |
| 66 | |
| 67 </help> | |
| 68 </tool> |
