/* Highcharts JS v6.0.4 (2017-12-15) (c) 2009-2016 Torstein Honsi License: www.highcharts.com/license */ (function(S,L){"object"===typeof module&&module.exports?module.exports=S.document?L(S):L:S.Highcharts=L(S)})("undefined"!==typeof window?window:this,function(S){var L=function(){var a="undefined"===typeof S?window:S,z=a.document,A=a.navigator&&a.navigator.userAgent||"",D=z&&z.createElementNS&&!!z.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,p=/(edge|msie|trident)/i.test(A)&&!a.opera,k=/Firefox/.test(A),f=k&&4>parseInt(A.split("Firefox/")[1],10);return a.Highcharts?a.Highcharts.error(16, !0):{product:"Highcharts",version:"6.0.4",deg2rad:2*Math.PI/360,doc:z,hasBidiBug:f,hasTouch:z&&void 0!==z.documentElement.ontouchstart,isMS:p,isWebKit:/AppleWebKit/.test(A),isFirefox:k,isTouchDevice:/(Mobile|Android|Windows Phone)/.test(A),SVG_NS:"http://www.w3.org/2000/svg",chartCount:0,seriesTypes:{},symbolSizes:{},svg:D,win:a,marginNames:["plotTop","marginRight","marginBottom","plotLeft"],noop:function(){},charts:[]}}();(function(a){a.timers=[];var z=a.charts,A=a.doc,D=a.win;a.error=function(p, k){p=a.isNumber(p)?"Highcharts error #"+p+": www.highcharts.com/errors/"+p:p;if(k)throw Error(p);D.console&&console.log(p)};a.Fx=function(a,k,f){this.options=k;this.elem=a;this.prop=f};a.Fx.prototype={dSetter:function(){var a=this.paths[0],k=this.paths[1],f=[],l=this.now,t=a.length,n;if(1===l)f=this.toD;else if(t===k.length&&1>l)for(;t--;)n=parseFloat(a[t]),f[t]=isNaN(n)?k[t]:l*parseFloat(k[t]-n)+n;else f=k;this.elem.attr("d",f,null,!0)},update:function(){var a=this.elem,k=this.prop,f=this.now,l= this.options.step;if(this[k+"Setter"])this[k+"Setter"]();else a.attr?a.element&&a.attr(k,f,null,!0):a.style[k]=f+this.unit;l&&l.call(a,f,this)},run:function(p,k,f){var l=this,t=l.options,n=function(a){return n.stopped?!1:l.step(a)},m=D.requestAnimationFrame||function(a){setTimeout(a,13)},d=function(){for(var e=0;e=m+this.startTime?(this.now=this.end,this.pos=1,this.update(),f=d[this.prop]=!0,a.objectEach(d,function(a){!0!==a&&(f=!1)}),f&&n&&n.call(t),p=!1):(this.pos=l.easing((k-this.startTime)/m),this.now=this.start+(this.end- this.start)*this.pos,this.update(),p=!0);return p},initPath:function(p,k,f){function l(a){var b,h;for(w=a.length;w--;)b="M"===a[w]||"L"===a[w],h=/[a-zA-Z]/.test(a[w+3]),b&&h&&a.splice(w+1,0,a[w+1],a[w+2],a[w+1],a[w+2])}function t(a,h){for(;a.lengtha&&-Infinityn?"AM":"PM",P:12>n?"am":"pm",S:w(t.getSeconds()),L:w(Math.round(k%1E3),3)},a.dateFormats);a.objectEach(l,function(a,b){for(;-1!==p.indexOf("%"+b);)p=p.replace("%"+b,"function"===typeof a?a(k):a)});return f?p.substr(0,1).toUpperCase()+p.substr(1):p};a.formatSingle=function(p,k){var f=/\.([0-9])/,l=a.defaultOptions.lang;/f$/.test(p)?(f=(f=p.match(f))?f[1]:-1,null!==k&&(k=a.numberFormat(k,f,l.decimalPoint,-1=f&&(k=[1/f])));for(l=0;l=p||!t&&n<=(k[l]+(k[l+1]||k[l]))/2);l++);return m=a.correctFloat(m*f,-Math.round(Math.log(.001)/Math.LN10))};a.stableSort=function(a,k){var f=a.length,l,t;for(t=0;tf&&(f=a[k]);return f};a.destroyObjectProperties=function(p,k){a.objectEach(p,function(a,l){a&&a!==k&&a.destroy&&a.destroy();delete p[l]})};a.discardElement=function(p){var k=a.garbageBin;k||(k=a.createElement("div"));p&&k.appendChild(p);k.innerHTML=""};a.correctFloat=function(a,k){return parseFloat(a.toPrecision(k||14))};a.setAnimation=function(p,k){k.renderer.globalAnimation=a.pick(p,k.options.chart.animation, !0)};a.animObject=function(p){return a.isObject(p)?a.merge(p):{duration:p?500:0}};a.timeUnits={millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5,month:24192E5,year:314496E5};a.numberFormat=function(p,k,f,l){p=+p||0;k=+k;var t=a.defaultOptions.lang,n=(p.toString().split(".")[1]||"").split("e")[0].length,m,d,e=p.toString().split("e");-1===k?k=Math.min(n,20):a.isNumber(k)?k&&e[1]&&0>e[1]&&(m=k+ +e[1],0<=m?(e[0]=(+e[0]).toExponential(m).split("e")[0],k=m):(e[0]=e[0].split(".")[0]||0, p=20>k?(e[0]*Math.pow(10,e[1])).toFixed(k):0,e[1]=0)):k=2;d=(Math.abs(e[1]?e[0]:p)+Math.pow(10,-Math.max(k,n)-1)).toFixed(k);n=String(a.pInt(d));m=3p?"-":"")+(m?n.substr(0,m)+l:"");p+=n.substr(m).replace(/(\d{3})(?=\d)/g,"$1"+l);k&&(p+=f+d.slice(-k));e[1]&&0!==+p&&(p+="e"+e[1]);return p};Math.easeInOutSine=function(a){return-.5*(Math.cos(Math.PI*a)-1)};a.getStyle=function(p,k,f){if("width"===k)return Math.min(p.offsetWidth, p.scrollWidth)-a.getStyle(p,"padding-left")-a.getStyle(p,"padding-right");if("height"===k)return Math.min(p.offsetHeight,p.scrollHeight)-a.getStyle(p,"padding-top")-a.getStyle(p,"padding-bottom");D.getComputedStyle||a.error(27,!0);if(p=D.getComputedStyle(p,void 0))p=p.getPropertyValue(k),a.pick(f,"opacity"!==k)&&(p=a.pInt(p));return p};a.inArray=function(p,k){return(a.indexOfPolyfill||Array.prototype.indexOf).call(k,p)};a.grep=function(p,k){return(a.filterPolyfill||Array.prototype.filter).call(p, k)};a.find=Array.prototype.find?function(a,k){return a.find(k)}:function(a,k){var f,l=a.length;for(f=0;f>16,(f&65280)>> 8,f&255,1]:4===l&&(k=[(f&3840)>>4|(f&3840)>>8,(f&240)>>4|f&240,(f&15)<<4|f&15,1])),!k)for(n=this.parsers.length;n--&&!k;)m=this.parsers[n],(l=m.regex.exec(f))&&(k=m.parse(l));this.rgba=k||[]},get:function(a){var f=this.input,k=this.rgba,n;this.stops?(n=p(f),n.stops=[].concat(n.stops),z(this.stops,function(m,d){n.stops[d]=[n.stops[d][0],m.get(a)]})):n=k&&A(k[0])?"rgb"===a||!a&&1===k[3]?"rgb("+k[0]+","+k[1]+","+k[2]+")":"a"===a?k[3]:"rgba("+k.join(",")+")":f;return n},brighten:function(a){var f,t=this.rgba; if(this.stops)z(this.stops,function(f){f.brighten(a)});else if(A(a)&&0!==a)for(f=0;3>f;f++)t[f]+=k(255*a),0>t[f]&&(t[f]=0),255h.width)h= {width:0,height:0}}else h=this.htmlGetBBox();B.isSVG&&(a=h.width,B=h.height,q&&"11px"===q.fontSize&&17===Math.round(B)&&(h.height=B=14),r&&(h.width=Math.abs(B*Math.sin(M))+Math.abs(a*Math.cos(M)),h.height=Math.abs(B*Math.cos(M))+Math.abs(a*Math.sin(M))));if(f&&0]*>/g,"")))},textSetter:function(a){a!== this.textStr&&(delete this.bBox,this.textStr=a,this.added&&this.renderer.buildText(this))},fillSetter:function(a,g,b){"string"===typeof a?b.setAttribute(g,a):a&&this.colorGradient(a,g,b)},visibilitySetter:function(a,g,b){"inherit"===a?b.removeAttribute(g):this[g]!==a&&b.setAttribute(g,a);this[g]=a},zIndexSetter:function(a,g){var b=this.renderer,h=this.parentGroup,c=(h||b).element||b.box,B,e=this.element,d,q,b=c===b.box;B=this.added;var u;m(a)&&(e.zIndex=a,a=+a,this[g]===a&&(B=!1),this[g]=a);if(B){(a= this.zIndex)&&h&&(h.handleZ=!0);g=c.childNodes;for(u=g.length-1;0<=u&&!d;u--)if(h=g[u],B=h.zIndex,q=!m(B),h!==e)if(0>a&&q&&!b&&!u)c.insertBefore(e,g[u]),d=!0;else if(r(B)<=a||q&&(!m(a)||0<=a))c.insertBefore(e,g[u+1]||null),d=!0;d||(c.insertBefore(e,g[b?3:0]||null),d=!0)}return d},_defaultSetter:function(a,g,b){b.setAttribute(g,a)}});z.prototype.yGetter=z.prototype.xGetter;z.prototype.translateXSetter=z.prototype.translateYSetter=z.prototype.rotationSetter=z.prototype.verticalAlignSetter=z.prototype.rotationOriginXSetter= z.prototype.rotationOriginYSetter=z.prototype.scaleXSetter=z.prototype.scaleYSetter=z.prototype.matrixSetter=function(a,g){this[g]=a;this.doTransform=!0};A=a.SVGRenderer=function(){this.init.apply(this,arguments)};b(A.prototype,{Element:z,SVG_NS:R,init:function(a,g,b,r,h,c){var B;r=this.createElement("svg").attr({version:"1.1","class":"highcharts-root"});B=r.element;a.appendChild(B);k(a,"dir","ltr");-1===a.innerHTML.indexOf("xmlns")&&k(B,"xmlns",this.SVG_NS);this.isSVG=!0;this.box=B;this.boxWrapper= r;this.alignedObjects=[];this.url=(C||y)&&x.getElementsByTagName("base").length?P.location.href.replace(/#.*?$/,"").replace(/<[^>]*>/g,"").replace(/([\('\)])/g,"\\$1").replace(/ /g,"%20"):"";this.createElement("desc").add().element.appendChild(x.createTextNode("Created with Highcharts 6.0.4"));this.defs=this.createElement("defs").add();this.allowHTML=c;this.forExport=h;this.gradients={};this.cache={};this.cacheKeys=[];this.imgCount=0;this.setSize(g,b,!1);var e;C&&a.getBoundingClientRect&&(g=function(){t(a, {left:0,top:0});e=a.getBoundingClientRect();t(a,{left:Math.ceil(e.left)-e.left+"px",top:Math.ceil(e.top)-e.top+"px"})},g(),this.unSubPixelFix=D(P,"resize",g))},definition:function(a){function g(a,r){var h;c(K(a),function(a){var c=b.createElement(a.tagName),B={};I(a,function(a,g){"tagName"!==g&&"children"!==g&&"textContent"!==g&&(B[g]=a)});c.attr(B);c.add(r||b.defs);a.textContent&&c.element.appendChild(x.createTextNode(a.textContent));g(a.children||[],c);h=c});return h}var b=this;return g(a)},isHidden:function(){return!this.boxWrapper.getBBox().width}, destroy:function(){var a=this.defs;this.box=null;this.boxWrapper=this.boxWrapper.destroy();e(this.gradients||{});this.gradients=null;a&&(this.defs=a.destroy());this.unSubPixelFix&&this.unSubPixelFix();return this.alignedObjects=null},createElement:function(a){var g=new this.Element;g.init(this,a);return g},draw:u,getRadialAttr:function(a,g){return{cx:a[0]-a[2]/2+g.cx*a[2],cy:a[1]-a[2]/2+g.cy*a[2],r:g.r*a[2]}},getSpanWidth:function(a,g){var b=a.getBBox(!0).width;!O&&this.forExport&&(b=this.measureSpanWidth(g.firstChild.data, a.styles));return b},applyEllipsis:function(a,g,b,r){var h=a.rotation,c=b,B,e=0,d=b.length,q=function(a){g.removeChild(g.firstChild);a&&g.appendChild(x.createTextNode(a))},u;a.rotation=0;c=this.getSpanWidth(a,g);if(u=c>r){for(;e<=d;)B=Math.ceil((e+d)/2),c=b.substring(0,B)+"\u2026",q(c),c=this.getSpanWidth(a,g),e===d?e=d+1:c>r?d=B-1:e=B;0===d&&q("")}a.rotation=h;return u},escapes:{"\x26":"\x26amp;","\x3c":"\x26lt;","\x3e":"\x26gt;","'":"\x26#39;",'"':"\x26quot;"},buildText:function(a){var b=a.element, h=this,B=h.forExport,e=g(a.textStr,"").toString(),d=-1!==e.indexOf("\x3c"),q=b.childNodes,u,y,m,K,v=k(b,"x"),f=a.styles,E=a.textWidth,l=f&&f.lineHeight,N=f&&f.textOutline,M=f&&"ellipsis"===f.textOverflow,C=f&&"nowrap"===f.whiteSpace,G,F=q.length,n=E&&!a.added&&this.box,Q=function(a){return l?r(l):h.fontMetrics(void 0,a.getAttribute("style")?a:b).h},p=function(a){I(h.escapes,function(g,b){a=a.replace(new RegExp(g,"g"),b)});return a},f=[e,M,C,l,N,f&&f.fontSize,E].join();if(f!==a.textCache){for(a.textCache= f;F--;)b.removeChild(q[F]);d||N||M||E||-1!==e.indexOf(" ")?(u=/<.*class="([^"]+)".*>/,y=/<.*style="([^"]+)".*>/,m=/<.*href="([^"]+)".*>/,n&&n.appendChild(b),e=d?e.replace(/<(b|strong)>/g,'\x3cspan class\x3d"highcharts-strong"\x3e').replace(/<(i|em)>/g,'\x3cspan class\x3d"highcharts-emphasized"\x3e').replace(//g,"\x3c/span\x3e").split(//g):[e],e=w(e,function(a){return""!==a}),c(e,function(g,r){var e,d=0;g=g.replace(/^\s+|\s+$/g,"").replace(//g,"\x3c/span\x3e|||");e=g.split("|||");c(e,function(g){if(""!==g||1===e.length){var c={},q=x.createElementNS(h.SVG_NS,"tspan"),w,f;u.test(g)&&(w=g.match(u)[1],k(q,"class",w));y.test(g)&&(f=g.match(y)[1].replace(/(;| |^)color([ :])/,"$1fill$2"),k(q,"style",f));m.test(g)&&!B&&(k(q,"onclick",'location.href\x3d"'+g.match(m)[1]+'"'),k(q,"class","highcharts-anchor"));g=p(g.replace(/<[a-zA-Z\/](.|\n)*?>/g,"")||" ");if(" "!==g){q.appendChild(x.createTextNode(g));d?c.dx=0: r&&null!==v&&(c.x=v);k(q,c);b.appendChild(q);!d&&G&&(!O&&B&&t(q,{display:"block"}),k(q,"dy",Q(q)));if(E){c=g.replace(/([^\^])-/g,"$1- ").split(" ");w=1E,void 0===K&&(K=g),g&&1!==c.length?(q.removeChild(q.firstChild),l.unshift(c.pop())):(c=l,l=[],c.length&&!C&&(q=x.createElementNS(R,"tspan"),k(q,{dy:F,x:v}),f&&k(q,"style",f),b.appendChild(q)), N>E&&(E=N)),c.length&&q.appendChild(x.createTextNode(c.join(" ").replace(/- /g,"-")));a.rotation=n}d++}}});G=G||b.childNodes.length}),K&&a.attr("title",a.textStr),n&&n.removeChild(b),N&&a.applyTextOutline&&a.applyTextOutline(N)):b.appendChild(x.createTextNode(p(e)))}},getContrast:function(a){a=l(a).rgba;return 510Math.abs(c.end-c.start-2*Math.PI));var u=Math.cos(B),y=Math.sin(B),w=Math.cos(q),q=Math.sin(q);c=.001>c.end-B-Math.PI?0:1; e=["M",a+e*u,b+d*y,"A",e,d,0,c,1,a+e*w,b+d*q];m(r)&&e.push(h?"M":"L",a+r*w,b+r*q,"A",r,r,0,c,0,a+r*u,b+r*y);e.push(h?"":"Z");return e},callout:function(a,g,b,r,h){var c=Math.min(h&&h.r||0,b,r),B=c+6,e=h&&h.anchorX;h=h&&h.anchorY;var d;d=["M",a+c,g,"L",a+b-c,g,"C",a+b,g,a+b,g,a+b,g+c,"L",a+b,g+r-c,"C",a+b,g+r,a+b,g+r,a+b-c,g+r,"L",a+c,g+r,"C",a,g+r,a,g+r,a,g+r-c,"L",a,g+c,"C",a,g,a,g,a+c,g];e&&e>b?h>g+B&&he?h>g+B&&hr&&e>a+B&&eh&&e>a+B&&ea?a+3:Math.round(1.2*a);return{h:g,b:Math.round(.8*g),f:a}},rotCorr:function(a,g,b){var r=a;g&&b&&(r=Math.max(r*Math.cos(g*d),4));return{x:-a/3*Math.sin(g*d),y:r}},label:function(g,r,h,B,e,d,q,u,y){var w=this,f=w.g("button"!==y&&"label"),K=f.text=w.text("",0,0,q).attr({zIndex:1}),v,l,k=0,O=3,C=0,F,G,x,t,n,R={},Q,p=/^url\((.*?)\)$/.test(B),H=p,I,J,M,P;y&&f.addClass("highcharts-"+y);H=!0;I=function(){return v.strokeWidth()%2/2};J=function(){var a=K.element.style,g={};l=(void 0===F||void 0=== G||n)&&m(K.textStr)&&K.getBBox();f.width=(F||l.width||0)+2*O+C;f.height=(G||l.height||0)+2*O;Q=O+w.fontMetrics(a&&a.fontSize,K).b;H&&(v||(f.box=v=w.symbols[B]||p?w.symbol(B):w.rect(),v.addClass(("button"===y?"":"highcharts-label-box")+(y?" highcharts-"+y+"-box":"")),v.add(f),a=I(),g.x=a,g.y=(u?-Q:0)+a),g.width=Math.round(f.width),g.height=Math.round(f.height),v.attr(b(g,R)),R={})};M=function(){var a=C+O,g;g=u?0:Q;m(F)&&l&&("center"===n||"right"===n)&&(a+={center:.5,right:1}[n]*(F-l.width));if(a!== K.x||g!==K.y)K.attr("x",a),void 0!==g&&K.attr("y",g);K.x=a;K.y=g};P=function(a,g){v?v.attr(a,g):R[a]=g};f.onAdd=function(){K.add(f);f.attr({text:g||0===g?g:"",x:r,y:h});v&&m(e)&&f.attr({anchorX:e,anchorY:d})};f.widthSetter=function(g){F=a.isNumber(g)?g:null};f.heightSetter=function(a){G=a};f["text-alignSetter"]=function(a){n=a};f.paddingSetter=function(a){m(a)&&a!==O&&(O=f.padding=a,M())};f.paddingLeftSetter=function(a){m(a)&&a!==C&&(C=a,M())};f.alignSetter=function(a){a={left:0,center:.5,right:1}[a]; a!==k&&(k=a,l&&f.attr({x:x}))};f.textSetter=function(a){void 0!==a&&K.textSetter(a);J();M()};f["stroke-widthSetter"]=function(a,g){a&&(H=!0);this["stroke-width"]=a;P(g,a)};f.rSetter=function(a,g){P(g,a)};f.anchorXSetter=function(a,g){e=f.anchorX=a;P(g,Math.round(a)-I()-x)};f.anchorYSetter=function(a,g){d=f.anchorY=a;P(g,a-t)};f.xSetter=function(a){f.x=a;k&&(a-=k*((F||l.width)+2*O));x=Math.round(a);f.attr("translateX",x)};f.ySetter=function(a){t=f.y=Math.round(a);f.attr("translateY",t)};var T=f.css; return b(f,{css:function(a){if(a){var g={};a=E(a);c(f.textProps,function(b){void 0!==a[b]&&(g[b]=a[b],delete a[b])});K.css(g)}return T.call(f,a)},getBBox:function(){return{width:l.width+2*O,height:l.height+2*O,x:l.x-O,y:l.y-O}},destroy:function(){N(f.element,"mouseenter");N(f.element,"mouseleave");K&&(K=K.destroy());v&&(v=v.destroy());z.prototype.destroy.call(f);f=w=J=M=P=null}})}});a.Renderer=A})(L);(function(a){var z=a.attr,A=a.createElement,D=a.css,p=a.defined,k=a.each,f=a.extend,l=a.isFirefox, t=a.isMS,n=a.isWebKit,m=a.pick,d=a.pInt,e=a.SVGRenderer,x=a.win,c=a.wrap;f(a.SVGElement.prototype,{htmlCss:function(a){var b=this.element;if(b=a&&"SPAN"===b.tagName&&a.width)delete a.width,this.textWidth=b,this.updateTransform();a&&"ellipsis"===a.textOverflow&&(a.whiteSpace="nowrap",a.overflow="hidden");this.styles=f(this.styles,a);D(this.element,a);return this},htmlGetBBox:function(){var a=this.element;return{x:a.offsetLeft,y:a.offsetTop,width:a.offsetWidth,height:a.offsetHeight}},htmlUpdateTransform:function(){if(this.added){var a= this.renderer,h=this.element,c=this.x||0,e=this.y||0,f=this.textAlign||"left",m={left:0,center:.5,right:1}[f],l=this.styles;D(h,{marginLeft:this.translateX||0,marginTop:this.translateY||0});this.inverted&&k(h.childNodes,function(b){a.invertChild(b,h)});if("SPAN"===h.tagName){var F=this.rotation,v=d(this.textWidth),x=l&&l.whiteSpace,y=[F,f,h.innerHTML,this.textWidth,this.textAlign].join();y!==this.cTT&&(l=a.fontMetrics(h.style.fontSize).b,p(F)&&this.setSpanRotation(F,m,l),D(h,{width:"",whiteSpace:x|| "nowrap"}),h.offsetWidth>v&&/[ \-]/.test(h.textContent||h.innerText)&&D(h,{width:v+"px",display:"block",whiteSpace:x||"normal"}),this.getSpanCorrection(h.offsetWidth,l,m,F,f));D(h,{left:c+(this.xCorr||0)+"px",top:e+(this.yCorr||0)+"px"});n&&(l=h.offsetHeight);this.cTT=y}}else this.alignOnAdd=!0},setSpanRotation:function(a,h,c){var b={},e=this.renderer.getTransformKey();b[e]=b.transform="rotate("+a+"deg)";b[e+(l?"Origin":"-origin")]=b.transformOrigin=100*h+"% "+c+"px";D(this.element,b)},getSpanCorrection:function(a, h,c){this.xCorr=-a*c;this.yCorr=-h}});f(e.prototype,{getTransformKey:function(){return t&&!/Edge/.test(x.navigator.userAgent)?"-ms-transform":n?"-webkit-transform":l?"MozTransform":x.opera?"-o-transform":""},html:function(a,h,e){var b=this.createElement("span"),d=b.element,w=b.renderer,l=w.isSVG,F=function(a,b){k(["opacity","visibility"],function(h){c(a,h+"Setter",function(a,h,c,g){a.call(this,h,c,g);b[c]=h})})};b.textSetter=function(a){a!==d.innerHTML&&delete this.bBox;this.textStr=a;d.innerHTML= m(a,"");b.htmlUpdateTransform()};l&&F(b,b.element.style);b.xSetter=b.ySetter=b.alignSetter=b.rotationSetter=function(a,h){"align"===h&&(h="textAlign");b[h]=a;b.htmlUpdateTransform()};b.attr({text:a,x:Math.round(h),y:Math.round(e)}).css({position:"absolute"});d.style.whiteSpace="nowrap";b.css=b.htmlCss;l&&(b.add=function(a){var h,c=w.box.parentNode,e=[];if(this.parentGroup=a){if(h=a.div,!h){for(;a;)e.push(a),a=a.parentGroup;k(e.reverse(),function(a){function d(b,r){a[r]=b;t?g[w.getTransformKey()]= "translate("+(a.x||a.translateX)+"px,"+(a.y||a.translateY)+"px)":"translateX"===r?g.left=b+"px":g.top=b+"px";a.doTransform=!0}var g,r=z(a.element,"class");r&&(r={className:r});h=a.div=a.div||A("div",r,{position:"absolute",left:(a.translateX||0)+"px",top:(a.translateY||0)+"px",display:a.display,opacity:a.opacity,pointerEvents:a.styles&&a.styles.pointerEvents},h||c);g=h.style;f(a,{classSetter:function(a){return function(g){this.element.setAttribute("class",g);a.className=g}}(h),on:function(){e[0].div&& b.on.apply({element:e[0].div},arguments);return a},translateXSetter:d,translateYSetter:d});F(a,g)})}}else h=c;h.appendChild(d);b.added=!0;b.alignOnAdd&&b.htmlUpdateTransform();return b});return b}})})(L);(function(a){function z(){var l=a.defaultOptions.global,k=f.moment;if(l.timezone){if(k)return function(a){return-k.tz(a,l.timezone).utcOffset()};a.error(25)}return l.useUTC&&l.getTimezoneOffset}function A(){var l=a.defaultOptions.global,t,n=l.useUTC,m=n?"getUTC":"get",d=n?"setUTC":"set",e="Minutes Hours Day Date Month FullYear".split(" "), x=e.concat(["Milliseconds","Seconds"]);a.Date=t=l.Date||f.Date;t.hcTimezoneOffset=n&&l.timezoneOffset;t.hcGetTimezoneOffset=z();t.hcHasTimeZone=!(!t.hcTimezoneOffset&&!t.hcGetTimezoneOffset);t.hcMakeTime=function(a,b,h,e,d,f){var c;n?(c=t.UTC.apply(0,arguments),c+=D(c)):c=(new t(a,b,k(h,1),k(e,0),k(d,0),k(f,0))).getTime();return c};for(l=0;lb&&m-h*we&&(C=Math.round((d-m)/Math.cos(b*f)));else if(d=m+(1-h)*w,m-h*we&&(G=e-a.x+G*h,p=-1),G=Math.min(q,G),GG||l.autoRotation&&(c.styles||{}).width)C=G;C&&(F.width=C,(n.style||{}).textOverflow||(F.textOverflow="ellipsis"),c.css(F))},getPosition:function(a,f,k,m){var d=this.axis,e=d.chart,l=m&&e.oldChartHeight||e.chartHeight;return{x:a?d.translate(f+k,null,null,m)+d.transB:d.left+d.offset+(d.opposite?(m&&e.oldChartWidth||e.chartWidth)-d.right-d.left:0),y:a?l-d.bottom+d.offset-(d.opposite?d.height:0):l-d.translate(f+k,null,null,m)-d.transB}},getLabelPosition:function(a,k,n,m,d,e, x,c){var b=this.axis,h=b.transA,w=b.reversed,q=b.staggerLines,l=b.tickRotCorr||{x:0,y:0},p=d.y,C=m||b.reserveSpaceDefault?0:-b.labelOffset*("center"===b.labelAlign?.5:1);A(p)||(p=0===b.side?n.rotation?-8:-n.getBBox().height:2===b.side?l.y+8:Math.cos(n.rotation*f)*(l.y-n.getBBox(!1,0).height/2));a=a+d.x+C+l.x-(e&&m?e*h*(w?-1:1):0);k=k+p-(e&&!m?e*h*(w?1:-1):0);q&&(n=x/(c||1)%q,b.opposite&&(n=q-n-1),k+=b.labelOffset/q*n);return{x:a,y:Math.round(k)}},getMarkPath:function(a,f,k,m,d,e){return e.crispLine(["M", a,f,"L",a+(d?0:-k),f+(d?k:0)],m)},renderGridLine:function(a,f,k){var m=this.axis,d=this.gridLine,e={},l=this.pos,c=this.type,b=m.tickmarkOffset,h=m.chart.renderer;d||(c||(e.zIndex=1),a&&(e.opacity=0),this.gridLine=d=h.path().attr(e).addClass("highcharts-"+(c?c+"-":"")+"grid-line").add(m.gridGroup));if(!a&&d&&(a=m.getPlotLinePath(l+b,d.strokeWidth()*k,a,!0)))d[this.isNew?"attr":"animate"]({d:a,opacity:f})},renderMark:function(a,f,k){var m=this.axis,d=m.chart.renderer,e=this.type,l=m.tickSize(e?e+"Tick": "tick"),c=this.mark,b=!c,h=a.x;a=a.y;l&&(m.opposite&&(l[0]=-l[0]),b&&(this.mark=c=d.path().addClass("highcharts-"+(e?e+"-":"")+"tick").add(m.axisGroup)),c[b?"attr":"animate"]({d:this.getMarkPath(h,a,l[0],c.strokeWidth()*k,m.horiz,d),opacity:f}))},renderLabel:function(a,f,n,m){var d=this.axis,e=d.horiz,l=d.options,c=this.label,b=l.labels,h=b.step,d=d.tickmarkOffset,w=!0,q=a.x;a=a.y;c&&p(q)&&(c.xy=a=this.getLabelPosition(q,a,c,e,b,d,m,h),this.isFirst&&!this.isLast&&!k(l.showFirstLabel,1)||this.isLast&& !this.isFirst&&!k(l.showLastLabel,1)?w=!1:!e||b.step||b.rotation||f||0===n||this.handleOverflow(a),h&&m%h&&(w=!1),w&&p(a.y)?(a.opacity=n,c[this.isNewLabel?"attr":"animate"](a),this.isNewLabel=!1):(c.attr("y",-9999),this.isNewLabel=!0))},render:function(a,f,n){var m=this.axis,d=m.horiz,e=this.getPosition(d,this.pos,m.tickmarkOffset,f),l=e.x,c=e.y,m=d&&l===m.pos+m.len||!d&&c===m.pos?-1:1;n=k(n,1);this.isActive=!0;this.renderGridLine(f,n,m);this.renderMark(e,n,m);this.renderLabel(e,f,n,a);this.isNew= !1},destroy:function(){D(this,this.axis)}}})(L);var U=function(a){var z=a.addEvent,A=a.animObject,D=a.arrayMax,p=a.arrayMin,k=a.correctFloat,f=a.defaultOptions,l=a.defined,t=a.deg2rad,n=a.destroyObjectProperties,m=a.each,d=a.extend,e=a.fireEvent,x=a.format,c=a.getMagnitude,b=a.grep,h=a.inArray,w=a.isArray,q=a.isNumber,G=a.isString,J=a.merge,C=a.normalizeTickInterval,F=a.objectEach,v=a.pick,H=a.removeEvent,y=a.splat,E=a.syncTimeout,u=a.Tick,I=function(){this.init.apply(this,arguments)};a.extend(I.prototype, {defaultOptions:{dateTimeLabelFormats:{millisecond:"%H:%M:%S.%L",second:"%H:%M:%S",minute:"%H:%M",hour:"%H:%M",day:"%e. %b",week:"%e. %b",month:"%b '%y",year:"%Y"},endOnTick:!1,labels:{enabled:!0,x:0},maxPadding:.01,minorTickLength:2,minorTickPosition:"outside",minPadding:.01,startOfWeek:1,startOnTick:!1,tickLength:10,tickmarkPlacement:"between",tickPixelInterval:100,tickPosition:"outside",title:{align:"middle"},type:"linear"},defaultYAxisOptions:{endOnTick:!0,tickPixelInterval:72,showLastLabel:!0, labels:{x:-8},maxPadding:.05,minPadding:.05,startOnTick:!0,title:{rotation:270,text:"Values"},stackLabels:{allowOverlap:!1,enabled:!1,formatter:function(){return a.numberFormat(this.total,-1)}}},defaultLeftAxisOptions:{labels:{x:-15},title:{rotation:270}},defaultRightAxisOptions:{labels:{x:15},title:{rotation:90}},defaultBottomAxisOptions:{labels:{autoRotation:[-45],x:0},title:{rotation:0}},defaultTopAxisOptions:{labels:{autoRotation:[-45],x:0},title:{rotation:0}},init:function(a,b){var g=b.isX,r= this;r.chart=a;r.horiz=a.inverted&&!r.isZAxis?!g:g;r.isXAxis=g;r.coll=r.coll||(g?"xAxis":"yAxis");r.opposite=b.opposite;r.side=b.side||(r.horiz?r.opposite?0:2:r.opposite?1:3);r.setOptions(b);var c=this.options,e=c.type;r.labelFormatter=c.labels.formatter||r.defaultLabelFormatter;r.userOptions=b;r.minPixelPadding=0;r.reversed=c.reversed;r.visible=!1!==c.visible;r.zoomEnabled=!1!==c.zoomEnabled;r.hasNames="category"===e||!0===c.categories;r.categories=c.categories||r.hasNames;r.names=r.names||[];r.plotLinesAndBandsGroups= {};r.isLog="logarithmic"===e;r.isDatetimeAxis="datetime"===e;r.positiveValuesOnly=r.isLog&&!r.allowNegativeLog;r.isLinked=l(c.linkedTo);r.ticks={};r.labelEdge=[];r.minorTicks={};r.plotLinesAndBands=[];r.alternateBands={};r.len=0;r.minRange=r.userMinRange=c.minRange||c.maxZoom;r.range=c.range;r.offset=c.offset||0;r.stacks={};r.oldStacks={};r.stacksTouched=0;r.max=null;r.min=null;r.crosshair=v(c.crosshair,y(a.options.tooltip.crosshairs)[g?0:1],!1);b=r.options.events;-1===h(r,a.axes)&&(g?a.axes.splice(a.xAxis.length, 0,r):a.axes.push(r),a[r.coll].push(r));r.series=r.series||[];a.inverted&&!r.isZAxis&&g&&void 0===r.reversed&&(r.reversed=!0);F(b,function(a,g){z(r,g,a)});r.lin2log=c.linearToLogConverter||r.lin2log;r.isLog&&(r.val2lin=r.log2lin,r.lin2val=r.lin2log)},setOptions:function(a){this.options=J(this.defaultOptions,"yAxis"===this.coll&&this.defaultYAxisOptions,[this.defaultTopAxisOptions,this.defaultRightAxisOptions,this.defaultBottomAxisOptions,this.defaultLeftAxisOptions][this.side],J(f[this.coll],a))}, defaultLabelFormatter:function(){var g=this.axis,b=this.value,h=g.categories,c=this.dateTimeLabelFormat,e=f.lang,d=e.numericSymbols,e=e.numericSymbolMagnitude||1E3,u=d&&d.length,q,y=g.options.labels.format,g=g.isLog?Math.abs(b):g.tickInterval;if(y)q=x(y,this);else if(h)q=b;else if(c)q=a.dateFormat(c,b);else if(u&&1E3<=g)for(;u--&&void 0===q;)h=Math.pow(e,u+1),g>=h&&0===10*b%h&&null!==d[u]&&0!==b&&(q=a.numberFormat(b/h,-1)+d[u]);void 0===q&&(q=1E4<=Math.abs(b)?a.numberFormat(b,-1):a.numberFormat(b, -1,void 0,""));return q},getSeriesExtremes:function(){var a=this,r=a.chart;a.hasVisibleSeries=!1;a.dataMin=a.dataMax=a.threshold=null;a.softThreshold=!a.isXAxis;a.buildStacks&&a.buildStacks();m(a.series,function(g){if(g.visible||!r.options.chart.ignoreHiddenSeries){var h=g.options,c=h.threshold,e;a.hasVisibleSeries=!0;a.positiveValuesOnly&&0>=c&&(c=null);if(a.isXAxis)h=g.xData,h.length&&(g=p(h),e=D(h),q(g)||g instanceof Date||(h=b(h,q),g=p(h)),a.dataMin=Math.min(v(a.dataMin,h[0],g),g),a.dataMax=Math.max(v(a.dataMax, h[0],e),e));else if(g.getExtremes(),e=g.dataMax,g=g.dataMin,l(g)&&l(e)&&(a.dataMin=Math.min(v(a.dataMin,g),g),a.dataMax=Math.max(v(a.dataMax,e),e)),l(c)&&(a.threshold=c),!h.softThreshold||a.positiveValuesOnly)a.softThreshold=!1}})},translate:function(a,b,h,c,e,d){var g=this.linkedParent||this,r=1,B=0,f=c?g.oldTransA:g.transA;c=c?g.oldMin:g.min;var u=g.minPixelPadding;e=(g.isOrdinal||g.isBroken||g.isLog&&e)&&g.lin2val;f||(f=g.transA);h&&(r*=-1,B=g.len);g.reversed&&(r*=-1,B-=r*(g.sector||g.len));b? (a=(a*r+B-u)/f+c,e&&(a=g.lin2val(a))):(e&&(a=g.val2lin(a)),a=q(c)?r*(a-c)*f+B+r*u+(q(d)?f*d:0):void 0);return a},toPixels:function(a,b){return this.translate(a,!1,!this.horiz,null,!0)+(b?0:this.pos)},toValue:function(a,b){return this.translate(a-(b?0:this.pos),!0,!this.horiz,null,!0)},getPlotLinePath:function(a,b,h,c,e){var g=this.chart,r=this.left,d=this.top,B,f,u=h&&g.oldChartHeight||g.chartHeight,y=h&&g.oldChartWidth||g.chartWidth,w;B=this.transB;var m=function(a,g,b){if(ab)c?a=Math.min(Math.max(g, a),b):w=!0;return a};e=v(e,this.translate(a,null,null,h));a=h=Math.round(e+B);B=f=Math.round(u-e-B);q(e)?this.horiz?(B=d,f=u-this.bottom,a=h=m(a,r,r+this.width)):(a=r,h=y-this.right,B=f=m(B,d,d+this.height)):(w=!0,c=!1);return w&&!c?null:g.renderer.crispLine(["M",a,B,"L",h,f],b||1)},getLinearTickPositions:function(a,b,h){var g,r=k(Math.floor(b/a)*a);h=k(Math.ceil(h/a)*a);var c=[],e;k(r+a)===r&&(e=20);if(this.single)return[b];for(b=r;b<=h;){c.push(b);b=k(b+a,e);if(b===g)break;g=b}return c},getMinorTickInterval:function(){var a= this.options;return!0===a.minorTicks?v(a.minorTickInterval,"auto"):!1===a.minorTicks?null:a.minorTickInterval},getMinorTickPositions:function(){var a=this,b=a.options,h=a.tickPositions,c=a.minorTickInterval,e=[],d=a.pointRangePadding||0,f=a.min-d,d=a.max+d,u=d-f;if(u&&u/c= this.minRange,w=this.minRange,c=(w-h+b)/2,c=[b-c,v(a.min,b-c)],e&&(c[2]=this.isLog?this.log2lin(this.dataMin):this.dataMin),b=D(c),h=[b+w,v(a.max,b+w)],e&&(h[2]=this.isLog?this.log2lin(this.dataMax):this.dataMax),h=p(h),h-b=t?(H=t,x=0):b.dataMax<=t&&(J=t,F=0)),b.min=v(A,H,b.dataMin),b.max=v(z,J,b.dataMax));f&&(b.positiveValuesOnly&&!g&&0>=Math.min(b.min,v(b.dataMin,b.min))&&a.error(10,1),b.min=k(u(b.min), 15),b.max=k(u(b.max),15));b.range&&l(b.max)&&(b.userMin=b.min=A=Math.max(b.dataMin,b.minFromRange()),b.userMax=z=b.max,b.range=null);e(b,"foundExtremes");b.beforePadding&&b.beforePadding();b.adjustForMinRange();!(p||b.axisPointRange||b.usePercentage||E)&&l(b.min)&&l(b.max)&&(u=b.max-b.min)&&(!l(A)&&x&&(b.min-=u*x),!l(z)&&F&&(b.max+=u*F));q(d.softMin)&&!q(b.userMin)&&(b.min=Math.min(b.min,d.softMin));q(d.softMax)&&!q(b.userMax)&&(b.max=Math.max(b.max,d.softMax));q(d.floor)&&(b.min=Math.max(b.min,d.floor)); q(d.ceiling)&&(b.max=Math.min(b.max,d.ceiling));I&&l(b.dataMin)&&(t=t||0,!l(A)&&b.min=t?b.min=t:!l(z)&&b.max>t&&b.dataMax<=t&&(b.max=t));b.tickInterval=b.min===b.max||void 0===b.min||void 0===b.max?1:E&&!G&&n===b.linkedParent.options.tickPixelInterval?G=b.linkedParent.tickInterval:v(G,this.tickAmount?(b.max-b.min)/Math.max(this.tickAmount-1,1):void 0,p?1:(b.max-b.min)*n/Math.max(b.len,n));y&&!g&&m(b.series,function(a){a.processData(b.min!==b.oldMin||b.max!==b.oldMax)});b.setAxisTranslation(!0); b.beforeSetTickPositions&&b.beforeSetTickPositions();b.postProcessTickInterval&&(b.tickInterval=b.postProcessTickInterval(b.tickInterval));b.pointRange&&!G&&(b.tickInterval=Math.max(b.pointRange,b.tickInterval));g=v(d.minTickInterval,b.isDatetimeAxis&&b.closestPointRange);!G&&b.tickIntervalb.tickInterval&&1E3b.max)),!!this.tickAmount));this.tickAmount||(b.tickInterval= b.unsquish());this.setTickPositions()},setTickPositions:function(){var a=this.options,b,h=a.tickPositions;b=this.getMinorTickInterval();var c=a.tickPositioner,e=a.startOnTick,d=a.endOnTick;this.tickmarkOffset=this.categories&&"between"===a.tickmarkPlacement&&1===this.tickInterval?.5:0;this.minorTickInterval="auto"===b&&this.tickInterval?this.tickInterval/5:b;this.single=this.min===this.max&&l(this.min)&&!this.tickAmount&&(parseInt(this.min,10)===this.min||!1!==a.allowDecimals);this.tickPositions= b=h&&h.slice();!b&&(b=this.isDatetimeAxis?this.getTimeTicks(this.normalizeTimeTickInterval(this.tickInterval,a.units),this.min,this.max,a.startOfWeek,this.ordinalPositions,this.closestPointRange,!0):this.isLog?this.getLogTickPositions(this.tickInterval,this.min,this.max):this.getLinearTickPositions(this.tickInterval,this.min,this.max),b.length>this.len&&(b=[b[0],b.pop()],b[0]===b[1]&&(b.length=1)),this.tickPositions=b,c&&(c=c.apply(this,[this.min,this.max])))&&(this.tickPositions=b=c);this.paddedTicks= b.slice(0);this.trimTicks(b,e,d);this.isLinked||(this.single&&2>b.length&&(this.min-=.5,this.max+=.5),h||c||this.adjustTickAmount())},trimTicks:function(a,b,h){var g=a[0],c=a[a.length-1],e=this.minPointOffset||0;if(!this.isLinked){if(b&&-Infinity!==g)this.min=g;else for(;this.min-e>a[0];)a.shift();if(h)this.max=c;else for(;this.max+eb&&(this.finalTickAmt=b,b=5);this.tickAmount=b},adjustTickAmount:function(){var a= this.tickInterval,b=this.tickPositions,h=this.tickAmount,c=this.finalTickAmt,e=b&&b.length,d=v(this.threshold,this.softThreshold?0:null);if(this.hasData()){if(eh&&(this.tickInterval*=2,this.setTickPositions());if(l(c)){for(a=h=b.length;a--;)(3===c&&1===a%2||2>=c&&0c&&(a=c)),l(h)&&(bc&&(b=c))),this.displayBtn=void 0!==a||void 0!==b,this.setExtremes(a,b,!1,void 0,{trigger:"zoom"});return!0},setAxisSize:function(){var b=this.chart,h=this.options,c=h.offsets||[0,0,0,0],e=this.horiz,d=this.width=Math.round(a.relativeLength(v(h.width,b.plotWidth-c[3]+c[1]),b.plotWidth)),f=this.height=Math.round(a.relativeLength(v(h.height,b.plotHeight-c[0]+c[2]),b.plotHeight)),u=this.top=Math.round(a.relativeLength(v(h.top,b.plotTop+c[0]),b.plotHeight,b.plotTop)), h=this.left=Math.round(a.relativeLength(v(h.left,b.plotLeft+c[3]),b.plotWidth,b.plotLeft));this.bottom=b.chartHeight-f-u;this.right=b.chartWidth-d-h;this.len=Math.max(e?d:f,0);this.pos=e?h:u},getExtremes:function(){var a=this.isLog,b=this.lin2log;return{min:a?k(b(this.min)):this.min,max:a?k(b(this.max)):this.max,dataMin:this.dataMin,dataMax:this.dataMax,userMin:this.userMin,userMax:this.userMax}},getThreshold:function(a){var b=this.isLog,g=this.lin2log,h=b?g(this.min):this.min,b=b?g(this.max):this.max; null===a?a=h:h>a?a=h:ba?"right":195a?"left":"center"},tickSize:function(a){var b=this.options,g=b[a+"Length"],h=v(b[a+"Width"],"tick"===a&&this.isXAxis?1:0);if(h&&g)return"inside"===b[a+"Position"]&&(g=-g),[g,h]},labelMetrics:function(){var a=this.tickPositions&&this.tickPositions[0]||0;return this.chart.renderer.fontMetrics(this.options.labels.style&&this.options.labels.style.fontSize, this.ticks[a]&&this.ticks[a].label)},unsquish:function(){var a=this.options.labels,b=this.horiz,h=this.tickInterval,c=h,e=this.len/(((this.categories?1:0)+this.max-this.min)/h),d,f=a.rotation,u=this.labelMetrics(),q,w=Number.MAX_VALUE,y,k=function(a){a/=e||1;a=1=a)q=k(Math.abs(u.h/Math.sin(t*a))),b=q+Math.abs(a/360),b(h.step||0)&&!h.rotation&&(this.staggerLines||1)*this.len/c||!b&&(h.style&&parseInt(h.style.width,10)||e&&e-a.spacing[3]||.33*a.chartWidth)},renderUnsquish:function(){var a=this.chart,b=a.renderer,h=this.tickPositions,c=this.ticks,e=this.options.labels,d=this.horiz, f=this.getSlotWidth(),u=Math.max(1,Math.round(f-2*(e.padding||5))),q={},w=this.labelMetrics(),y=e.style&&e.style.textOverflow,v,k=0,l,E;G(e.rotation)||(q.rotation=e.rotation||0);m(h,function(a){(a=c[a])&&a.labelLength>k&&(k=a.labelLength)});this.maxLabelLength=k;if(this.autoRotation)k>u&&k>w.h?q.rotation=this.labelRotation:this.labelRotation=0;else if(f&&(v={width:u+"px"},!y))for(v.textOverflow="clip",l=h.length;!d&&l--;)if(E=h[l],u=c[E].label)u.styles&&"ellipsis"===u.styles.textOverflow?u.css({textOverflow:"clip"}): c[E].labelLength>f&&u.css({width:f+"px"}),u.getBBox().height>this.len/h.length-(w.h-w.f)&&(u.specCss={textOverflow:"ellipsis"});q.rotation&&(v={width:(k>.5*a.chartHeight?.33*a.chartHeight:a.chartHeight)+"px"},y||(v.textOverflow="ellipsis"));if(this.labelAlign=e.align||this.autoLabelAlign(this.labelRotation))q.align=this.labelAlign;m(h,function(a){var b=(a=c[a])&&a.label;b&&(b.attr(q),v&&b.css(J(v,b.specCss)),delete b.specCss,a.rotation=q.rotation)});this.tickRotCorr=b.rotCorr(w.b,this.labelRotation|| 0,0!==this.side)},hasData:function(){return this.hasVisibleSeries||l(this.min)&&l(this.max)&&this.tickPositions&&0=this.min&&a<=this.max)h[a]||(h[a]=new u(this,a)),c&&h[a].isNew&&h[a].render(b,!0,.1),h[a].render(b)},render:function(){var b=this,h=b.chart,c=b.options,e=b.isLog,d=b.lin2log,f=b.isLinked,w=b.tickPositions,y=b.axisTitle,v=b.ticks,k=b.minorTicks,l=b.alternateBands,C=c.stackLabels,G=c.alternateGridColor,x=b.tickmarkOffset,n=b.axisLine,p=b.showAxis,t=A(h.renderer.globalAnimation),I,H;b.labelEdge.length=0;b.overlap=!1;m([v,k,l],function(a){F(a, function(a){a.isActive=!1})});if(b.hasData()||f)b.minorTickInterval&&!b.categories&&m(b.getMinorTickPositions(),function(a){b.renderMinorTick(a)}),w.length&&(m(w,function(a,h){b.renderTick(a,h)}),x&&(0===b.min||b.single)&&(v[-1]||(v[-1]=new u(b,-1,null,!0)),v[-1].render(-1))),G&&m(w,function(g,c){H=void 0!==w[c+1]?w[c+1]+x:b.max-x;0===c%2&&g=e.second?0:t*Math.floor(C.getMilliseconds()/t));if(v>= e.second)C[A.hcSetSeconds](v>=e.minute?0:t*Math.floor(C.getSeconds()/t));if(v>=e.minute)C[A.hcSetMinutes](v>=e.hour?0:t*Math.floor(C[A.hcGetMinutes]()/t));if(v>=e.hour)C[A.hcSetHours](v>=e.day?0:t*Math.floor(C[A.hcGetHours]()/t));if(v>=e.day)C[A.hcSetDate](v>=e.month?1:t*Math.floor(C[A.hcGetDate]()/t));v>=e.month&&(C[A.hcSetMonth](v>=e.year?0:t*Math.floor(C[A.hcGetMonth]()/t)),x=C[A.hcGetFullYear]());if(v>=e.year)C[A.hcSetFullYear](x-x%t);if(v===e.week)C[A.hcSetDate](C[A.hcGetDate]()-C[A.hcGetDay]()+ d(h,1));x=C[A.hcGetFullYear]();h=C[A.hcGetMonth]();var u=C[A.hcGetDate](),I=C[A.hcGetHours]();c=C.getTime();A.hcHasTimeZone&&(E=(!m||!!A.hcGetTimezoneOffset)&&(b-c>4*e.month||n(c)!==n(b)),y=n(C),C=new A(c+y));m=C.getTime();for(c=1;mw.length&&f(w,function(a){0===a%18E5&&"000000000"===D("%H%M%S%L",a)&&(q[a]="day")})}w.info= l(a,{higherRanks:q,totalRange:v*t});return w};z.prototype.normalizeTimeTickInterval=function(a,c){var b=c||[["millisecond",[1,2,5,10,20,25,50,100,200,500]],["second",[1,2,5,10,15,30]],["minute",[1,2,5,10,15,30]],["hour",[1,2,3,4,6,8,12]],["day",[1,2]],["week",[1,2]],["month",[1,2,3,4,6]],["year",null]];c=b[b.length-1];var h=e[c[0]],d=c[1],f;for(f=0;fl&&(!n||q<=t)&&void 0!==q&&c.push(q),q>t&&(G=!0),q=w;else l=e(l),t=e(t),a=n?this.getMinorTickInterval():f.tickInterval,a=k("auto"===a?null:a,this._minorAutoInterval,f.tickPixelInterval/(n?5:1)*(t-l)/((n?d/this.tickPositions.length:d)||1)),a=p(a,null,A(a)),c=D(this.getLinearTickPositions(a,l,t),x),n||(this._minorAutoInterval=a/5);n||(this.tickInterval=a);return c};z.prototype.log2lin=function(a){return Math.log(a)/Math.LN10};z.prototype.lin2log=function(a){return Math.pow(10,a)}})(L); (function(a,z){var A=a.arrayMax,D=a.arrayMin,p=a.defined,k=a.destroyObjectProperties,f=a.each,l=a.erase,t=a.merge,n=a.pick;a.PlotLineOrBand=function(a,d){this.axis=a;d&&(this.options=d,this.id=d.id)};a.PlotLineOrBand.prototype={render:function(){var f=this,d=f.axis,e=d.horiz,k=f.options,c=k.label,b=f.label,h=k.to,w=k.from,q=k.value,l=p(w)&&p(h),J=p(q),C=f.svgElem,F=!C,v=[],H=n(k.zIndex,0),y=k.events,v={"class":"highcharts-plot-"+(l?"band ":"line ")+(k.className||"")},E={},u=d.chart.renderer,I=l?"bands": "lines",g;g=d.log2lin;d.isLog&&(w=g(w),h=g(h),q=g(q));E.zIndex=H;I+="-"+H;(g=d.plotLinesAndBandsGroups[I])||(d.plotLinesAndBandsGroups[I]=g=u.g("plot-"+I).attr(E).add());F&&(f.svgElem=C=u.path().attr(v).add(g));if(J)v=d.getPlotLinePath(q,C.strokeWidth());else if(l)v=d.getPlotBandPath(w,h,k);else return;F&&v&&v.length?(C.attr({d:v}),y&&a.objectEach(y,function(a,b){C.on(b,function(a){y[b].apply(f,[a])})})):C&&(v?(C.show(),C.animate({d:v})):(C.hide(),b&&(f.label=b=b.destroy())));c&&p(c.text)&&v&&v.length&& 0this.max&&d>this.max;if(f&&e)for(a&&(w=f.toString()===e.toString(),h=0),a=0;aw-f?w:w-f);else if(y)e[a]=Math.max(d,c+f+g>b?c:c+f);else return!1},n=function(a,b,g,c){var d;cb-h?d=!1:e[a]=cb-g/2?b-g-2:c-g/2;return d},y=function(a){var b=l;l=m;m=b;k=a},E=function(){!1!==v.apply(0,l)?!1!==n.apply(0,m)||k||(y(!0),E()):k?e.x=e.y=0:(y(!0),E())};(b.inverted||1v&&(q=!1);a=(e.series&&e.series.yAxis&&e.series.yAxis.pos)+(e.plotY||0);a-=h.plotTop;b.push({target:e.isHeader?h.plotHeight+l:a,rank:e.isHeader?1:0,size:w.tt.getBBox().height+1,point:e,x:v,tt:y})}});this.cleanSplit();a.distribute(b,h.plotHeight+l);A(b,function(a){var b=a.point,c=b.series;a.tt.attr({visibility:void 0===a.pos?"hidden":"inherit",x:q||b.isHeader? a.x:b.plotX+h.plotLeft+t(k.distance,16),y:a.pos+h.plotTop,anchorX:b.isHeader?b.plotX+h.plotLeft:b.plotX+c.xAxis.pos,anchorY:b.isHeader?a.pos+h.plotTop-15:b.plotY+c.yAxis.pos})})},updatePosition:function(a){var e=this.chart,c=this.getLabel(),c=(this.options.positioner||this.getPosition).call(this,c.width,c.height,a);this.move(Math.round(c.x),Math.round(c.y||0),a.plotX+e.plotLeft,a.plotY+e.plotTop)},getDateFormat:function(a,f,c,b){var h=z("%m-%d %H:%M:%S.%L",f),e,q,k={millisecond:15,second:12,minute:9, hour:6,day:3},l="millisecond";for(q in d){if(a===d.week&&+z("%w",f)===c&&"00:00:00.000"===h.substr(6)){q="week";break}if(d[q]>a){q=l;break}if(k[q]&&h.substr(k[q])!=="01-01 00:00:00.000".substr(k[q]))break;"week"!==q&&(l=q)}q&&(e=b[q]);return e},getXDateFormat:function(a,d,c){d=d.dateTimeLabelFormats;var b=c&&c.closestPointRange;return(b?this.getDateFormat(b,a.x,c.options.startOfWeek,d):d.day)||d.year},tooltipFooterHeaderFormatter:function(a,d){d=d?"footer":"header";var c=a.series,b=c.tooltipOptions, h=b.xDateFormat,e=c.xAxis,f=e&&"datetime"===e.options.type&&k(a.key),l=b[d+"Format"];f&&!h&&(h=this.getXDateFormat(a,b,e));f&&h&&A(a.point&&a.point.tooltipDateKeys||["key"],function(a){l=l.replace("{point."+a+"}","{point."+a+":"+h+"}")});return p(l,{point:a,series:c})},bodyFormatter:function(a){return f(a,function(a){var c=a.series.tooltipOptions;return(c[(a.point.formatPrefix||"point")+"Formatter"]||a.point.tooltipFormatter).call(a.point,c[(a.point.formatPrefix||"point")+"Format"])})}}})(L);(function(a){var z= a.addEvent,A=a.attr,D=a.charts,p=a.css,k=a.defined,f=a.each,l=a.extend,t=a.find,n=a.fireEvent,m=a.isObject,d=a.offset,e=a.pick,x=a.splat,c=a.Tooltip;a.Pointer=function(a,h){this.init(a,h)};a.Pointer.prototype={init:function(a,h){this.options=h;this.chart=a;this.runChartClick=h.chart.events&&!!h.chart.events.click;this.pinchDown=[];this.lastValidTouch={};c&&(a.tooltip=new c(a,h.tooltip),this.followTouchMove=e(h.tooltip.followTouchMove,!0));this.setDOMEvents()},zoomOption:function(a){var b=this.chart, c=b.options.chart,d=c.zoomType||"",b=b.inverted;/touch/.test(a.type)&&(d=e(c.pinchType,d));this.zoomX=a=/x/.test(d);this.zoomY=d=/y/.test(d);this.zoomHor=a&&!b||d&&b;this.zoomVert=d&&!b||a&&b;this.hasZoom=a||d},normalize:function(a,h){var b;b=a.touches?a.touches.length?a.touches.item(0):a.changedTouches[0]:a;h||(this.chartPosition=h=d(this.chart.container));return l(a,{chartX:Math.round(b.pageX-h.left),chartY:Math.round(b.pageY-h.top)})},getCoordinates:function(a){var b={xAxis:[],yAxis:[]};f(this.chart.axes, function(h){b[h.isXAxis?"xAxis":"yAxis"].push({axis:h,value:h.toValue(a[h.horiz?"chartX":"chartY"])})});return b},findNearestKDPoint:function(a,h,c){var b;f(a,function(a){var e=!(a.noSharedTooltip&&h)&&0>a.options.findNearestPointBy.indexOf("y");a=a.searchPoint(c,e);if((e=m(a,!0))&&!(e=!m(b,!0)))var e=b.distX-a.distX,d=b.dist-a.dist,f=(a.series.group&&a.series.group.zIndex)-(b.series.group&&b.series.group.zIndex),e=0<(0!==e&&h?e:0!==d?d:0!==f?f:b.series.index>a.series.index?-1:1);e&&(b=a)});return b}, getPointFromEvent:function(a){a=a.target;for(var b;a&&!b;)b=a.point,a=a.parentNode;return b},getChartCoordinatesFromPoint:function(a,h){var b=a.series,c=b.xAxis,b=b.yAxis,d=e(a.clientX,a.plotX);if(c&&b)return h?{chartX:c.len+c.pos-d,chartY:b.len+b.pos-a.plotY}:{chartX:d+c.pos,chartY:a.plotY+b.pos}},getHoverData:function(b,h,c,d,k,l,C){var q,w=[],n=C&&C.isBoosting;d=!(!d||!b);C=h&&!h.stickyTracking?[h]:a.grep(c,function(a){return a.visible&&!(!k&&a.directTouch)&&e(a.options.enableMouseTracking,!0)&& a.stickyTracking});h=(q=d?b:this.findNearestKDPoint(C,k,l))&&q.series;q&&(k&&!h.noSharedTooltip?(C=a.grep(c,function(a){return a.visible&&!(!k&&a.directTouch)&&e(a.options.enableMouseTracking,!0)&&!a.noSharedTooltip}),f(C,function(a){var b=t(a.points,function(a){return a.x===q.x&&!a.isNull});m(b)&&(n&&(b=a.getPoint(b)),w.push(b))})):w.push(q));return{hoverPoint:q,hoverSeries:h,hoverPoints:w}},runPointActions:function(b,h){var c=this.chart,d=c.tooltip&&c.tooltip.options.enabled?c.tooltip:void 0,k= d?d.shared:!1,l=h||c.hoverPoint,m=l&&l.series||c.hoverSeries,m=this.getHoverData(l,m,c.series,!!h||m&&m.directTouch&&this.isDirectTouch,k,b,{isBoosting:c.isBoosting}),n,l=m.hoverPoint;n=m.hoverPoints;h=(m=m.hoverSeries)&&m.tooltipOptions.followPointer;k=k&&m&&!m.noSharedTooltip;if(l&&(l!==c.hoverPoint||d&&d.isHidden)){f(c.hoverPoints||[],function(b){-1===a.inArray(b,n)&&b.setState()});f(n||[],function(a){a.setState("hover")});if(c.hoverSeries!==m)m.onMouseOver();c.hoverPoint&&c.hoverPoint.firePointEvent("mouseOut"); if(!l.series)return;l.firePointEvent("mouseOver");c.hoverPoints=n;c.hoverPoint=l;d&&d.refresh(k?n:l,b)}else h&&d&&!d.isHidden&&(l=d.getAnchor([{}],b),d.updatePosition({plotX:l[0],plotY:l[1]}));this.unDocMouseMove||(this.unDocMouseMove=z(c.container.ownerDocument,"mousemove",function(b){var h=D[a.hoverChartIndex];if(h)h.pointer.onDocumentMouseMove(b)}));f(c.axes,function(h){var c=e(h.crosshair.snap,!0),d=c?a.find(n,function(a){return a.series[h.coll]===h}):void 0;d||!c?h.drawCrosshair(b,d):h.hideCrosshair()})}, reset:function(a,h){var b=this.chart,c=b.hoverSeries,d=b.hoverPoint,e=b.hoverPoints,k=b.tooltip,l=k&&k.shared?e:d;a&&l&&f(x(l),function(b){b.series.isCartesian&&void 0===b.plotX&&(a=!1)});if(a)k&&l&&(k.refresh(l),d&&(d.setState(d.state,!0),f(b.axes,function(a){a.crosshair&&a.drawCrosshair(null,d)})));else{if(d)d.onMouseOut();e&&f(e,function(a){a.setState()});if(c)c.onMouseOut();k&&k.hide(h);this.unDocMouseMove&&(this.unDocMouseMove=this.unDocMouseMove());f(b.axes,function(a){a.hideCrosshair()});this.hoverX= b.hoverPoints=b.hoverPoint=null}},scaleGroups:function(a,h){var b=this.chart,c;f(b.series,function(d){c=a||d.getPlotBox();d.xAxis&&d.xAxis.zoomEnabled&&d.group&&(d.group.attr(c),d.markerGroup&&(d.markerGroup.attr(c),d.markerGroup.clip(h?b.clipRect:null)),d.dataLabelsGroup&&d.dataLabelsGroup.attr(c))});b.clipRect.attr(h||b.clipBox)},dragStart:function(a){var b=this.chart;b.mouseIsDown=a.type;b.cancelClick=!1;b.mouseDownX=this.mouseDownX=a.chartX;b.mouseDownY=this.mouseDownY=a.chartY},drag:function(a){var b= this.chart,c=b.options.chart,d=a.chartX,e=a.chartY,f=this.zoomHor,k=this.zoomVert,l=b.plotLeft,m=b.plotTop,n=b.plotWidth,y=b.plotHeight,E,u=this.selectionMarker,t=this.mouseDownX,g=this.mouseDownY,r=c.panKey&&a[c.panKey+"Key"];u&&u.touch||(dl+n&&(d=l+n),em+y&&(e=m+y),this.hasDragged=Math.sqrt(Math.pow(t-d,2)+Math.pow(g-e,2)),10y.max&&(f=y.max-C,N=!0);N?(I-=.8*(I-p[h][0]),E||(r-=.8*(r-p[h][1])),k()):p[h]=[I,r];x||(e[h]=F-t,e[n]=C);e=x?1/v:v;d[n]=C;d[h]=f;m[x?a?"scaleY":"scaleX":"scale"+l]=v;m["translate"+l]=e*t+(I-e*u)},pinch:function(a){var l= this,n=l.chart,m=l.pinchDown,d=a.touches,e=d.length,x=l.lastValidTouch,c=l.hasZoom,b=l.selectionMarker,h={},w=1===e&&(l.inClass(a.target,"highcharts-tracker")&&n.runTrackerClick||l.runChartClick),q={};1b-6&&f(p||b.spacingBox.width-2*l-d.x)&&(this.itemX=l,this.itemY+=E+this.lastLineHeight+y,this.lastLineHeight=0);this.maxItemWidth=Math.max(this.maxItemWidth,f);this.lastItemY=E+this.itemY+y;this.lastLineHeight=Math.max(c,this.lastLineHeight);a._legendItemPos=[this.itemX,this.itemY];e?this.itemX+= f:(this.itemY+=E+c+y,this.lastLineHeight=c);this.offsetWidth=p||Math.max((e?this.itemX-l-(a.checkbox?0:m):f)+l,this.offsetWidth)},getAllItems:function(){var a=[];k(this.chart.series,function(b){var c=b&&b.options;b&&n(c.showInLegend,p(c.linkedTo)?!1:void 0,!0)&&(a=a.concat(b.legendItems||("point"===c.legendType?b.data:b)))});return a},getAlignment:function(){var a=this.options;return a.floating?"":a.align.charAt(0)+a.verticalAlign.charAt(0)+a.layout.charAt(0)},adjustMargins:function(a,b){var c=this.chart, d=this.options,e=this.getAlignment();e&&k([/(lth|ct|rth)/,/(rtv|rm|rbv)/,/(rbh|cb|lbh)/,/(lbv|lm|ltv)/],function(h,f){h.test(e)&&!p(a[f])&&(c[l[f]]=Math.max(c[l[f]],c.legend[(f+1)%2?"legendHeight":"legendWidth"]+[1,-1,-1,1][f]*d[f%2?"x":"y"]+n(d.margin,12)+b[f]+(0===f?c.titleOffset+c.options.title.margin:0)))})},render:function(){var a=this,b=a.chart,h=b.renderer,e=a.group,f,l,m,n,p=a.box,v=a.options,x=a.padding;a.itemX=x;a.itemY=a.initialItemY;a.offsetWidth=0;a.lastItemY=0;e||(a.group=e=h.g("legend").attr({zIndex:7}).add(), a.contentGroup=h.g().attr({zIndex:1}).add(e),a.scrollGroup=h.g().add(a.contentGroup));a.renderTitle();f=a.getAllItems();d(f,function(a,b){return(a.options&&a.options.legendIndex||0)-(b.options&&b.options.legendIndex||0)});v.reversed&&f.reverse();a.allItems=f;a.display=l=!!f.length;a.lastLineHeight=0;k(f,function(b){a.renderItem(b)});m=(v.width||a.offsetWidth)+x;n=a.lastItemY+a.lastLineHeight+a.titleHeight;n=a.handleOverflow(n);n+=x;p||(a.box=p=h.rect().addClass("highcharts-legend-box").attr({r:v.borderRadius}).add(e), p.isNew=!0);0c&&!1!==v.enabled?(this.clipHeight=m=Math.max(c-20-this.titleHeight-l,0),this.currentPage=n(this.currentPage,1),this.fullHeight=a,k(g,function(a,b){var c=a._legendItemPos[1],d=Math.round(a.legendItem.getBBox().height),e=u.length;if(!e||c-u[e-1]>m&&(I||c)!==u[e-1])u.push(I||c),e++;a.pageIx=e-1;I&&(g[b-1].pageIx=e-1);b===g.length-1&&c+d-u[e-1]>m&&(u.push(c),a.pageIx=e);c!==I&&(I=c)}),p||(p=b.clipRect=d.clipRect(0,l,9999,0),b.contentGroup.clip(p)),r(m),E||(this.nav=E=d.g().attr({zIndex:1}).add(this.group), this.up=d.symbol("triangle",0,0,y,y).on("click",function(){b.scroll(-1,t)}).add(E),this.pager=d.text("",15,10).addClass("highcharts-legend-navigation").add(E),this.down=d.symbol("triangle-down",0,0,y,y).on("click",function(){b.scroll(1,t)}).add(E)),b.scroll(0),a=c):E&&(r(),this.nav=E.destroy(),this.scrollGroup.attr({translateY:1}),this.clipHeight=0);return a},scroll:function(a,b){var c=this.pages,d=c.length;a=this.currentPage+a;var e=this.clipHeight,f=this.pager,k=this.padding;a>d&&(a=d);0h&&(f=typeof a[0],"string"===f?d.name=a[0]:"number"===f&&(d.x=a[0]),k++);m=c.value;)c=e[++f];c&&c.color&&!this.options.color&&(this.color= c.color);return c},destroy:function(){var a=this.series.chart,e=a.hoverPoints,f;a.pointCount--;e&&(this.setState(),p(e,this),e.length||(a.hoverPoints=null));if(this===a.hoverPoint)this.onMouseOut();if(this.graphic||this.dataLabel)m(this),this.destroyElements();this.legendItem&&a.legend.destroyItem(this);for(f in this)this[f]=null},destroyElements:function(){for(var a=["graphic","dataLabel","dataLabelUpper","connector","shadowGroup"],e,f=6;f--;)e=a[f],this[e]&&(this[e]=this[e].destroy())},getLabelConfig:function(){return{x:this.category, y:this.y,color:this.color,colorIndex:this.colorIndex,key:this.name||this.category,series:this.series,point:this,percentage:this.percentage,total:this.total||this.stackTotal}},tooltipFormatter:function(a){var d=this.series,k=d.tooltipOptions,c=n(k.valueDecimals,""),b=k.valuePrefix||"",h=k.valueSuffix||"";A(d.pointArrayMap||["y"],function(d){d="{point."+d;if(b||h)a=a.replace(d+"}",b+d+"}"+h);a=a.replace(d+"}",d+":,."+c+"f}")});return f(a,{point:this,series:this.series})},firePointEvent:function(a,e, f){var c=this,b=this.series.options;(b.point.events[a]||c.options&&c.options.events&&c.options.events[a])&&this.importEvents();"click"===a&&b.allowPointSelect&&(f=function(a){c.select&&c.select(null,a.ctrlKey||a.metaKey||a.shiftKey)});k(this,a,e,f)},visible:!0}})(L);(function(a){var z=a.addEvent,A=a.animObject,D=a.arrayMax,p=a.arrayMin,k=a.correctFloat,f=a.Date,l=a.defaultOptions,t=a.defined,n=a.each,m=a.erase,d=a.extend,e=a.fireEvent,x=a.grep,c=a.isArray,b=a.isNumber,h=a.isString,w=a.merge,q=a.objectEach, G=a.pick,J=a.removeEvent,C=a.splat,F=a.SVGElement,v=a.syncTimeout,H=a.win;a.Series=a.seriesType("line",null,{allowPointSelect:!1,showCheckbox:!1,animation:{duration:1E3},events:{},marker:{radius:4,states:{hover:{animation:{duration:50},enabled:!0,radiusPlus:2}}},point:{events:{}},dataLabels:{align:"center",formatter:function(){return null===this.y?"":a.numberFormat(this.y,-1)},verticalAlign:"bottom",x:0,y:0,padding:5},cropThreshold:300,pointRange:0,softThreshold:!0,states:{hover:{animation:{duration:50}, lineWidthPlus:1,marker:{},halo:{size:10}},select:{marker:{}}},stickyTracking:!0,turboThreshold:1E3,findNearestPointBy:"x"},{isCartesian:!0,pointClass:a.Point,sorted:!0,requireSorting:!0,directTouch:!1,axisTypes:["xAxis","yAxis"],colorCounter:0,parallelArrays:["x","y"],coll:"series",init:function(a,b){var c=this,e,g=a.series,h;c.chart=a;c.options=b=c.setOptions(b);c.linkedSeries=[];c.bindAxes();d(c,{name:b.name,state:"",visible:!1!==b.visible,selected:!0===b.selected});e=b.events;q(e,function(a,b){z(c, b,a)});if(e&&e.click||b.point&&b.point.events&&b.point.events.click||b.allowPointSelect)a.runTrackerClick=!0;c.getColor();c.getSymbol();n(c.parallelArrays,function(a){c[a+"Data"]=[]});c.setData(b.data,!1);c.isCartesian&&(a.hasCartesianSeries=!0);g.length&&(h=g[g.length-1]);c._i=G(h&&h._i,-1)+1;a.orderSeries(this.insert(g))},insert:function(a){var c=this.options.index,d;if(b(c)){for(d=a.length;d--;)if(c>=G(a[d].options.index,a[d]._i)){a.splice(d+1,0,this);break}-1===d&&a.unshift(this);d+=1}else a.push(this); return G(d,a.length-1)},bindAxes:function(){var b=this,c=b.options,d=b.chart,e;n(b.axisTypes||[],function(g){n(d[g],function(a){e=a.options;if(c[g]===e.index||void 0!==c[g]&&c[g]===e.id||void 0===c[g]&&0===e.index)b.insert(a.series),b[g]=a,a.isDirty=!0});b[g]||b.optionalAxis===g||a.error(18,!0)})},updateParallelArrays:function(a,c){var d=a.series,e=arguments,g=b(c)?function(b){var g="y"===b&&d.toYData?d.toYData(a):a[b];d[b+"Data"][c]=g}:function(a){Array.prototype[c].apply(d[a+"Data"],Array.prototype.slice.call(e, 2))};n(d.parallelArrays,g)},autoIncrement:function(){var b=this.options,c=this.xIncrement,d,e=b.pointIntervalUnit,g=0,c=G(c,b.pointStart,0);this.pointInterval=d=G(this.pointInterval,b.pointInterval,1);e&&(b=new f(c),"day"===e?b=+b[f.hcSetDate](b[f.hcGetDate]()+d):"month"===e?b=+b[f.hcSetMonth](b[f.hcGetMonth]()+d):"year"===e&&(b=+b[f.hcSetFullYear](b[f.hcGetFullYear]()+d)),f.hcHasTimeZone&&(g=a.getTZOffset(b)-a.getTZOffset(c)),d=b-c+g);this.xIncrement=c+d;return c},setOptions:function(a){var b=this.chart, c=b.options,d=c.plotOptions,g=(b.userOptions||{}).plotOptions||{},e=d[this.type];this.userOptions=a;b=w(e,d.series,a);this.tooltipOptions=w(l.tooltip,l.plotOptions.series&&l.plotOptions.series.tooltip,l.plotOptions[this.type].tooltip,c.tooltip.userOptions,d.series&&d.series.tooltip,d[this.type].tooltip,a.tooltip);this.stickyTracking=G(a.stickyTracking,g[this.type]&&g[this.type].stickyTracking,g.series&&g.series.stickyTracking,this.tooltipOptions.shared&&!this.noSharedTooltip?!0:b.stickyTracking); null===e.marker&&delete b.marker;this.zoneAxis=b.zoneAxis;a=this.zones=(b.zones||[]).slice();!b.negativeColor&&!b.negativeFillColor||b.zones||a.push({value:b[this.zoneAxis+"Threshold"]||b.threshold||0,className:"highcharts-negative"});a.length&&t(a[a.length-1].value)&&a.push({});return b},getCyclic:function(a,b,c){var d,g=this.chart,e=this.userOptions,h=a+"Index",f=a+"Counter",k=c?c.length:G(g.options.chart[a+"Count"],g[a+"Count"]);b||(d=G(e[h],e["_"+h]),t(d)||(g.series.length||(g[f]=0),e["_"+h]= d=g[f]%k,g[f]+=1),c&&(b=c[d]));void 0!==d&&(this[h]=d);this[a]=b},getColor:function(){this.getCyclic("color")},getSymbol:function(){this.getCyclic("symbol",this.options.marker.symbol,this.chart.options.symbols)},drawLegendSymbol:a.LegendSymbolMixin.drawLineMarker,setData:function(d,e,f,k){var g=this,l=g.points,u=l&&l.length||0,m,y=g.options,v=g.chart,q=null,p=g.xAxis,E=y.turboThreshold,w=this.xData,t=this.yData,C=(m=g.pointArrayMap)&&m.length;d=d||[];m=d.length;e=G(e,!0);if(!1!==k&&m&&u===m&&!g.cropped&& !g.hasGroupedData&&g.visible)n(d,function(a,b){l[b].update&&a!==y.data[b]&&l[b].update(a,!1,null,!1)});else{g.xIncrement=null;g.colorCounter=0;n(this.parallelArrays,function(a){g[a+"Data"].length=0});if(E&&m>E){for(f=0;null===q&&fl||this.forceCrop))if(c[e-1]w)c=[],d=[];else if(c[0]w)g=this.cropData(this.xData,this.yData,n,w),c=g.xData,d=g.yData,g=g.start,h=!0;for(l=c.length||1;--l;)e=v?m(c[l])-m(c[l-1]):c[l]-c[l-1],0e&&p&&(a.error(15),p=!1);this.cropped=h;this.cropStart=g; this.processedXData=c;this.processedYData=d;this.closestPointRange=f},cropData:function(a,b,c,d){var g=a.length,e=0,h=g,f=G(this.cropShoulder,1),k;for(k=0;k=c){e=Math.max(0,k-f);break}for(c=k;cd){h=c+f;break}return{xData:a.slice(e,h),yData:b.slice(e,h),start:e,end:h}},generatePoints:function(){var a=this.options,b=a.data,c=this.data,d,g=this.processedXData,e=this.processedYData,h=this.pointClass,f=g.length,k=this.cropStart||0,l,m=this.hasGroupedData,a=a.keys,q,v=[],n; c||m||(c=[],c.length=b.length,c=this.data=c);a&&m&&(this.options.keys=!1);for(n=0;n=k&&(e[v-1]||q)<=l,m&&q)if(m=y.length)for(;m--;)"number"===typeof y[m]&&(g[f++]=y[m]);else g[f++]=y;this.dataMin=p(g);this.dataMax=D(g)},translate:function(){this.processedXData||this.processData();this.generatePoints();var a=this.options, c=a.stacking,d=this.xAxis,e=d.categories,g=this.yAxis,h=this.points,f=h.length,l=!!this.modifyValue,m=a.pointPlacement,q="between"===m||b(m),v=a.threshold,n=a.startFromThreshold?v:0,p,w,C,F,x=Number.MAX_VALUE;"between"===m&&(m=.5);b(m)&&(m*=G(a.pointRange||d.pointRange));for(a=0;a=J&&(H.isNull=!0);H.plotX=p=k(Math.min(Math.max(-1E5,d.translate(A,0,0,0,1,m, "flags"===this.type)),1E5));c&&this.visible&&!H.isNull&&z&&z[A]&&(F=this.getStackIndicator(F,A,this.index),D=z[A],J=D.points[F.key],w=J[0],J=J[1],w===n&&F.key===z[A].base&&(w=G(v,g.min)),g.positiveValuesOnly&&0>=w&&(w=null),H.total=H.stackTotal=D.total,H.percentage=D.total&&H.y/D.total*100,H.stackY=J,D.setOffset(this.pointXOffset||0,this.barW||0));H.yBottom=t(w)?g.translate(w,0,1,0,1):null;l&&(J=this.modifyValue(J,H));H.plotY=w="number"===typeof J&&Infinity!==J?Math.min(Math.max(-1E5,g.translate(J, 0,1,0,1)),1E5):void 0;H.isInside=void 0!==w&&0<=w&&w<=g.len&&0<=p&&p<=d.len;H.clientX=q?k(d.translate(A,0,0,0,1,m)):p;H.negative=H.y<(v||0);H.category=e&&void 0!==e[H.x]?e[H.x]:H.x;H.isNull||(void 0!==C&&(x=Math.min(x,Math.abs(p-C))),C=p);H.zone=this.zones.length&&H.getZone()}this.closestPointRangePx=x},getValidPoints:function(a,b){var c=this.chart;return x(a||this.points||[],function(a){return b&&!c.isInsidePlot(a.plotX,a.plotY,c.inverted)?!1:!a.isNull})},setClip:function(a){var b=this.chart,c=this.options, d=b.renderer,g=b.inverted,e=this.clipBox,h=e||b.clipBox,f=this.sharedClipKey||["_sharedClip",a&&a.duration,a&&a.easing,h.height,c.xAxis,c.yAxis].join(),k=b[f],l=b[f+"m"];k||(a&&(h.width=0,g&&(h.x=b.plotSizeX),b[f+"m"]=l=d.clipRect(g?b.plotSizeX+99:-99,g?-b.plotLeft:-b.plotTop,99,g?b.chartWidth:b.chartHeight)),b[f]=k=d.clipRect(h),k.count={length:0});a&&!k.count[this.index]&&(k.count[this.index]=!0,k.count.length+=1);!1!==c.clip&&(this.group.clip(a||e?k:b.clipRect),this.markerGroup.clip(l),this.sharedClipKey= f);a||(k.count[this.index]&&(delete k.count[this.index],--k.count.length),0===k.count.length&&f&&b[f]&&(e||(b[f]=b[f].destroy()),b[f+"m"]&&(b[f+"m"]=b[f+"m"].destroy())))},animate:function(a){var b=this.chart,c=A(this.options.animation),d;a?this.setClip(c):(d=this.sharedClipKey,(a=b[d])&&a.animate({width:b.plotSizeX,x:0},c),b[d+"m"]&&b[d+"m"].animate({width:b.plotSizeX+99,x:0},c),this.animate=null)},afterAnimate:function(){this.setClip();e(this,"afterAnimate");this.finishedAnimating=!0},drawPoints:function(){var a= this.points,b=this.chart,c,d,g,e,h=this.options.marker,f,k,l,m=this[this.specialGroup]||this.markerGroup,q,v=G(h.enabled,this.xAxis.isRadial?!0:null,this.closestPointRangePx>=2*h.radius);if(!1!==h.enabled||this._hasPointMarkers)for(c=0;cv.max}),this.clips=h)},invertGroups:function(a){function b(){n(["group","markerGroup"],function(b){c[b]&&(d.renderer.isVML&&c[b].attr({width:c.yAxis.len,height:c.xAxis.len}), c[b].width=c.yAxis.len,c[b].height=c.xAxis.len,c[b].invert(a))})}var c=this,d=c.chart,g;c.xAxis&&(g=z(d,"resize",b),z(c,"destroy",g),b(a),c.invertGroups=b)},plotGroup:function(a,b,c,d,g){var e=this[a],h=!e;h&&(this[a]=e=this.chart.renderer.g().attr({zIndex:d||.1}).add(g));e.addClass("highcharts-"+b+" highcharts-series-"+this.index+" highcharts-"+this.type+"-series "+(t(this.colorIndex)?"highcharts-color-"+this.colorIndex+" ":"")+(this.options.className||"")+(e.hasClass("highcharts-tracker")?" highcharts-tracker": ""),!0);e.attr({visibility:c})[h?"attr":"animate"](this.getPlotBox());return e},getPlotBox:function(){var a=this.chart,b=this.xAxis,c=this.yAxis;a.inverted&&(b=c,c=this.xAxis);return{translateX:b?b.left:a.plotLeft,translateY:c?c.top:a.plotTop,scaleX:1,scaleY:1}},render:function(){var a=this,b=a.chart,c,d=a.options,g=!!a.animate&&b.renderer.isSVG&&A(d.animation).duration,e=a.visible?"inherit":"hidden",h=d.zIndex,f=a.hasRendered,k=b.seriesGroup,l=b.inverted;c=a.plotGroup("group","series",e,h,k);a.markerGroup= a.plotGroup("markerGroup","markers",e,h,k);g&&a.animate(!0);c.inverted=a.isCartesian?l:!1;a.drawGraph&&(a.drawGraph(),a.applyZones());a.drawDataLabels&&a.drawDataLabels();a.visible&&a.drawPoints();a.drawTracker&&!1!==a.options.enableMouseTracking&&a.drawTracker();a.invertGroups(l);!1===d.clip||a.sharedClipKey||f||c.clip(b.clipRect);g&&a.animate();f||(a.animationTimeout=v(function(){a.afterAnimate()},g));a.isDirty=!1;a.hasRendered=!0},redraw:function(){var a=this.chart,b=this.isDirty||this.isDirtyData, c=this.group,d=this.xAxis,g=this.yAxis;c&&(a.inverted&&c.attr({width:a.plotWidth,height:a.plotHeight}),c.animate({translateX:G(d&&d.left,a.plotLeft),translateY:G(g&&g.top,a.plotTop)}));this.translate();this.render();b&&delete this.kdTree},kdAxisArray:["clientX","plotY"],searchPoint:function(a,b){var c=this.xAxis,d=this.yAxis,g=this.chart.inverted;return this.searchKDTree({clientX:g?c.len-a.chartY+c.pos:a.chartX-c.pos,plotY:g?d.len-a.chartX+d.pos:a.chartY-d.pos},b)},buildKDTree:function(){function a(c, d,e){var g,h;if(h=c&&c.length)return g=b.kdAxisArray[d%e],c.sort(function(a,b){return a[g]-b[g]}),h=Math.floor(h/2),{point:c[h],left:a(c.slice(0,h),d+1,e),right:a(c.slice(h+1),d+1,e)}}this.buildingKdTree=!0;var b=this,c=-1m?"left":"right";v=0>m?"right":"left";b[q]&&(q=c(a,b[q],f+1,k),u=q[h]p;)n--;this.updateParallelArrays(m,"splice",n,0,0);this.updateParallelArrays(m,n);g&&m.name&&(g[p]=m.name);l.splice(n,0,a);q&&(this.data.splice(n,0,null),this.processData());"point"===e.legendType&& this.generatePoints();c&&(f[0]&&f[0].remove?f[0].remove(!1):(f.shift(),this.updateParallelArrays(m,"shift"),l.shift()));this.isDirtyData=this.isDirty=!0;b&&k.redraw(d)},removePoint:function(a,b,c){var d=this,e=d.data,f=e[a],k=d.points,g=d.chart,l=function(){k&&k.length===e.length&&k.splice(a,1);e.splice(a,1);d.options.data.splice(a,1);d.updateParallelArrays(f||{series:d},"splice",a,1);f&&f.destroy();d.isDirty=!0;d.isDirtyData=!0;b&&g.redraw()};J(c,g);b=h(b,!0);f?f.firePointEvent("remove",null,l): l()},remove:function(a,b,c){function d(){e.destroy();f.isDirtyLegend=f.isDirtyBox=!0;f.linkSeries();h(a,!0)&&f.redraw(b)}var e=this,f=e.chart;!1!==c?n(e,"remove",null,d):d()},update:function(a,b){var d=this,e=d.chart,k=d.userOptions,l=d.oldType||d.type,m=a.type||k.type||e.options.chart.type,g=G[l].prototype,q,v=["group","markerGroup","dataLabelsGroup"],n=["navigatorSeries","baseSeries"],p=d.finishedAnimating&&{animation:!1};if(Object.keys&&"data"===Object.keys(a).toString())return this.setData(a.data, b);n=v.concat(n);f(n,function(a){n[a]=d[a];delete d[a]});a=c(k,p,{index:d.index,pointStart:d.xData[0]},{data:d.options.data},a);d.remove(!1,null,!1);for(q in g)d[q]=void 0;t(d,G[m||l].prototype);f(n,function(a){d[a]=n[a]});d.init(e,a);a.zIndex!==k.zIndex&&f(v,function(b){d[b]&&d[b].attr({zIndex:a.zIndex})});d.oldType=l;e.linkSeries();h(b,!0)&&e.redraw(!1)}});t(A.prototype,{update:function(a,b){var d=this.chart;a=d.options[this.coll][this.options.index]=c(this.userOptions,a);this.destroy(!0);this.init(d, t(a,{events:void 0}));d.isDirtyBox=!0;h(b,!0)&&d.redraw()},remove:function(a){for(var b=this.chart,c=this.coll,d=this.series,e=d.length;e--;)d[e]&&d[e].remove(!1);l(b.axes,this);l(b[c],this);x(b.options[c])?b.options[c].splice(this.options.index,1):delete b.options[c];f(b[c],function(a,b){a.options.index=b});this.destroy();b.isDirtyBox=!0;h(a,!0)&&b.redraw()},setTitle:function(a,b){this.update({title:a},b)},setCategories:function(a,b){this.update({categories:a},b)}})})(L);(function(a){var z=a.each, A=a.map,D=a.pick,p=a.Series,k=a.seriesType;k("area","line",{softThreshold:!1,threshold:0},{singleStacks:!1,getStackPoints:function(f){var k=[],p=[],n=this.xAxis,m=this.yAxis,d=m.stacks[this.stackKey],e={},x=this.index,c=m.series,b=c.length,h,w=D(m.options.reversedStacks,!0)?1:-1,q;f=f||this.points;if(this.options.stacking){for(q=0;qa&&n>f?(n=Math.max(a,f),d=2*f-n):np&&d>f?(d=Math.max(p,f),n=2*f-d):d=Math.abs(d)&&.5a.closestPointRange*a.xAxis.transA,k=a.borderWidth=f(e.borderWidth,k?0:1),c=a.yAxis,b=e.threshold,h=a.translatedThreshold=c.getThreshold(b),n=f(e.minPointLength,5),q=a.getColumnMetrics(),p=q.width,t=a.barW=Math.max(p,1+2*k),C=a.pointXOffset=q.offset;d.inverted&&(h-=.5);e.pointPadding&&(t=Math.ceil(t));l.prototype.translate.apply(a);A(a.points,function(e){var k=f(e.yBottom,h),l=999+Math.abs(k),l=Math.min(Math.max(-l,e.plotY),c.len+l),m=e.plotX+C,q=t,u=Math.min(l,k), w,g=Math.max(l,k)-u;n&&Math.abs(g)n?k-n:h-(w?n:0));e.barX=m;e.pointWidth=p;e.tooltipPos=d.inverted?[c.len+c.pos-d.plotLeft-l,a.xAxis.len-m-q/2,g]:[m+q/2,l+c.pos-d.plotTop,g];e.shapeType="rect";e.shapeArgs=a.crispCol.apply(a,e.isNull?[m,h,q,0]:[m,u,q,g])})},getSymbol:a.noop,drawLegendSymbol:a.LegendSymbolMixin.drawRectangle,drawGraph:function(){this.group[this.dense?"addClass":"removeClass"]("highcharts-dense-data")}, drawPoints:function(){var a=this,d=this.chart,e=a.options,f=d.renderer,c=e.animationLimit||250,b;A(a.points,function(h){var l=h.graphic;if(p(h.plotY)&&null!==h.y){b=h.shapeArgs;if(l)l[d.pointCountd;++d)e=n[d],a=2>d||2===d&&/%$/.test(e),n[d]=p(e,[t,f,m,n[2]][d])+ (a?l:0);n[3]>n[2]&&(n[3]=n[2]);return n},getStartAndEndRadians:function(a,f){a=A(a)?a:0;f=A(f)&&f>a&&360>f-a?f:a+360;return{start:z*(a+-90),end:z*(f+-90)}}}})(L);(function(a){var z=a.addEvent,A=a.CenteredSeriesMixin,D=a.defined,p=a.each,k=a.extend,f=A.getStartAndEndRadians,l=a.inArray,t=a.noop,n=a.pick,m=a.Point,d=a.Series,e=a.seriesType,x=a.setAnimation;e("pie","line",{center:[null,null],clip:!1,colorByPoint:!0,dataLabels:{distance:30,enabled:!0,formatter:function(){return this.point.isNull?void 0: this.point.name},x:0},ignoreHiddenPoint:!0,legendType:"point",marker:null,size:null,showInLegend:!1,slicedOffset:10,stickyTracking:!1,tooltip:{followPointer:!0}},{isCartesian:!1,requireSorting:!1,directTouch:!0,noSharedTooltip:!0,trackerGroups:["group","dataLabelsGroup"],axisTypes:[],pointAttribs:a.seriesTypes.column.prototype.pointAttribs,animate:function(a){var b=this,c=b.points,d=b.startAngleRad;a||(p(c,function(a){var c=a.graphic,e=a.shapeArgs;c&&(c.attr({r:a.startR||b.center[3]/2,start:d,end:d}), c.animate({r:e.r,start:e.start,end:e.end},b.options.animation))}),b.animate=null)},updateTotals:function(){var a,b=0,d=this.points,e=d.length,f,k=this.options.ignoreHiddenPoint;for(a=0;a1.5*Math.PI?m-=2*Math.PI:m<-Math.PI/2&&(m+=2*Math.PI);g.slicedTranslation={translateX:Math.round(Math.cos(m)*d),translateY:Math.round(Math.sin(m)*d)};l=Math.cos(m)*a[2]/2;y=Math.sin(m)*a[2]/2;g.tooltipPos=[a[0]+.7*l,a[1]+.7*y];g.half=m<-Math.PI/2||m>Math.PI/2?1:0;g.angle=m;k=Math.min(e,g.labelDistance/ 5);g.labelPos=[a[0]+l+Math.cos(m)*g.labelDistance,a[1]+y+Math.sin(m)*g.labelDistance,a[0]+l+Math.cos(m)*k,a[1]+y+Math.sin(m)*k,a[0]+l,a[1]+y,0>g.labelDistance?"center":g.half?"right":"left",m]}},drawGraph:null,drawPoints:function(){var a=this,b=a.chart.renderer,d,e,f;p(a.points,function(c){e=c.graphic;c.isNull?e&&(c.graphic=e.destroy()):(f=c.shapeArgs,d=c.getTranslate(),e?e.setRadialReference(a.center).animate(k(f,d)):(c.graphic=e=b[c.shapeType](f).setRadialReference(a.center).attr(d).add(a.group), c.visible||e.attr({visibility:"hidden"})),e.addClass(c.getClassName()))})},searchPoint:t,sortByAngle:function(a,b){a.sort(function(a,c){return void 0!==a.angle&&(c.angle-a.angle)*b})},drawLegendSymbol:a.LegendSymbolMixin.drawRectangle,getCenter:A.getCenter,getSymbol:t},{init:function(){m.prototype.init.apply(this,arguments);var a=this,b;a.name=n(a.name,"Slice");b=function(b){a.slice("select"===b.type)};z(a,"select",b);z(a,"unselect",b);return a},isValid:function(){return a.isNumber(this.y,!0)&&0<= this.y},setVisible:function(a,b){var c=this,d=c.series,e=d.chart,f=d.options.ignoreHiddenPoint;b=n(b,f);a!==c.visible&&(c.visible=c.options.visible=a=void 0===a?!c.visible:a,d.options.data[l(c,d.data)]=c.options,p(["graphic","dataLabel","connector","shadowGroup"],function(b){if(c[b])c[b][a?"show":"hide"](!0)}),c.legendItem&&e.legend.colorizeItem(c,a),a||"hover"!==c.state||c.setState(""),f&&(d.isDirty=!0),b&&e.redraw())},slice:function(a,b,d){var c=this.series;x(d,c.chart);n(b,!0);this.sliced=this.options.sliced= D(a)?a:!this.sliced;c.options.data[l(this,c.data)]=this.options;this.graphic.animate(this.getTranslate())},getTranslate:function(){return this.sliced?this.slicedTranslation:{translateX:0,translateY:0}},haloPath:function(a){var b=this.shapeArgs;return this.sliced||!this.visible?[]:this.series.chart.renderer.symbols.arc(b.x,b.y,b.r+a,b.r+a,{innerR:this.shapeArgs.r-1,start:b.start,end:b.end})}})})(L);(function(a){var z=a.addEvent,A=a.arrayMax,D=a.defined,p=a.each,k=a.extend,f=a.format,l=a.map,t=a.merge, n=a.noop,m=a.pick,d=a.relativeLength,e=a.Series,x=a.seriesTypes,c=a.stableSort;a.distribute=function(a,d){function b(a,b){return a.target-b.target}var e,f=!0,h=a,k=[],n;n=0;for(e=a.length;e--;)n+=a[e].size;if(n>d){c(a,function(a,b){return(b.rank||0)-(a.rank||0)});for(n=e=0;n<=d;)n+=a[e].size,e++;k=a.splice(e-1,a.length)}c(a,b);for(a=l(a,function(a){return{size:a.size,targets:[a.target],align:m(a.align,.5)}});f;){for(e=a.length;e--;)f=a[e],n=(Math.min.apply(0,f.targets)+Math.max.apply(0,f.targets))/ 2,f.pos=Math.min(Math.max(0,n-f.size*f.align),d-f.size);e=a.length;for(f=!1;e--;)0a[e].pos&&(a[e-1].size+=a[e].size,a[e-1].targets=a[e-1].targets.concat(a[e].targets),a[e-1].align=.5,a[e-1].pos+a[e-1].size>d&&(a[e-1].pos=d-a[e-1].size),a.splice(e,1),f=!0)}e=0;p(a,function(a){var b=0;p(a.targets,function(){h[e].pos=a.pos+b;b+=h[e].size;e++})});h.push.apply(h,k);c(h,b)};e.prototype.drawDataLabels=function(){function b(a,b){var c=b.filter;return c?(b=c.operator,a=a[c.property], c=c.value,"\x3e"===b&&a>c||"\x3c"===b&&a=c||"\x3c\x3d"===b&&a<=c||"\x3d\x3d"===b&&a==c||"\x3d\x3d\x3d"===b&&a===c?!0:!1):!0}var c=this,d=c.options,e=d.dataLabels,k=c.points,l,n,F=c.hasRendered||0,v,H,y=m(e.defer,!!d.animation),x=c.chart.renderer;if(e.enabled||c._hasPointLabels)c.dlProcessOptions&&c.dlProcessOptions(e),H=c.plotGroup("dataLabelsGroup","data-labels",y&&!F?"hidden":"visible",e.zIndex||6),y&&(H.attr({opacity:+F}),F||z(c,"afterAnimate",function(){c.visible&&H.show(!0); H[d.animation?"animate":"attr"]({opacity:1},{duration:200})})),n=e,p(k,function(d){var h,g=d.dataLabel,k,q,p=d.connector,u=!g,w;l=d.dlOptions||d.options&&d.options.dataLabels;(h=m(l&&l.enabled,n.enabled)&&!d.isNull)&&(h=!0===b(d,l||e));h&&(e=t(n,l),k=d.getLabelConfig(),w=e[d.formatPrefix+"Format"]||e.format,v=D(w)?f(w,k):(e[d.formatPrefix+"Formatter"]||e.formatter).call(k,e),k=e.rotation,q={r:e.borderRadius||0,rotation:k,padding:e.padding,zIndex:1},a.objectEach(q,function(a,b){void 0===a&&delete q[b]})); !g||h&&D(v)?h&&D(v)&&(g?q.text=v:(g=d.dataLabel=k?x.text(v,0,-9999).addClass("highcharts-data-label"):x.label(v,0,-9999,e.shape,null,null,e.useHTML,null,"data-label"),g.addClass(" highcharts-data-label-color-"+d.colorIndex+" "+(e.className||"")+(e.useHTML?"highcharts-tracker":""))),g.attr(q),g.added||g.add(H),c.alignDataLabel(d,g,e,null,u)):(d.dataLabel=g=g.destroy(),p&&(d.connector=p.destroy()))})};e.prototype.alignDataLabel=function(a,c,d,e,f){var b=this.chart,h=b.inverted,l=m(a.dlBox&&a.dlBox.centerX, a.plotX,-9999),n=m(a.plotY,-9999),q=c.getBBox(),p,t=d.rotation,u=d.align,w=this.visible&&(a.series.forceDL||b.isInsidePlot(l,Math.round(n),h)||e&&b.isInsidePlot(l,h?e.x+1:e.y+e.height-1,h)),g="justify"===m(d.overflow,"justify");if(w&&(p=b.renderer.fontMetrics(void 0,c).b,e=k({x:h?this.yAxis.len-n:l,y:Math.round(h?this.xAxis.len-l:n),width:0,height:0},e),k(d,{width:q.width,height:q.height}),t?(g=!1,l=b.renderer.rotCorr(p,t),l={x:e.x+d.x+e.width/2+l.x,y:e.y+d.y+{top:0,middle:.5,bottom:1}[d.verticalAlign]* e.height},c[f?"attr":"animate"](l).attr({align:u}),n=(t+720)%360,n=180n,"left"===u?l.y-=n?q.height:0:"center"===u?(l.x-=q.width/2,l.y-=q.height/2):"right"===u&&(l.x-=q.width,l.y-=n?0:q.height)):(c.align(d,null,e),l=c.alignAttr),g?a.isLabelJustified=this.justifyDataLabel(c,d,l,q,e,f):m(d.crop,!0)&&(w=b.isInsidePlot(l.x,l.y)&&b.isInsidePlot(l.x+q.width,l.y+q.height)),d.shape&&!t))c[f?"attr":"animate"]({anchorX:h?b.plotWidth-a.plotY:a.plotX,anchorY:h?b.plotHeight-a.plotX:a.plotY});w||(c.attr({y:-9999}), c.placed=!1)};e.prototype.justifyDataLabel=function(a,c,d,e,f,k){var b=this.chart,h=c.align,l=c.verticalAlign,m,n,q=a.box?0:a.padding||0;m=d.x+q;0>m&&("right"===h?c.align="left":c.x=-m,n=!0);m=d.x+e.width-q;m>b.plotWidth&&("left"===h?c.align="right":c.x=b.plotWidth-m,n=!0);m=d.y+q;0>m&&("bottom"===l?c.verticalAlign="top":c.y=-m,n=!0);m=d.y+e.height-q;m>b.plotHeight&&("top"===l?c.verticalAlign="bottom":c.y=b.plotHeight-m,n=!0);n&&(a.placed=!k,a.align(c,null,f));return n};x.pie&&(x.pie.prototype.drawDataLabels= function(){var b=this,c=b.data,d,f=b.chart,k=b.options.dataLabels,l=m(k.connectorPadding,10),n=m(k.connectorWidth,1),t=f.plotWidth,v=f.plotHeight,x,y=b.center,E=y[2]/2,u=y[1],z,g,r,N,K=[[],[]],B,O,L,Q,P=[0,0,0,0];b.visible&&(k.enabled||b._hasPointLabels)&&(p(c,function(a){a.dataLabel&&a.visible&&a.dataLabel.shortened&&(a.dataLabel.attr({width:"auto"}).css({width:"auto",textOverflow:"clip"}),a.dataLabel.shortened=!1)}),e.prototype.drawDataLabels.apply(b),p(c,function(a){a.dataLabel&&a.visible&&(K[a.half].push(a), a.dataLabel._pos=null)}),p(K,function(c,e){var h,n,q=c.length,w=[],C;if(q)for(b.sortByAngle(c,e-.5),0d.bottom-2?h:O,e,d),z._attr={visibility:L,align:r[6]},z._pos={x:B+k.x+({left:l,right:-l}[r[6]]||0),y:O+k.y-10},r.x=B,r.y=O,m(k.crop,!0)&&(g=z.getBBox().width,h=null,B-gt-l&&(h=Math.round(B+g-t+l), P[1]=Math.max(h,P[1])),0>O-N/2?P[0]=Math.max(Math.round(-O+N/2),P[0]):O+N/2>v&&(P[2]=Math.max(Math.round(O+N/2-v),P[2])),z.sideOverflow=h)}),0===A(P)||this.verifyDataLabelOverflow(P))&&(this.placeDataLabels(),n&&p(this.points,function(a){var c;x=a.connector;if((z=a.dataLabel)&&z._pos&&a.visible&&0m(this.translatedThreshold,h.yAxis.len)),p=m(d.inside,!!this.options.stacking);l&&(f=t(l),0>f.y&&(f.height+=f.y,f.y=0),l=f.y+f.height-h.yAxis.len,0a+c||e+hb+d||f+kthis.pointCount))},pan:function(a,b){var c=this,d=c.hoverPoints,e;d&&l(d,function(a){a.setState()});l("xy"===b?[1,0]:[1],function(b){b=c[b?"xAxis":"yAxis"][0];var d=b.horiz,f=a[d?"chartX":"chartY"],d=d?"mouseDownX":"mouseDownY",g=c[d],h=(b.pointRange||0)/2,k=b.getExtremes(),l=b.toValue(g-f,!0)+h,m=b.toValue(g+ b.len-f,!0)-h,n=m= f(l.minWidth,0)&&this.chartHeight>=f(l.minHeight,0)}).call(this)&&k.push(a._id)};z.prototype.currentOptions=function(f){function n(d,e,f,c){var b;a.objectEach(d,function(a,d){if(!c&&-1