Gio.js
Getting Start
Gio.js 2.0
Basic Elements
Configuration
Object Design API
Color and Style API
Working with Data
Callback
Dependence Interface
Advanced Feature
set line color from data
As mentioned in line section, there are two types of lines: in line and out line. The colors associated with these two types of lines are called inColor and outColor. Each line can have a unique color specified through the input data as follows:
[
        {
                "e": "CN",
                "i": "US",
                "v": 100000,
                "inColor": "#0000FF",
                "outColor": "#00FF00"
        },
        {
                "e": "CN",
                "i": "RU",
                "v": 3000000,
                "inColor": "#EE0E00",
                "outColor": "#FFFF00"
        }
]
Note: e, i, and v have the same definition as in addData.