# 시리즈 관련기능 3 (chartSkill)

> 시리즈 관련기능 `막대 그라데이션` 을 구현 할 수 있습니다.

### Example

    var LightenColor = function (color, percent) {
      var num = parseInt(color.replace("#",""), 16),
      amt = Math.round(2.55 * percent),
      R = (num >> 16) + amt,
      B = (num >> 8 & 0x00FF) + amt,
      G = (num & 0x0000FF) + amt;

        return "#" + (0x1000000 + (R < 255 ? R < 1 ? 0 : R : 255) * 0x10000 + (B < 255 ? B < 1 ? 0 : B : 255) * 0x100 +)
      (G < 255 ? G < 1 ? 0 : G : 255)).toString(16).slice(1);
    };

    var defaultColors = myChart.getOptions().colors; //기본 컬러 값
    var gradientColors = [];

    for(var i =0; i < defaultColors.length; i++){
      gradientColors[i] = {
        radialGradient: {
          cx: 0.5,
          cy: 0.3,
          r: 0.7
        },
        // 그라데이션 단계
        stop: [
          [0, defaultColors[i]],
          [1, LightenColor(defaultColors[i], 30)] //brighton
        ]
      }
      myChart.setOptions({
        colors: gradientColors,
        chart: {
        type: 'column',
                plotBorderColor: '#346691',
                plotBorderWidth: 2
        },
            xAxis: {
            categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct','Nov', 'Dec']
        },
        series: [{
            data: [29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4]
        }]
        }, {
        append: true,
        redraw: true
      }
    );

### Since

version | desc
--- | ---
7.3.0.0 |