Spaces:
Sleeping
Sleeping
Update index.py
Browse files
index.py
CHANGED
@@ -252,7 +252,8 @@ def update_output(selected_topic, selected_domain, start_date, end_date):
|
|
252 |
|
253 |
# Reindex the DataFrame to include all periods and media
|
254 |
grouped_df = grouped_df.set_index(['period', 'Veículos de notícias']).reindex(idx, fill_value=0).reset_index()
|
255 |
-
|
|
|
256 |
bar_fig_1 = px.bar(grouped_df, x='period', y='occurrences', color='Veículos de notícias',
|
257 |
labels={'period': 'Período', 'occurrences': 'Número de notícias', 'Veículos de notícias': 'Portal'},
|
258 |
title='Número de notícias por período de tempo')
|
|
|
252 |
|
253 |
# Reindex the DataFrame to include all periods and media
|
254 |
grouped_df = grouped_df.set_index(['period', 'Veículos de notícias']).reindex(idx, fill_value=0).reset_index()
|
255 |
+
|
256 |
+
print(grouped_df.shape)
|
257 |
bar_fig_1 = px.bar(grouped_df, x='period', y='occurrences', color='Veículos de notícias',
|
258 |
labels={'period': 'Período', 'occurrences': 'Número de notícias', 'Veículos de notícias': 'Portal'},
|
259 |
title='Número de notícias por período de tempo')
|