title: How to set color of each slice in pie chart in high charts library?
body: <p>I am making pie chart from high chart library. I want to change color of each slice in pie chart
  How can i do this ? My code is - </p>
  
  <pre><code>var colors = ["color:'#2a8482'","color:'#64DECF'","color:'#BCCDF8'"]; 
  var responseData = {"2":40,"1":30}
  var obj =  $.parseJSON(responseData);
               var dataArrayFinal = Array();
               var value = Array();
               var name = Array();
               var j = 0;
               for (var key in obj) {
                    if (obj.hasOwnProperty(key)) {
                        name[j] =  "name:'"+key+"'";
                        value[j] = obj[key];
                        j++;
                    }
               }
  
               for(k=0;k&lt;name.length;k++) { 
                     var temp = new Array(name[k],value[k],colors[k]); 
                     dataArrayFinal[k] = temp;     
               }
  
              $(function () {
  
                  new Highcharts.Chart({
                      chart: {
                          renderTo: 'container'+counter,
                          type: 'pie',
                          height: 280,
                          width: 280
                      },
                      title: {
                          text: ' '
                      },
                      tooltip: {
                          valueSuffix: '%',
                          positioner: function () {
                              return {
                                  x: this.chart.series[0].center[0] -
                                     (this.label.width / 2) + 8,
                                  y: this.chart.series[0].center[1] -
                                     (this.label.height / 2) + 8
                              };
                          }
                      },
                      series: [{
                          name: 'Answer',
                          size: '100%',
                          innerSize: '65%',
                          data: dataArrayFinal
                      }]
                  });
              });
  </code></pre>
  
  <p>In this graph is coming but colors are not changed. They are taking default color.</p>
  
  <p><img src="https://i.stack.imgur.com/AGPOv.png" alt="enter image description here"></p>