Skip to content

Commit ddf9899

Browse files
Merge pull request #216 from jeromekelleher/fix-info-bug
Use pango_source for recombinant info
2 parents c24cd33 + b9f1706 commit ddf9899

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sc2ts/utils.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -393,6 +393,7 @@ def __init__(self, ts, show_progress=True, pango_source="Viridian_pangolin"):
393393
# # Corresponding sample-set names for this array
394394
# self.pango_lineage_keys = np.array(list(self.pango_lineage_samples.keys()))
395395

396+
396397
def _compute_mutation_stats(self):
397398
ts = self.ts
398399

@@ -715,7 +716,7 @@ def recombinants_summary(self):
715716
for u in df.node:
716717
md = self.nodes_metadata[sample_map[u]]
717718
causal_strain.append(md["strain"])
718-
causal_pango.append(md["Nextclade_pango"])
719+
causal_pango.append(md[self.pango_source])
719720
causal_date.append(md["date"])
720721
df["causal_strain"] = causal_strain
721722
df["causal_pango"] = causal_pango
@@ -2013,7 +2014,7 @@ def add_gisaid_lineages_to_ts(ts, node_gisaid_lineages, linmuts_dict):
20132014
return edited_ts
20142015

20152016

2016-
# NOTE: this is broken since moving to Viridian metadata, we no longer have
2017+
# NOTE: this is broken since moving to Viridian metadata, we no longer have
20172018
# GISAID EPI ISL in the metadata
20182019
def check_lineages(
20192020
ts,

0 commit comments

Comments
 (0)