JavaScript
FusionCharts.ready(function() {
var mapDataSource = {
"chart": {
"caption": "Top 10 Revenue earning US states",
"subcaption": "Last Year",
"entityFillColor": "#cccccc",
"entityFillHoverColor": "#666666",
"numberPrefix": "$",
"showLabels": "1",
"useSNameInLabels": "0",
"theme": "fint"
},
"colorrange": {
//"minvalue": "0",
//"startlabel": "Low",
//"endlabel": "High",
//"code": "#e44a00",
//"gradient": "0",
"color": [{
"minValue": "0",
"maxvalue": "25",
"displayvalue": "Bad",
"code": "#FF0000"
}, {
"minValue": "25",
"maxvalue": "50",
"displayvalue": "Average",
"code": "#FFFF00"
}, {
"minValue": "50",
"maxvalue": "100",
"displayvalue": "Average",
"code": "#00FF00"
}]
},
"data": [{
"id": "HI",
"value": "40",
"showLabel": "0"
}, {
"id": "DC",
"value": "50",
"showLabel": "0"
}, {
"id": "MD",
"value": "30",
"showLabel": "0"
}, {
"id": "DE",
"value": "70",
"showLabel": "0"
}, {
"id": "RI",
"value": "80",
"showLabel": "0"
}, {
"id": "WA",
"value": "47",
"showLabel": "0"
}, {
"id": "OR",
"value": "50",
"showLabel": "0"
}, {
"id": "CA",
"value": "45",
"showLabel": "0"
}, {
"id": "AK",
"value": "20",
"showLabel": "0"
}, {
"id": "ID",
"value": "25",
"showLabel": "0"
}, {
"id": "NV",
"value": "146",
"showLabel": "0"
}, {
"id": "AZ",
"value": "90",
"showLabel": "0"
}, {
"id": "MT",
"value": "110",
"showLabel": "0"
}]
};
retrieve(mapDataSource);
var salesByState = new FusionCharts({
type: 'usa',
renderAt: 'chart-container',
width: '600',
height: '500',
...