Spatial proximity based clustering of customers

Providing a coding example for how to conduct spatial proximity customer clustering, applicable e.g. when searching for multiple centers of gravity (i.e. when wanting to locate multiple warehouses). The logic and approach is the same as in any kind of distance based clustering problem. I willk apply k-means clustering for grouping customers based on their spatial distance. […]

Geocoding spatial data with tidygeocoder in R

In previous posts I have demonstrated how to geocode location strings using the Open Street Map API in two different ways. The first approach was to implement a function that sents a string to the OSM API directly, using http. The API then returns spatial coordinates in json-format. The second approach was to use the […]

Spatial SCM data visualisation in R

In this post I want to provide a brief overview of useful packages in R for visualizing spatial data in R. The packages discussed are webglobe, deckgl, ggmap, ggplot2 and Leaflet. webglobe The webglobe package allows you to create e.g. bar charts on a 2D or 3D map. You can view your visualisation in your […]