Update app.py
Browse files
app.py
CHANGED
|
@@ -256,6 +256,12 @@ with gr.Blocks(title="An谩lisis de Opciones") as demo:
|
|
| 256 |
with gr.Row():
|
| 257 |
|
| 258 |
output_df_call = gr.DataFrame(label="Datos de Opciones call", value=initial_df_call)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 259 |
'''
|
| 260 |
ticker_input.change(
|
| 261 |
fn = generar_calls,
|
|
@@ -270,8 +276,12 @@ with gr.Blocks(title="An谩lisis de Opciones") as demo:
|
|
| 270 |
with gr.Row():
|
| 271 |
output_plot1 = gr.Plot(label="Distribuci贸n de Volumen de las opciones")
|
| 272 |
output_plot2 = gr.Plot(label = 'Volatilidad Impl铆cita por strike')
|
| 273 |
-
|
| 274 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 275 |
|
| 276 |
with gr.Tab("Exportar"):
|
| 277 |
gr.Markdown("# Exportaci贸n:")
|
|
@@ -288,16 +298,6 @@ with gr.Blocks(title="An谩lisis de Opciones") as demo:
|
|
| 288 |
outputs=[output_file, output_msg]
|
| 289 |
)
|
| 290 |
|
| 291 |
-
|
| 292 |
-
fn=generar_todo,
|
| 293 |
-
inputs=[ticker_input, expiration_date, size_of_the_window],
|
| 294 |
-
outputs= [ output_df_put, output_df_call, df_call_state, df_put_state]
|
| 295 |
-
)
|
| 296 |
-
|
| 297 |
-
btn_plot.click(
|
| 298 |
-
fn=plot_opciones,
|
| 299 |
-
inputs=[df_put_state, df_call_state, ticker_input, expiration_date],
|
| 300 |
-
outputs=[output_plot1, output_plot2]
|
| 301 |
-
)
|
| 302 |
# Inicia la aplicaci贸n
|
| 303 |
demo.launch(share=True)
|
|
|
|
| 256 |
with gr.Row():
|
| 257 |
|
| 258 |
output_df_call = gr.DataFrame(label="Datos de Opciones call", value=initial_df_call)
|
| 259 |
+
|
| 260 |
+
btn_mostrar.click(
|
| 261 |
+
fn=generar_todo,
|
| 262 |
+
inputs=[ticker_input, expiration_date, size_of_the_window],
|
| 263 |
+
outputs= [ output_df_put, output_df_call, df_call_state, df_put_state]
|
| 264 |
+
)
|
| 265 |
'''
|
| 266 |
ticker_input.change(
|
| 267 |
fn = generar_calls,
|
|
|
|
| 276 |
with gr.Row():
|
| 277 |
output_plot1 = gr.Plot(label="Distribuci贸n de Volumen de las opciones")
|
| 278 |
output_plot2 = gr.Plot(label = 'Volatilidad Impl铆cita por strike')
|
| 279 |
+
|
| 280 |
+
btn_plot.click(
|
| 281 |
+
fn=plot_opciones,
|
| 282 |
+
inputs=[df_put_state, df_call_state, ticker_input, expiration_date],
|
| 283 |
+
outputs=[output_plot1, output_plot2]
|
| 284 |
+
)
|
| 285 |
|
| 286 |
with gr.Tab("Exportar"):
|
| 287 |
gr.Markdown("# Exportaci贸n:")
|
|
|
|
| 298 |
outputs=[output_file, output_msg]
|
| 299 |
)
|
| 300 |
|
| 301 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 302 |
# Inicia la aplicaci贸n
|
| 303 |
demo.launch(share=True)
|