Skip to content

Commit

Permalink
Add avg age and vaccination to nextflu-private builds
Browse files Browse the repository at this point in the history
  • Loading branch information
huddlej committed Dec 8, 2023
1 parent fc95b81 commit 8519f65
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 1 deletion.
19 changes: 18 additions & 1 deletion profiles/nextflu-private/antigenic_distances.smk
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,25 @@ rule summarize_haplotype_titer_coverage:
--output-node-data {output.node_data} 2>&1 | tee {log}
"""

rule scores:
input:
metadata = "builds/{build_name}/metadata.tsv",
tree = "builds/{build_name}/{segment}/tree.nwk",
output:
node_data = "builds/{build_name}/{segment}/scores.json",
conda: "../../workflow/envs/nextstrain.yaml"
shell:
"""
python3 scripts/scores.py \
--metadata {input.metadata} \
--tree {input.tree} \
--output {output}
"""

def get_private_node_data(wildcards):
node_data = []
node_data = [
"builds/{build_name}/{segment}/scores.json",
]

# Only try to annotate titer collections for HA.
if wildcards.segment == "ha":
Expand Down
10 changes: 10 additions & 0 deletions profiles/nextflu-private/h1n1pdm/ha/auspice_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,16 @@
"title": "Epiweek (CDC)",
"type": "ordinal"
},
{
"key": "avg_age",
"title": "Avg age",
"type": "continuous"
},
{
"key": "vaccov",
"title": "Avg vaccination",
"type": "continuous"
},
{
"key": "egg_hi_cTiter",
"title": "Antigenic advance (tree, ferret egg HI)",
Expand Down
10 changes: 10 additions & 0 deletions profiles/nextflu-private/h3n2/ha/auspice_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,16 @@
"title": "Epiweek (CDC)",
"type": "ordinal"
},
{
"key": "avg_age",
"title": "Avg age",
"type": "continuous"
},
{
"key": "vaccov",
"title": "Avg vaccination",
"type": "continuous"
},
{
"key": "cell_fra_dTiter",
"title": "Antigenic weight (tree, ferret cell FRA)",
Expand Down
10 changes: 10 additions & 0 deletions profiles/nextflu-private/vic/ha/auspice_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,16 @@
"title": "Epiweek (CDC)",
"type": "ordinal"
},
{
"key": "avg_age",
"title": "Avg age",
"type": "continuous"
},
{
"key": "vaccov",
"title": "Avg vaccination",
"type": "continuous"
},
{
"key": "egg_hi_cTiter",
"title": "Antigenic advance (tree, ferret egg HI)",
Expand Down

0 comments on commit 8519f65

Please sign in to comment.