Mercurial > repos > matthias > dada2_plotqualityprofile
comparison dada2_plotQualityProfile.xml @ 5:863ebf0d28d5 draft
planemo upload for repository https://github.com/bernt-matthias/mb-galaxy-tools/tree/topic/dada2/tools/dada2 commit 990192685955e9cda0282e348c28ef6462d88a38
| author | matthias |
|---|---|
| date | Sun, 05 May 2019 12:26:15 -0400 |
| parents | cf166b8a8e27 |
| children | ec0479593908 |
comparison
equal
deleted
inserted
replaced
| 4:4be2c17fd0b2 | 5:863ebf0d28d5 |
|---|---|
| 4 <import>macros.xml</import> | 4 <import>macros.xml</import> |
| 5 </macros> | 5 </macros> |
| 6 <expand macro="requirements"/> | 6 <expand macro="requirements"/> |
| 7 <expand macro="version_command"/> | 7 <expand macro="version_command"/> |
| 8 <command detect_errors="exit_code"><![CDATA[ | 8 <command detect_errors="exit_code"><![CDATA[ |
| 9 Rscript --slave '$dada2_script' | 9 ##name files by linking |
| 10 #import re | |
| 11 #if "batch" in str($paired_cond.paired_select) | |
| 12 #set elid = re.sub('[^\w\-\.]', '_', str($paired_cond.fl.element_identifier)) | |
| 13 #if "single" in str($paired_cond.paired_select) | |
| 14 ln -s '$paired_cond.fl' '$elid' && | |
| 15 #else | |
| 16 ln -s '$paired_cond.fl.forward' '$elid'_forward && | |
| 17 ln -s '$paired_cond.fl.reverse' '$elid'_reverse && | |
| 18 #end if | |
| 19 #else | |
| 20 #for $read in $paired_cond.fl: | |
| 21 #set elid = re.sub('[^\w\-\.]', '_', str($read.element_identifier)) | |
| 22 #if "single" in str($paired_cond.paired_select) | |
| 23 ln -s '$read' '$elid' && | |
| 24 #else | |
| 25 ln -s '$read.forward' '$elid'_forward && | |
| 26 ln -s '$read.reverse' '$elid'_reverse && | |
| 27 #end if | |
| 28 #end for | |
| 29 #end if | |
| 30 | |
| 31 Rscript --slave '$dada2_script' | |
| 10 ]]></command> | 32 ]]></command> |
| 11 <configfiles> | 33 <configfiles> |
| 12 <configfile name="dada2_script"><![CDATA[ | 34 <configfile name="dada2_script"><![CDATA[ |
| 35 #import re | |
| 13 files = c() | 36 files = c() |
| 14 #if "batch" in str($paired_cond.paired_select) | 37 #if "batch" in str($paired_cond.paired_select) |
| 38 #set elid = re.sub('[^\w\-\.]', '_', str($paired_cond.fl.element_identifier)) | |
| 15 #if "single" in str($paired_cond.paired_select) | 39 #if "single" in str($paired_cond.paired_select) |
| 16 files = c(files, '$paired_cond.reads') | 40 files = c(files, '$elid') |
| 17 #else | 41 #else |
| 18 files = c(files, '$paired_cond.reads.forward') | 42 files = c(files, paste('$elid', 'forward', sep = "_")) |
| 19 files = c(files, '$paired_cond.reads.reverse') | 43 files = c(files, paste('$elid', 'reverse', sep = "_")) |
| 20 #end if | 44 #end if |
| 21 #else | 45 #else |
| 22 #for $read in $paired_cond.reads: | 46 #for $read in $paired_cond.fl: |
| 47 #set elid = re.sub('[^\w\-\.]', '_', str($read.element_identifier)) | |
| 23 #if "single" in str($paired_cond.paired_select) | 48 #if "single" in str($paired_cond.paired_select) |
| 24 files = c(files, '$read') | 49 files = c(files, '$elid') |
| 25 #else | 50 #else |
| 26 files = c(files, '$read.forward') | 51 files = c(files, paste('$elid', 'forward', sep = "_")) |
| 27 files = c(files, '$read.reverse') | 52 files = c(files, paste('$elid', 'reverse', sep = "_")) |
| 28 #end if | 53 #end if |
| 29 #end for | 54 #end for |
| 30 #end if | 55 #end if |
| 31 | 56 |
| 32 library(ggplot2, quietly=T) | 57 library(ggplot2, quietly=T) |
| 48 <option value="single">single - non batch</option> | 73 <option value="single">single - non batch</option> |
| 49 <option value="paired_batch">paired - batch</option> | 74 <option value="paired_batch">paired - batch</option> |
| 50 <option value="single_batch">single - batch</option> | 75 <option value="single_batch">single - batch</option> |
| 51 </param> | 76 </param> |
| 52 <when value="paired"> | 77 <when value="paired"> |
| 53 <param name="reads" type="data_collection" collection_type="list:paired" format="fastqsanger,fastqsanger.gz" label="Short read data"/> | 78 <param argument="fl" type="data_collection" collection_type="list:paired" format="fastqsanger,fastqsanger.gz" label="Short read data"/> |
| 54 </when> | 79 </when> |
| 55 <when value="single"> | 80 <when value="single"> |
| 56 <param name="reads" type="data" multiple="true" format="fastqsanger,fastqsanger.gz" label="Short read data"/> | 81 <param argument="fl" type="data" multiple="true" format="fastqsanger,fastqsanger.gz" label="Short read data"/> |
| 57 </when> | 82 </when> |
| 58 <when value="paired_batch"> | 83 <when value="paired_batch"> |
| 59 <param name="reads" type="data_collection" collection_type="paired" format="fastqsanger,fastqsanger.gz" label="Short read data"/> | 84 <param argument="fl" type="data_collection" collection_type="paired" format="fastqsanger,fastqsanger.gz" label="Short read data"/> |
| 60 </when> | 85 </when> |
| 61 <when value="single_batch"> | 86 <when value="single_batch"> |
| 62 <param name="reads" type="data" format="fastqsanger,fastqsanger.gz" label="Short read data"/> | 87 <param argument="fl" type="data" format="fastqsanger,fastqsanger.gz" label="Short read data"/> |
| 63 </when> | 88 </when> |
| 64 </conditional> | 89 </conditional> |
| 65 <param argument="aggregate" type="boolean" label="Aggregate data" checked="True" truevalue="TRUE" falsevalue="FALSE" help="Create a single plot for all data sets (default) or a separate plot for each data set"/> | 90 <param argument="aggregate" type="boolean" label="Aggregate data" checked="True" truevalue="TRUE" falsevalue="FALSE" help="Create a single plot for all data sets (default) or a separate plot for each data set"/> |
| 66 <param argument="n" type="integer" value="500000" label="sample number" help="number of records to sample from the fastq file"/> | 91 <param argument="n" type="integer" value="500000" label="sample number" help="number of records to sample from the fastq file"/> |
| 67 </inputs> | 92 </inputs> |
| 71 <tests> | 96 <tests> |
| 72 <!-- paired non-batch, aggregate --> | 97 <!-- paired non-batch, aggregate --> |
| 73 <test> | 98 <test> |
| 74 <param name="aggregate" value="TRUE"/> | 99 <param name="aggregate" value="TRUE"/> |
| 75 <param name="paired_cond|paired_select" value="paired"/> | 100 <param name="paired_cond|paired_select" value="paired"/> |
| 76 <param name="paired_cond|reads"> | 101 <param name="paired_cond|fl"> |
| 77 <collection type="list:paired"> | 102 <collection type="list:paired"> |
| 78 <element name="F3D0_S188_L001"> | 103 <element name="F3D0_S188_L001"> |
| 79 <collection type="paired"> | 104 <collection type="paired"> |
| 80 <element name="forward" value="F3D0_S188_L001_R1_001.fastq.gz" ftype="fastqsanger.gz"/> | 105 <element name="forward" value="F3D0_S188_L001_R1_001.fastq.gz" ftype="fastqsanger.gz"/> |
| 81 <element name="reverse" value="F3D0_S188_L001_R2_001.fastq.gz" ftype="fastqsanger.gz"/> | 106 <element name="reverse" value="F3D0_S188_L001_R2_001.fastq.gz" ftype="fastqsanger.gz"/> |
| 87 </test> | 112 </test> |
| 88 <!-- paired, batch, no aggregate--> | 113 <!-- paired, batch, no aggregate--> |
| 89 <test> | 114 <test> |
| 90 <param name="aggregate" value="FALSE"/> | 115 <param name="aggregate" value="FALSE"/> |
| 91 <param name="paired_cond|paired_select" value="paired_batch"/> | 116 <param name="paired_cond|paired_select" value="paired_batch"/> |
| 92 <param name="paired_cond|reads"> | 117 <param name="paired_cond|fl"> |
| 93 <collection type="paired"> | 118 <collection type="paired"> |
| 94 <element name="forward" value="F3D0_S188_L001_R1_001.fastq.gz" ftype="fastqsanger.gz"/> | 119 <element name="forward" value="F3D0_S188_L001_R1_001.fastq.gz" ftype="fastqsanger.gz"/> |
| 95 <element name="reverse" value="F3D0_S188_L001_R2_001.fastq.gz" ftype="fastqsanger.gz"/> | 120 <element name="reverse" value="F3D0_S188_L001_R2_001.fastq.gz" ftype="fastqsanger.gz"/> |
| 96 </collection> | 121 </collection> |
| 97 </param> | 122 </param> |
| 99 </test> | 124 </test> |
| 100 <!-- single, non-batch, aggregate --> | 125 <!-- single, non-batch, aggregate --> |
| 101 <test> | 126 <test> |
| 102 <param name="aggregate" value="TRUE"/> | 127 <param name="aggregate" value="TRUE"/> |
| 103 <param name="paired_cond|paired_select" value="single"/> | 128 <param name="paired_cond|paired_select" value="single"/> |
| 104 <param name="paired_cond|reads" value="F3D0_S188_L001_R1_001.fastq.gz,F3D0_S188_L001_R2_001.fastq.gz" ftype="fastqsanger.gz"/> | 129 <param name="paired_cond|fl" value="F3D0_S188_L001_R1_001.fastq.gz,F3D0_S188_L001_R2_001.fastq.gz" ftype="fastqsanger.gz"/> |
| 105 <param name="n" value="10000"/> | 130 <param name="n" value="10000"/> |
| 106 <output name="output" value="qualityProfileSmallSample.pdf" ftype="pdf"/> | 131 <output name="output" value="qualityProfileSmallSample.pdf" ftype="pdf"/> |
| 107 </test> | 132 </test> |
| 108 <!-- single, batch, no aggregate --> | 133 <!-- single, batch, no aggregate --> |
| 109 <test> | 134 <test> |
| 110 <param name="aggregate" value="FALSE"/> | 135 <param name="aggregate" value="FALSE"/> |
| 111 <param name="paired_cond|paired_select" value="single_batch"/> | 136 <param name="paired_cond|paired_select" value="single_batch"/> |
| 112 <param name="paired_cond|reads" value="F3D0_S188_L001_R1_001.fastq.gz" ftype="fastqsanger.gz"/> | 137 <param name="paired_cond|fl" value="F3D0_S188_L001_R1_001.fastq.gz" ftype="fastqsanger.gz"/> |
| 113 <param name="n" value="10000"/> | 138 <param name="n" value="10000"/> |
| 114 <output name="output" value="qualityProfileSmallSample.pdf" ftype="pdf" compare="sim_size"/> | 139 <output name="output" value="qualityProfileSmallSample.pdf" ftype="pdf" compare="sim_size"/> |
| 115 </test> </tests> | 140 </test> </tests> |
| 116 <help><