text: var visualize=function(e,t,o,a){var l=t.qInfo.qId+"_chartjs_stacked_bar",i=a.calculateMargin(e,t),r=i[0],s=i[1];e.html('<canvas id="'+l+'" width="'+r+'" height="'+s+'"></canvas>');var n=[];n="auto"==t.colors?a.defineColorPalette(t.color_selection):t.custom_colors.split("-");var c=t.qHyperCube.qDataPages[0].qMatrix,u=a.flattenData(c),d=u[0],m=u[1],v=u[2];t.sort&&m.sort();var h=_.groupBy(d,"dim1"),p=[];p.dim1=[],p.dim1_elem=[],p=a.initializeArrayWithZero(_.size(h),m,p),p=a.storeHypercubeDataToArray(h,p),t.cumulative&&(p=a.addCumulativeValuesOnTwoDimensions(m,p));for(var g=[],b=0;b<m.length;b++){var f=[],y=b;"auto"==t.colors&&"twelve"==t.color_selection?y=b%12:"auto"==t.colors&&"one-handred"==t.color_selection?y=b%100:"custom"==t.colors&&(y=b%n.length),f.label=m[b],f.backgroundColor="rgba("+n[y]+","+t.opacity+")",f.data=p[m[b]],f.fill=t.background_color_switch,f.borderColor="rgba("+n[y]+","+t.opacity+")",f.pointBackgroundColor="#FFFFFF",f.pointRadius=t.point_radius_size,g.push(f)}var k={labels:p.dim1,datasets:g},C=document.getElementById(l);new Chart(C,{type:"radar",data:k,options:{title:{display:t.title_switch,text:t.title},legend:{display:"hide"!=t.legend_position,position:t.legend_position,onClick:function(e,t){var a=[],l=1;v[t.text]<0||(a.push(v[t.text]),o.selectValues(l,a,!0))}},scale:{ticks:{beginAtZero:!0,callback:function(e,o,l){return a.formatMeasure(e,t,0)}}},tooltips:{mode:"label",callbacks:{label:function(e,o){return o.datasets[e.datasetIndex].label+": "+a.formatMeasure(e.yLabel,t,0)}}},responsive:!0,events:["mousemove","mouseout","click","touchstart","touchmove","touchend"],onClick:function(e){var t=this.getElementsAtEvent(e);t.length>0&&a.makeSelectionsOnDataPoints(p.dim1_elem[t[0]._index],o)}}})};