/* Highcharts JS v3.0.10 (2014-03-10) (c) 2009-2013 Torstein Hønsi License: www.highcharts.com/license */ (function(c){function v(e,a,b,d){b*=q;a*=q;var g=[],l,h,f;b*=-1;l=d.x;h=d.y;f=d.z===0?1.0E-4:d.z*100;var j=i(b),n=k(b),u=i(a),w=k(a),s,m,r,o;c.each(e,function(a){s=a.x-l;m=a.y-h;r=a.z;o={x:n*s-j*r,y:-j*u*s-n*u*r+w*m,z:j*w*s+n*w*r+u*m};o.x=o.x*((f-o.z)/f)+l;o.y=o.y*((f-o.z)/f)+h;g.push(o)});return g}function y(e,a,b,d,g,c,h,f){var j=[];return c>g&&c-g>m/2+1.0E-4?(j=j.concat(y(e,a,b,d,g,g+m/2,h,f)),j=j.concat(y(e,a,b,d,g+m/2,c,h,f))):cm/2+1.0E-4?(j=j.concat(y(e,a,b,d,g,g-m/2,h,f)),j=j.concat(y(e, a,b,d,g-m/2,c,h,f))):(j=c-g,["C",e+b*k(g)-b*C*j*i(g)+h,a+d*i(g)+d*C*j*k(g)+f,e+b*k(c)+b*C*j*i(c)+h,a+d*i(c)-d*C*j*k(c)+f,e+b*k(c)+h,a+d*i(c)+f])}var m=Math.PI,q=m/180,i=Math.sin,k=Math.cos,E=Math.round,C=4*(Math.sqrt(2)-1)/3/(m/2);c.SVGRenderer.prototype.toLinePath=function(e,a){var b=[];c.each(e,function(a){b.push("L",a.x,a.y)});b[0]="M";a&&b.push("Z");return b};c.SVGRenderer.prototype.cuboid=function(e){var a=this.g(),e=this.cuboidPath(e);a.front=this.path(e[0]).attr({zIndex:e[3]}).add(a);a.top= this.path(e[1]).attr({zIndex:e[4]}).add(a);a.side=this.path(e[2]).attr({zIndex:e[5]}).add(a);a.attrSetters.fill=function(a){var d=c.Color(a).brighten(0.1).get(),e=c.Color(a).brighten(-0.1).get();this.front.attr({fill:a});this.top.attr({fill:d});this.side.attr({fill:e});return this};a.animate=function(a,d,e){a.x&&a.y?(a=this.renderer.cuboidPath(a),this.front.animate({d:a[0],zIndex:a[3]},d,e),this.top.animate({d:a[1],zIndex:a[4]},d,e),this.side.animate({d:a[2],zIndex:a[5]},d,e)):c.SVGElement.prototype.animate.call(this, a,d,e);return this};a.destroy=function(){this.front.destroy();this.top.destroy();this.side.destroy();return null};return a};c.SVGRenderer.prototype.cuboidPath=function(e){var a=e.x,b=e.y,d=e.z,c=e.height,l=e.width,h=e.depth,f=e.alpha,j=e.beta,a=[{x:a,y:b,z:d},{x:a+l,y:b,z:d},{x:a+l,y:b+c,z:d},{x:a,y:b+c,z:d},{x:a,y:b+c,z:d+h},{x:a+l,y:b+c,z:d+h},{x:a+l,y:b,z:d+h},{x:a,y:b,z:d+h}],a=v(a,f,j,e.origin);return[["M",a[0].x,a[0].y,"L",a[1].x,a[1].y,"L",a[2].x,a[2].y,"L",a[3].x,a[3].y,"Z"],j>0?["M",a[0].x, a[0].y,"L",a[7].x,a[7].y,"L",a[6].x,a[6].y,"L",a[1].x,a[1].y,"Z"]:["M",a[3].x,a[3].y,"L",a[2].x,a[2].y,"L",a[5].x,a[5].y,"L",a[4].x,a[4].y,"Z"],f>0?["M",a[1].x,a[1].y,"L",a[2].x,a[2].y,"L",a[5].x,a[5].y,"L",a[6].x,a[6].y,"Z"]:["M",a[0].x,a[0].y,"L",a[7].x,a[7].y,"L",a[4].x,a[4].y,"L",a[3].x,a[3].y,"Z"],(a[0].z+a[1].z+a[2].z+a[3].z)/4,j>0?(a[0].z+a[7].z+a[6].z+a[1].z)/4:(a[3].z+a[2].z+a[5].z+a[4].z)/4,f>0?(a[1].z+a[2].z+a[5].z+a[6].z)/4:(a[0].z+a[7].z+a[4].z+a[3].z)/4]};c.SVGRenderer.prototype.arc3d= function(e){e.alpha*=q;e.beta*=q;var a=this.g(),b=this.arc3dPath(e),d=a.renderer,g=b.zAll*100;a.shapeArgs=e;a.side1=d.path(b.side2).attr({zIndex:b.zSide2}).add(a);a.side2=d.path(b.side1).attr({zIndex:b.zSide1}).add(a);a.inn=d.path(b.inn).attr({zIndex:b.zInn}).add(a);a.out=d.path(b.out).attr({zIndex:b.zOut}).add(a);a.top=d.path(b.top).attr({zIndex:b.zTop}).add(a);a.attrSetters.fill=function(a){this.color=a;var b=c.Color(a).brighten(-0.1).get();this.side1.attr({fill:b});this.side2.attr({fill:b});this.inn.attr({fill:b}); this.out.attr({fill:b});this.top.attr({fill:a});return this};a.animate=function(a,b,e){c.SVGElement.prototype.animate.call(this,a,b,e);if(a.x&&a.y)b=this.renderer,a=c.splat(a)[0],a.alpha*=q,a.beta*=q,b=b.arc3dPath(a),this.shapeArgs=a,this.inn.attr({d:b.inn,zIndex:b.zInn}),this.out.attr({d:b.out,zIndex:b.zOut}),this.side1.attr({d:b.side1,zIndex:b.zSide2}),this.side2.attr({d:b.side2,zIndex:b.zSide1}),this.top.attr({d:b.top,zIndex:b.zTop}),this.attr({fill:this.color}),this.attr({zIndex:b.zAll*100}); return this};a.zIndex=g;a.attr({zIndex:g});return a};c.SVGRenderer.prototype.arc3dPath=function(e){var a=e.x,b=e.y,d=e.start,c=e.end-1.0E-5,l=e.r,h=e.innerR,f=e.depth,j=e.alpha,n=e.beta,u=k(d),w=i(d),s=k(c),q=i(c),r=l*k(n),o=l*k(j),x=h*k(n),z=h*k(j),A=f*i(n),B=f*i(j),f=["M",a+r*u,b+o*w],f=f.concat(y(a,b,r,o,d,c,0,0)),f=f.concat(["L",a+x*s,b+z*q]),f=f.concat(y(a,b,x,z,c,d,0,0)),f=f.concat(["Z"]),e=(e.start+e.end)/2,e=i(n)*k(e)+i(-j)*i(-e),p=n>0?m/2:0,t=j>0?0:m/2,p=d>-p?d:c>-p?-p:d,v=c0?i(h)*e:0),-c*(1-k(l))*i(b)+(i(b)>0?i(l)*e:0));a.dataLabel&&a.dataLabel.attr({x:a.dataLabel.connX+-c*(1-k(h))*k(b)+(k(b)>0?k(h)*e:0)-a.dataLabel.width/2,y:a.dataLabel.connY+-c*(1-k(l))*i(b)+(i(b)>0?i(l)*e:0)-a.dataLabel.height/2})})});c.wrap(c.seriesTypes.pie.prototype,"addPoint",function(c){c.apply(this,[].slice.call(arguments, 1));this.chart.is3d()&&this.update()});c.wrap(c.seriesTypes.scatter.prototype,"translate",function(e){e.apply(this,[].slice.call(arguments,1));if(this.chart.is3d()){var a=this.chart,b=this.chart.options.chart.options3d,d=b.alpha,g=b.beta,i={x:a.inverted?a.plotHeight/2:a.plotWidth/2,y:a.inverted?a.plotWidth/2:a.plotHeight/2,z:b.depth},b=b.depth,h=a.options.zAxis||{min:0,max:b},f=b/(h.max-h.min);c.each(this.data,function(a){var b={x:a.plotX,y:a.plotY,z:(a.z-h.min)*f},b=v([b],d,g,i)[0];a.plotXold=a.plotX; a.plotYold=a.plotY;a.plotX=b.x;a.plotY=b.y;a.plotZ=b.z})}});c.wrap(c.seriesTypes.scatter.prototype,"init",function(c){var a=c.apply(this,[].slice.call(arguments,1));if(this.chart.is3d())this.pointArrayMap=["x","y","z"],this.tooltipOptions.pointFormat=this.userOptions.tooltip?this.userOptions.tooltip.pointFormat||"x: {point.x}
y: {point.y}
z: {point.z}
":"x: {point.x}
y: {point.y}
z: {point.z}
";return a});if(c.VMLRenderer)c.VMLRenderer.prototype.cuboid= c.SVGRenderer.prototype.cuboid,c.VMLRenderer.prototype.cuboidPath=c.SVGRenderer.prototype.cuboidPath,c.VMLRenderer.prototype.toLinePath=c.SVGRenderer.prototype.toLinePath,c.VMLRenderer.prototype.createElement3D=c.SVGRenderer.prototype.createElement3D,c.VMLRenderer.prototype.arc3d=function(e){e=c.SVGRenderer.prototype.arc3d.call(this,e);e.css({zIndex:e.zIndex});return e},c.VMLRenderer.prototype.arc3dPath=c.SVGRenderer.prototype.arc3dPath,c.Chart.prototype.renderSeries=function(){for(var c,a=this.series.length;a--;)c= this.series[a],c.translate(),c.setTooltipPoints&&c.setTooltipPoints(),c.render()}})(Highcharts);