James McCool
commited on
Commit
·
9324c8a
1
Parent(s):
bfb331d
Refine dupes calculation in predict_dupes function by adjusting the formula to prioritize Contest_Size and ownership metrics, enhancing the accuracy of duplicate predictions.
Browse files
global_func/predict_dupes.py
CHANGED
@@ -527,8 +527,8 @@ def predict_dupes(portfolio, maps_dict, site_var, type_var, Contest_Size, streng
|
|
527 |
print(portfolio[['Own', 'own_product', 'own_average', 'own_sum', 'avg_own_rank']].head(10))
|
528 |
|
529 |
# Calculate dupes formula
|
530 |
-
portfolio['dupes_calc'] = (portfolio['own_product'] * portfolio['avg_own_rank']) *
|
531 |
-
portfolio['dupes_calc'] = portfolio['dupes_calc'] * dupes_multiplier
|
532 |
|
533 |
# Round and handle negative values
|
534 |
portfolio['Dupes'] = np.where(
|
|
|
527 |
print(portfolio[['Own', 'own_product', 'own_average', 'own_sum', 'avg_own_rank']].head(10))
|
528 |
|
529 |
# Calculate dupes formula
|
530 |
+
portfolio['dupes_calc'] = (portfolio['own_product'] * portfolio['avg_own_rank']) * Contest_Size + ((portfolio['salary'] - (50000 - portfolio['Own'])) / 100) - ((50000 - portfolio['salary']) / 100)
|
531 |
+
portfolio['dupes_calc'] = portfolio['dupes_calc'] * dupes_multiplier * (portfolio['Own'] / (100 + (Contest_Size / 1000)))
|
532 |
|
533 |
# Round and handle negative values
|
534 |
portfolio['Dupes'] = np.where(
|