...
 
Commits (4)
......@@ -301,14 +301,14 @@ def set_default_values():
set_default_value("global", "parallel-samples", False)
if "denoiser" in config["global"]:
# FASTQ type
# FASTQ type and format
if config["global"]["library-type"] == "single-end":
set_default_value("import", "type", "\"SampleData[SequencesWithQuality]\"")
set_default_value("import", "input-format", "SingleEndFastqManifestPhred33")
else:
set_default_value("import", "type", "\"SampleData[PairedEndSequencesWithQuality]\"")
# FASTQ format
set_default_value("import", "input-format", "PairedEndFastqManifestPhred33")
set_default_value("import", "input-format", "PairedEndFastqManifestPhred33")
# Set global multithreading parameter
set_default_value("global", "nbthreads", 1)
......@@ -750,7 +750,7 @@ if "denoiser" in config["global"]:
getOutput("deblur", "representative_sequences.qza"),
getOutput("deblur", "stats.qza"),
getOutput("deblur", "stats.qzv"),
getOutput("deblur", "html"),
directory(getOutput("deblur", "html")),
getOutput("deblur", "stats/stats.csv")
params: options = getOptions("deblur"),
......@@ -770,7 +770,7 @@ if "denoiser" in config["global"]:
getOutput("dada2", "representative_sequences.qza"),
getOutput("dada2", "stats.qza"),
getOutput("dada2", "stats.qzv"),
getOutput("dada2", "html"),
directory(getOutput("dada2", "html")),
getOutput("dada2", "stats/stats.csv")
params: options = getOptions("dada2"),
lib_type = pairedOrSingle("dada2")
......@@ -807,16 +807,15 @@ if "denoiser" in config["global"]:
input: getInput("summarize_table", "table.qza"),
getInput("summarize_table", "representative_sequences.qza")
output: getOutput("summarize_table", "table.qzv"),
getOutput("summarize_table", "rep-seqs.qzv"),
getOutput("summarize_table")
getOutput("summarize_table", "rep-seqs.qzv")
params: logfile = config["global"]["outdir"] + "/" + LOGFILE
priority: 1
conda: qiime2_yml
shell: """
qiime feature-table summarize --i-table {input[0]} --o-visualization {output[0]}
qiime feature-table tabulate-seqs --i-data {input[1]} --o-visualization {output[1]}
qiime tools export --input-path {output[0]} --output-path {output[2]}table_html
qiime tools export --input-path {output[1]} --output-path {output[2]}seqs_html
qiime tools export --input-path {output[0]} --output-path `dirname $(dirname {output[1]})`/table_html
qiime tools export --input-path {output[1]} --output-path `dirname $(dirname {output[1]})`/seqs_html
echo "\nDenoising.....OK" >> {params.logfile}
"""
......@@ -915,13 +914,12 @@ if "denoiser" in config["global"]:
output: getOutput("phylogenetic_tree", "aligned-rep-seqs.qza"),
getOutput("phylogenetic_tree", "masked-aligned-rep-seqs.qza"),
getOutput("phylogenetic_tree", "unrooted-tree.qza"),
getOutput("phylogenetic_tree", "rooted-tree.qza"),
getOutput("phylogenetic_tree")
getOutput("phylogenetic_tree", "rooted-tree.qza")
params: options = getOptions("phylogeny")
conda: qiime2_yml
shell: """
qiime phylogeny align-to-tree-mafft-fasttree --i-sequences {input} --o-alignment {output[0]} --o-masked-alignment {output[1]} --o-tree {output[2]} --o-rooted-tree {output[3]} {params.options}
qiime tools export --input-path {output[3]} --output-path {output[4]}
qiime tools export --input-path {output[3]} --output-path `dirname $(dirname {output[3]})`
"""
# Compute diversity metrics
......@@ -948,9 +946,9 @@ if "denoiser" in config["global"]:
getOutput("diversity", "weighted_unifrac_emperor.qzv"),
getOutput("diversity", "jaccard_emperor.qzv"),
getOutput("diversity", "bray_curtis_emperor.qzv"),
braycurtis = getOutput("diversity", "pcoa/bray_curtis"),
jaccard = getOutput("diversity", "pcoa/jaccard"),
unweighted_unifrac = getOutput("diversity", "pcoa/unweighted_unifrac"),
braycurtis = directory(getOutput("diversity", "pcoa/bray_curtis")),
jaccard = directory(getOutput("diversity", "pcoa/jaccard")),
unweighted_unifrac = directory(getOutput("diversity", "pcoa/unweighted_unifrac")),
html = getOutput("diversity", "pcoa/weighted_unifrac/emperor.html")
params: options = getOptions("diversity"),
logfile = config["global"]["outdir"] + "/" + LOGFILE
......
name : microSysMics
dependencies :
- bioconda::snakemake=3.11.2
- pandas=0.19.2
- bioconda::snakemake
- pandas
- python-dateutil
- conda-forge::gitpython
- jsonschema
#SampleID Category Day Period
#q2:types categorical categorical categorical
F3D0 F3 0 first
F3D1 F3 1 first
F3D2 F3 2 first
F3D3 F3 3 first
F3D5 F3 5 first
F3D6 F3 6 first
F3D7 F3 7 first
F3D8 F3 8 first
F3D9 F3 9 first
F3D141 F3 141 second
F3D142 F3 142 second
F3D143 F3 143 second
F3D144 F3 144 second
F3D145 F3 145 second
F3D146 F3 146 second
F3D147 F3 147 second
F3D148 F3 148 second
F3D149 F3 149 second
F3D150 F3 150 second
Mock Mock NA NA
#SampleID time dpw
#q2:types categorical numeric
F3D0 Early 0
F3D1 Early 1
F3D2 Early 2
F3D3 Early 3
F3D5 Early 5
F3D6 Early 6
F3D7 Early 7
F3D8 Early 8
F3D9 Early 9
F3D141 Late 141
F3D142 Late 142
F3D143 Late 143
F3D144 Late 144
F3D145 Late 145
F3D146 Late 146
F3D147 Late 147
F3D148 Late 148
F3D149 Late 149
F3D150 Late 150
......@@ -37,5 +37,3 @@ F3D8,test/fastq/F3D8_S196_L001_R1_001.fastq.gz,forward
F3D8,test/fastq/F3D8_S196_L001_R2_001.fastq.gz,reverse
F3D9,test/fastq/F3D9_S197_L001_R1_001.fastq.gz,forward
F3D9,test/fastq/F3D9_S197_L001_R2_001.fastq.gz,reverse
Mock,test/fastq/Mock_S280_L001_R2_001.fastq.gz,reverse
Mock,test/fastq/Mock_S280_L001_R1_001.fastq.gz,forward