Project detail

Project detail

SafePath

A data product that recommends the safest route to walk between two points in London based on one year of Met Police data

Data Product

2 months

2024

R - R Shiny

Objective:

This project focuses on developing a data product that aids users in navigating London safely by optimizing routes based on real-time and historical crime data. The system integrates descriptive, predictive, and prescriptive analytics to provide actionable insights for route safety, emphasizing user interactivity, efficiency, and scalability.

Key Design Features:

  1. Interactive Map-Based Interface:

    • Users can input start and end locations, visualizing multiple routes overlaid on a map styled with CartoDB Positron tiles.

    • A heatmap highlights high-crime areas for situational awareness.

  2. Safety Scoring:

    • Routes are ranked based on a safety score that incorporates crime proximity, recency, and severity.

    • Spatial operations using sf ensure efficient geospatial processing.

  3. Real-Time Data Integration:

    • The system fetches route data dynamically via the OpenRouteService API.

    • Crime data is processed monthly, ensuring up-to-date insights.

  4. Dynamic Visualizations:

    • Heatmaps, route polylines, and interactive tables present data intuitively.

    • Color-coded routes and pop-ups provide detailed route summaries, including distance, duration, and safety scores.

  5. Scalability:

    • Modular design allows adaptation to other cities or datasets with minimal changes.

    • Efficient spatial joins and buffered operations ensure performance with large datasets.

Design Process:

  1. Requirement Analysis:

    • Identified user needs: safety prioritization, route visualization, and ease of use.

    • Defined goals for interactivity and efficiency.

  2. Data Acquisition and Preprocessing:

    • Crime datasets from multiple months were merged and cleaned, retaining relevant columns (Month, Latitude, Longitude, Crime type).

    • Recency weights were computed for predictive analytics.

  3. Back-End Development:

    • Implemented geospatial operations using sf for proximity analysis and risk scoring.

    • API integration with OpenRouteService to fetch routing data and provide alternative paths.

  4. Front-End Development:

    • Designed an intuitive Shiny interface with responsive elements.

    • Interactive features include search inputs, dynamic tables, and map overlays (heatmaps, routes).

  5. Testing and Validation:

    • Validated accuracy of safety scores and ensured robustness against edge cases (e.g., missing data).

    • Performance optimized for real-time updates with large datasets.

  6. Deployment:

    • The modular structure ensures easy deployment and adaptability to other regions or environments.

Mettalic shape background image

Contact

Let's Get in Touch

Let's connect and get to know each other.

Mettalic shape background image

Contact

Let's Get in Touch

Let's connect and get to know each other.

Mettalic shape background image

Contact

Let's Get in Touch

Let's connect and get to know each other.