sneves commited on
Commit
33d4be9
·
verified ·
1 Parent(s): 040542a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -19,7 +19,7 @@ with st.sidebar:
19
  year_list = list(df.Year.unique())[::-1]
20
  year_list = sorted(year_list)
21
 
22
- selected_year = st.selectbox('Select a year', year_list, index=len(year_list)-1).to_string()
23
 
24
  cik_list = list(df.CIK.unique())[::-1]
25
  cik_list = sorted(cik_list)
@@ -48,7 +48,7 @@ with col2:
48
  wc_list = ['E_Text', 'S_Text', 'G_Text']
49
 
50
  for x in wc_list:
51
- row = df_selected_cik.loc[selected_year]
52
  text = row.loc[x]
53
  text = re.sub(r'[^A-Za-z\s]', '', text)
54
  text = text.lower()
 
19
  year_list = list(df.Year.unique())[::-1]
20
  year_list = sorted(year_list)
21
 
22
+ selected_year = st.selectbox('Select a year', year_list, index=len(year_list)-1)
23
 
24
  cik_list = list(df.CIK.unique())[::-1]
25
  cik_list = sorted(cik_list)
 
48
  wc_list = ['E_Text', 'S_Text', 'G_Text']
49
 
50
  for x in wc_list:
51
+ row = df_selected_cik.loc[selected_year.astype(string)]
52
  text = row.loc[x]
53
  text = re.sub(r'[^A-Za-z\s]', '', text)
54
  text = text.lower()