Spaces:
Runtime error
Runtime error
Commit
·
e5f8353
1
Parent(s):
fc3e5ca
Update app.py
Browse files
app.py
CHANGED
@@ -31,6 +31,13 @@ auth = tw.OAuthHandler(consumer_key, consumer_secret)
|
|
31 |
auth.set_access_token(access_token, access_token_secret)
|
32 |
api = tw.API(auth, wait_on_rate_limit=True)
|
33 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
st.set_page_config(layout="wide")
|
35 |
st.markdown('<style>body{background-color: Blue;}</style>',unsafe_allow_html=True)
|
36 |
|
|
|
31 |
auth.set_access_token(access_token, access_token_secret)
|
32 |
api = tw.API(auth, wait_on_rate_limit=True)
|
33 |
|
34 |
+
def highlight_survived(s):
|
35 |
+
return ['background-color: red']*len(s) if (s.Sexista == 1) else ['background-color: green']*len(s)
|
36 |
+
|
37 |
+
def color_survived(val):
|
38 |
+
color = 'red' if val=='Sexista' else 'white'
|
39 |
+
return f'background-color: {color}'
|
40 |
+
|
41 |
st.set_page_config(layout="wide")
|
42 |
st.markdown('<style>body{background-color: Blue;}</style>',unsafe_allow_html=True)
|
43 |
|