Skip to content

Commit 4339462

Browse files
kzeileraleaf
authored andcommitted
Fix: drop_NHDPlusIDs compared as strings in load_nhdplus_hr()
Map the user-supplied list of NHDPlusIDs to drop to strings for comparison following #171. Resolves #186.
1 parent 30bc74e commit 4339462

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sfrmaker/nhdplus_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ def load_nhdplus_hr(NHDPlusHR_paths, bbox_filter=None,
478478
if drop_ftypes is not None:
479479
df = df.loc[~df.FType.isin(drop_ftypes)]
480480
if drop_NHDPlusIDs is not None:
481-
df = df.loc[~df.NHDPlusID.isin(drop_NHDPlusIDs)]
481+
df = df.loc[~df.NHDPlusID.isin(map(str, drop_NHDPlusIDs))]
482482

483483
keep_cols = ['NHDPlusID', 'ToNHDPID', 'ArbolateSu',
484484
'geometry', 'StreamOrde',

0 commit comments

Comments
 (0)