Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -79,9 +79,9 @@ def create_dashboard(data):
|
|
| 79 |
|
| 80 |
with col2:
|
| 81 |
# Event Types Distribution
|
| 82 |
-
event_counts = data['events']['
|
| 83 |
-
event_counts.columns = ['Event', '
|
| 84 |
-
fig = px.pie(event_counts, names='Event', values='
|
| 85 |
title='Event Type Distribution')
|
| 86 |
st.plotly_chart(fig, use_container_width=True)
|
| 87 |
|
|
|
|
| 79 |
|
| 80 |
with col2:
|
| 81 |
# Event Types Distribution
|
| 82 |
+
event_counts = data['events']['Order Value $'].sum().reset_index()
|
| 83 |
+
event_counts.columns = ['Event', 'Order Value $'] # Rename columns explicitly
|
| 84 |
+
fig = px.pie(event_counts, names='Event', values='Order Value',
|
| 85 |
title='Event Type Distribution')
|
| 86 |
st.plotly_chart(fig, use_container_width=True)
|
| 87 |
|