Skip to content

Commit ea950fc

Browse files
committed
Merge branch 'master' into GH716_add_constructor_params
2 parents 23e9012 + 1cba09b commit ea950fc

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

malariagen_data/anoph/fst.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -539,8 +539,11 @@ def plot_pairwise_average_fst(
539539
if annotation == "standard error":
540540
fig_df.loc[cohort1, cohort2] = se
541541
elif annotation == "Z score":
542-
zs = fst / se
543-
fig_df.loc[cohort1, cohort2] = zs
542+
try:
543+
zs = fst / se
544+
fig_df.loc[cohort1, cohort2] = zs
545+
except ZeroDivisionError:
546+
fig_df.loc[cohort1, cohort2] = np.nan
544547
else:
545548
fig_df.loc[cohort1, cohort2] = fst
546549

0 commit comments

Comments
 (0)