Spaces:
Runtime error
Runtime error
Update app3.py
Browse files
app3.py
CHANGED
@@ -46,7 +46,7 @@ def create_plot(subgroup='All polls', date_range=[df2['timestamp'].min(), df2['t
|
|
46 |
]
|
47 |
|
48 |
# Apply any required transformations to the data in pandas
|
49 |
-
smooth_data = approval_df2.sort_values('timestamp').rolling(window=moving_av_window, on='timestamp').mean().shift(-moving_av_window+1)
|
50 |
|
51 |
chart_data = approval_df2.sort_values('timestamp').copy()
|
52 |
|
|
|
46 |
]
|
47 |
|
48 |
# Apply any required transformations to the data in pandas
|
49 |
+
smooth_data = approval_df2.sort_values('timestamp').rolling(window=moving_av_window, on='timestamp', center=True).mean().shift(-moving_av_window+1)
|
50 |
|
51 |
chart_data = approval_df2.sort_values('timestamp').copy()
|
52 |
|