hyzhang00 commited on
Commit
0014df0
·
verified ·
1 Parent(s): a76acf8

add conclusion

Browse files
Files changed (1) hide show
  1. app.py +45 -3
app.py CHANGED
@@ -354,7 +354,7 @@ def main():
354
 
355
 
356
  st.markdown("""
357
- ### Introduction to the Traffic Accident Dataset
358
  This dataset contains detailed information about traffic accidents in the city of **Tempe**. It includes various attributes of the accidents, such as the severity of injuries, the demographics of the drivers involved, the locations of the incidents, and the conditions at the time of the accidents. The dataset covers accidents that occurred over several years, with data on factors like **weather conditions**, **road surface conditions**, the **time of day**, and the type of **violations** (e.g., alcohol or drug use) that may have contributed to the accident.
359
 
360
  The data was sourced from **Tempe City's traffic incident reports** and provides a comprehensive view of the factors influencing road safety and accident severity in the city. By analyzing this dataset, we can gain insights into the key contributors to traffic incidents and uncover trends that could help improve traffic safety measures, urban planning, and law enforcement policies in the city.
@@ -597,7 +597,7 @@ def main():
597
  st.markdown("---")
598
 
599
  # Add TODO section title
600
- st.markdown("## To-Do List for Part 3")
601
  st.markdown("For the final project part 3, we plan to create two pairs of linked interactive visualizations for analyzing traffic accident data as follows:")
602
 
603
  # Create two columns
@@ -642,7 +642,49 @@ def main():
642
  - Clear interaction instructions
643
  - Display of applied filters
644
  """)
645
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
646
 
647
 
648
  if __name__ == "__main__":
 
354
 
355
 
356
  st.markdown("""
357
+ # Introduction to the Traffic Accident Dataset
358
  This dataset contains detailed information about traffic accidents in the city of **Tempe**. It includes various attributes of the accidents, such as the severity of injuries, the demographics of the drivers involved, the locations of the incidents, and the conditions at the time of the accidents. The dataset covers accidents that occurred over several years, with data on factors like **weather conditions**, **road surface conditions**, the **time of day**, and the type of **violations** (e.g., alcohol or drug use) that may have contributed to the accident.
359
 
360
  The data was sourced from **Tempe City's traffic incident reports** and provides a comprehensive view of the factors influencing road safety and accident severity in the city. By analyzing this dataset, we can gain insights into the key contributors to traffic incidents and uncover trends that could help improve traffic safety measures, urban planning, and law enforcement policies in the city.
 
597
  st.markdown("---")
598
 
599
  # Add TODO section title
600
+ st.markdown("# To-Do List for Part 3")
601
  st.markdown("For the final project part 3, we plan to create two pairs of linked interactive visualizations for analyzing traffic accident data as follows:")
602
 
603
  # Create two columns
 
642
  - Clear interaction instructions
643
  - Display of applied filters
644
  """)
645
+ st.markdown("---")
646
+
647
+ # Add conclusion section
648
+ st.markdown("# FP2 Conclusion")
649
+
650
+ st.markdown("""
651
+ In FP2, we created interactive visualizations to analyze traffic accident data, focusing on trends, contributing factors, and safety implications.
652
+ Each visualization provides specific insights and helps users make data-driven decisions to improve road safety.
653
+ """)
654
+
655
+ # Create columns for different visualizations' conclusions
656
+ con1, con2, con3 = st.columns(3)
657
+
658
+ with con1:
659
+ st.markdown("""
660
+ ### Crash Trend Over Time
661
+ An interactive line chart showing annual crash patterns with an optional weather filter, helping identify:
662
+ * Long-term accident trends
663
+ * Weather-related correlations
664
+ * Seasonal patterns in crash frequencies
665
+ * Peak accident periods
666
+ """)
667
+
668
+ with con2:
669
+ st.markdown("""
670
+ ### Severity of Violations Across Age Groups
671
+ Visualizes crash severities by violation types and driver age groups:
672
+ * Age-specific violation patterns
673
+ * High-risk behavior identification
674
+ * Severity distribution analysis
675
+ * Targeted intervention opportunities
676
+ """)
677
+
678
+ with con3:
679
+ st.markdown("""
680
+ ### Distribution of Incidents
681
+ A comprehensive analysis of incidents by various factors:
682
+ * Collision manner analysis
683
+ * Surface condition impacts
684
+ * Gender-based patterns
685
+ * Environmental factor effects
686
+ * Time-based distribution
687
+ """)
688
 
689
 
690
  if __name__ == "__main__":