CACloudNumber
Configuration Options
chartName
Type: string
Default: CACloudNumber
Name of chart for reporting
fontSize
Type: number
Default: 48
Units: px
Font size of the text
height
Type: number
Default: 250
Height of the chart
indicatorColor
Type: color
Default: #73B0D7
Text color of the number
postfixString
Type: string
Default: %
Suffix to be appended to the end of the number
prefixString
Type: string
Default: ``
Prefix to be appended to the front of the number
shouldValidate
Type: boolean
Default: true
Flag for turning off data validation.
textFontFamily
Type: string
Default: Open Sans
Font family for any text.
updateSizeableConfigs
Type: boolean
Default: true
Flag for turning off the mimic of illustrator's scale functionality.
width
Type: number
Default: 250
Width of the chart
Data Definition
Date
Type: date
Default validate:
function (d) { return new Date(this.accessor(d)) !== 'Invalid Date'; }
Default accessor:
function (line) { return line[2]; }
Label
Type: string
Default validate:
function (d) { return this.accessor(d) !== undefined; }
Default accessor:
function (line) { return line[0] === undefined ? undefined : String(line[0]); }
Value
Type: number
Default validate:
function (d) { return !isNaN(this.accessor(d)) && this.accessor(d) >= 0; }
Default accessor:
function (line) { return Number(line[1]); }
Events
Dispatch Events
External Events
Example
//Setup some fake data
var data = [
['Name', 45]
];
//Initialze the widget
var chart = d3.select("#vis")
.select('svg')
.append("g")
.attr('transform', 'translate(250,264)')
.chart("CACloudNumber")
.c({
width: 183,
height: 104
});
//Render the chart with data
chart._notifier.showMessage(true);
chart.draw(data);