score:1

Accepted answer

this is where you create your data array:

        pnldata.push([
            data[i][0], // the date
            data[i][2] // cumulativepnl  data[i][1] is the day's pnl
        ]);

you need to change from array to object, so you will be able to set individual color, for example:

        pnldata.push({
            x: data[i][0], // the date
            y: data[i][2], // cumulativepnl  data[i][1] is the day's pnl
            color: 'somecolor'
        });

Related Query

More Query from same tag