Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -89,17 +89,14 @@ def visualize_data(csv_file, sort_entries=False):
|
|
89 |
|
90 |
# Expandable section to display context
|
91 |
with st.expander("Click to view context"):
|
92 |
-
# Display context for each entry using
|
93 |
-
|
|
|
|
|
|
|
|
|
|
|
94 |
|
95 |
-
fig_table = go.Figure(data=[go.Table(
|
96 |
-
header=dict(values=['<b>Lemma</b>', '<b>Book/Chapter</b>', '<b>Context</b>']),
|
97 |
-
cells=dict(values=table_values)
|
98 |
-
)])
|
99 |
-
|
100 |
-
st.plotly_chart(fig_table)
|
101 |
-
|
102 |
-
# Main Streamlit app
|
103 |
def main():
|
104 |
st.title("Lemma Frequency Visualization")
|
105 |
|
|
|
89 |
|
90 |
# Expandable section to display context
|
91 |
with st.expander("Click to view context"):
|
92 |
+
# Display context for each entry using st.write
|
93 |
+
for _, row in data.iterrows():
|
94 |
+
st.write("### Entry")
|
95 |
+
st.write(f"**Lemma:** {row['Lemma']}")
|
96 |
+
st.write(f"**Book/Chapter:** {row['Book/Chapter']}")
|
97 |
+
st.write(f"**Context:** {row['Context']}")
|
98 |
+
st.write('-' * 50)
|
99 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
100 |
def main():
|
101 |
st.title("Lemma Frequency Visualization")
|
102 |
|