emvecchi commited on
Commit
3cfa329
1 Parent(s): 9ff34e6

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -42,7 +42,8 @@ COLS_TO_SAVE = ['comment_id','comment','confidence_score']
42
  agreement_labels = ['strongly disagree', 'disagree', 'neither agree no disagree', 'agree', 'strongly agree']
43
  quality_labels = ['very poor', 'poor', 'acceptable', 'good', 'very good']
44
  priority_labels = ['not a priority', 'low priority', 'neutral', 'moderate priority', 'high priority']
45
- yes_no_labels = ['yes','no','other']
 
46
  default_labels = agreement_labels
47
 
48
  function_choices = ['Broadening Discussion',
@@ -311,7 +312,7 @@ def show_field(f: Field, index: int, data_collected):
311
  value=value, help=f.help)
312
  case 'radio':
313
  st.radio(f.title,
314
- ["yes","no","other"],
315
  key=key,
316
  help=f.help)
317
  case 'slider':
@@ -343,7 +344,7 @@ def show_field(f: Field, index: int, data_collected):
343
  case 'y_n_radio':
344
  labels = yes_no_labels if not f.other_params.get('labels') else f.other_params.get('labels')
345
  st.radio(f.title,
346
- options=[0, 1, 2],
347
  format_func=lambda x: labels[x],
348
  key=key,
349
  index=value, help=f.help, horizontal=True)
 
42
  agreement_labels = ['strongly disagree', 'disagree', 'neither agree no disagree', 'agree', 'strongly agree']
43
  quality_labels = ['very poor', 'poor', 'acceptable', 'good', 'very good']
44
  priority_labels = ['not a priority', 'low priority', 'neutral', 'moderate priority', 'high priority']
45
+ yes_no_labels = ['yes','no']
46
+ yes_no_other_labels = ['yes','no','other']
47
  default_labels = agreement_labels
48
 
49
  function_choices = ['Broadening Discussion',
 
312
  value=value, help=f.help)
313
  case 'radio':
314
  st.radio(f.title,
315
+ ["yes","no"],
316
  key=key,
317
  help=f.help)
318
  case 'slider':
 
344
  case 'y_n_radio':
345
  labels = yes_no_labels if not f.other_params.get('labels') else f.other_params.get('labels')
346
  st.radio(f.title,
347
+ options=[0, 1],
348
  format_func=lambda x: labels[x],
349
  key=key,
350
  index=value, help=f.help, horizontal=True)