mannnon commited on
Commit
f11be2a
·
verified ·
1 Parent(s): 08b688a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -785,12 +785,12 @@ def compute_domain_scores(merged_data, df_analysis, patterns):
785
  row_map = {row["variable"]: row for _, row in df_analysis.iterrows()}
786
 
787
  def var_points(var_name, weight=1.0):
788
- row = row_map.get(var_name)
789
- if row is None:
790
- return 0.0
791
- base = priority_to_points(row["priority"]) * 10
792
- bonus = row["deviation_score"] * 20
793
- return (base + bonus) * weight
794
 
795
  def pattern_points(category):
796
  total = 0
 
785
  row_map = {row["variable"]: row for _, row in df_analysis.iterrows()}
786
 
787
  def var_points(var_name, weight=1.0):
788
+ row = row_map.get(var_name)
789
+ if row is None:
790
+ return 0.0
791
+ base = priority_to_points(row["priority"]) * 10
792
+ bonus = row["deviation_score"] * 20
793
+ return (base + bonus) * weight
794
 
795
  def pattern_points(category):
796
  total = 0