Spaces:
Running
Running
James McCool
commited on
Commit
·
50d171e
1
Parent(s):
30cafb8
Modify median calculation in DraftKings MMA ROO flex file generation
Browse files
function_hold/MMA_functions.py
CHANGED
@@ -119,7 +119,7 @@ def DK_MMA_ROO_Build(projections_file, std_var, distribution_type):
|
|
119 |
|
120 |
flex_file = basic_own_df[['Player', 'Salary', 'Median', 'KO_odds', 'Sub_odds', 'range_var']]
|
121 |
flex_file = flex_file.rename(columns={"Agg": "Median"})
|
122 |
-
flex_file['Median'] = flex_file['Median']
|
123 |
flex_file['Floor'] = flex_file['Median'] * (1-flex_file['range_var'])
|
124 |
flex_file['Ceiling'] = flex_file['Median'] * (1+flex_file['range_var'])
|
125 |
flex_file['STD'] = (flex_file['Median'] / std_var)
|
|
|
119 |
|
120 |
flex_file = basic_own_df[['Player', 'Salary', 'Median', 'KO_odds', 'Sub_odds', 'range_var']]
|
121 |
flex_file = flex_file.rename(columns={"Agg": "Median"})
|
122 |
+
flex_file['Median'] = (flex_file['Median'] * (1 - flex_file['range_var']))
|
123 |
flex_file['Floor'] = flex_file['Median'] * (1-flex_file['range_var'])
|
124 |
flex_file['Ceiling'] = flex_file['Median'] * (1+flex_file['range_var'])
|
125 |
flex_file['STD'] = (flex_file['Median'] / std_var)
|