vgosavi2 commited on
Commit
bc4ed7b
·
verified ·
1 Parent(s): f00a29c

Update src/streamlit_app.py

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +11 -7
src/streamlit_app.py CHANGED
@@ -51,12 +51,17 @@ design targeted strategies to improve public safety.</div>""",unsafe_allow_html=
51
  # 2. Data info & load
52
  st.markdown("<div class='sectionheader'> Dataset Information </div>", unsafe_allow_html=True)
53
  st.markdown(
54
- """ <div class='description'>
55
- - **Source:** LAPD crime incidents dataset
56
- - **Rows:** incidents (one per row)
57
- - **Columns:** e.g. `crm_cd_desc` (crime type), `arrest` (boolean), `date`, `location_description`, etc.
58
- - **Purpose:** Interactive exploration of top crime categories and arrest rates.</div>
59
- """
 
 
 
 
 
60
  )
61
 
62
  # 1. Resolve the path to the CSV next to this script
@@ -77,7 +82,6 @@ if df.empty:
77
 
78
  # 3. Data preview
79
  st.markdown("<div class='sectionheader'> Data Preview </div>", unsafe_allow_html=True)
80
- st.write(f"Total records: {df.shape[0]} | Total columns: {df.shape[1]}")
81
  st.markdown(
82
  f"<div class='description'>"
83
  f"Total records: <strong>{df.shape[0]:,}</strong> &nbsp;|&nbsp; "
 
51
  # 2. Data info & load
52
  st.markdown("<div class='sectionheader'> Dataset Information </div>", unsafe_allow_html=True)
53
  st.markdown(
54
+ """
55
+ <div class="description">
56
+ <ul>
57
+ <li><strong>Source:</strong> LAPD crime incidents dataset</li>
58
+ <li><strong>Rows:</strong> one incident per row</li>
59
+ <li><strong>Columns:</strong> e.g. <code>crm_cd_desc</code> (crime type), <code>arrest</code> (boolean), <code>year</code>, <code>location_description</code>, etc.</li>
60
+ <li><strong>Purpose:</strong> Interactive exploration of top crime categories and arrest rates.</li>
61
+ </ul>
62
+ </div>
63
+ """,
64
+ unsafe_allow_html=True
65
  )
66
 
67
  # 1. Resolve the path to the CSV next to this script
 
82
 
83
  # 3. Data preview
84
  st.markdown("<div class='sectionheader'> Data Preview </div>", unsafe_allow_html=True)
 
85
  st.markdown(
86
  f"<div class='description'>"
87
  f"Total records: <strong>{df.shape[0]:,}</strong> &nbsp;|&nbsp; "