Spaces:
Runtime error
Runtime error
Commit
路
a7bf2cb
1
Parent(s):
7c434c5
Update app.py
Browse files
app.py
CHANGED
|
@@ -210,12 +210,10 @@ def analizar_frase(frase):
|
|
| 210 |
return tabla
|
| 211 |
|
| 212 |
def run():
|
| 213 |
-
|
| 214 |
-
col1
|
| 215 |
-
|
| 216 |
-
|
| 217 |
-
search_words = col.text_input("Introduzca la frase, el usuario o localidad para analizar y pulse el check correspondiente")
|
| 218 |
-
number_of_tweets = col.number_input('Introduzca n煤mero de tweets a analizar del usuario M谩ximo 50', 0,50,0)
|
| 219 |
st.write("Escoja una Opci贸n")
|
| 220 |
termino=st.checkbox('Frase')
|
| 221 |
usuario=st.checkbox('Usuario')
|
|
@@ -234,10 +232,13 @@ def run():
|
|
| 234 |
|
| 235 |
if (error == False):
|
| 236 |
if (termino):
|
| 237 |
-
col2
|
|
|
|
| 238 |
elif (usuario):
|
| 239 |
-
col2
|
|
|
|
| 240 |
elif (localidad):
|
| 241 |
-
col2
|
|
|
|
| 242 |
|
| 243 |
run()
|
|
|
|
| 210 |
return tabla
|
| 211 |
|
| 212 |
def run():
|
| 213 |
+
col1, col2, col3 = st.columns(3)
|
| 214 |
+
with col1.form("my_form"):
|
| 215 |
+
search_words = st.text_input("Introduzca la frase, el usuario o localidad para analizar y pulse el check correspondiente")
|
| 216 |
+
number_of_tweets = st.number_input('Introduzca n煤mero de tweets a analizar del usuario M谩ximo 50', 0,50,0)
|
|
|
|
|
|
|
| 217 |
st.write("Escoja una Opci贸n")
|
| 218 |
termino=st.checkbox('Frase')
|
| 219 |
usuario=st.checkbox('Usuario')
|
|
|
|
| 232 |
|
| 233 |
if (error == False):
|
| 234 |
if (termino):
|
| 235 |
+
with col2:
|
| 236 |
+
analizar_frase(search_words)
|
| 237 |
elif (usuario):
|
| 238 |
+
with col2:
|
| 239 |
+
tweets_usuario(search_words,number_of_tweets)
|
| 240 |
elif (localidad):
|
| 241 |
+
with col2:
|
| 242 |
+
tweets_localidad(search_words)
|
| 243 |
|
| 244 |
run()
|