Spaces:
Runtime error
Runtime error
added dataframe to demo
Browse files
app.py
CHANGED
@@ -18,12 +18,12 @@ with gr.Blocks() as demo:
|
|
18 |
|
19 |
with gr.Row():
|
20 |
serie = gr.Dropdown(choices = ['SOM', 'Volumen'], value = 'SOM', label = 'Serie', info = 'Choose the serie to forecast')
|
21 |
-
periods = gr.Slider(minimum = 1, maximum = 12, step = 1, value = 3, label = 'Months')
|
22 |
-
percent_change = gr.Slider(minimum = -100, maximum = 100, step = 5, value = -5, label = '% Change vs Last Year')
|
23 |
|
24 |
with gr.Row():
|
25 |
dataframe = gr.Dataframe(label = 'Predicted values')
|
26 |
-
plot = gr.Plot()
|
27 |
|
28 |
serie.change(get_forecast, [serie, periods, percent_change], [plot, dataframe], queue=False)
|
29 |
periods.change(get_forecast, [serie, periods, percent_change], [plot, dataframe], queue=False)
|
|
|
18 |
|
19 |
with gr.Row():
|
20 |
serie = gr.Dropdown(choices = ['SOM', 'Volumen'], value = 'SOM', label = 'Serie', info = 'Choose the serie to forecast')
|
21 |
+
periods = gr.Slider(minimum = 1, maximum = 12, step = 1, value = 3, label = 'Months', info = 'How many months to forecast')
|
22 |
+
percent_change = gr.Slider(minimum = -100, maximum = 100, step = 5, value = -5, label = '% Change vs Last Year', info = "Price change vs last year")
|
23 |
|
24 |
with gr.Row():
|
25 |
dataframe = gr.Dataframe(label = 'Predicted values')
|
26 |
+
plot = gr.Plot(label = 'Forecast curve')
|
27 |
|
28 |
serie.change(get_forecast, [serie, periods, percent_change], [plot, dataframe], queue=False)
|
29 |
periods.change(get_forecast, [serie, periods, percent_change], [plot, dataframe], queue=False)
|