bestroi commited on
Commit
79c09ca
·
1 Parent(s): 5e1c778

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -33,6 +33,10 @@ def visualize_data(csv_file, sort_entries=False):
33
  # Basic statistics
34
  lemma_stats = data.groupby('Lemma').agg({'Context': 'count', 'Token_Count': 'mean'}).reset_index()
35
 
 
 
 
 
36
  # Bar chart for lemma frequency using Plotly Express
37
  fig_bar = px.bar(
38
  lemma_stats,
@@ -46,10 +50,6 @@ def visualize_data(csv_file, sort_entries=False):
46
  # Display the bar chart using st.plotly_chart()
47
  st.plotly_chart(fig_bar)
48
 
49
- # Display basic statistics
50
- st.write("Basic Statistics:")
51
- st.write(lemma_stats)
52
-
53
  # Additional Visualization
54
  # Basic statistics for additional data
55
  lemma_stats_additional = data['Lemma'].value_counts().reset_index()
 
33
  # Basic statistics
34
  lemma_stats = data.groupby('Lemma').agg({'Context': 'count', 'Token_Count': 'mean'}).reset_index()
35
 
36
+ # Display the basic statistics using st.table()
37
+ st.write("Basic Statistics:")
38
+ st.table(lemma_stats)
39
+
40
  # Bar chart for lemma frequency using Plotly Express
41
  fig_bar = px.bar(
42
  lemma_stats,
 
50
  # Display the bar chart using st.plotly_chart()
51
  st.plotly_chart(fig_bar)
52
 
 
 
 
 
53
  # Additional Visualization
54
  # Basic statistics for additional data
55
  lemma_stats_additional = data['Lemma'].value_counts().reset_index()