Update app.py
Browse files
app.py
CHANGED
@@ -13,7 +13,7 @@ def huff_model_probability(df_distances, df_attractiveness, alpha, beta, df_popu
|
|
13 |
df_population = pd.Series(np.ones(df_distances.shape[0]), index=df_distances.index)
|
14 |
|
15 |
adjustment_factors = pd.DataFrame(index=df_distances.index, columns=df_distances.columns)
|
16 |
-
if distance_threshold is not None:
|
17 |
# Calculate adjustment factors for each origin-destination pair
|
18 |
for destination in df_distances.columns:
|
19 |
adjustment_factors[destination] = df_distances[destination].apply(
|
|
|
13 |
df_population = pd.Series(np.ones(df_distances.shape[0]), index=df_distances.index)
|
14 |
|
15 |
adjustment_factors = pd.DataFrame(index=df_distances.index, columns=df_distances.columns)
|
16 |
+
if distance_threshold is not None and distance_threshold is not "None":
|
17 |
# Calculate adjustment factors for each origin-destination pair
|
18 |
for destination in df_distances.columns:
|
19 |
adjustment_factors[destination] = df_distances[destination].apply(
|