The following external libraries are used to create this visualisation:
Papa Parse to parse the data from csv to json Wicket to transform the coordinates from WKT to json objects containing lat and lon Leaflet for the map Mapbox.directions for calculation of routes between the points L.OverPassLayer for external data via Overpass API Leaflet.markercluster for cluster markers at same location D3 for the interactive visualisation Bootstrap for a responsive layout
The page was tested in Chrome, Safari, and Firefox as well as on Android. Some bugs are known and not yet fixed:
- zoom to selected route does not work, nor zoom to FeatureGroup with directions layer. Uncaught TypeError: e.getBounds is not a function
- time line does not scale correctly on small screens
- CRS won't fit when using EPSG:4326 and WMS layer
- after filtering all routes could show up for that time slot
- select multiple markers at once to show all their routes
- bounce corresponding directions marker on hover
- buttons to change routing profile (driving / cycling / walking) - or maybe show strait lines without routing
- routes along same street to add up stroke width instead of overlapping each other
- use distance for further analysis: how far do people travel?
- check out Crossfilter for fast filtering of large datasets
The file searches.csv contains a random selection of route searches done by users in Berlin on one day.