Skip to content

Commit

Permalink
add dummy yam files, fix rule name
Browse files Browse the repository at this point in the history
  • Loading branch information
rneher committed Aug 23, 2023
1 parent d9589e6 commit ea07025
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 4 deletions.
12 changes: 12 additions & 0 deletions config/yam/ha/subclades.tsv
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
clade gene site alt
Y1 SigPep 1 M
Y2 HA1 48 K
Y2 HA1 108 A
Y2 HA1 181 A
Y3 HA1 116 K
Y3 HA1 150 I
Y3 HA1 165 Y
Y3 HA1 202 S
Y3 HA1 229 D
Y3 HA1 298 E
Y3 HA1 312 K
Empty file added config/yam/na/subclades.tsv
Empty file.
6 changes: 3 additions & 3 deletions workflow/snakemake_rules/core.smk
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ rule clades:
"""

# Determine subclades for na and ha.
rule subclade:
rule subclades:
input:
tree = build_dir + "/{build_name}/{segment}/tree.nwk",
nt_muts = build_dir + "/{build_name}/{segment}/nt-muts.json",
Expand All @@ -377,9 +377,9 @@ rule subclade:
label_name = "Subclade",
conda: "../envs/nextstrain.yaml"
benchmark:
"benchmarks/clades_{build_name}.txt"
"benchmarks/clades_{build_name}_{segment}.txt"
log:
"logs/clades_{build_name}.txt"
"logs/clades_{build_name}_{segment}.txt"
shell:
"""
augur clades \
Expand Down
5 changes: 4 additions & 1 deletion workflow/snakemake_rules/export.smk
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ def _get_node_data_by_wildcards(wildcards):
rules.ancestral.output.node_data,
rules.translate.output.node_data,
rules.clades.output.node_data,
rules.subclades.output.node_data,
rules.traits.output.node_data,
rules.annotate_epiweeks.output.node_data,
rules.annotate_recency_of_submissions.output.node_data,
Expand All @@ -21,6 +20,10 @@ def _get_node_data_by_wildcards(wildcards):
if _get_build_distance_map_config(wildcards) is not None:
inputs.append(rules.distances.output.distances)


if config["builds"][wildcards.build_name].get('subclades', False):
inputs.append(rules.subclades.output.node_data)

if config["builds"][wildcards.build_name].get('enable_titer_models', False) and wildcards.segment == 'ha':
for collection in config["builds"][wildcards.build_name]["titer_collections"]:
inputs.append(rules.titers_sub.output.titers_model.format(titer_collection=collection["name"], **wildcards_dict))
Expand Down

0 comments on commit ea07025

Please sign in to comment.