Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Laura Denies
PathoFact
Commits
03b526bc
Commit
03b526bc
authored
Jun 22, 2020
by
Laura Denies
Browse files
update HMM virulence prediction report
parent
850f0c34
Changes
3
Hide whitespace changes
Inline
Side-by-side
config.yaml
View file @
03b526bc
...
...
@@ -2,7 +2,7 @@ pathofact:
sample
:
[
"
test_sample"
]
# requires user input
project
:
PathoFact_update_trial
# requires user input
datadir
:
../test_dataset
# requires user input
workflow
:
"
Tox
"
workflow
:
"
Vir
"
size_fasta
:
1000
scripts
:
"
scripts"
signalp
:
"
/work/projects/ecosystem_biology/local_tools/SignalP/signalp-5.0b/bin"
# requires user input
...
...
rules/Virulence/Combine_Virulence_SignalP.smk
View file @
03b526bc
...
...
@@ -10,7 +10,7 @@ import os
rule merge_SignalPVir:
input:
Vir="{datadir}/{project}/VIRULENCE/HMM_classifier_virulence/{sample}_virulence_final_prediction.tsv",
SignalP="{datadir}/{project}/SignalP/aggregated/{sample}_SignalP_results.t
xt
"
SignalP="{datadir}/{project}/SignalP/aggregated/{sample}_SignalP_results.t
sv
"
output:
"{datadir}/{project}/VIRULENCE/virulence_merged/{sample}_virulence_SignalP_prediction.tsv"
params:
...
...
rules/Virulence/Virulence.smk
View file @
03b526bc
...
...
@@ -88,44 +88,23 @@ rule HMM_R_VIR:
"../../scripts/hmm.R"
# Give pathogenicity prediction
rule HMM_VIR_
nonpath
:
rule HMM_VIR_
classification
:
input:
"{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}.hmm_results.csv"
output:
temp("{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}_hmm_non_path.txt")
non_path=temp("{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}_hmm_non_path.txt"),
pathogenic=temp("{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}_hmm_pathogenic.txt"),
unclassified=temp("{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}_hmm_unclassified.txt")
params:
runtime=config["pathofact"]["runtime"]["short"],
mem=config["pathofact"]["mem"]["normal_mem_per_core_gb"]
shell:
"""
awk '$2 == "True" && $3 == "False" && $4 == "False"' {input} | awk '$5 = "Non-Pathogenic"' | sed 's/ /\\t/g' > {output}
awk '$2 == "True" && $3 == "False" && $4 == "False"' {input} | awk '$5 = "Non-Pathogenic"' | sed 's/ /\\t/g' > {output.non_path}
awk '$3 == "True"' {input} | awk '$5 = "Pathogenic"' | sed 's/ /\\t/g' > {output.pathogenic}
awk '$3 == "False" && $4 == "True"' {input} | awk '$5 = "Unclassified"' | sed 's/ /\\t/g' > {output.unclassified}
"""
rule HMM_VIR_pathogenic:
input:
"{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}.hmm_results.csv"
output:
temp("{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}_hmm_pathogenic.txt")
params:
runtime=config["pathofact"]["runtime"]["short"],
mem=config["pathofact"]["mem"]["normal_mem_per_core_gb"]
shell:
"""
awk '$3 == "True"' {input} | awk '$5 = "Pathogenic"' | sed 's/ /\\t/g' > {output}
"""
rule HMM_VIR_unclassified:
input:
"{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}.hmm_results.csv"
output:
temp("{datadir}/{project}/VIRULENCE/HMM_virulence/{sample}_hmm_unclassified.txt")
params:
runtime=config["pathofact"]["runtime"]["short"],
mem=config["pathofact"]["mem"]["normal_mem_per_core_gb"]
shell:
"""
awk '$3 == "False" && $4 == "True"' {input} | awk '$5 = "Unclassified"' | sed 's/ /\\t/g' > {output}
"""
rule HMM_VIR_report:
input:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment