Skip to content

Commit

Permalink
Merge pull request #119 from jGaboardi/condense_pp
Browse files Browse the repository at this point in the history
condensing idvariable code chunk
  • Loading branch information
jGaboardi committed Sep 18, 2018
2 parents 5108dcd + 316a7c4 commit 7b5d38d
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions spaghetti/network.py
Original file line number Diff line number Diff line change
Expand Up @@ -1511,10 +1511,8 @@ def __init__(self, in_data=None, idvariable=None, attribute=False):
else:
from_shp = False

if idvariable and from_shp:
if idvariable:
ids = weights.util.get_ids(in_data, idvariable)
elif idvariable and not from_shp:
ids = list(in_data[idvariable])
else:
ids = None

Expand Down

0 comments on commit 7b5d38d

Please sign in to comment.