Chart is the generic component used for any chart type
- Source:
Methods
(static) addTooltip(d, e)
Adds a tooltip to the SVG
Parameters:
Name | Type | Description |
---|---|---|
d |
Object | dataset |
e |
Object | event x and y coordinates |
- Source:
(static) clearAxis()
Remove x and y axes
- Source:
(static) clearCanvas()
Remove all content from the SVG
- Source:
(static) dim() → {string}
Dimension getter function
- Source:
Returns:
dim
- Type
- string
(static) displayHeight() → {number}
Gets the height of the dispaly area
- Source:
Returns:
Height of the chart display
- Type
- number
(static) drawGrid()
Redraw the Chart when the data is recycled
- Source:
(static) drawTitle()
Appends title and subtitle to the chart
- Source:
(static) ds() → {Object}
Dataset getter function
- Source:
Returns:
normalized dataset
- Type
- Object
(static) generateAxisLabels(cs)
Generate Axis Lables
Parameters:
Name | Type | Description |
---|---|---|
cs |
Object | configuration of the coordinate system |
- Source:
(static) generateGoal(cs)
Generate Goal
Parameters:
Name | Type | Description |
---|---|---|
cs |
Object | configuration of the coordinate system |
- Source:
(static) generateLegend(cs)
Generate legend if option -legends- defined as true
Parameters:
Name | Type | Description |
---|---|---|
cs |
Object | configuration of the coordinate system |
- Source:
(static) goal() → {number}
Goal getter function
- Source:
Returns:
Goal
- Type
- number
(static) gridTicks() → {number}
Grid Tick getter function
- Source:
Returns:
gridTicks
- Type
- number
(static) header() → {number}
Gets the combined height of the title and subtitle
- Source:
Returns:
Total header height
- Type
- number
(static) height() → {number}
Height getter function
- Source:
Returns:
Chart Height
- Type
- number
(static) initalizeChart()
Generate a new Chart of type chartType
- Source:
(static) max() → {number}
Get the maxium value for metric
- Source:
Returns:
Max value for metric
- Type
- number
(static) maxTriplet() → {Array}
Get the maxium value for triplet
- Source:
Returns:
Max values for triplet
- Type
- Array
(static) metric() → {array}
Metric getter function
- Source:
Returns:
Metrics
- Type
- array
(static) metricAsArray() → {Array}
get the values of a metric as an array
- Source:
Returns:
metric values
- Type
- Array
(static) min() → {number}
Get the minimum value for dataset
- Source:
Returns:
Min value for metric
- Type
- number
(static) minTriplet() → {Array}
Get the minimum value for triplet
- Source:
Returns:
Min values for triplet
- Type
- Array
(static) refreshChart()
Redraw the Chart when the data is recycled
- Source:
(static) removeTooltip(d)
Removes all tooltips from the SVG
Parameters:
Name | Type | Description |
---|---|---|
d |
Object | dataset |
- Source:
(static) subtitleHeight() → {number}
Gets the subtitle height
- Source:
Returns:
Height of chart subtitle
- Type
- number
(static) titleHeight() → {number}
Gets the height of the title
- Source:
Returns:
Height of the chart title
- Type
- number
(static) width() → {number}
Width getter function
- Source:
Returns:
Chart width
- Type
- number