MapInfo Pro

 View Only
  • 1.  MapBasic Tool of the Week: Spider Graph

    Posted 06-19-2019 20:06
    Edited by Tony Maber 08-05-2019 02:48

    SPIDER GRAPH is used to map relationships between tables based on a designated field in MapInfo Pro. By joining the tables based on the designated field, MapInfo Pro then creates a new table of lines that connect the objects from the original tables based on this join – effectively "connecting the dots".


    The Spider Graph tool provides visual and analytic insight in your data.  The table developed as a result of using the Spider Graph tool contains the lines linking locations as well as chosen attributes from the input table(s) and a column that stores the length of each line.

     Examples of applying the Spider Graph tool could include creating links between:

    • customers and stores they visit;
    • warehouses and delivery locations;
    • mobile phones and telecom antennas;
    • crimes scenes and possible offenders;
    • postcode centroids (as part of sales territories) to branch offices;
    • where students are going to school or patients are going to hospitals; and
    • vehicle theft and recovery locations.



    To demonstrate to power of the Spider Graph tool, we will look at the business problem of customers and stores.  In this case, there are 1,514 customers from a membership database whose closest location to shop is one of the 6 stores shown.  These are presented in the map below – customers as red dots and stores as blue diamonds.

    Customer & Store map

    Our customer data contains attribute fields relating to purchase history, geo-demographic segmentation using CAMEO, closest store, distance to closest store and the customers preferred store.    The closest store analysis was completed using the Distance Calculator tool in MapInfo Pro which was a previously highlighted in the MapInfo Pro section on Knowledge Communities (Distance Calculator).

    Data View

    Using the "PreferredStore" attribute, we will be able to determine travel distance comparisons and analyse other attributes for the customer group that not shop at their closest store using the Spider Graph tool.

     The first step is to load the Spider Graph tool using the Tool Manager. Next, you access the Spider Graph dialog box as follows: 
    SG dialogThe Spider Graph dialog box will then appear.  For this example, the customer table is chosen as the origin and the stores table is chosen as the destination.  The attribute field in both tables that contains the data on which to join the tables is selected in each case.  The attribute fields available from both tables are shown on the R/H side of the dialog and allows users to determine which attributes they would like to have returned with the line linking both objects.

    Selecting key attributes here allows for further analysis on records.  For example, what CAMEO Groups are most represented in those records where customers choose not to shop at their closest store OR what is the average distance customers travel to their preferred store compared to the average distance to their closest store.
    SG dialog complete

    In the example above, I have chosen not to colour code the resulting lines linking the points (this can be done on the lines at any stage later using any of the attributes returned).  I have chosen the distance unit to be used (kilometres) and also ticked the option to add a field with the line distance.

    Once satisfied with the selections in the Spider Graph dialog, click on "Create Lines" to generate the outcome.  If a map window is active the results will be displayed in this window, otherwise a new map window will be presented containing the Spider Graph results generated.

    In our example, the map and browser resulting from the running of the Spider Graph tool are shown below.
    SG MapSG Browser


    A quick review of these Spider Graph results revealed some actionable insights about the customer base involved in the study.  Some of these insights include:

    • 345 (22.8%) of customers shop at stores which are not their closest store
    • 8% of these customers are in the top 2 CAMEO Groups (which is significantly higher than the sample from all 1,514 customers used in the study at 67.3%) – this may indicate a propensity for more affluent customers to be more selective about where they shop or have reason to shop at stores other than for convenience (eg. closer to work, major shopping mall vs neighbourhood strip shops, etc)
    • The 345 customers that did not shop at their closest store chose to travel an extra 57.3% further to shop at their preferred store

    The final map image below uses green dots to represent customers that shop at their closest store and red dots to represent those customers that did not.  This visual insight allows users to look for trends or reasons (geographic barriers, infrastructure influence, movement pattern in toward city, etc) that may be influencing the customer behaviour.

    So, in a very short space of time, MapInfo Pro and the Spider Graph tool have delivered visual and analytical insights based on the relationship between two datasets.

    We would love to hear how MapInfo Pro users have applied the Spider Graph tool in solving problems.  Or please feel free to let us know what your favourite MapInfo Pro MBX is.

    This was another article in the MapBasic Tool of the Week #series.

    Tony Maber
    Location Analytics & Data - PreSales
    Pitney Bowes
    Sydney - Australia

  • 2.  RE: MapBasic Tool of the Week: Spider Graph

    Posted 06-24-2019 19:09
    Edited by Kalu Ribush 06-25-2019 03:05
    We use the Spider Graph tool quite often, but usually in a slightly different way to the cases illustrated above.

    It's very useful for creating links between geographic areas from a matrix of data, such as travel demand (observed of modelled journeys between locations).

    The map below is an example of demand between local government areas (LGAs). The circular arrows illustrate internal demand within the LGA.

    Note - I've blurred the actual values on this map.

    This is just one map in a series of maps.  We can also create maps showing demand by transport mode (public transport vs private vehicle), and by different forecast years.  This really helps us visualise and understand how demand on the network will change in the future.

    Kalu Ribush
    Senior Mapping Specialist
    Department of Economic Development, Jobs, Transport and Resources (DEDJTR)
    Melbourne NT

  • 3.  RE: MapBasic Tool of the Week: Spider Graph

    Posted 06-24-2019 19:21
    Hi Kalu.
    Thanks for sending through this tremendous example of how spider graph can be applied.  The thematic colouring and thickness of the lines can produce a very visually informative presentation of complex data and relationships.

    As per the examples I listed in the article, there are many and varied uses for this tool which can deliver benefit to organisations of all kinds.

    Appreciate you sharing your use case.  Any others out there that people would like to share?

    Tony Maber
    Location Analytics & Data - PreSales
    Pitney Bowes
    Sydney - Australia