Skip to content

Commit c662806

Browse files
Fixing another Mypy error
1 parent 2440b3a commit c662806

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

malariagen_data/anoph/phenotypes.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,9 +71,12 @@ def _load_phenotype_data(
7171
if insecticide is not None:
7272
df_combined = df_combined[df_combined["insecticide"].isin(insecticide)]
7373

74-
df_combined = df_combined[
75-
df_combined["dose"].isin(dose if isinstance(dose, list) else [dose])
76-
]
74+
if dose is None:
75+
df_combined = df_combined[df_combined["dose"].isna()]
76+
else:
77+
df_combined = df_combined[
78+
df_combined["dose"].isin(dose if isinstance(dose, list) else [dose])
79+
]
7780

7881
if phenotype is not None:
7982
df_combined = df_combined[df_combined["phenotype"].isin(phenotype)]

0 commit comments

Comments
 (0)