Skip to content

Dashboard Architecture

Alberto Cottica edited this page Dec 4, 2015 · 4 revisions

The Edgesense architecture The current incarnation of the edgesense SNA tool is made up of three components:

  • website APIs to query the database and return source json files. In Drupal these are provided by the Views and Views JSON modules.
  • a python script used to build the network from the source json files and to compute all the metrics. This script is contained in the python directory (it is build_network.py). It uses the networkX library for handling graphs.
  • a single-page HTML5/javascript application that reads the json produced by the python script and builds a dashboard with the visualization of the network and the metrics. It uses the sigma.js and D3 library for graph and non-graph data visualizations respectively.

N.B. both the python script and the dashboard should be on the same machine, but they can be on a different host from the one where the community is hosted provided that the community host has made the JSON files available for download (they can be password protected, and should be accessible only over https.)

The process to populate the dashboard is the following:

  1. the views to dump the JSON for the users,nodes and comments are created in the community sites
  2. the build_network script is scheduled to be run at regular intervals, the paths or URLs to the json files are passed to the script with all the other parameters needed to generate the network and calculate the metrics.
  3. the configuration.json file is created with the analytics tracking id, and the dashboard name to use (and eventually the endpoint for the tutorial results upload).
  4. when a user opens the dashboard page the javascript code in the page populates the visualization:
  5. the configuration.json file is read from the server and used to set the dashboard title and activate the analytics tracking
  6. the help.json file is read from the server and used to populate the dashboard contextual help
  7. the latest.json file is read from the server and with the information provided there the processed data is read
  8. the json containing the processed data is used to setup the dates range to be shown and the latest metrics are shown
  9. the json containing the processed data is used to populate the network graph
  10. all the dashboard controls (filters, time slider, ...) are activated

When the dashboard is running, each user interaction with the time slider or with the filters results in the following events:

  1. the current view-date is updated
  2. the metrics corresponding to the current view-date are extracted from the processed data
  3. the network is updated by showing only the elements that are valid at the current view-date selected
  4. the graphs are updated to show the current metrics

The user can also access an interactive tutorial from a link in the top-right of the page. A moderator of this community (or any user who has access to the dashboard) can follow the interactive tutorial to gain confidence with the tool interface, and most importantly start to learn how to interpret some of the social network analytics exposed by the metrics. Each tutorial step will ask a question that addresses a concrete problem that an administrator might have. Under each question a hint is shown, with information about how to use the EdgeSense interface to answer the question.