A radar chart visualizes multivariate data in a 2D chart of three or more quantitative variables represented on axes.
The project is created using AngularJS and D3.js.
This is a variation of the original and improved D3 radar chart.
Major improvements include:
levels
, labels
, axes
, polygons
, legend
), which now can be controlled through the config
object.Use the configuration parameters to adjust the plot to your tastes, and you can also choose to view the plots stacked vs facetted.
The data input has to be a 4-column CSV (headers MUST be included) conforming to the data schema of:
group (int/string)
: data to be grouped into an object to plot the required polygon on the radar chart.
axis (int/string)
: the axis of the radar charts (dimensions of the multivariate data).
value (int)
: the data value of the given record.
description (int/string)
: not a mandatory field, and additional columns after this are accepted as well.
All D3 logic is contained in the radar.js
file. You should be able to look at just this file if you intend to use the
visualization logic without AngularJS.
index.html
: Main HTML file.
app.js
: AngularJS core logic to connect Javascript components and D3 visualization updates with user interactions. The
directive onReadFile
handles file uploads and the directive radar
draws the D3 visualization.
radar.js
: All D3 logic is contained in this file. You should use this file if you are looking solely to use D3 without
AngularJS.
radarDraw.js
: This is the directive-link function called by the AngularJS directive radar
in app.js
. Funnels the dataset
from the angular app into the D3 drawing logic called from radar.js
.
style.css
: stylesheet containing optional D3 classes that can be adjusted (commented out)
data.csv
: Three CSV-data files for sample downloads and uploads to the app.
$scope.$watch
. Not too familiar on resolving these issues.FileReader
.Modified http://code.angularjs.org/1.3.5/angular.js to a secure url
Modified http://d3js.org/d3.v3.min.js to a secure url
https://code.angularjs.org/1.3.5/angular.js
https://d3js.org/d3.v3.min.js