/*
 Highcharts JS v5.0.4 (2016-11-25)

 (c) 2009-2016 Torstein Honsi

 License: www.highcharts.com/license
*/
(function(L,a){"object"===typeof module&&module.exports?module.exports=L.document?a(L):a:L.Highcharts=a(L)})("undefined"!==typeof window?window:this,function(L){L=function(){var a=window,x=a.document,A=a.navigator&&a.navigator.userAgent||"",F=x&&x.createElementNS&&!!x.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,H=/(edge|msie|trident)/i.test(A)&&!window.opera,p=!F,e=/Firefox/.test(A),g=e&&4>parseInt(A.split("Firefox/")[1],10);return a.Highcharts?a.Highcharts.error(16,!0):{product:"Highcharts",
version:"5.0.4",deg2rad:2*Math.PI/360,doc:x,hasBidiBug:g,hasTouch:x&&void 0!==x.documentElement.ontouchstart,isMS:H,isWebKit:/AppleWebKit/.test(A),isFirefox:e,isTouchDevice:/(Mobile|Android|Windows Phone)/.test(A),SVG_NS:"http://www.w3.org/2000/svg",chartCount:0,seriesTypes:{},symbolSizes:{},svg:F,vml:p,win:a,charts:[],marginNames:["plotTop","marginRight","marginBottom","plotLeft"],noop:function(){}}}();(function(a){var x=[],A=a.charts,F=a.doc,H=a.win;a.error=function(a,e){a="Highcharts error #"+
a+": www.highcharts.com/errors/"+a;if(e)throw Error(a);H.console&&console.log(a)};a.Fx=function(a,e,g){this.options=e;this.elem=a;this.prop=g};a.Fx.prototype={dSetter:function(){var a=this.paths[0],e=this.paths[1],g=[],l=this.now,m=a.length,k;if(1===l)g=this.toD;else if(m===e.length&&1>l)for(;m--;)k=parseFloat(a[m]),g[m]=isNaN(k)?a[m]:l*parseFloat(e[m]-k)+k;else g=e;this.elem.animProp="d";this.elem.attr("d",g);this.elem.animProp=null},update:function(){var a=this.elem,e=this.prop,g=this.now,l=this.options.step;
if(this[e+"Setter"])this[e+"Setter"]();else a.attr?a.element&&(a.animProp=e,a.attr(e,g),a.animProp=null):a.style[e]=g+this.unit;l&&l.call(a,g,this)},run:function(a,e,g){var l=this,p=function(a){return p.stopped?!1:l.step(a)},k;this.startTime=+new Date;this.start=a;this.end=e;this.unit=g;this.now=this.start;this.pos=0;p.elem=this.elem;p.prop=this.prop;p()&&1===x.push(p)&&(p.timerId=setInterval(function(){for(k=0;k<x.length;k++)x[k]()||x.splice(k--,1);x.length||clearInterval(p.timerId)},13))},step:function(a){var e=
+new Date,g,l=this.options;g=this.elem;var p=l.complete,k=l.duration,d=l.curAnim,b;if(g.attr&&!g.element)g=!1;else if(a||e>=k+this.startTime){this.now=this.end;this.pos=1;this.update();a=d[this.prop]=!0;for(b in d)!0!==d[b]&&(a=!1);a&&p&&p.call(g);g=!1}else this.pos=l.easing((e-this.startTime)/k),this.now=this.start+(this.end-this.start)*this.pos,this.update(),g=!0;return g},initPath:function(p,e,g){function l(a){var c,b;for(n=a.length;n--;)c="M"===a[n]||"L"===a[n],b=/[a-zA-Z]/.test(a[n+3]),c&&!b&&
a.splice(n+1,0,a[n+1],a[n+2],a[n+1],a[n+2])}function m(a,b){for(;a.length<c;){a[0]=b[c-a.length];var h=a.slice(0,t);[].splice.apply(a,[0,0].concat(h));E&&(h=a.slice(a.length-t),[].splice.apply(a,[a.length,0].concat(h)),n--)}a[0]="M"}function k(a,b){for(var d=(c-a.length)/t;0<d&&d--;)h=a.slice().splice(a.length/q-t,t*q),h[0]=b[c-t-d*t],u&&(h[t-6]=h[t-2],h[t-5]=h[t-1]),[].splice.apply(a,[a.length/q,0].concat(h)),E&&d--}e=e||"";var d,b=p.startX,z=p.endX,u=-1<e.indexOf("C"),t=u?7:3,c,h,n;e=e.split(" ");
g=g.slice();var E=p.isArea,q=E?2:1,D;u&&(l(e),l(g));if(b&&z){for(n=0;n<b.length;n++)if(b[n]===z[0]){d=n;break}else if(b[0]===z[z.length-b.length+n]){d=n;D=!0;break}void 0===d&&(e=[])}e.length&&a.isNumber(d)&&(c=g.length+d*q*t,D?(m(e,g),k(g,e)):(m(g,e),k(e,g)));return[e,g]}};a.extend=function(a,e){var g;a||(a={});for(g in e)a[g]=e[g];return a};a.merge=function(){var p,e=arguments,g,l={},m=function(k,d){var b,e;"object"!==typeof k&&(k={});for(e in d)d.hasOwnProperty(e)&&(b=d[e],a.isObject(b,!0)&&"renderTo"!==
e&&"number"!==typeof b.nodeType?k[e]=m(k[e]||{},b):k[e]=d[e]);return k};!0===e[0]&&(l=e[1],e=Array.prototype.slice.call(e,2));g=e.length;for(p=0;p<g;p++)l=m(l,e[p]);return l};a.pInt=function(a,e){return parseInt(a,e||10)};a.isString=function(a){return"string"===typeof a};a.isArray=function(a){a=Object.prototype.toString.call(a);return"[object Array]"===a||"[object Array Iterator]"===a};a.isObject=function(p,e){return p&&"object"===typeof p&&(!e||!a.isArray(p))};a.isNumber=function(a){return"number"===
typeof a&&!isNaN(a)};a.erase=function(a,e){for(var g=a.length;g--;)if(a[g]===e){a.splice(g,1);break}};a.defined=function(a){return void 0!==a&&null!==a};a.attr=function(p,e,g){var l,m;if(a.isString(e))a.defined(g)?p.setAttribute(e,g):p&&p.getAttribute&&(m=p.getAttribute(e));else if(a.defined(e)&&a.isObject(e))for(l in e)p.setAttribute(l,e[l]);return m};a.splat=function(p){return a.isArray(p)?p:[p]};a.syncTimeout=function(a,e,g){if(e)return setTimeout(a,e,g);a.call(0,g)};a.pick=function(){var a=arguments,
e,g,l=a.length;for(e=0;e<l;e++)if(g=a[e],void 0!==g&&null!==g)return g};a.css=function(p,e){a.isMS&&!a.svg&&e&&void 0!==e.opacity&&(e.filter="alpha(opacity\x3d"+100*e.opacity+")");a.extend(p.style,e)};a.createElement=function(p,e,g,l,m){p=F.createElement(p);var k=a.css;e&&a.extend(p,e);m&&k(p,{padding:0,border:"none",margin:0});g&&k(p,g);l&&l.appendChild(p);return p};a.extendClass=function(p,e){var g=function(){};g.prototype=new p;a.extend(g.prototype,e);return g};a.pad=function(a,e,g){return Array((e||
2)+1-String(a).length).join(g||0)+a};a.relativeLength=function(a,e){return/%$/.test(a)?e*parseFloat(a)/100:parseFloat(a)};a.wrap=function(a,e,g){var l=a[e];a[e]=function(){var a=Array.prototype.slice.call(arguments),e=arguments,d=this;d.proceed=function(){l.apply(d,arguments.length?arguments:e)};a.unshift(l);a=g.apply(this,a);d.proceed=null;return a}};a.getTZOffset=function(p){var e=a.Date;return 6E4*(e.hcGetTimezoneOffset&&e.hcGetTimezoneOffset(p)||e.hcTimezoneOffset||0)};a.dateFormat=function(p,
e,g){if(!a.defined(e)||isNaN(e))return a.defaultOptions.lang.invalidDate||"";p=a.pick(p,"%Y-%m-%d %H:%M:%S");var l=a.Date,m=new l(e-a.getTZOffset(e)),k,d=m[l.hcGetHours](),b=m[l.hcGetDay](),z=m[l.hcGetDate](),u=m[l.hcGetMonth](),t=m[l.hcGetFullYear](),c=a.defaultOptions.lang,h=c.weekdays,n=c.shortWeekdays,E=a.pad,l=a.extend({a:n?n[b]:h[b].substr(0,3),A:h[b],d:E(z),e:E(z,2," "),w:b,b:c.shortMonths[u],B:c.months[u],m:E(u+1),y:t.toString().substr(2,2),Y:t,H:E(d),k:d,I:E(d%12||12),l:d%12||12,M:E(m[l.hcGetMinutes]()),
p:12>d?"AM":"PM",P:12>d?"am":"pm",S:E(m.getSeconds()),L:E(Math.round(e%1E3),3)},a.dateFormats);for(k in l)for(;-1!==p.indexOf("%"+k);)p=p.replace("%"+k,"function"===typeof l[k]?l[k](e):l[k]);return g?p.substr(0,1).toUpperCase()+p.substr(1):p};a.formatSingle=function(p,e){var g=/\.([0-9])/,l=a.defaultOptions.lang;/f$/.test(p)?(g=(g=p.match(g))?g[1]:-1,null!==e&&(e=a.numberFormat(e,g,l.decimalPoint,-1<p.indexOf(",")?l.thousandsSep:""))):e=a.dateFormat(p,e);return e};a.format=function(p,e){for(var g=
"{",l=!1,m,k,d,b,z=[],u;p;){g=p.indexOf(g);if(-1===g)break;m=p.slice(0,g);if(l){m=m.split(":");k=m.shift().split(".");b=k.length;u=e;for(d=0;d<b;d++)u=u[k[d]];m.length&&(u=a.formatSingle(m.join(":"),u));z.push(u)}else z.push(m);p=p.slice(g+1);g=(l=!l)?"}":"{"}z.push(p);return z.join("")};a.getMagnitude=function(a){return Math.pow(10,Math.floor(Math.log(a)/Math.LN10))};a.normalizeTickInterval=function(p,e,g,l,m){var k,d=p;g=a.pick(g,1);k=p/g;e||(e=m?[1,1.2,1.5,2,2.5,3,4,5,6,8,10]:[1,2,2.5,5,10],!1===
l&&(1===g?e=a.grep(e,function(a){return 0===a%1}):.1>=g&&(e=[1/g])));for(l=0;l<e.length&&!(d=e[l],m&&d*g>=p||!m&&k<=(e[l]+(e[l+1]||e[l]))/2);l++);return d*g};a.stableSort=function(a,e){var g=a.length,l,m;for(m=0;m<g;m++)a[m].safeI=m;a.sort(function(a,d){l=e(a,d);return 0===l?a.safeI-d.safeI:l});for(m=0;m<g;m++)delete a[m].safeI};a.arrayMin=function(a){for(var e=a.length,g=a[0];e--;)a[e]<g&&(g=a[e]);return g};a.arrayMax=function(a){for(var e=a.length,g=a[0];e--;)a[e]>g&&(g=a[e]);return g};a.destroyObjectProperties=
function(a,e){for(var g in a)a[g]&&a[g]!==e&&a[g].destroy&&a[g].destroy(),delete a[g]};a.discardElement=function(p){var e=a.garbageBin;e||(e=a.createElement("div"));p&&e.appendChild(p);e.innerHTML=""};a.correctFloat=function(a,e){return parseFloat(a.toPrecision(e||14))};a.setAnimation=function(p,e){e.renderer.globalAnimation=a.pick(p,e.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,e,g,l){p=+p||0;e=+e;var m=a.defaultOptions.lang,k=(p.toString().split(".")[1]||"").length,d,b,z=Math.abs(p);-1===e?e=Math.min(k,20):a.isNumber(e)||(e=2);d=String(a.pInt(z.toFixed(e)));b=3<d.length?d.length%3:0;g=a.pick(g,m.decimalPoint);l=a.pick(l,m.thousandsSep);p=(0>p?"-":"")+(b?d.substr(0,b)+l:"");p+=d.substr(b).replace(/(\d{3})(?=\d)/g,"$1"+l);e&&(l=Math.abs(z-d+Math.pow(10,-Math.max(e,k)-1)),p+=g+l.toFixed(e).slice(2));
return p};Math.easeInOutSine=function(a){return-.5*(Math.cos(Math.PI*a)-1)};a.getStyle=function(p,e){return"width"===e?Math.min(p.offsetWidth,p.scrollWidth)-a.getStyle(p,"padding-left")-a.getStyle(p,"padding-right"):"height"===e?Math.min(p.offsetHeight,p.scrollHeight)-a.getStyle(p,"padding-top")-a.getStyle(p,"padding-bottom"):(p=H.getComputedStyle(p,void 0))&&a.pInt(p.getPropertyValue(e))};a.inArray=function(a,e){return e.indexOf?e.indexOf(a):[].indexOf.call(e,a)};a.grep=function(a,e){return[].filter.call(a,
e)};a.map=function(a,e){for(var g=[],l=0,m=a.length;l<m;l++)g[l]=e.call(a[l],a[l],l,a);return g};a.offset=function(a){var e=F.documentElement;a=a.getBoundingClientRect();return{top:a.top+(H.pageYOffset||e.scrollTop)-(e.clientTop||0),left:a.left+(H.pageXOffset||e.scrollLeft)-(e.clientLeft||0)}};a.stop=function(a,e){for(var g=x.length;g--;)x[g].elem!==a||e&&e!==x[g].prop||(x[g].stopped=!0)};a.each=function(a,e,g){return Array.prototype.forEach.call(a,e,g)};a.addEvent=function(p,e,g){function l(a){a.target=
a.srcElement||H;g.call(p,a)}var m=p.hcEvents=p.hcEvents||{};p.addEventListener?p.addEventListener(e,g,!1):p.attachEvent&&(p.hcEventsIE||(p.hcEventsIE={}),p.hcEventsIE[g.toString()]=l,p.attachEvent("on"+e,l));m[e]||(m[e]=[]);m[e].push(g);return function(){a.removeEvent(p,e,g)}};a.removeEvent=function(p,e,g){function l(a,b){p.removeEventListener?p.removeEventListener(a,b,!1):p.attachEvent&&(b=p.hcEventsIE[b.toString()],p.detachEvent("on"+a,b))}function m(){var a,b;if(p.nodeName)for(b in e?(a={},a[e]=
!0):a=d,a)if(d[b])for(a=d[b].length;a--;)l(b,d[b][a])}var k,d=p.hcEvents,b;d&&(e?(k=d[e]||[],g?(b=a.inArray(g,k),-1<b&&(k.splice(b,1),d[e]=k),l(e,g)):(m(),d[e]=[])):(m(),p.hcEvents={}))};a.fireEvent=function(p,e,g,l){var m;m=p.hcEvents;var k,d;g=g||{};if(F.createEvent&&(p.dispatchEvent||p.fireEvent))m=F.createEvent("Events"),m.initEvent(e,!0,!0),a.extend(m,g),p.dispatchEvent?p.dispatchEvent(m):p.fireEvent(e,m);else if(m)for(m=m[e]||[],k=m.length,g.target||a.extend(g,{preventDefault:function(){g.defaultPrevented=
!0},target:p,type:e}),e=0;e<k;e++)(d=m[e])&&!1===d.call(p,g)&&g.preventDefault();l&&!g.defaultPrevented&&l(g)};a.animate=function(p,e,g){var l,m="",k,d,b;a.isObject(g)||(l=arguments,g={duration:l[2],easing:l[3],complete:l[4]});a.isNumber(g.duration)||(g.duration=400);g.easing="function"===typeof g.easing?g.easing:Math[g.easing]||Math.easeInOutSine;g.curAnim=a.merge(e);for(b in e)a.stop(p,b),d=new a.Fx(p,g,b),k=null,"d"===b?(d.paths=d.initPath(p,p.d,e.d),d.toD=e.d,l=0,k=1):p.attr?l=p.attr(b):(l=parseFloat(a.getStyle(p,
b))||0,"opacity"!==b&&(m="px")),k||(k=e[b]),k.match&&k.match("px")&&(k=k.replace(/px/g,"")),d.run(l,k,m)};a.seriesType=function(p,e,g,l,m){var k=a.getOptions(),d=a.seriesTypes;k.plotOptions[p]=a.merge(k.plotOptions[e],g);d[p]=a.extendClass(d[e]||function(){},l);d[p].prototype.type=p;m&&(d[p].prototype.pointClass=a.extendClass(a.Point,m));return d[p]};a.uniqueKey=function(){var a=Math.random().toString(36).substring(2,9),e=0;return function(){return"highcharts-"+a+"-"+e++}}();H.jQuery&&(H.jQuery.fn.highcharts=
function(){var p=[].slice.call(arguments);if(this[0])return p[0]?(new (a[a.isString(p[0])?p.shift():"Chart"])(this[0],p[0],p[1]),this):A[a.attr(this[0],"data-highcharts-chart")]});F&&!F.defaultView&&(a.getStyle=function(p,e){var g={width:"clientWidth",height:"clientHeight"}[e];if(p.style[e])return a.pInt(p.style[e]);"opacity"===e&&(e="filter");if(g)return p.style.zoom=1,Math.max(p[g]-2*a.getStyle(p,"padding"),0);p=p.currentStyle[e.replace(/\-(\w)/g,function(a,e){return e.toUpperCase()})];"filter"===
e&&(p=p.replace(/alpha\(opacity=([0-9]+)\)/,function(a,e){return e/100}));return""===p?1:a.pInt(p)});Array.prototype.forEach||(a.each=function(a,e,g){for(var l=0,m=a.length;l<m;l++)if(!1===e.call(g,a[l],l,a))return l});Array.prototype.indexOf||(a.inArray=function(a,e){var g,l=0;if(e)for(g=e.length;l<g;l++)if(e[l]===a)return l;return-1});Array.prototype.filter||(a.grep=function(a,e){for(var g=[],l=0,m=a.length;l<m;l++)e(a[l],l)&&g.push(a[l]);return g})})(L);(function(a){var x=a.each,A=a.isNumber,F=
a.map,H=a.merge,p=a.pInt;a.Color=function(e){if(!(this instanceof a.Color))return new a.Color(e);this.init(e)};a.Color.prototype={parsers:[{regex:/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]?(?:\.[0-9]+)?)\s*\)/,parse:function(a){return[p(a[1]),p(a[2]),p(a[3]),parseFloat(a[4],10)]}},{regex:/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/,parse:function(a){return[p(a[1],16),p(a[2],16),p(a[3],16),1]}},{regex:/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/,
parse:function(a){return[p(a[1]),p(a[2]),p(a[3]),1]}}],names:{white:"#ffffff",black:"#000000"},init:function(e){var g,l,m,k;if((this.input=e=this.names[e]||e)&&e.stops)this.stops=F(e.stops,function(d){return new a.Color(d[1])});else for(m=this.parsers.length;m--&&!l;)k=this.parsers[m],(g=k.regex.exec(e))&&(l=k.parse(g));this.rgba=l||[]},get:function(a){var e=this.input,l=this.rgba,m;this.stops?(m=H(e),m.stops=[].concat(m.stops),x(this.stops,function(e,d){m.stops[d]=[m.stops[d][0],e.get(a)]})):m=l&&
A(l[0])?"rgb"===a||!a&&1===l[3]?"rgb("+l[0]+","+l[1]+","+l[2]+")":"a"===a?l[3]:"rgba("+l.join(",")+")":e;return m},brighten:function(a){var e,l=this.rgba;if(this.stops)x(this.stops,function(e){e.brighten(a)});else if(A(a)&&0!==a)for(e=0;3>e;e++)l[e]+=p(255*a),0>l[e]&&(l[e]=0),255<l[e]&&(l[e]=255);return this},setOpacity:function(a){this.rgba[3]=a;return this}};a.color=function(e){return new a.Color(e)}})(L);(function(a){var x,A,F=a.addEvent,H=a.animate,p=a.attr,e=a.charts,g=a.color,l=a.css,m=a.createElement,
k=a.defined,d=a.deg2rad,b=a.destroyObjectProperties,z=a.doc,u=a.each,t=a.extend,c=a.erase,h=a.grep,n=a.hasTouch,E=a.isArray,q=a.isFirefox,D=a.isMS,B=a.isObject,I=a.isString,w=a.isWebKit,K=a.merge,r=a.noop,C=a.pick,G=a.pInt,N=a.removeEvent,f=a.splat,y=a.stop,R=a.svg,P=a.SVG_NS,Q=a.symbolSizes,J=a.win;x=a.SVGElement=function(){return this};x.prototype={opacity:1,SVG_NS:P,textProps:"direction fontSize fontWeight fontFamily fontStyle color lineHeight width textDecoration textOverflow textOutline".split(" "),
init:function(a,f){this.element="span"===f?m(f):z.createElementNS(this.SVG_NS,f);this.renderer=a},animate:function(a,f,c){(f=C(f,this.renderer.globalAnimation,!0))?(c&&(f.complete=c),H(this,a,f)):this.attr(a,null,c);return this},colorGradient:function(v,f,c){var b=this.renderer,y,M,h,d,n,r,q,O,e,t,g,l=[],J;v.linearGradient?M="linearGradient":v.radialGradient&&(M="radialGradient");if(M){h=v[M];n=b.gradients;q=v.stops;t=c.radialReference;E(h)&&(v[M]=h={x1:h[0],y1:h[1],x2:h[2],y2:h[3],gradientUnits:"userSpaceOnUse"});
"radialGradient"===M&&t&&!k(h.gradientUnits)&&(d=h,h=K(h,b.getRadialAttr(t,d),{gradientUnits:"userSpaceOnUse"}));for(g in h)"id"!==g&&l.push(g,h[g]);for(g in q)l.push(q[g]);l=l.join(",");n[l]?t=n[l].attr("id"):(h.id=t=a.uniqueKey(),n[l]=r=b.createElement(M).attr(h).add(b.defs),r.radAttr=d,r.stops=[],u(q,function(v){0===v[1].indexOf("rgba")?(y=a.color(v[1]),O=y.get("rgb"),e=y.get("a")):(O=v[1],e=1);v=b.createElement("stop").attr({offset:v[0],"stop-color":O,"stop-opacity":e}).add(r);r.stops.push(v)}));
J="url("+b.url+"#"+t+")";c.setAttribute(f,J);c.gradient=l;v.toString=function(){return J}}},applyTextOutline:function(a){var v=this.element,f,b,y;-1!==a.indexOf("contrast")&&(a=a.replace(/contrast/g,this.renderer.getContrast(v.style.fill)));this.fakeTS=!0;this.ySetter=this.xSetter;f=[].slice.call(v.getElementsByTagName("tspan"));a=a.split(" ");b=a[a.length-1];(y=a[0])&&"none"!==y&&(y=y.replace(/(^[\d\.]+)(.*?)$/g,function(a,v,f){return 2*v+f}),u(f,function(a){"highcharts-text-outline"===a.getAttribute("class")&&
c(f,v.removeChild(a))}),u(f,function(a,f){0===f&&(a.setAttribute("x",v.getAttribute("x")),f=v.getAttribute("y"),a.setAttribute("y",f||0),null===f&&v.setAttribute("y",0));a=a.cloneNode(1);p(a,{"class":"highcharts-text-outline",fill:b,stroke:b,"stroke-width":y,"stroke-linejoin":"round"});v.insertBefore(a,v.firstChild)}))},attr:function(a,f,c){var v,b=this.element,M,h=this,d;"string"===typeof a&&void 0!==f&&(v=a,a={},a[v]=f);if("string"===typeof a)h=(this[a+"Getter"]||this._defaultGetter).call(this,
a,b);else{for(v in a)f=a[v],d=!1,v!==this.animProp&&y(this,v),this.symbolName&&/^(x|y|width|height|r|start|end|innerR|anchorX|anchorY)/.test(v)&&(M||(this.symbolAttr(a),M=!0),d=!0),!this.rotation||"x"!==v&&"y"!==v||(this.doTransform=!0),d||(d=this[v+"Setter"]||this._defaultSetter,d.call(this,f,v,b));this.doTransform&&(this.updateTransform(),this.doTransform=!1)}c&&c();return h},addClass:function(a,f){var v=this.attr("class")||"";-1===v.indexOf(a)&&(f||(a=(v+(v?" ":"")+a).replace("  "," ")),this.attr("class",
a));return this},hasClass:function(a){return-1!==p(this.element,"class").indexOf(a)},removeClass:function(a){p(this.element,"class",(p(this.element,"class")||"").replace(a,""));return this},symbolAttr:function(a){var v=this;u("x y r start end width height innerR anchorX anchorY".split(" "),function(f){v[f]=C(a[f],v[f])});v.attr({d:v.renderer.symbols[v.symbolName](v.x,v.y,v.width,v.height,v)})},clip:function(a){return this.attr("clip-path",a?"url("+this.renderer.url+"#"+a.id+")":"none")},crisp:function(a,
f){var v,c={},b;f=f||a.strokeWidth||0;b=Math.round(f)%2/2;a.x=Math.floor(a.x||this.x||0)+b;a.y=Math.floor(a.y||this.y||0)+b;a.width=Math.floor((a.width||this.width||0)-2*b);a.height=Math.floor((a.height||this.height||0)-2*b);k(a.strokeWidth)&&(a.strokeWidth=f);for(v in a)this[v]!==a[v]&&(this[v]=c[v]=a[v]);return c},css:function(a){var v=this.styles,f={},c=this.element,b,y,h="";b=!v;a&&a.color&&(a.fill=a.color);if(v)for(y in a)a[y]!==v[y]&&(f[y]=a[y],b=!0);if(b){b=this.textWidth=a&&a.width&&"text"===
c.nodeName.toLowerCase()&&G(a.width)||this.textWidth;v&&(a=t(v,f));this.styles=a;b&&!R&&this.renderer.forExport&&delete a.width;if(D&&!R)l(this.element,a);else{v=function(a,v){return"-"+v.toLowerCase()};for(y in a)h+=y.replace(/([A-Z])/g,v)+":"+a[y]+";";p(c,"style",h)}this.added&&(b&&this.renderer.buildText(this),a&&a.textOutline&&this.applyTextOutline(a.textOutline))}return this},getStyle:function(a){return J.getComputedStyle(this.element||this,"").getPropertyValue(a)},strokeWidth:function(){var a=
this.getStyle("stroke-width"),f;a.indexOf("px")===a.length-2?a=G(a):(f=z.createElementNS(P,"rect"),p(f,{width:a,"stroke-width":0}),this.element.parentNode.appendChild(f),a=f.getBBox().width,f.parentNode.removeChild(f));return a},on:function(a,f){var v=this,c=v.element;n&&"click"===a?(c.ontouchstart=function(a){v.touchEventFired=Date.now();a.preventDefault();f.call(c,a)},c.onclick=function(a){(-1===J.navigator.userAgent.indexOf("Android")||1100<Date.now()-(v.touchEventFired||0))&&f.call(c,a)}):c["on"+
a]=f;return this},setRadialReference:function(a){var v=this.renderer.gradients[this.element.gradient];this.element.radialReference=a;v&&v.radAttr&&v.animate(this.renderer.getRadialAttr(a,v.radAttr));return this},translate:function(a,f){return this.attr({translateX:a,translateY:f})},invert:function(a){this.inverted=a;this.updateTransform();return this},updateTransform:function(){var a=this.translateX||0,f=this.translateY||0,c=this.scaleX,b=this.scaleY,y=this.inverted,h=this.rotation,d=this.element;
y&&(a+=this.attr("width"),f+=this.attr("height"));a=["translate("+a+","+f+")"];y?a.push("rotate(90) scale(-1,1)"):h&&a.push("rotate("+h+" "+(d.getAttribute("x")||0)+" "+(d.getAttribute("y")||0)+")");(k(c)||k(b))&&a.push("scale("+C(c,1)+" "+C(b,1)+")");a.length&&d.setAttribute("transform",a.join(" "))},toFront:function(){var a=this.element;a.parentNode.appendChild(a);return this},align:function(a,f,b){var v,y,h,d,n={};y=this.renderer;h=y.alignedObjects;var M,r;if(a){if(this.alignOptions=a,this.alignByTranslate=
f,!b||I(b))this.alignTo=v=b||"renderer",c(h,this),h.push(this),b=null}else a=this.alignOptions,f=this.alignByTranslate,v=this.alignTo;b=C(b,y[v],y);v=a.align;y=a.verticalAlign;h=(b.x||0)+(a.x||0);d=(b.y||0)+(a.y||0);"right"===v?M=1:"center"===v&&(M=2);M&&(h+=(b.width-(a.width||0))/M);n[f?"translateX":"x"]=Math.round(h);"bottom"===y?r=1:"middle"===y&&(r=2);r&&(d+=(b.height-(a.height||0))/r);n[f?"translateY":"y"]=Math.round(d);this[this.placed?"animate":"attr"](n);this.placed=!0;this.alignAttr=n;return this},
getBBox:function(a,f){var v,c=this.renderer,b,y=this.element,h=this.styles,n,r=this.textStr,M,q=c.cache,e=c.cacheKeys,k;f=C(f,this.rotation);b=f*d;n=y&&x.prototype.getStyle.call(y,"font-size");void 0!==r&&(k=r.toString(),-1===k.indexOf("\x3c")&&(k=k.replace(/[0-9]/g,"0")),k+=["",f||0,n,y.style.width,y.style["text-overflow"]].join());k&&!a&&(v=q[k]);if(!v){if(y.namespaceURI===this.SVG_NS||c.forExport){try{(M=this.fakeTS&&function(a){u(y.querySelectorAll(".highcharts-text-outline"),function(v){v.style.display=
a})})&&M("none"),v=y.getBBox?t({},y.getBBox()):{width:y.offsetWidth,height:y.offsetHeight},M&&M("")}catch(T){}if(!v||0>v.width)v={width:0,height:0}}else v=this.htmlGetBBox();c.isSVG&&(a=v.width,c=v.height,D&&h&&"11px"===h.fontSize&&"16.9"===c.toPrecision(3)&&(v.height=c=14),f&&(v.width=Math.abs(c*Math.sin(b))+Math.abs(a*Math.cos(b)),v.height=Math.abs(c*Math.cos(b))+Math.abs(a*Math.sin(b))));if(k&&0<v.height){for(;250<e.length;)delete q[e.shift()];q[k]||e.push(k);q[k]=v}}return v},show:function(a){return this.attr({visibility:a?
"inherit":"visible"})},hide:function(){return this.attr({visibility:"hidden"})},fadeOut:function(a){var v=this;v.animate({opacity:0},{duration:a||150,complete:function(){v.attr({y:-9999})}})},add:function(a){var v=this.renderer,f=this.element,c;a&&(this.parentGroup=a);this.parentInverted=a&&a.inverted;void 0!==this.textStr&&v.buildText(this);this.added=!0;if(!a||a.handleZ||this.zIndex)c=this.zIndexSetter();c||(a?a.element:v.box).appendChild(f);if(this.onAdd)this.onAdd();return this},safeRemoveChild:function(a){var v=
a.parentNode;v&&v.removeChild(a)},destroy:function(){var a=this.element||{},f=this.renderer.isSVG&&"SPAN"===a.nodeName&&this.parentGroup,b,h;a.onclick=a.onmouseout=a.onmouseover=a.onmousemove=a.point=null;y(this);this.clipPath&&(this.clipPath=this.clipPath.destroy());if(this.stops){for(h=0;h<this.stops.length;h++)this.stops[h]=this.stops[h].destroy();this.stops=null}for(this.safeRemoveChild(a);f&&f.div&&0===f.div.childNodes.length;)a=f.parentGroup,this.safeRemoveChild(f.div),delete f.div,f=a;this.alignTo&&
c(this.renderer.alignedObjects,this);for(b in this)delete this[b];return null},xGetter:function(a){"circle"===this.element.nodeName&&("x"===a?a="cx":"y"===a&&(a="cy"));return this._defaultGetter(a)},_defaultGetter:function(a){a=C(this[a],this.element?this.element.getAttribute(a):null,0);/^[\-0-9\.]+$/.test(a)&&(a=parseFloat(a));return a},dSetter:function(a,f,c){a&&a.join&&(a=a.join(" "));/(NaN| {2}|^$)/.test(a)&&(a="M 0 0");c.setAttribute(f,a);this[f]=a},alignSetter:function(a){this.element.setAttribute("text-anchor",
{left:"start",center:"middle",right:"end"}[a])},opacitySetter:function(a,f,c){this[f]=a;c.setAttribute(f,a)},titleSetter:function(a){var f=this.element.getElementsByTagName("title")[0];f||(f=z.createElementNS(this.SVG_NS,"title"),this.element.appendChild(f));f.firstChild&&f.removeChild(f.firstChild);f.appendChild(z.createTextNode(String(C(a),"").replace(/<[^>]*>/g,"")))},textSetter:function(a){a!==this.textStr&&(delete this.bBox,this.textStr=a,this.added&&this.renderer.buildText(this))},fillSetter:function(a,
f,c){"string"===typeof a?c.setAttribute(f,a):a&&this.colorGradient(a,f,c)},visibilitySetter:function(a,f,c){"inherit"===a?c.removeAttribute(f):c.setAttribute(f,a)},zIndexSetter:function(a,f){var v=this.renderer,c=this.parentGroup,b=(c||v).element||v.box,y,h=this.element,d;y=this.added;var n;k(a)&&(h.zIndex=a,a=+a,this[f]===a&&(y=!1),this[f]=a);if(y){(a=this.zIndex)&&c&&(c.handleZ=!0);f=b.childNodes;for(n=0;n<f.length&&!d;n++)c=f[n],y=c.zIndex,c!==h&&(G(y)>a||!k(a)&&k(y)||0>a&&!k(y)&&b!==v.box)&&(b.insertBefore(h,
c),d=!0);d||b.appendChild(h)}return d},_defaultSetter:function(a,f,c){c.setAttribute(f,a)}};x.prototype.yGetter=x.prototype.xGetter;x.prototype.translateXSetter=x.prototype.translateYSetter=x.prototype.rotationSetter=x.prototype.verticalAlignSetter=x.prototype.scaleXSetter=x.prototype.scaleYSetter=function(a,f){this[f]=a;this.doTransform=!0};A=a.SVGRenderer=function(){this.init.apply(this,arguments)};A.prototype={Element:x,SVG_NS:P,init:function(a,f,c,b,y,h){var v;b=this.createElement("svg").attr({version:"1.1",
"class":"highcharts-root"});v=b.element;a.appendChild(v);-1===a.innerHTML.indexOf("xmlns")&&p(v,"xmlns",this.SVG_NS);this.isSVG=!0;this.box=v;this.boxWrapper=b;this.alignedObjects=[];this.url=(q||w)&&z.getElementsByTagName("base").length?J.location.href.replace(/#.*?$/,"").replace(/([\('\)])/g,"\\$1").replace(/ /g,"%20"):"";this.createElement("desc").add().element.appendChild(z.createTextNode("Created with Highcharts 5.0.4"));this.defs=this.createElement("defs").add();this.allowHTML=h;this.forExport=
y;this.gradients={};this.cache={};this.cacheKeys=[];this.imgCount=0;this.setSize(f,c,!1);var d;q&&a.getBoundingClientRect&&(f=function(){l(a,{left:0,top:0});d=a.getBoundingClientRect();l(a,{left:Math.ceil(d.left)-d.left+"px",top:Math.ceil(d.top)-d.top+"px"})},f(),this.unSubPixelFix=F(J,"resize",f))},definition:function(a){function c(a,b){var y;u(f(a),function(a){var f=v.createElement(a.tagName),h,d={};for(h in a)"tagName"!==h&&"children"!==h&&"textContent"!==h&&(d[h]=a[h]);f.attr(d);f.add(b||v.defs);
a.textContent&&f.element.appendChild(z.createTextNode(a.textContent));c(a.children||[],f);y=f});return y}var v=this;return c(a)},isHidden:function(){return!this.boxWrapper.getBBox().width},destroy:function(){var a=this.defs;this.box=null;this.boxWrapper=this.boxWrapper.destroy();b(this.gradients||{});this.gradients=null;a&&(this.defs=a.destroy());this.unSubPixelFix&&this.unSubPixelFix();return this.alignedObjects=null},createElement:function(a){var f=new this.Element;f.init(this,a);return f},draw:r,
getRadialAttr:function(a,f){return{cx:a[0]-a[2]/2+f.cx*a[2],cy:a[1]-a[2]/2+f.cy*a[2],r:f.r*a[2]}},buildText:function(a){for(var f=a.element,c=this,v=c.forExport,b=C(a.textStr,"").toString(),y=-1!==b.indexOf("\x3c"),d=f.childNodes,n,r,q,e,t=p(f,"x"),k=a.styles,g=a.textWidth,J=k&&k.lineHeight,m=k&&k.textOutline,D=k&&"ellipsis"===k.textOverflow,w=d.length,B=g&&!a.added&&this.box,E=function(a){return J?G(J):c.fontMetrics(void 0,a.getAttribute("style")?a:f).h};w--;)f.removeChild(d[w]);y||m||D||g||-1!==
b.indexOf(" ")?(n=/<.*class="([^"]+)".*>/,r=/<.*style="([^"]+)".*>/,q=/<.*href="(http[^"]+)".*>/,B&&B.appendChild(f),b=y?b.replace(/<(b|strong)>/g,'\x3cspan style\x3d"font-weight:bold"\x3e').replace(/<(i|em)>/g,'\x3cspan style\x3d"font-style:italic"\x3e').replace(/<a/g,"\x3cspan").replace(/<\/(b|strong|i|em|a)>/g,"\x3c/span\x3e").split(/<br.*?>/g):[b],b=h(b,function(a){return""!==a}),u(b,function(b,y){var h,d=0;b=b.replace(/^\s+|\s+$/g,"").replace(/<span/g,"|||\x3cspan").replace(/<\/span>/g,"\x3c/span\x3e|||");
h=b.split("|||");u(h,function(b){if(""!==b||1===h.length){var M={},J=z.createElementNS(c.SVG_NS,"tspan"),u,G;n.test(b)&&(u=b.match(n)[1],p(J,"class",u));r.test(b)&&(G=b.match(r)[1].replace(/(;| |^)color([ :])/,"$1fill$2"),p(J,"style",G));q.test(b)&&!v&&(p(J,"onclick",'location.href\x3d"'+b.match(q)[1]+'"'),l(J,{cursor:"pointer"}));b=(b.replace(/<(.|\n)*?>/g,"")||" ").replace(/&lt;/g,"\x3c").replace(/&gt;/g,"\x3e");if(" "!==b){J.appendChild(z.createTextNode(b));d?M.dx=0:y&&null!==t&&(M.x=t);p(J,M);
f.appendChild(J);!d&&y&&(!R&&v&&l(J,{display:"block"}),p(J,"dy",E(J)));if(g){M=b.replace(/([^\^])-/g,"$1- ").split(" ");u="nowrap"===k.whiteSpace;for(var m=1<h.length||y||1<M.length&&!u,C,O,B=[],w=E(J),I=a.rotation,N=b,Q=N.length;(m||D)&&(M.length||B.length);)a.rotation=0,C=a.getBBox(!0),O=C.width,!R&&c.forExport&&(O=c.measureSpanWidth(J.firstChild.data,a.styles)),C=O>g,void 0===e&&(e=C),D&&e?(Q/=2,""===N||!C&&.5>Q?M=[]:(N=b.substring(0,N.length+(C?-1:1)*Math.ceil(Q)),M=[N+(3<g?"\u2026":"")],J.removeChild(J.firstChild))):
C&&1!==M.length?(J.removeChild(J.firstChild),B.unshift(M.pop())):(M=B,B=[],M.length&&!u&&(J=z.createElementNS(P,"tspan"),p(J,{dy:w,x:t}),G&&p(J,"style",G),f.appendChild(J)),O>g&&(g=O)),M.length&&J.appendChild(z.createTextNode(M.join(" ").replace(/- /g,"-")));a.rotation=I}d++}}})}),e&&a.attr("title",a.textStr),B&&B.removeChild(f),m&&a.applyTextOutline&&a.applyTextOutline(m)):f.appendChild(z.createTextNode(b.replace(/&lt;/g,"\x3c").replace(/&gt;/g,"\x3e")))},getContrast:function(a){a=g(a).rgba;return 510<
a[0]+a[1]+a[2]?"#000000":"#FFFFFF"},button:function(a,f,c,b,y,h,d,n,r){var v=this.label(a,f,c,r,null,null,null,null,"button"),q=0;v.attr(K({padding:8,r:2},y));F(v.element,D?"mouseover":"mouseenter",function(){3!==q&&v.setState(1)});F(v.element,D?"mouseout":"mouseleave",function(){3!==q&&v.setState(q)});v.setState=function(a){1!==a&&(v.state=q=a);v.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-"+["normal","hover","pressed","disabled"][a||0])};return v.on("click",
function(a){3!==q&&b.call(v,a)})},crispLine:function(a,f){a[1]===a[4]&&(a[1]=a[4]=Math.round(a[1])-f%2/2);a[2]===a[5]&&(a[2]=a[5]=Math.round(a[2])+f%2/2);return a},path:function(a){var f={};E(a)?f.d=a:B(a)&&t(f,a);return this.createElement("path").attr(f)},circle:function(a,f,c){a=B(a)?a:{x:a,y:f,r:c};f=this.createElement("circle");f.xSetter=f.ySetter=function(a,f,c){c.setAttribute("c"+f,a)};return f.attr(a)},arc:function(a,f,c,b,y,h){B(a)&&(f=a.y,c=a.r,b=a.innerR,y=a.start,h=a.end,a=a.x);a=this.symbol("arc",
a||0,f||0,c||0,c||0,{innerR:b||0,start:y||0,end:h||0});a.r=c;return a},rect:function(a,f,c,b,y,h){y=B(a)?a.r:y;h=this.createElement("rect");a=B(a)?a:void 0===a?{}:{x:a,y:f,width:Math.max(c,0),height:Math.max(b,0)};y&&(a.r=y);h.rSetter=function(a,f,c){p(c,{rx:a,ry:a})};return h.attr(a)},setSize:function(a,f,c){var b=this.alignedObjects,y=b.length;this.width=a;this.height=f;for(this.boxWrapper.animate({width:a,height:f},{step:function(){this.attr({viewBox:"0 0 "+this.attr("width")+" "+this.attr("height")})},
duration:C(c,!0)?void 0:0});y--;)b[y].align()},g:function(a){var f=this.createElement("g");return a?f.attr({"class":"highcharts-"+a}):f},image:function(a,f,c,b,y){var v={preserveAspectRatio:"none"};1<arguments.length&&t(v,{x:f,y:c,width:b,height:y});v=this.createElement("image").attr(v);v.element.setAttributeNS?v.element.setAttributeNS("http://www.w3.org/1999/xlink","href",a):v.element.setAttribute("hc-svg-href",a);return v},symbol:function(a,f,c,b,y,h){var v=this,d,n=this.symbols[a],r=k(f)&&n&&n(Math.round(f),
Math.round(c),b,y,h),q=/^url\((.*?)\)$/,g,J;n?(d=this.path(r),t(d,{symbolName:a,x:f,y:c,width:b,height:y}),h&&t(d,h)):q.test(a)&&(g=a.match(q)[1],d=this.image(g),d.imgwidth=C(Q[g]&&Q[g].width,h&&h.width),d.imgheight=C(Q[g]&&Q[g].height,h&&h.height),J=function(){d.attr({width:d.width,height:d.height})},u(["width","height"],function(a){d[a+"Setter"]=function(a,f){var c={},b=this["img"+f],y="width"===f?"translateX":"translateY";this[f]=a;k(b)&&(this.element&&this.element.setAttribute(f,b),this.alignByTranslate||
(c[y]=((this[f]||0)-b)/2,this.attr(c)))}}),k(f)&&d.attr({x:f,y:c}),d.isImg=!0,k(d.imgwidth)&&k(d.imgheight)?J():(d.attr({width:0,height:0}),m("img",{onload:function(){var a=e[v.chartIndex];0===this.width&&(l(this,{position:"absolute",top:"-999em"}),z.body.appendChild(this));Q[g]={width:this.width,height:this.height};d.imgwidth=this.width;d.imgheight=this.height;d.element&&J();this.parentNode&&this.parentNode.removeChild(this);v.imgCount--;if(!v.imgCount&&a&&a.onload)a.onload()},src:g}),this.imgCount++));
return d},symbols:{circle:function(a,f,c,b){var y=.166*c;return["M",a+c/2,f,"C",a+c+y,f,a+c+y,f+b,a+c/2,f+b,"C",a-y,f+b,a-y,f,a+c/2,f,"Z"]},square:function(a,f,c,b){return["M",a,f,"L",a+c,f,a+c,f+b,a,f+b,"Z"]},triangle:function(a,f,c,b){return["M",a+c/2,f,"L",a+c,f+b,a,f+b,"Z"]},"triangle-down":function(a,f,c,b){return["M",a,f,"L",a+c,f,a+c/2,f+b,"Z"]},diamond:function(a,f,c,b){return["M",a+c/2,f,"L",a+c,f+b/2,a+c/2,f+b,a,f+b/2,"Z"]},arc:function(a,f,c,b,y){var h=y.start;c=y.r||c||b;var d=y.end-.001;
b=y.innerR;var v=y.open,n=Math.cos(h),r=Math.sin(h),q=Math.cos(d),d=Math.sin(d);y=y.end-h<Math.PI?0:1;return["M",a+c*n,f+c*r,"A",c,c,0,y,1,a+c*q,f+c*d,v?"M":"L",a+b*q,f+b*d,"A",b,b,0,y,0,a+b*n,f+b*r,v?"":"Z"]},callout:function(a,f,c,b,y){var h=Math.min(y&&y.r||0,c,b),d=h+6,v=y&&y.anchorX;y=y&&y.anchorY;var n;n=["M",a+h,f,"L",a+c-h,f,"C",a+c,f,a+c,f,a+c,f+h,"L",a+c,f+b-h,"C",a+c,f+b,a+c,f+b,a+c-h,f+b,"L",a+h,f+b,"C",a,f+b,a,f+b,a,f+b-h,"L",a,f+h,"C",a,f,a,f,a+h,f];v&&v>c?y>f+d&&y<f+b-d?n.splice(13,
3,"L",a+c,y-6,a+c+6,y,a+c,y+6,a+c,f+b-h):n.splice(13,3,"L",a+c,b/2,v,y,a+c,b/2,a+c,f+b-h):v&&0>v?y>f+d&&y<f+b-d?n.splice(33,3,"L",a,y+6,a-6,y,a,y-6,a,f+h):n.splice(33,3,"L",a,b/2,v,y,a,b/2,a,f+h):y&&y>b&&v>a+d&&v<a+c-d?n.splice(23,3,"L",v+6,f+b,v,f+b+6,v-6,f+b,a+h,f+b):y&&0>y&&v>a+d&&v<a+c-d&&n.splice(3,3,"L",v-6,f,v,f-6,v+6,f,c-h,f);return n}},clipRect:function(f,c,b,y){var h=a.uniqueKey(),d=this.createElement("clipPath").attr({id:h}).add(this.defs);f=this.rect(f,c,b,y,0).add(d);f.id=h;f.clipPath=
d;f.count=0;return f},text:function(a,f,c,b){var y=!R&&this.forExport,h={};if(b&&(this.allowHTML||!this.forExport))return this.html(a,f,c);h.x=Math.round(f||0);c&&(h.y=Math.round(c));if(a||0===a)h.text=a;a=this.createElement("text").attr(h);y&&a.css({position:"absolute"});b||(a.xSetter=function(a,f,c){var b=c.getElementsByTagName("tspan"),y,h=c.getAttribute(f),d;for(d=0;d<b.length;d++)y=b[d],y.getAttribute(f)===h&&y.setAttribute(f,a);c.setAttribute(f,a)});return a},fontMetrics:function(a,f){a=f&&
x.prototype.getStyle.call(f,"font-size");a=/px/.test(a)?G(a):/em/.test(a)?parseFloat(a)*(f?this.fontMetrics(null,f.parentNode).f:16):12;f=24>a?a+3:Math.round(1.2*a);return{h:f,b:Math.round(.8*f),f:a}},rotCorr:function(a,f,c){var b=a;f&&c&&(b=Math.max(b*Math.cos(f*d),4));return{x:-a/3*Math.sin(f*d),y:b}},label:function(a,f,c,b,y,h,d,n,r){var v=this,q=v.g("button"!==r&&"label"),e=q.text=v.text("",0,0,d).attr({zIndex:1}),g,J,l=0,G=3,C=0,m,B,D,w,z,E={},P,I=/^url\((.*?)\)$/.test(b),R=I,p,M,O,Q;r&&q.addClass("highcharts-"+
r);R=!0;p=function(){return g.strokeWidth()%2/2};M=function(){var a=e.element.style,f={};J=(void 0===m||void 0===B||z)&&k(e.textStr)&&e.getBBox();q.width=(m||J.width||0)+2*G+C;q.height=(B||J.height||0)+2*G;P=G+v.fontMetrics(a&&a.fontSize,e).b;R&&(g||(q.box=g=v.symbols[b]||I?v.symbol(b):v.rect(),g.addClass(("button"===r?"":"highcharts-label-box")+(r?" highcharts-"+r+"-box":"")),g.add(q),a=p(),f.x=a,f.y=(n?-P:0)+a),f.width=Math.round(q.width),f.height=Math.round(q.height),g.attr(t(f,E)),E={})};O=function(){var a=
C+G,f;f=n?0:P;k(m)&&J&&("center"===z||"right"===z)&&(a+={center:.5,right:1}[z]*(m-J.width));if(a!==e.x||f!==e.y)e.attr("x",a),void 0!==f&&e.attr("y",f);e.x=a;e.y=f};Q=function(a,f){g?g.attr(a,f):E[a]=f};q.onAdd=function(){e.add(q);q.attr({text:a||0===a?a:"",x:f,y:c});g&&k(y)&&q.attr({anchorX:y,anchorY:h})};q.widthSetter=function(a){m=a};q.heightSetter=function(a){B=a};q["text-alignSetter"]=function(a){z=a};q.paddingSetter=function(a){k(a)&&a!==G&&(G=q.padding=a,O())};q.paddingLeftSetter=function(a){k(a)&&
a!==C&&(C=a,O())};q.alignSetter=function(a){a={left:0,center:.5,right:1}[a];a!==l&&(l=a,J&&q.attr({x:D}))};q.textSetter=function(a){void 0!==a&&e.textSetter(a);M();O()};q["stroke-widthSetter"]=function(a,f){a&&(R=!0);this["stroke-width"]=a;Q(f,a)};q.rSetter=function(a,f){Q(f,a)};q.anchorXSetter=function(a,f){y=a;Q(f,Math.round(a)-p()-D)};q.anchorYSetter=function(a,f){h=a;Q(f,a-w)};q.xSetter=function(a){q.x=a;l&&(a-=l*((m||J.width)+2*G));D=Math.round(a);q.attr("translateX",D)};q.ySetter=function(a){w=
q.y=Math.round(a);q.attr("translateY",w)};var S=q.css;return t(q,{css:function(a){if(a){var f={};a=K(a);u(q.textProps,function(c){void 0!==a[c]&&(f[c]=a[c],delete a[c])});e.css(f)}return S.call(q,a)},getBBox:function(){return{width:J.width+2*G,height:J.height+2*G,x:J.x-G,y:J.y-G}},destroy:function(){N(q.element,"mouseenter");N(q.element,"mouseleave");e&&(e=e.destroy());g&&(g=g.destroy());x.prototype.destroy.call(q);q=v=M=O=Q=null}})}};a.Renderer=A})(L);(function(a){var x=a.attr,A=a.createElement,
F=a.css,H=a.defined,p=a.each,e=a.extend,g=a.isFirefox,l=a.isMS,m=a.isWebKit,k=a.pInt,d=a.SVGRenderer,b=a.win,z=a.wrap;e(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=e(this.styles,a);F(this.element,a);return this},htmlGetBBox:function(){var a=this.element;"text"===a.nodeName&&(a.style.position="absolute");
return{x:a.offsetLeft,y:a.offsetTop,width:a.offsetWidth,height:a.offsetHeight}},htmlUpdateTransform:function(){if(this.added){var a=this.renderer,b=this.element,c=this.x||0,h=this.y||0,d=this.textAlign||"left",e={left:0,center:.5,right:1}[d],q=this.styles;F(b,{marginLeft:this.translateX||0,marginTop:this.translateY||0});this.inverted&&p(b.childNodes,function(c){a.invertChild(c,b)});if("SPAN"===b.tagName){var g=this.rotation,l=k(this.textWidth),z=q&&q.whiteSpace,w=[g,d,b.innerHTML,this.textWidth,this.textAlign].join();
w!==this.cTT&&(q=a.fontMetrics(b.style.fontSize).b,H(g)&&this.setSpanRotation(g,e,q),F(b,{width:"",whiteSpace:z||"nowrap"}),b.offsetWidth>l&&/[ \-]/.test(b.textContent||b.innerText)&&F(b,{width:l+"px",display:"block",whiteSpace:z||"normal"}),this.getSpanCorrection(b.offsetWidth,q,e,g,d));F(b,{left:c+(this.xCorr||0)+"px",top:h+(this.yCorr||0)+"px"});m&&(q=b.offsetHeight);this.cTT=w}}else this.alignOnAdd=!0},setSpanRotation:function(a,d,c){var h={},n=l?"-ms-transform":m?"-webkit-transform":g?"MozTransform":
b.opera?"-o-transform":"";h[n]=h.transform="rotate("+a+"deg)";h[n+(g?"Origin":"-origin")]=h.transformOrigin=100*d+"% "+c+"px";F(this.element,h)},getSpanCorrection:function(a,b,c){this.xCorr=-a*c;this.yCorr=-b}});e(d.prototype,{html:function(a,b,c){var h=this.createElement("span"),d=h.element,g=h.renderer,q=g.isSVG,k=function(a,c){p(["opacity","visibility"],function(b){z(a,b+"Setter",function(a,b,h,d){a.call(this,b,h,d);c[h]=b})})};h.textSetter=function(a){a!==d.innerHTML&&delete this.bBox;d.innerHTML=
this.textStr=a;h.htmlUpdateTransform()};q&&k(h,h.element.style);h.xSetter=h.ySetter=h.alignSetter=h.rotationSetter=function(a,c){"align"===c&&(c="textAlign");h[c]=a;h.htmlUpdateTransform()};h.attr({text:a,x:Math.round(b),y:Math.round(c)}).css({position:"absolute"});d.style.whiteSpace="nowrap";h.css=h.htmlCss;q&&(h.add=function(a){var c,b=g.box.parentNode,q=[];if(this.parentGroup=a){if(c=a.div,!c){for(;a;)q.push(a),a=a.parentGroup;p(q.reverse(),function(a){var h,d=x(a.element,"class");d&&(d={className:d});
c=a.div=a.div||A("div",d,{position:"absolute",left:(a.translateX||0)+"px",top:(a.translateY||0)+"px",display:a.display,opacity:a.opacity,pointerEvents:a.styles&&a.styles.pointerEvents},c||b);h=c.style;e(a,{translateXSetter:function(c,f){h.left=c+"px";a[f]=c;a.doTransform=!0},translateYSetter:function(c,f){h.top=c+"px";a[f]=c;a.doTransform=!0}});k(a,h)})}}else c=b;c.appendChild(d);h.added=!0;h.alignOnAdd&&h.htmlUpdateTransform();return h});return h}})})(L);(function(a){function x(){var g=a.defaultOptions.global,
l,m=g.useUTC,k=m?"getUTC":"get",d=m?"setUTC":"set";a.Date=l=g.Date||e.Date;l.hcTimezoneOffset=m&&g.timezoneOffset;l.hcGetTimezoneOffset=m&&g.getTimezoneOffset;l.hcMakeTime=function(a,d,e,g,c,h){var b;m?(b=l.UTC.apply(0,arguments),b+=F(b)):b=(new l(a,d,p(e,1),p(g,0),p(c,0),p(h,0))).getTime();return b};A("Minutes Hours Day Date Month FullYear".split(" "),function(a){l["hcGet"+a]=k+a});A("Milliseconds Seconds Minutes Hours Date Month FullYear".split(" "),function(a){l["hcSet"+a]=d+a})}var A=a.each,F=
a.getTZOffset,H=a.merge,p=a.pick,e=a.win;a.defaultOptions={symbols:["circle","diamond","square","triangle","triangle-down"],lang:{loading:"Loading...",months:"January February March April May June July August September October November December".split(" "),shortMonths:"Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),weekdays:"Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),decimalPoint:".",numericSymbols:"kMGTPE".split(""),resetZoom:"Reset zoom",resetZoomTitle:"Reset zoom level 1:1",
thousandsSep:" "},global:{useUTC:!0},chart:{borderRadius:0,colorCount:10,defaultSeriesType:"line",ignoreHiddenSeries:!0,spacing:[10,10,15,10],resetZoomButton:{theme:{zIndex:20},position:{align:"right",x:-10,y:10}},width:null,height:null},title:{text:"Chart title",align:"center",margin:15,widthAdjust:-44},subtitle:{text:"",align:"center",widthAdjust:-44},plotOptions:{},labels:{style:{position:"absolute",color:"#333333"}},legend:{enabled:!0,align:"center",layout:"horizontal",labelFormatter:function(){return this.name},
borderColor:"#999999",borderRadius:0,navigation:{},itemCheckboxStyle:{position:"absolute",width:"13px",height:"13px"},squareSymbol:!0,symbolPadding:5,verticalAlign:"bottom",x:0,y:0,title:{}},loading:{},tooltip:{enabled:!0,animation:a.svg,borderRadius:3,dateTimeLabelFormats:{millisecond:"%A, %b %e, %H:%M:%S.%L",second:"%A, %b %e, %H:%M:%S",minute:"%A, %b %e, %H:%M",hour:"%A, %b %e, %H:%M",day:"%A, %b %e, %Y",week:"Week from %A, %b %e, %Y",month:"%B %Y",year:"%Y"},footerFormat:"",padding:8,snap:a.isTouchDevice?
25:10,headerFormat:'\x3cspan class\x3d"highcharts-header"\x3e{point.key}\x3c/span\x3e\x3cbr/\x3e',pointFormat:'\x3cspan class\x3d"highcharts-color-{point.colorIndex}"\x3e\u25cf\x3c/span\x3e {series.name}: \x3cb\x3e{point.y}\x3c/b\x3e\x3cbr/\x3e'},credits:{enabled:!0,href:"http://www.highcharts.com",position:{align:"right",x:-10,verticalAlign:"bottom",y:-5},text:"Highcharts.com"}};a.setOptions=function(e){a.defaultOptions=H(!0,a.defaultOptions,e);x();return a.defaultOptions};a.getOptions=function(){return a.defaultOptions};
a.defaultPlotOptions=a.defaultOptions.plotOptions;x()})(L);(function(a){var x=a.arrayMax,A=a.arrayMin,F=a.defined,H=a.destroyObjectProperties,p=a.each,e=a.erase,g=a.merge,l=a.pick;a.PlotLineOrBand=function(a,e){this.axis=a;e&&(this.options=e,this.id=e.id)};a.PlotLineOrBand.prototype={render:function(){var a=this,e=a.axis,d=e.horiz,b=a.options,z=b.label,u=a.label,t=b.to,c=b.from,h=b.value,n=F(c)&&F(t),E=F(h),q=a.svgElem,D=!q,B=[],I,w=l(b.zIndex,0),p=b.events,B={"class":"highcharts-plot-"+(n?"band ":
"line ")+(b.className||"")},r={},C=e.chart.renderer,G=n?"bands":"lines",N;N=e.log2lin;e.isLog&&(c=N(c),t=N(t),h=N(h));r.zIndex=w;G+="-"+w;(N=e[G])||(e[G]=N=C.g("plot-"+G).attr(r).add());D&&(a.svgElem=q=C.path().attr(B).add(N));if(E)B=e.getPlotLinePath(h,q.strokeWidth());else if(n)B=e.getPlotBandPath(c,t,b);else return;if(D&&B&&B.length){if(q.attr({d:B}),p)for(I in b=function(f){q.on(f,function(c){p[f].apply(a,[c])})},p)b(I)}else q&&(B?(q.show(),q.animate({d:B})):(q.hide(),u&&(a.label=u=u.destroy())));
z&&F(z.text)&&B&&B.length&&0<e.width&&0<e.height&&!B.flat?(z=g({align:d&&n&&"center",x:d?!n&&4:10,verticalAlign:!d&&n&&"middle",y:d?n?16:10:n?6:-4,rotation:d&&!n&&90},z),this.renderLabel(z,B,n,w)):u&&u.hide();return a},renderLabel:function(a,e,d,b){var g=this.label,k=this.axis.chart.renderer;g||(g={align:a.textAlign||a.align,rotation:a.rotation,"class":"highcharts-plot-"+(d?"band":"line")+"-label "+(a.className||"")},g.zIndex=b,this.label=g=k.text(a.text,0,0,a.useHTML).attr(g).add());b=[e[1],e[4],
d?e[6]:e[1]];e=[e[2],e[5],d?e[7]:e[2]];d=A(b);k=A(e);g.align(a,!1,{x:d,y:k,width:x(b)-d,height:x(e)-k});g.show()},destroy:function(){e(this.axis.plotLinesAndBands,this);delete this.axis;H(this)}};a.AxisPlotLineOrBandExtension={getPlotBandPath:function(a,e){e=this.getPlotLinePath(e,null,null,!0);(a=this.getPlotLinePath(a,null,null,!0))&&e?(a.flat=a.toString()===e.toString(),a.push(e[4],e[5],e[1],e[2],"z")):a=null;return a},addPlotBand:function(a){return this.addPlotBandOrLine(a,"plotBands")},addPlotLine:function(a){return this.addPlotBandOrLine(a,
"plotLines")},addPlotBandOrLine:function(e,g){var d=(new a.PlotLineOrBand(this,e)).render(),b=this.userOptions;d&&(g&&(b[g]=b[g]||[],b[g].push(e)),this.plotLinesAndBands.push(d));return d},removePlotBandOrLine:function(a){for(var g=this.plotLinesAndBands,d=this.options,b=this.userOptions,l=g.length;l--;)g[l].id===a&&g[l].destroy();p([d.plotLines||[],b.plotLines||[],d.plotBands||[],b.plotBands||[]],function(b){for(l=b.length;l--;)b[l].id===a&&e(b,b[l])})}}})(L);(function(a){var x=a.correctFloat,A=
a.defined,F=a.destroyObjectProperties,H=a.isNumber,p=a.pick,e=a.deg2rad;a.Tick=function(a,e,m,k){this.axis=a;this.pos=e;this.type=m||"";this.isNew=!0;m||k||this.addLabel()};a.Tick.prototype={addLabel:function(){var a=this.axis,e=a.options,m=a.chart,k=a.categories,d=a.names,b=this.pos,z=e.labels,u=a.tickPositions,t=b===u[0],c=b===u[u.length-1],d=k?p(k[b],d[b],b):b,k=this.label,u=u.info,h;a.isDatetimeAxis&&u&&(h=e.dateTimeLabelFormats[u.higherRanks[b]||u.unitName]);this.isFirst=t;this.isLast=c;e=a.labelFormatter.call({axis:a,
chart:m,isFirst:t,isLast:c,dateTimeLabelFormat:h,value:a.isLog?x(a.lin2log(d)):d});A(k)?k&&k.attr({text:e}):(this.labelLength=(this.label=k=A(e)&&z.enabled?m.renderer.text(e,0,0,z.useHTML).add(a.labelGroup):null)&&k.getBBox().width,this.rotation=0)},getLabelSize:function(){return this.label?this.label.getBBox()[this.axis.horiz?"height":"width"]:0},handleOverflow:function(a){var g=this.axis,m=a.x,k=g.chart.chartWidth,d=g.chart.spacing,b=p(g.labelLeft,Math.min(g.pos,d[3])),d=p(g.labelRight,Math.max(g.pos+
g.len,k-d[1])),z=this.label,u=this.rotation,t={left:0,center:.5,right:1}[g.labelAlign],c=z.getBBox().width,h=g.getSlotWidth(),n=h,E=1,q,D={};if(u)0>u&&m-t*c<b?q=Math.round(m/Math.cos(u*e)-b):0<u&&m+t*c>d&&(q=Math.round((k-m)/Math.cos(u*e)));else if(k=m+(1-t)*c,m-t*c<b?n=a.x+n*(1-t)-b:k>d&&(n=d-a.x+n*t,E=-1),n=Math.min(h,n),n<h&&"center"===g.labelAlign&&(a.x+=E*(h-n-t*(h-Math.min(c,n)))),c>n||g.autoRotation&&(z.styles||{}).width)q=n;q&&(D.width=q,(g.options.labels.style||{}).textOverflow||(D.textOverflow=
"ellipsis"),z.css(D))},getPosition:function(a,e,m,k){var d=this.axis,b=d.chart,g=k&&b.oldChartHeight||b.chartHeight;return{x:a?d.translate(e+m,null,null,k)+d.transB:d.left+d.offset+(d.opposite?(k&&b.oldChartWidth||b.chartWidth)-d.right-d.left:0),y:a?g-d.bottom+d.offset-(d.opposite?d.height:0):g-d.translate(e+m,null,null,k)-d.transB}},getLabelPosition:function(a,l,m,k,d,b,z,u){var g=this.axis,c=g.transA,h=g.reversed,n=g.staggerLines,E=g.tickRotCorr||{x:0,y:0},q=d.y;A(q)||(q=0===g.side?m.rotation?-8:
-m.getBBox().height:2===g.side?E.y+8:Math.cos(m.rotation*e)*(E.y-m.getBBox(!1,0).height/2));a=a+d.x+E.x-(b&&k?b*c*(h?-1:1):0);l=l+q-(b&&!k?b*c*(h?1:-1):0);n&&(m=z/(u||1)%n,g.opposite&&(m=n-m-1),l+=g.labelOffset/n*m);return{x:a,y:Math.round(l)}},getMarkPath:function(a,e,m,k,d,b){return b.crispLine(["M",a,e,"L",a+(d?0:-m),e+(d?m:0)],k)},render:function(a,e,m){var g=this.axis,d=g.options,b=g.chart.renderer,l=g.horiz,u=this.type,t=this.label,c=this.pos,h=d.labels,n=this.gridLine,E=g.tickSize(u?u+"Tick":
"tick"),q=this.mark,D=!q,B=h.step,I={},w=!0,K=g.tickmarkOffset,r=this.getPosition(l,c,K,e),C=r.x,r=r.y,G=l&&C===g.pos+g.len||!l&&r===g.pos?-1:1;m=p(m,1);this.isActive=!0;n||(u||(I.zIndex=1),e&&(I.opacity=0),this.gridLine=n=b.path().attr(I).addClass("highcharts-"+(u?u+"-":"")+"grid-line").add(g.gridGroup));if(!e&&n&&(c=g.getPlotLinePath(c+K,n.strokeWidth()*G,e,!0)))n[this.isNew?"attr":"animate"]({d:c,opacity:m});E&&(g.opposite&&(E[0]=-E[0]),D&&(this.mark=q=b.path().addClass("highcharts-"+(u?u+"-":
"")+"tick").add(g.axisGroup)),q[D?"attr":"animate"]({d:this.getMarkPath(C,r,E[0],q.strokeWidth()*G,l,b),opacity:m}));t&&H(C)&&(t.xy=r=this.getLabelPosition(C,r,t,l,h,K,a,B),this.isFirst&&!this.isLast&&!p(d.showFirstLabel,1)||this.isLast&&!this.isFirst&&!p(d.showLastLabel,1)?w=!1:!l||g.isRadial||h.step||h.rotation||e||0===m||this.handleOverflow(r),B&&a%B&&(w=!1),w&&H(r.y)?(r.opacity=m,t[this.isNew?"attr":"animate"](r)):t.attr("y",-9999),this.isNew=!1)},destroy:function(){F(this,this.axis)}}})(L);(function(a){var x=
a.addEvent,A=a.animObject,F=a.arrayMax,H=a.arrayMin,p=a.AxisPlotLineOrBandExtension,e=a.correctFloat,g=a.defaultOptions,l=a.defined,m=a.deg2rad,k=a.destroyObjectProperties,d=a.each,b=a.error,z=a.extend,u=a.fireEvent,t=a.format,c=a.getMagnitude,h=a.grep,n=a.inArray,E=a.isArray,q=a.isNumber,D=a.isString,B=a.merge,I=a.normalizeTickInterval,w=a.pick,K=a.PlotLineOrBand,r=a.removeEvent,C=a.splat,G=a.syncTimeout,N=a.Tick;a.Axis=function(){this.init.apply(this,arguments)};a.Axis.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},minPadding:.01,maxPadding:.01,minorTickLength:2,minorTickPosition:"outside",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:{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,c){var f=c.isX;this.chart=a;this.horiz=a.inverted?!f:f;this.isXAxis=f;this.coll=this.coll||(f?"xAxis":"yAxis");
this.opposite=c.opposite;this.side=c.side||(this.horiz?this.opposite?0:2:this.opposite?1:3);this.setOptions(c);var b=this.options,y=b.type;this.labelFormatter=b.labels.formatter||this.defaultLabelFormatter;this.userOptions=c;this.minPixelPadding=0;this.reversed=b.reversed;this.visible=!1!==b.visible;this.zoomEnabled=!1!==b.zoomEnabled;this.hasNames="category"===y||!0===b.categories;this.categories=b.categories||this.hasNames;this.names=this.names||[];this.isLog="logarithmic"===y;this.isDatetimeAxis=
"datetime"===y;this.isLinked=l(b.linkedTo);this.ticks={};this.labelEdge=[];this.minorTicks={};this.plotLinesAndBands=[];this.alternateBands={};this.len=0;this.minRange=this.userMinRange=b.minRange||b.maxZoom;this.range=b.range;this.offset=b.offset||0;this.stacks={};this.oldStacks={};this.stacksTouched=0;this.min=this.max=null;this.crosshair=w(b.crosshair,C(a.options.tooltip.crosshairs)[f?0:1],!1);var h;c=this.options.events;-1===n(this,a.axes)&&(f?a.axes.splice(a.xAxis.length,0,this):a.axes.push(this),
a[this.coll].push(this));this.series=this.series||[];a.inverted&&f&&void 0===this.reversed&&(this.reversed=!0);this.removePlotLine=this.removePlotBand=this.removePlotBandOrLine;for(h in c)x(this,h,c[h]);this.isLog&&(this.val2lin=this.log2lin,this.lin2val=this.lin2log)},setOptions:function(a){this.options=B(this.defaultOptions,"yAxis"===this.coll&&this.defaultYAxisOptions,[this.defaultTopAxisOptions,this.defaultRightAxisOptions,this.defaultBottomAxisOptions,this.defaultLeftAxisOptions][this.side],
B(g[this.coll],a))},defaultLabelFormatter:function(){var f=this.axis,c=this.value,b=f.categories,h=this.dateTimeLabelFormat,d=g.lang,e=d.numericSymbols,d=d.numericSymbolMagnitude||1E3,q=e&&e.length,n,r=f.options.labels.format,f=f.isLog?c:f.tickInterval;if(r)n=t(r,this);else if(b)n=c;else if(h)n=a.dateFormat(h,c);else if(q&&1E3<=f)for(;q--&&void 0===n;)b=Math.pow(d,q+1),f>=b&&0===10*c%b&&null!==e[q]&&0!==c&&(n=a.numberFormat(c/b,-1)+e[q]);void 0===n&&(n=1E4<=Math.abs(c)?a.numberFormat(c,-1):a.numberFormat(c,
-1,void 0,""));return n},getSeriesExtremes:function(){var a=this,c=a.chart;a.hasVisibleSeries=!1;a.dataMin=a.dataMax=a.threshold=null;a.softThreshold=!a.isXAxis;a.buildStacks&&a.buildStacks();d(a.series,function(f){if(f.visible||!c.options.chart.ignoreHiddenSeries){var b=f.options,y=b.threshold,d;a.hasVisibleSeries=!0;a.isLog&&0>=y&&(y=null);if(a.isXAxis)b=f.xData,b.length&&(f=H(b),q(f)||f instanceof Date||(b=h(b,function(a){return q(a)}),f=H(b)),a.dataMin=Math.min(w(a.dataMin,b[0]),f),a.dataMax=
Math.max(w(a.dataMax,b[0]),F(b)));else if(f.getExtremes(),d=f.dataMax,f=f.dataMin,l(f)&&l(d)&&(a.dataMin=Math.min(w(a.dataMin,f),f),a.dataMax=Math.max(w(a.dataMax,d),d)),l(y)&&(a.threshold=y),!b.softThreshold||a.isLog)a.softThreshold=!1}})},translate:function(a,c,b,h,d,e){var f=this.linkedParent||this,y=1,n=0,g=h?f.oldTransA:f.transA;h=h?f.oldMin:f.min;var r=f.minPixelPadding;d=(f.isOrdinal||f.isBroken||f.isLog&&d)&&f.lin2val;g||(g=f.transA);b&&(y*=-1,n=f.len);f.reversed&&(y*=-1,n-=y*(f.sector||f.len));
c?(a=(a*y+n-r)/g+h,d&&(a=f.lin2val(a))):(d&&(a=f.val2lin(a)),a=y*(a-h)*g+n+y*r+(q(e)?g*e:0));return a},toPixels:function(a,c){return this.translate(a,!1,!this.horiz,null,!0)+(c?0:this.pos)},toValue:function(a,c){return this.translate(a-(c?0:this.pos),!0,!this.horiz,null,!0)},getPlotLinePath:function(a,c,b,h,d){var f=this.chart,y=this.left,e=this.top,n,g,r=b&&f.oldChartHeight||f.chartHeight,t=b&&f.oldChartWidth||f.chartWidth,l;n=this.transB;var k=function(a,f,c){if(a<f||a>c)h?a=Math.min(Math.max(f,
a),c):l=!0;return a};d=w(d,this.translate(a,null,null,b));a=b=Math.round(d+n);n=g=Math.round(r-d-n);q(d)?this.horiz?(n=e,g=r-this.bottom,a=b=k(a,y,y+this.width)):(a=y,b=t-this.right,n=g=k(n,e,e+this.height)):l=!0;return l&&!h?null:f.renderer.crispLine(["M",a,n,"L",b,g],c||1)},getLinearTickPositions:function(a,c,b){var f,y=e(Math.floor(c/a)*a),h=e(Math.ceil(b/a)*a),d=[];if(c===b&&q(c))return[c];for(c=y;c<=h;){d.push(c);c=e(c+a);if(c===f)break;f=c}return d},getMinorTickPositions:function(){var a=this.options,
c=this.tickPositions,b=this.minorTickInterval,h=[],d,e=this.pointRangePadding||0;d=this.min-e;var e=this.max+e,q=e-d;if(q&&q/b<this.len/3)if(this.isLog)for(e=c.length,d=1;d<e;d++)h=h.concat(this.getLogTickPositions(b,c[d-1],c[d],!0));else if(this.isDatetimeAxis&&"auto"===a.minorTickInterval)h=h.concat(this.getTimeTicks(this.normalizeTimeTickInterval(b),d,e,a.startOfWeek));else for(c=d+(c[0]-d)%b;c<=e&&c!==h[0];c+=b)h.push(c);0!==h.length&&this.trimTicks(h,a.startOnTick,a.endOnTick);return h},adjustForMinRange:function(){var a=
this.options,c=this.min,b=this.max,h,e=this.dataMax-this.dataMin>=this.minRange,q,n,g,r,t,k;this.isXAxis&&void 0===this.minRange&&!this.isLog&&(l(a.min)||l(a.max)?this.minRange=null:(d(this.series,function(a){r=a.xData;for(n=t=a.xIncrement?1:r.length-1;0<n;n--)if(g=r[n]-r[n-1],void 0===q||g<q)q=g}),this.minRange=Math.min(5*q,this.dataMax-this.dataMin)));b-c<this.minRange&&(k=this.minRange,h=(k-b+c)/2,h=[c-h,w(a.min,c-h)],e&&(h[2]=this.isLog?this.log2lin(this.dataMin):this.dataMin),c=F(h),b=[c+k,w(a.max,
c+k)],e&&(b[2]=this.isLog?this.log2lin(this.dataMax):this.dataMax),b=H(b),b-c<k&&(h[0]=b-k,h[1]=w(a.min,b-k),c=F(h)));this.min=c;this.max=b},getClosest:function(){var a;this.categories?a=1:d(this.series,function(f){var c=f.closestPointRange,b=f.visible||!f.chart.options.chart.ignoreHiddenSeries;!f.noSharedTooltip&&l(c)&&b&&(a=l(a)?Math.min(a,c):c)});return a},nameToX:function(a){var f=E(this.categories),c=f?this.categories:this.names,b=a.options.x,h;a.series.requireSorting=!1;l(b)||(b=!1===this.options.uniqueNames?
a.series.autoIncrement():n(a.name,c));-1===b?f||(h=c.length):h=b;this.names[h]=a.name;return h},updateNames:function(){var a=this;0<this.names.length&&(this.names.length=0,this.minRange=void 0,d(this.series||[],function(f){f.xIncrement=null;if(!f.points||f.isDirtyData)f.processData(),f.generatePoints();d(f.points,function(c,b){var h;c.options&&void 0===c.options.x&&(h=a.nameToX(c),h!==c.x&&(c.x=h,f.xData[b]=h))})}))},setAxisTranslation:function(a){var f=this,c=f.max-f.min,b=f.axisPointRange||0,h,
e=0,q=0,n=f.linkedParent,g=!!f.categories,r=f.transA,t=f.isXAxis;if(t||g||b)n?(e=n.minPointOffset,q=n.pointRangePadding):(h=f.getClosest(),d(f.series,function(a){var c=g?1:t?w(a.options.pointRange,h,0):f.axisPointRange||0;a=a.options.pointPlacement;b=Math.max(b,c);f.single||(e=Math.max(e,D(a)?0:c/2),q=Math.max(q,"on"===a?0:c))})),n=f.ordinalSlope&&h?f.ordinalSlope/h:1,f.minPointOffset=e*=n,f.pointRangePadding=q*=n,f.pointRange=Math.min(b,c),t&&(f.closestPointRange=h);a&&(f.oldTransA=r);f.translationSlope=
f.transA=r=f.len/(c+q||1);f.transB=f.horiz?f.left:f.bottom;f.minPixelPadding=r*e},minFromRange:function(){return this.max-this.range},setTickInterval:function(a){var f=this,h=f.chart,n=f.options,g=f.isLog,r=f.log2lin,v=f.isDatetimeAxis,t=f.isXAxis,k=f.isLinked,G=n.maxPadding,C=n.minPadding,D=n.tickInterval,B=n.tickPixelInterval,m=f.categories,E=f.threshold,z=f.softThreshold,p,N,K,x;v||m||k||this.getTickAmount();K=w(f.userMin,n.min);x=w(f.userMax,n.max);k?(f.linkedParent=h[f.coll][n.linkedTo],h=f.linkedParent.getExtremes(),
f.min=w(h.min,h.dataMin),f.max=w(h.max,h.dataMax),n.type!==f.linkedParent.options.type&&b(11,1)):(!z&&l(E)&&(f.dataMin>=E?(p=E,C=0):f.dataMax<=E&&(N=E,G=0)),f.min=w(K,p,f.dataMin),f.max=w(x,N,f.dataMax));g&&(!a&&0>=Math.min(f.min,w(f.dataMin,f.min))&&b(10,1),f.min=e(r(f.min),15),f.max=e(r(f.max),15));f.range&&l(f.max)&&(f.userMin=f.min=K=Math.max(f.min,f.minFromRange()),f.userMax=x=f.max,f.range=null);u(f,"foundExtremes");f.beforePadding&&f.beforePadding();f.adjustForMinRange();!(m||f.axisPointRange||
f.usePercentage||k)&&l(f.min)&&l(f.max)&&(r=f.max-f.min)&&(!l(K)&&C&&(f.min-=r*C),!l(x)&&G&&(f.max+=r*G));q(n.floor)?f.min=Math.max(f.min,n.floor):q(n.softMin)&&(f.min=Math.min(f.min,n.softMin));q(n.ceiling)?f.max=Math.min(f.max,n.ceiling):q(n.softMax)&&(f.max=Math.max(f.max,n.softMax));z&&l(f.dataMin)&&(E=E||0,!l(K)&&f.min<E&&f.dataMin>=E?f.min=E:!l(x)&&f.max>E&&f.dataMax<=E&&(f.max=E));f.tickInterval=f.min===f.max||void 0===f.min||void 0===f.max?1:k&&!D&&B===f.linkedParent.options.tickPixelInterval?
D=f.linkedParent.tickInterval:w(D,this.tickAmount?(f.max-f.min)/Math.max(this.tickAmount-1,1):void 0,m?1:(f.max-f.min)*B/Math.max(f.len,B));t&&!a&&d(f.series,function(a){a.processData(f.min!==f.oldMin||f.max!==f.oldMax)});f.setAxisTranslation(!0);f.beforeSetTickPositions&&f.beforeSetTickPositions();f.postProcessTickInterval&&(f.tickInterval=f.postProcessTickInterval(f.tickInterval));f.pointRange&&!D&&(f.tickInterval=Math.max(f.pointRange,f.tickInterval));a=w(n.minTickInterval,f.isDatetimeAxis&&f.closestPointRange);
!D&&f.tickInterval<a&&(f.tickInterval=a);v||g||D||(f.tickInterval=I(f.tickInterval,null,c(f.tickInterval),w(n.allowDecimals,!(.5<f.tickInterval&&5>f.tickInterval&&1E3<f.max&&9999>f.max)),!!this.tickAmount));this.tickAmount||(f.tickInterval=f.unsquish());this.setTickPositions()},setTickPositions:function(){var a=this.options,c,b=a.tickPositions,h=a.tickPositioner,d=a.startOnTick,e=a.endOnTick,n;this.tickmarkOffset=this.categories&&"between"===a.tickmarkPlacement&&1===this.tickInterval?.5:0;this.minorTickInterval=
"auto"===a.minorTickInterval&&this.tickInterval?this.tickInterval/5:a.minorTickInterval;this.tickPositions=c=b&&b.slice();!c&&(c=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),c.length>this.len&&(c=[c[0],c.pop()]),this.tickPositions=
c,h&&(h=h.apply(this,[this.min,this.max])))&&(this.tickPositions=c=h);this.isLinked||(this.trimTicks(c,d,e),this.min===this.max&&l(this.min)&&!this.tickAmount&&(n=!0,this.min-=.5,this.max+=.5),this.single=n,b||h||this.adjustTickAmount())},trimTicks:function(a,c,b){var f=a[0],h=a[a.length-1],d=this.minPointOffset||0;if(c)this.min=f;else for(;this.min-d>a[0];)a.shift();if(b)this.max=h;else for(;this.max+d<a[a.length-1];)a.pop();0===a.length&&l(f)&&a.push((h+f)/2)},alignToOthers:function(){var a={},
c,b=this.options;!1!==this.chart.options.chart.alignTicks&&!1!==b.alignTicks&&d(this.chart[this.coll],function(f){var b=f.options,b=[f.horiz?b.left:b.top,b.width,b.height,b.pane].join();f.series.length&&(a[b]?c=!0:a[b]=1)});return c},getTickAmount:function(){var a=this.options,c=a.tickAmount,b=a.tickPixelInterval;!l(a.tickInterval)&&this.len<b&&!this.isRadial&&!this.isLog&&a.startOnTick&&a.endOnTick&&(c=2);!c&&this.alignToOthers()&&(c=Math.ceil(this.len/b)+1);4>c&&(this.finalTickAmt=c,c=5);this.tickAmount=
c},adjustTickAmount:function(){var a=this.tickInterval,c=this.tickPositions,b=this.tickAmount,h=this.finalTickAmt,d=c&&c.length;if(d<b){for(;c.length<b;)c.push(e(c[c.length-1]+a));this.transA*=(d-1)/(b-1);this.max=c[c.length-1]}else d>b&&(this.tickInterval*=2,this.setTickPositions());if(l(h)){for(a=b=c.length;a--;)(3===h&&1===a%2||2>=h&&0<a&&a<b-1)&&c.splice(a,1);this.finalTickAmt=void 0}},setScale:function(){var a,c;this.oldMin=this.min;this.oldMax=this.max;this.oldAxisLength=this.len;this.setAxisSize();
c=this.len!==this.oldAxisLength;d(this.series,function(f){if(f.isDirtyData||f.isDirty||f.xAxis.isDirty)a=!0});c||a||this.isLinked||this.forceRedraw||this.userMin!==this.oldUserMin||this.userMax!==this.oldUserMax||this.alignToOthers()?(this.resetStacks&&this.resetStacks(),this.forceRedraw=!1,this.getSeriesExtremes(),this.setTickInterval(),this.oldUserMin=this.userMin,this.oldUserMax=this.userMax,this.isDirty||(this.isDirty=c||this.min!==this.oldMin||this.max!==this.oldMax)):this.cleanStacks&&this.cleanStacks()},
setExtremes:function(a,c,b,h,e){var f=this,n=f.chart;b=w(b,!0);d(f.series,function(a){delete a.kdTree});e=z(e,{min:a,max:c});u(f,"setExtremes",e,function(){f.userMin=a;f.userMax=c;f.eventArgs=e;b&&n.redraw(h)})},zoom:function(a,c){var f=this.dataMin,b=this.dataMax,h=this.options,d=Math.min(f,w(h.min,f)),h=Math.max(b,w(h.max,b));if(a!==this.min||c!==this.max)this.allowZoomOutside||(l(f)&&a<=d&&(a=d),l(b)&&c>=h&&(c=h)),this.displayBtn=void 0!==a||void 0!==c,this.setExtremes(a,c,!1,void 0,{trigger:"zoom"});
return!0},setAxisSize:function(){var a=this.chart,c=this.options,b=c.offsetLeft||0,h=this.horiz,d=w(c.width,a.plotWidth-b+(c.offsetRight||0)),e=w(c.height,a.plotHeight),n=w(c.top,a.plotTop),c=w(c.left,a.plotLeft+b),b=/%$/;b.test(e)&&(e=Math.round(parseFloat(e)/100*a.plotHeight));b.test(n)&&(n=Math.round(parseFloat(n)/100*a.plotHeight+a.plotTop));this.left=c;this.top=n;this.width=d;this.height=e;this.bottom=a.chartHeight-e-n;this.right=a.chartWidth-d-c;this.len=Math.max(h?d:e,0);this.pos=h?c:n},getExtremes:function(){var a=
this.isLog,c=this.lin2log;return{min:a?e(c(this.min)):this.min,max:a?e(c(this.max)):this.max,dataMin:this.dataMin,dataMax:this.dataMax,userMin:this.userMin,userMax:this.userMax}},getThreshold:function(a){var f=this.isLog,c=this.lin2log,b=f?c(this.min):this.min,f=f?c(this.max):this.max;null===a?a=b:b>a?a=b:f<a&&(a=f);return this.translate(a,0,1,0,1)},autoLabelAlign:function(a){a=(w(a,0)-90*this.side+720)%360;return 15<a&&165>a?"right":195<a&&345>a?"left":"center"},tickSize:function(a){var f=this.options,
c=f[a+"Length"],b=w(f[a+"Width"],"tick"===a&&this.isXAxis?1:0);if(b&&c)return"inside"===f[a+"Position"]&&(c=-c),[c,b]},labelMetrics:function(){return this.chart.renderer.fontMetrics(this.options.labels.style&&this.options.labels.style.fontSize,this.ticks[0]&&this.ticks[0].label)},unsquish:function(){var a=this.options.labels,c=this.horiz,b=this.tickInterval,h=b,e=this.len/(((this.categories?1:0)+this.max-this.min)/b),n,q=a.rotation,g=this.labelMetrics(),r,t=Number.MAX_VALUE,k,G=function(a){a/=e||
1;a=1<a?Math.ceil(a):1;return a*b};c?(k=!a.staggerLines&&!a.step&&(l(q)?[q]:e<w(a.autoRotationLimit,80)&&a.autoRotation))&&d(k,function(a){var f;if(a===q||a&&-90<=a&&90>=a)r=G(Math.abs(g.h/Math.sin(m*a))),f=r+Math.abs(a/360),f<t&&(t=f,n=a,h=r)}):a.step||(h=G(g.h));this.autoRotation=k;this.labelRotation=w(n,q);return h},getSlotWidth:function(){var a=this.chart,c=this.horiz,b=this.options.labels,h=Math.max(this.tickPositions.length-(this.categories?0:1),1),d=a.margin[3];return c&&2>(b.step||0)&&!b.rotation&&
(this.staggerLines||1)*a.plotWidth/h||!c&&(d&&d-a.spacing[3]||.33*a.chartWidth)},renderUnsquish:function(){var a=this.chart,c=a.renderer,b=this.tickPositions,h=this.ticks,e=this.options.labels,n=this.horiz,q=this.getSlotWidth(),g=Math.max(1,Math.round(q-2*(e.padding||5))),r={},t=this.labelMetrics(),k=e.style&&e.style.textOverflow,l,G=0,C,w;D(e.rotation)||(r.rotation=e.rotation||0);d(b,function(a){(a=h[a])&&a.labelLength>G&&(G=a.labelLength)});this.maxLabelLength=G;if(this.autoRotation)G>g&&G>t.h?
r.rotation=this.labelRotation:this.labelRotation=0;else if(q&&(l={width:g+"px"},!k))for(l.textOverflow="clip",C=b.length;!n&&C--;)if(w=b[C],g=h[w].label)g.styles&&"ellipsis"===g.styles.textOverflow?g.css({textOverflow:"clip"}):h[w].labelLength>q&&g.css({width:q+"px"}),g.getBBox().height>this.len/b.length-(t.h-t.f)&&(g.specCss={textOverflow:"ellipsis"});r.rotation&&(l={width:(G>.5*a.chartHeight?.33*a.chartHeight:a.chartHeight)+"px"},k||(l.textOverflow="ellipsis"));if(this.labelAlign=e.align||this.autoLabelAlign(this.labelRotation))r.align=
this.labelAlign;d(b,function(a){var f=(a=h[a])&&a.label;f&&(f.attr(r),l&&f.css(B(l,f.specCss)),delete f.specCss,a.rotation=r.rotation)});this.tickRotCorr=c.rotCorr(t.b,this.labelRotation||0,0!==this.side)},hasData:function(){return this.hasVisibleSeries||l(this.min)&&l(this.max)&&!!this.tickPositions},getOffset:function(){var a=this,c=a.chart,b=c.renderer,h=a.options,e=a.tickPositions,n=a.ticks,q=a.horiz,g=a.side,r=c.inverted?[1,0,3,2][g]:g,t,k,G=0,C,D=0,B=h.title,E=h.labels,u=0,m=a.opposite,z=c.axisOffset,
c=c.clipOffset,p=[-1,1,1,-1][g],I,K=h.className,x=a.axisParent,A=this.tickSize("tick");t=a.hasData();a.showAxis=k=t||w(h.showEmpty,!0);a.staggerLines=a.horiz&&E.staggerLines;a.axisGroup||(a.gridGroup=b.g("grid").attr({zIndex:h.gridZIndex||1}).addClass("highcharts-"+this.coll.toLowerCase()+"-grid "+(K||"")).add(x),a.axisGroup=b.g("axis").attr({zIndex:h.zIndex||2}).addClass("highcharts-"+this.coll.toLowerCase()+" "+(K||"")).add(x),a.labelGroup=b.g("axis-labels").attr({zIndex:E.zIndex||7}).addClass("highcharts-"+
a.coll.toLowerCase()+"-labels "+(K||"")).add(x));if(t||a.isLinked)d(e,function(c){n[c]?n[c].addLabel():n[c]=new N(a,c)}),a.renderUnsquish(),!1===E.reserveSpace||0!==g&&2!==g&&{1:"left",3:"right"}[g]!==a.labelAlign&&"center"!==a.labelAlign||d(e,function(a){u=Math.max(n[a].getLabelSize(),u)}),a.staggerLines&&(u*=a.staggerLines,a.labelOffset=u*(a.opposite?-1:1));else for(I in n)n[I].destroy(),delete n[I];B&&B.text&&!1!==B.enabled&&(a.axisTitle||((I=B.textAlign)||(I=(q?{low:"left",middle:"center",high:"right"}:
{low:m?"right":"left",middle:"center",high:m?"left":"right"})[B.align]),a.axisTitle=b.text(B.text,0,0,B.useHTML).attr({zIndex:7,rotation:B.rotation||0,align:I}).addClass("highcharts-axis-title").add(a.axisGroup),a.axisTitle.isNew=!0),k&&(G=a.axisTitle.getBBox()[q?"height":"width"],C=B.offset,D=l(C)?0:w(B.margin,q?5:10)),a.axisTitle[k?"show":"hide"](!0));a.renderLine();a.offset=p*w(h.offset,z[g]);a.tickRotCorr=a.tickRotCorr||{x:0,y:0};b=0===g?-a.labelMetrics().h:2===g?a.tickRotCorr.y:0;D=Math.abs(u)+
D;u&&(D=D-b+p*(q?w(E.y,a.tickRotCorr.y+8*p):E.x));a.axisTitleMargin=w(C,D);z[g]=Math.max(z[g],a.axisTitleMargin+G+p*a.offset,D,t&&e.length&&A?A[0]:0);h=h.offset?0:2*Math.floor(a.axisLine.strokeWidth()/2);c[r]=Math.max(c[r],h)},getLinePath:function(a){var c=this.chart,f=this.opposite,b=this.offset,h=this.horiz,d=this.left+(f?this.width:0)+b,b=c.chartHeight-this.bottom-(f?this.height:0)+b;f&&(a*=-1);return c.renderer.crispLine(["M",h?this.left:d,h?b:this.top,"L",h?c.chartWidth-this.right:d,h?b:c.chartHeight-
this.bottom],a)},renderLine:function(){this.axisLine||(this.axisLine=this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup))},getTitlePosition:function(){var a=this.horiz,c=this.left,b=this.top,h=this.len,d=this.options.title,e=a?c:b,n=this.opposite,q=this.offset,g=d.x||0,r=d.y||0,t=this.chart.renderer.fontMetrics(d.style&&d.style.fontSize,this.axisTitle).f,h={low:e+(a?0:h),middle:e+h/2,high:e+(a?h:0)}[d.align],c=(a?b+this.height:c)+(a?1:-1)*(n?-1:1)*this.axisTitleMargin+
(2===this.side?t:0);return{x:a?h+g:c+(n?this.width:0)+q+g,y:a?c+r-(n?this.height:0)+q:h+r}},render:function(){var a=this,c=a.chart,b=c.renderer,h=a.options,e=a.isLog,n=a.lin2log,g=a.isLinked,r=a.tickPositions,t=a.axisTitle,k=a.ticks,l=a.minorTicks,C=a.alternateBands,D=h.stackLabels,B=h.alternateGridColor,w=a.tickmarkOffset,E=a.axisLine,u=c.hasRendered&&q(a.oldMin),m=a.showAxis,z=A(b.globalAnimation),p,I;a.labelEdge.length=0;a.overlap=!1;d([k,l,C],function(a){for(var c in a)a[c].isActive=!1});if(a.hasData()||
g)a.minorTickInterval&&!a.categories&&d(a.getMinorTickPositions(),function(c){l[c]||(l[c]=new N(a,c,"minor"));u&&l[c].isNew&&l[c].render(null,!0);l[c].render(null,!1,1)}),r.length&&(d(r,function(c,b){if(!g||c>=a.min&&c<=a.max)k[c]||(k[c]=new N(a,c)),u&&k[c].isNew&&k[c].render(b,!0,.1),k[c].render(b)}),w&&(0===a.min||a.single)&&(k[-1]||(k[-1]=new N(a,-1,null,!0)),k[-1].render(-1))),B&&d(r,function(b,f){I=void 0!==r[f+1]?r[f+1]+w:a.max-w;0===f%2&&b<a.max&&I<=a.max+(c.polar?-w:w)&&(C[b]||(C[b]=new K(a)),
p=b+w,C[b].options={from:e?n(p):p,to:e?n(I):I,color:B},C[b].render(),C[b].isActive=!0)}),a._addedPlotLB||(d((h.plotLines||[]).concat(h.plotBands||[]),function(c){a.addPlotBandOrLine(c)}),a._addedPlotLB=!0);d([k,l,C],function(a){var b,f,h=[],d=z.duration;for(b in a)a[b].isActive||(a[b].render(b,!1,0),a[b].isActive=!1,h.push(b));G(function(){for(f=h.length;f--;)a[h[f]]&&!a[h[f]].isActive&&(a[h[f]].destroy(),delete a[h[f]])},a!==C&&c.hasRendered&&d?d:0)});E&&(E[E.isPlaced?"animate":"attr"]({d:this.getLinePath(E.strokeWidth())}),
E.isPlaced=!0,E[m?"show":"hide"](!0));t&&m&&(t[t.isNew?"attr":"animate"](a.getTitlePosition()),t.isNew=!1);D&&D.enabled&&a.renderStackTotals();a.isDirty=!1},redraw:function(){this.visible&&(this.render(),d(this.plotLinesAndBands,function(a){a.render()}));d(this.series,function(a){a.isDirty=!0})},keepProps:"extKey hcEvents names series userMax userMin".split(" "),destroy:function(a){var c=this,b=c.stacks,f,h=c.plotLinesAndBands,e;a||r(c);for(f in b)k(b[f]),b[f]=null;d([c.ticks,c.minorTicks,c.alternateBands],
function(a){k(a)});if(h)for(a=h.length;a--;)h[a].destroy();d("stackTotalGroup axisLine axisTitle axisGroup gridGroup labelGroup cross".split(" "),function(a){c[a]&&(c[a]=c[a].destroy())});for(e in c)c.hasOwnProperty(e)&&-1===n(e,c.keepProps)&&delete c[e]},drawCrosshair:function(a,c){var b,f=this.crosshair,h=w(f.snap,!0),d,e=this.cross;a||(a=this.cross&&this.cross.e);this.crosshair&&!1!==(l(c)||!h)?(h?l(c)&&(d=this.isXAxis?c.plotX:this.len-c.plotY):d=a&&(this.horiz?a.chartX-this.pos:this.len-a.chartY+
this.pos),l(d)&&(b=this.getPlotLinePath(c&&(this.isXAxis?c.x:w(c.stackY,c.y)),null,null,null,d)||null),l(b)?(c=this.categories&&!this.isRadial,e||(this.cross=e=this.chart.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-"+(c?"category ":"thin ")+f.className).attr({zIndex:w(f.zIndex,2)}).add()),e.show().attr({d:b}),c&&!f.width&&e.attr({"stroke-width":this.transA}),this.cross.e=a):this.hideCrosshair()):this.hideCrosshair()},hideCrosshair:function(){this.cross&&this.cross.hide()}};
z(a.Axis.prototype,p)})(L);(function(a){var x=a.Axis,A=a.Date,F=a.dateFormat,H=a.defaultOptions,p=a.defined,e=a.each,g=a.extend,l=a.getMagnitude,m=a.getTZOffset,k=a.normalizeTickInterval,d=a.pick,b=a.timeUnits;x.prototype.getTimeTicks=function(a,k,t,c){var h=[],n={},l=H.global.useUTC,q,D=new A(k-m(k)),B=A.hcMakeTime,u=a.unitRange,w=a.count,z;if(p(k)){D[A.hcSetMilliseconds](u>=b.second?0:w*Math.floor(D.getMilliseconds()/w));if(u>=b.second)D[A.hcSetSeconds](u>=b.minute?0:w*Math.floor(D.getSeconds()/
w));if(u>=b.minute)D[A.hcSetMinutes](u>=b.hour?0:w*Math.floor(D[A.hcGetMinutes]()/w));if(u>=b.hour)D[A.hcSetHours](u>=b.day?0:w*Math.floor(D[A.hcGetHours]()/w));if(u>=b.day)D[A.hcSetDate](u>=b.month?1:w*Math.floor(D[A.hcGetDate]()/w));u>=b.month&&(D[A.hcSetMonth](u>=b.year?0:w*Math.floor(D[A.hcGetMonth]()/w)),q=D[A.hcGetFullYear]());if(u>=b.year)D[A.hcSetFullYear](q-q%w);if(u===b.week)D[A.hcSetDate](D[A.hcGetDate]()-D[A.hcGetDay]()+d(c,1));q=D[A.hcGetFullYear]();c=D[A.hcGetMonth]();var r=D[A.hcGetDate](),
C=D[A.hcGetHours]();if(A.hcTimezoneOffset||A.hcGetTimezoneOffset)z=(!l||!!A.hcGetTimezoneOffset)&&(t-k>4*b.month||m(k)!==m(t)),D=D.getTime(),D=new A(D+m(D));l=D.getTime();for(k=1;l<t;)h.push(l),l=u===b.year?B(q+k*w,0):u===b.month?B(q,c+k*w):!z||u!==b.day&&u!==b.week?z&&u===b.hour?B(q,c,r,C+k*w):l+u*w:B(q,c,r+k*w*(u===b.day?1:7)),k++;h.push(l);u<=b.hour&&e(h,function(a){"000000000"===F("%H%M%S%L",a)&&(n[a]="day")})}h.info=g(a,{higherRanks:n,totalRange:u*w});return h};x.prototype.normalizeTimeTickInterval=
function(a,d){var e=d||[["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]];d=e[e.length-1];var c=b[d[0]],h=d[1],n;for(n=0;n<e.length&&!(d=e[n],c=b[d[0]],h=d[1],e[n+1]&&a<=(c*h[h.length-1]+b[e[n+1][0]])/2);n++);c===b.year&&a<5*c&&(h=[1,2,5]);a=k(a/c,h,"year"===d[0]?Math.max(l(a/c),1):1);return{unitRange:c,count:a,unitName:d[0]}}})(L);(function(a){var x=a.Axis,
A=a.getMagnitude,F=a.map,H=a.normalizeTickInterval,p=a.pick;x.prototype.getLogTickPositions=function(a,g,l,m){var e=this.options,d=this.len,b=this.lin2log,z=this.log2lin,u=[];m||(this._minorAutoInterval=null);if(.5<=a)a=Math.round(a),u=this.getLinearTickPositions(a,g,l);else if(.08<=a)for(var d=Math.floor(g),t,c,h,n,E,e=.3<a?[1,2,4]:.15<a?[1,2,4,6,8]:[1,2,3,4,5,6,7,8,9];d<l+1&&!E;d++)for(c=e.length,t=0;t<c&&!E;t++)h=z(b(d)*e[t]),h>g&&(!m||n<=l)&&void 0!==n&&u.push(n),n>l&&(E=!0),n=h;else g=b(g),l=
b(l),a=e[m?"minorTickInterval":"tickInterval"],a=p("auto"===a?null:a,this._minorAutoInterval,e.tickPixelInterval/(m?5:1)*(l-g)/((m?d/this.tickPositions.length:d)||1)),a=H(a,null,A(a)),u=F(this.getLinearTickPositions(a,g,l),z),m||(this._minorAutoInterval=a/5);m||(this.tickInterval=a);return u};x.prototype.log2lin=function(a){return Math.log(a)/Math.LN10};x.prototype.lin2log=function(a){return Math.pow(10,a)}})(L);(function(a){var x=a.dateFormat,A=a.each,F=a.extend,H=a.format,p=a.isNumber,e=a.map,g=
a.merge,l=a.pick,m=a.splat,k=a.syncTimeout,d=a.timeUnits;a.Tooltip=function(){this.init.apply(this,arguments)};a.Tooltip.prototype={init:function(a,d){this.chart=a;this.options=d;this.crosshairs=[];this.now={x:0,y:0};this.isHidden=!0;this.split=d.split&&!a.inverted;this.shared=d.shared||this.split},cleanSplit:function(a){A(this.chart.series,function(b){var d=b&&b.tt;d&&(!d.isActive||a?b.tt=d.destroy():d.isActive=!1)})},applyFilter:function(){var a=this.chart;a.renderer.definition({tagName:"filter",
id:"drop-shadow-"+a.index,opacity:.5,children:[{tagName:"feGaussianBlur",in:"SourceAlpha",stdDeviation:1},{tagName:"feOffset",dx:1,dy:1},{tagName:"feComponentTransfer",children:[{tagName:"feFuncA",type:"linear",slope:.3}]},{tagName:"feMerge",children:[{tagName:"feMergeNode"},{tagName:"feMergeNode",in:"SourceGraphic"}]}]});a.renderer.definition({tagName:"style",textContent:".highcharts-tooltip-"+a.index+"{filter:url(#drop-shadow-"+a.index+")}"})},getLabel:function(){var a=this.chart.renderer,d=this.options;
this.label||(this.label=this.split?a.g("tooltip"):a.label("",0,0,d.shape||"callout",null,null,d.useHTML,null,"tooltip").attr({padding:d.padding,r:d.borderRadius}),this.applyFilter(),this.label.addClass("highcharts-tooltip-"+this.chart.index),this.label.attr({zIndex:8}).add());return this.label},update:function(a){this.destroy();this.init(this.chart,g(!0,this.options,a))},destroy:function(){this.label&&(this.label=this.label.destroy());this.split&&this.tt&&(this.cleanSplit(this.chart,!0),this.tt=this.tt.destroy());
clearTimeout(this.hideTimer);clearTimeout(this.tooltipTimeout)},move:function(a,d,e,g){var c=this,b=c.now,n=!1!==c.options.animation&&!c.isHidden&&(1<Math.abs(a-b.x)||1<Math.abs(d-b.y)),k=c.followPointer||1<c.len;F(b,{x:n?(2*b.x+a)/3:a,y:n?(b.y+d)/2:d,anchorX:k?void 0:n?(2*b.anchorX+e)/3:e,anchorY:k?void 0:n?(b.anchorY+g)/2:g});c.getLabel().attr(b);n&&(clearTimeout(this.tooltipTimeout),this.tooltipTimeout=setTimeout(function(){c&&c.move(a,d,e,g)},32))},hide:function(a){var b=this;clearTimeout(this.hideTimer);
a=l(a,this.options.hideDelay,500);this.isHidden||(this.hideTimer=k(function(){b.getLabel()[a?"fadeOut":"hide"]();b.isHidden=!0},a))},getAnchor:function(a,d){var b,g=this.chart,c=g.inverted,h=g.plotTop,n=g.plotLeft,k=0,q=0,l,B;a=m(a);b=a[0].tooltipPos;this.followPointer&&d&&(void 0===d.chartX&&(d=g.pointer.normalize(d)),b=[d.chartX-g.plotLeft,d.chartY-h]);b||(A(a,function(a){l=a.series.yAxis;B=a.series.xAxis;k+=a.plotX+(!c&&B?B.left-n:0);q+=(a.plotLow?(a.plotLow+a.plotHigh)/2:a.plotY)+(!c&&l?l.top-
h:0)}),k/=a.length,q/=a.length,b=[c?g.plotWidth-q:k,this.shared&&!c&&1<a.length&&d?d.chartY-h:c?g.plotHeight-k:q]);return e(b,Math.round)},getPosition:function(a,d,e){var b=this.chart,c=this.distance,h={},n=e.h||0,g,q=["y",b.chartHeight,d,e.plotY+b.plotTop,b.plotTop,b.plotTop+b.plotHeight],k=["x",b.chartWidth,a,e.plotX+b.plotLeft,b.plotLeft,b.plotLeft+b.plotWidth],B=!this.followPointer&&l(e.ttBelow,!b.inverted===!!e.negative),m=function(a,b,d,f,e,q){var g=d<f-c,r=f+c+d<b,k=f-c-d;f+=c;if(B&&r)h[a]=
f;else if(!B&&g)h[a]=k;else if(g)h[a]=Math.min(q-d,0>k-n?k:k-n);else if(r)h[a]=Math.max(e,f+n+d>b?f:f+n);else return!1},w=function(a,b,d,f){var e;f<c||f>b-c?e=!1:h[a]=f<d/2?1:f>b-d/2?b-d-2:f-d/2;return e},u=function(a){var c=q;q=k;k=c;g=a},r=function(){!1!==m.apply(0,q)?!1!==w.apply(0,k)||g||(u(!0),r()):g?h.x=h.y=0:(u(!0),r())};(b.inverted||1<this.len)&&u();r();return h},defaultFormatter:function(a){var b=this.points||m(this),d;d=[a.tooltipFooterHeaderFormatter(b[0])];d=d.concat(a.bodyFormatter(b));
d.push(a.tooltipFooterHeaderFormatter(b[0],!0));return d},refresh:function(a,d){var b=this.chart,e,c,h,n={},g=[];e=this.options.formatter||this.defaultFormatter;var n=b.hoverPoints,q=this.shared;clearTimeout(this.hideTimer);this.followPointer=m(a)[0].series.tooltipOptions.followPointer;h=this.getAnchor(a,d);d=h[0];c=h[1];!q||a.series&&a.series.noSharedTooltip?n=a.getLabelConfig():(b.hoverPoints=a,n&&A(n,function(a){a.setState()}),A(a,function(a){a.setState("hover");g.push(a.getLabelConfig())}),n=
{x:a[0].category,y:a[0].y},n.points=g,this.len=g.length,a=a[0]);n=e.call(n,this);q=a.series;this.distance=l(q.tooltipOptions.distance,16);!1===n?this.hide():(e=this.getLabel(),this.isHidden&&e.attr({opacity:1}).show(),this.split?this.renderSplit(n,b.hoverPoints):(e.attr({text:n&&n.join?n.join(""):n}),e.removeClass(/highcharts-color-[\d]+/g).addClass("highcharts-color-"+l(a.colorIndex,q.colorIndex)),this.updatePosition({plotX:d,plotY:c,negative:a.negative,ttBelow:a.ttBelow,h:h[2]||0})),this.isHidden=
!1)},renderSplit:function(b,d){var e=this,g=[],c=this.chart,h=c.renderer,n=!0,k=this.options,q,D=this.getLabel();A(b.slice(0,b.length-1),function(a,b){b=d[b-1]||{isHeader:!0,plotX:d[0].plotX};var t=b.series||e,B=t.tt,r="highcharts-color-"+l(b.colorIndex,(b.series||{}).colorIndex,"none");B||(t.tt=B=h.label(null,null,null,"callout").addClass("highcharts-tooltip-box "+r).attr({padding:k.padding,r:k.borderRadius}).add(D));B.isActive=!0;B.attr({text:a});a=B.getBBox();r=a.width+B.strokeWidth();b.isHeader?
(q=a.height,r=Math.max(0,Math.min(b.plotX+c.plotLeft-r/2,c.chartWidth-r))):r=b.plotX+c.plotLeft-l(k.distance,16)-r;0>r&&(n=!1);a=(b.series&&b.series.yAxis&&b.series.yAxis.pos)+(b.plotY||0);a-=c.plotTop;g.push({target:b.isHeader?c.plotHeight+q:a,rank:b.isHeader?1:0,size:t.tt.getBBox().height+1,point:b,x:r,tt:B})});this.cleanSplit();a.distribute(g,c.plotHeight+q);A(g,function(a){var b=a.point;a.tt.attr({visibility:void 0===a.pos?"hidden":"inherit",x:n||b.isHeader?a.x:b.plotX+c.plotLeft+l(k.distance,
16),y:a.pos+c.plotTop,anchorX:b.plotX+c.plotLeft,anchorY:b.isHeader?a.pos+c.plotTop-15:b.plotY+c.plotTop})})},updatePosition:function(a){var b=this.chart,d=this.getLabel(),d=(this.options.positioner||this.getPosition).call(this,d.width,d.height,a);this.move(Math.round(d.x),Math.round(d.y||0),a.plotX+b.plotLeft,a.plotY+b.plotTop)},getXDateFormat:function(a,e,g){var b;e=e.dateTimeLabelFormats;var c=g&&g.closestPointRange,h,n={millisecond:15,second:12,minute:9,hour:6,day:3},k,q="millisecond";if(c){k=
x("%m-%d %H:%M:%S.%L",a.x);for(h in d){if(c===d.week&&+x("%w",a.x)===g.options.startOfWeek&&"00:00:00.000"===k.substr(6)){h="week";break}if(d[h]>c){h=q;break}if(n[h]&&k.substr(n[h])!=="01-01 00:00:00.000".substr(n[h]))break;"week"!==h&&(q=h)}h&&(b=e[h])}else b=e.day;return b||e.year},tooltipFooterHeaderFormatter:function(a,d){var b=d?"footer":"header";d=a.series;var e=d.tooltipOptions,c=e.xDateFormat,h=d.xAxis,n=h&&"datetime"===h.options.type&&p(a.key),b=e[b+"Format"];n&&!c&&(c=this.getXDateFormat(a,
e,h));n&&c&&(b=b.replace("{point.key}","{point.key:"+c+"}"));return H(b,{point:a,series:d})},bodyFormatter:function(a){return e(a,function(a){var b=a.series.tooltipOptions;return(b.pointFormatter||a.point.tooltipFormatter).call(a.point,b.pointFormat)})}}})(L);(function(a){var x=a.addEvent,A=a.attr,F=a.charts,H=a.css,p=a.defined,e=a.doc,g=a.each,l=a.extend,m=a.fireEvent,k=a.offset,d=a.pick,b=a.removeEvent,z=a.splat,u=a.Tooltip,t=a.win;a.Pointer=function(a,b){this.init(a,b)};a.Pointer.prototype={init:function(a,
b){this.options=b;this.chart=a;this.runChartClick=b.chart.events&&!!b.chart.events.click;this.pinchDown=[];this.lastValidTouch={};u&&b.tooltip.enabled&&(a.tooltip=new u(a,b.tooltip),this.followTouchMove=d(b.tooltip.followTouchMove,!0));this.setDOMEvents()},zoomOption:function(a){var c=this.chart,b=c.options.chart,e=b.zoomType||"",c=c.inverted;/touch/.test(a.type)&&(e=d(b.pinchType,e));this.zoomX=a=/x/.test(e);this.zoomY=e=/y/.test(e);this.zoomHor=a&&!c||e&&c;this.zoomVert=e&&!c||a&&c;this.hasZoom=
a||e},normalize:function(a,b){var c,d;a=a||t.event;a.target||(a.target=a.srcElement);d=a.touches?a.touches.length?a.touches.item(0):a.changedTouches[0]:a;b||(this.chartPosition=b=k(this.chart.container));void 0===d.pageX?(c=Math.max(a.x,a.clientX-b.left),b=a.y):(c=d.pageX-b.left,b=d.pageY-b.top);return l(a,{chartX:Math.round(c),chartY:Math.round(b)})},getCoordinates:function(a){var c={xAxis:[],yAxis:[]};g(this.chart.axes,function(b){c[b.isXAxis?"xAxis":"yAxis"].push({axis:b,value:b.toValue(a[b.horiz?
"chartX":"chartY"])})});return c},runPointActions:function(c){var b=this.chart,n=b.series,k=b.tooltip,q=k?k.shared:!1,l=!0,t=b.hoverPoint,m=b.hoverSeries,w,p,r,C=[],G;if(!q&&!m)for(w=0;w<n.length;w++)if(n[w].directTouch||!n[w].options.stickyTracking)n=[];m&&(q?m.noSharedTooltip:m.directTouch)&&t?C=[t]:(q||!m||m.options.stickyTracking||(n=[m]),g(n,function(a){p=a.noSharedTooltip&&q;r=!q&&a.directTouch;a.visible&&!p&&!r&&d(a.options.enableMouseTracking,!0)&&(G=a.searchPoint(c,!p&&1===a.kdDimensions))&&
G.series&&C.push(G)}),C.sort(function(a,c){var b=a.distX-c.distX,f=a.dist-c.dist,d=c.series.group.zIndex-a.series.group.zIndex;return 0!==b&&q?b:0!==f?f:0!==d?d:a.series.index>c.series.index?-1:1}));if(q)for(w=C.length;w--;)(C[w].x!==C[0].x||C[w].series.noSharedTooltip)&&C.splice(w,1);if(C[0]&&(C[0]!==this.prevKDPoint||k&&k.isHidden)){if(q&&!C[0].series.noSharedTooltip){for(w=0;w<C.length;w++)C[w].onMouseOver(c,C[w]!==(m&&m.directTouch&&t||C[0]));C.length&&k&&k.refresh(C.sort(function(a,c){return a.series.index-
c.series.index}),c)}else if(k&&k.refresh(C[0],c),!m||!m.directTouch)C[0].onMouseOver(c);this.prevKDPoint=C[0];l=!1}l&&(n=m&&m.tooltipOptions.followPointer,k&&n&&!k.isHidden&&(n=k.getAnchor([{}],c),k.updatePosition({plotX:n[0],plotY:n[1]})));this.unDocMouseMove||(this.unDocMouseMove=x(e,"mousemove",function(c){if(F[a.hoverChartIndex])F[a.hoverChartIndex].pointer.onDocumentMouseMove(c)}));g(q?C:[d(t,C[0])],function(a){g(b.axes,function(b){(!a||a.series&&a.series[b.coll]===b)&&b.drawCrosshair(c,a)})})},
reset:function(a,b){var c=this.chart,d=c.hoverSeries,h=c.hoverPoint,e=c.hoverPoints,k=c.tooltip,l=k&&k.shared?e:h;a&&l&&g(z(l),function(c){c.series.isCartesian&&void 0===c.plotX&&(a=!1)});if(a)k&&l&&(k.refresh(l),h&&(h.setState(h.state,!0),g(c.axes,function(a){a.crosshair&&a.drawCrosshair(null,h)})));else{if(h)h.onMouseOut();e&&g(e,function(a){a.setState()});if(d)d.onMouseOut();k&&k.hide(b);this.unDocMouseMove&&(this.unDocMouseMove=this.unDocMouseMove());g(c.axes,function(a){a.hideCrosshair()});this.hoverX=
this.prevKDPoint=c.hoverPoints=c.hoverPoint=null}},scaleGroups:function(a,b){var c=this.chart,d;g(c.series,function(h){d=a||h.getPlotBox();h.xAxis&&h.xAxis.zoomEnabled&&h.group&&(h.group.attr(d),h.markerGroup&&(h.markerGroup.attr(d),h.markerGroup.clip(b?c.clipRect:null)),h.dataLabelsGroup&&h.dataLabelsGroup.attr(d))});c.clipRect.attr(b||c.clipBox)},dragStart:function(a){var c=this.chart;c.mouseIsDown=a.type;c.cancelClick=!1;c.mouseDownX=this.mouseDownX=a.chartX;c.mouseDownY=this.mouseDownY=a.chartY},
drag:function(a){var c=this.chart,b=c.options.chart,d=a.chartX,e=a.chartY,g=this.zoomHor,k=this.zoomVert,l=c.plotLeft,t=c.plotTop,m=c.plotWidth,r=c.plotHeight,C,G=this.selectionMarker,p=this.mouseDownX,f=this.mouseDownY,y=b.panKey&&a[b.panKey+"Key"];G&&G.touch||(d<l?d=l:d>l+m&&(d=l+m),e<t?e=t:e>t+r&&(e=t+r),this.hasDragged=Math.sqrt(Math.pow(p-d,2)+Math.pow(f-e,2)),10<this.hasDragged&&(C=c.isInsidePlot(p-l,f-t),c.hasCartesianSeries&&(this.zoomX||this.zoomY)&&C&&!y&&!G&&(this.selectionMarker=G=c.renderer.rect(l,
t,g?1:m,k?1:r,0).attr({"class":"highcharts-selection-marker",zIndex:7}).add()),G&&g&&(d-=p,G.attr({width:Math.abs(d),x:(0<d?0:d)+p})),G&&k&&(d=e-f,G.attr({height:Math.abs(d),y:(0<d?0:d)+f})),C&&!G&&b.panning&&c.pan(a,b.panning)))},drop:function(a){var c=this,b=this.chart,d=this.hasPinched;if(this.selectionMarker){var e={originalEvent:a,xAxis:[],yAxis:[]},k=this.selectionMarker,t=k.attr?k.attr("x"):k.x,u=k.attr?k.attr("y"):k.y,w=k.attr?k.attr("width"):k.width,z=k.attr?k.attr("height"):k.height,r;if(this.hasDragged||
d)g(b.axes,function(b){if(b.zoomEnabled&&p(b.min)&&(d||c[{xAxis:"zoomX",yAxis:"zoomY"}[b.coll]])){var h=b.horiz,g="touchend"===a.type?b.minPixelPadding:0,f=b.toValue((h?t:u)+g),h=b.toValue((h?t+w:u+z)-g);e[b.coll].push({axis:b,min:Math.min(f,h),max:Math.max(f,h)});r=!0}}),r&&m(b,"selection",e,function(a){b.zoom(l(a,d?{animation:!1}:null))});this.selectionMarker=this.selectionMarker.destroy();d&&this.scaleGroups()}b&&(H(b.container,{cursor:b._cursor}),b.cancelClick=10<this.hasDragged,b.mouseIsDown=
this.hasDragged=this.hasPinched=!1,this.pinchDown=[])},onContainerMouseDown:function(a){a=this.normalize(a);this.zoomOption(a);a.preventDefault&&a.preventDefault();this.dragStart(a)},onDocumentMouseUp:function(c){F[a.hoverChartIndex]&&F[a.hoverChartIndex].pointer.drop(c)},onDocumentMouseMove:function(a){var b=this.chart,c=this.chartPosition;a=this.normalize(a,c);!c||this.inClass(a.target,"highcharts-tracker")||b.isInsidePlot(a.chartX-b.plotLeft,a.chartY-b.plotTop)||this.reset()},onContainerMouseLeave:function(b){var c=
F[a.hoverChartIndex];c&&(b.relatedTarget||b.toElement)&&(c.pointer.reset(),c.pointer.chartPosition=null)},onContainerMouseMove:function(b){var c=this.chart;p(a.hoverChartIndex)&&F[a.hoverChartIndex]&&F[a.hoverChartIndex].mouseIsDown||(a.hoverChartIndex=c.index);b=this.normalize(b);b.returnValue=!1;"mousedown"===c.mouseIsDown&&this.drag(b);!this.inClass(b.target,"highcharts-tracker")&&!c.isInsidePlot(b.chartX-c.plotLeft,b.chartY-c.plotTop)||c.openMenu||this.runPointActions(b)},inClass:function(a,b){for(var c;a;){if(c=
A(a,"class")){if(-1!==c.indexOf(b))return!0;if(-1!==c.indexOf("highcharts-container"))return!1}a=a.parentNode}},onTrackerMouseOut:function(a){var b=this.chart.hoverSeries;a=a.relatedTarget||a.toElement;if(!(!b||!a||b.options.stickyTracking||this.inClass(a,"highcharts-tooltip")||this.inClass(a,"highcharts-series-"+b.index)&&this.inClass(a,"highcharts-tracker")))b.onMouseOut()},onContainerClick:function(a){var b=this.chart,c=b.hoverPoint,d=b.plotLeft,e=b.plotTop;a=this.normalize(a);b.cancelClick||(c&&
this.inClass(a.target,"highcharts-tracker")?(m(c.series,"click",l(a,{point:c})),b.hoverPoint&&c.firePointEvent("click",a)):(l(a,this.getCoordinates(a)),b.isInsidePlot(a.chartX-d,a.chartY-e)&&m(b,"click",a)))},setDOMEvents:function(){var b=this,d=b.chart.container;d.onmousedown=function(a){b.onContainerMouseDown(a)};d.onmousemove=function(a){b.onContainerMouseMove(a)};d.onclick=function(a){b.onContainerClick(a)};x(d,"mouseleave",b.onContainerMouseLeave);1===a.chartCount&&x(e,"mouseup",b.onDocumentMouseUp);
a.hasTouch&&(d.ontouchstart=function(a){b.onContainerTouchStart(a)},d.ontouchmove=function(a){b.onContainerTouchMove(a)},1===a.chartCount&&x(e,"touchend",b.onDocumentTouchEnd))},destroy:function(){var c;b(this.chart.container,"mouseleave",this.onContainerMouseLeave);a.chartCount||(b(e,"mouseup",this.onDocumentMouseUp),b(e,"touchend",this.onDocumentTouchEnd));clearInterval(this.tooltipTimeout);for(c in this)this[c]=null}}})(L);(function(a){var x=a.charts,A=a.each,F=a.extend,H=a.map,p=a.noop,e=a.pick;
F(a.Pointer.prototype,{pinchTranslate:function(a,e,m,k,d,b){this.zoomHor&&this.pinchTranslateDirection(!0,a,e,m,k,d,b);this.zoomVert&&this.pinchTranslateDirection(!1,a,e,m,k,d,b)},pinchTranslateDirection:function(a,e,m,k,d,b,p,u){var g=this.chart,c=a?"x":"y",h=a?"X":"Y",n="chart"+h,l=a?"width":"height",q=g["plot"+(a?"Left":"Top")],D,B,z=u||1,w=g.inverted,K=g.bounds[a?"h":"v"],r=1===e.length,C=e[0][n],G=m[0][n],N=!r&&e[1][n],f=!r&&m[1][n],y;m=function(){!r&&20<Math.abs(C-N)&&(z=u||Math.abs(G-f)/Math.abs(C-
N));B=(q-G)/z+C;D=g["plot"+(a?"Width":"Height")]/z};m();e=B;e<K.min?(e=K.min,y=!0):e+D>K.max&&(e=K.max-D,y=!0);y?(G-=.8*(G-p[c][0]),r||(f-=.8*(f-p[c][1])),m()):p[c]=[G,f];w||(b[c]=B-q,b[l]=D);b=w?1/z:z;d[l]=D;d[c]=e;k[w?a?"scaleY":"scaleX":"scale"+h]=z;k["translate"+h]=b*q+(G-b*C)},pinch:function(a){var g=this,m=g.chart,k=g.pinchDown,d=a.touches,b=d.length,z=g.lastValidTouch,u=g.hasZoom,t=g.selectionMarker,c={},h=1===b&&(g.inClass(a.target,"highcharts-tracker")&&m.runTrackerClick||g.runChartClick),
n={};1<b&&(g.initiated=!0);u&&g.initiated&&!h&&a.preventDefault();H(d,function(a){return g.normalize(a)});"touchstart"===a.type?(A(d,function(a,b){k[b]={chartX:a.chartX,chartY:a.chartY}}),z.x=[k[0].chartX,k[1]&&k[1].chartX],z.y=[k[0].chartY,k[1]&&k[1].chartY],A(m.axes,function(a){if(a.zoomEnabled){var b=m.bounds[a.horiz?"h":"v"],c=a.minPixelPadding,d=a.toPixels(e(a.options.min,a.dataMin)),h=a.toPixels(e(a.options.max,a.dataMax)),g=Math.max(d,h);b.min=Math.min(a.pos,Math.min(d,h)-c);b.max=Math.max(a.pos+
a.len,g+c)}}),g.res=!0):g.followTouchMove&&1===b?this.runPointActions(g.normalize(a)):k.length&&(t||(g.selectionMarker=t=F({destroy:p,touch:!0},m.plotBox)),g.pinchTranslate(k,d,c,t,n,z),g.hasPinched=u,g.scaleGroups(c,n),g.res&&(g.res=!1,this.reset(!1,0)))},touch:function(g,l){var m=this.chart,k,d;if(m.index!==a.hoverChartIndex)this.onContainerMouseLeave({relatedTarget:!0});a.hoverChartIndex=m.index;1===g.touches.length?(g=this.normalize(g),(d=m.isInsidePlot(g.chartX-m.plotLeft,g.chartY-m.plotTop))&&
!m.openMenu?(l&&this.runPointActions(g),"touchmove"===g.type&&(l=this.pinchDown,k=l[0]?4<=Math.sqrt(Math.pow(l[0].chartX-g.chartX,2)+Math.pow(l[0].chartY-g.chartY,2)):!1),e(k,!0)&&this.pinch(g)):l&&this.reset()):2===g.touches.length&&this.pinch(g)},onContainerTouchStart:function(a){this.zoomOption(a);this.touch(a,!0)},onContainerTouchMove:function(a){this.touch(a)},onDocumentTouchEnd:function(e){x[a.hoverChartIndex]&&x[a.hoverChartIndex].pointer.drop(e)}})})(L);(function(a){var x=a.addEvent,A=a.charts,
F=a.css,H=a.doc,p=a.extend,e=a.noop,g=a.Pointer,l=a.removeEvent,m=a.win,k=a.wrap;if(m.PointerEvent||m.MSPointerEvent){var d={},b=!!m.PointerEvent,z=function(){var a,b=[];b.item=function(a){return this[a]};for(a in d)d.hasOwnProperty(a)&&b.push({pageX:d[a].pageX,pageY:d[a].pageY,target:d[a].target});return b},u=function(b,c,d,g){"touch"!==b.pointerType&&b.pointerType!==b.MSPOINTER_TYPE_TOUCH||!A[a.hoverChartIndex]||(g(b),g=A[a.hoverChartIndex].pointer,g[c]({type:d,target:b.currentTarget,preventDefault:e,
touches:z()}))};p(g.prototype,{onContainerPointerDown:function(a){u(a,"onContainerTouchStart","touchstart",function(a){d[a.pointerId]={pageX:a.pageX,pageY:a.pageY,target:a.currentTarget}})},onContainerPointerMove:function(a){u(a,"onContainerTouchMove","touchmove",function(a){d[a.pointerId]={pageX:a.pageX,pageY:a.pageY};d[a.pointerId].target||(d[a.pointerId].target=a.currentTarget)})},onDocumentPointerUp:function(a){u(a,"onDocumentTouchEnd","touchend",function(a){delete d[a.pointerId]})},batchMSEvents:function(a){a(this.chart.container,
b?"pointerdown":"MSPointerDown",this.onContainerPointerDown);a(this.chart.container,b?"pointermove":"MSPointerMove",this.onContainerPointerMove);a(H,b?"pointerup":"MSPointerUp",this.onDocumentPointerUp)}});k(g.prototype,"init",function(a,b,d){a.call(this,b,d);this.hasZoom&&F(b.container,{"-ms-touch-action":"none","touch-action":"none"})});k(g.prototype,"setDOMEvents",function(a){a.apply(this);(this.hasZoom||this.followTouchMove)&&this.batchMSEvents(x)});k(g.prototype,"destroy",function(a){this.batchMSEvents(l);
a.call(this)})}})(L);(function(a){var x,A=a.addEvent,F=a.css,H=a.discardElement,p=a.defined,e=a.each,g=a.extend,l=a.isFirefox,m=a.marginNames,k=a.merge,d=a.pick,b=a.setAnimation,z=a.stableSort,u=a.win,t=a.wrap;x=a.Legend=function(a,b){this.init(a,b)};x.prototype={init:function(a,b){this.chart=a;this.setOptions(b);b.enabled&&(this.render(),A(this.chart,"endResize",function(){this.legend.positionCheckboxes()}))},setOptions:function(a){var b=d(a.padding,8);this.options=a;this.itemMarginTop=a.itemMarginTop||
0;this.initialItemX=this.padding=b;this.initialItemY=b-5;this.itemHeight=this.maxItemWidth=0;this.symbolWidth=d(a.symbolWidth,16);this.pages=[]},update:function(a,b){var c=this.chart;this.setOptions(k(!0,this.options,a));this.destroy();c.isDirtyLegend=c.isDirtyBox=!0;d(b,!0)&&c.redraw()},colorizeItem:function(a,b){a.legendGroup[b?"removeClass":"addClass"]("highcharts-legend-item-hidden")},positionItem:function(a){var b=this.options,c=b.symbolPadding,b=!b.rtl,d=a._legendItemPos,e=d[0],d=d[1],g=a.checkbox;
(a=a.legendGroup)&&a.element&&a.translate(b?e:this.legendWidth-e-2*c-4,d);g&&(g.x=e,g.y=d)},destroyItem:function(a){var b=a.checkbox;e(["legendItem","legendLine","legendSymbol","legendGroup"],function(b){a[b]&&(a[b]=a[b].destroy())});b&&H(a.checkbox)},destroy:function(){var a=this.group,b=this.box;b&&(this.box=b.destroy());e(this.getAllItems(),function(a){e(["legendItem","legendGroup"],function(b){a[b]&&(a[b]=a[b].destroy())})});a&&(this.group=a.destroy());this.display=null},positionCheckboxes:function(a){var b=
this.group&&this.group.alignAttr,c,d=this.clipHeight||this.legendHeight,g=this.titleHeight;b&&(c=b.translateY,e(this.allItems,function(e){var h=e.checkbox,q;h&&(q=c+g+h.y+(a||0)+3,F(h,{left:b.translateX+e.checkboxOffset+h.x-20+"px",top:q+"px",display:q>c-6&&q<c+d-6?"":"none"}))}))},renderTitle:function(){var a=this.padding,b=this.options.title,d=0;b.text&&(this.title||(this.title=this.chart.renderer.label(b.text,a-3,a-4,null,null,null,null,null,"legend-title").attr({zIndex:1}).add(this.group)),a=
this.title.getBBox(),d=a.height,this.offsetWidth=a.width,this.contentGroup.attr({translateY:d}));this.titleHeight=d},setText:function(b){var c=this.options;b.legendItem.attr({text:c.labelFormat?a.format(c.labelFormat,b):c.labelFormatter.call(b)})},renderItem:function(a){var b=this.chart,c=b.renderer,e=this.options,g="horizontal"===e.layout,k=this.symbolWidth,l=e.symbolPadding,t=this.padding,m=g?d(e.itemDistance,20):0,p=!e.rtl,r=e.width,C=e.itemMarginBottom||0,G=this.itemMarginTop,u=this.initialItemX,
f=a.legendItem,y=!a.series,z=!y&&a.series.drawLegendSymbol?a.series:a,P=z.options,P=this.createCheckboxForItem&&P&&P.showCheckbox,x=e.useHTML;f||(a.legendGroup=c.g("legend-item").addClass("highcharts-"+z.type+"-series highcharts-color-"+a.colorIndex+(a.options.className?" "+a.options.className:"")+(y?" highcharts-series-"+a.index:"")).attr({zIndex:1}).add(this.scrollGroup),a.legendItem=f=c.text("",p?k+l:-l,this.baseline||0,x).attr({align:p?"left":"right",zIndex:2}).add(a.legendGroup),this.baseline||
(this.fontMetrics=c.fontMetrics(12,f),this.baseline=this.fontMetrics.f+3+G,f.attr("y",this.baseline)),z.drawLegendSymbol(this,a),this.setItemEvents&&this.setItemEvents(a,f,x),P&&this.createCheckboxForItem(a));this.colorizeItem(a,a.visible);this.setText(a);c=f.getBBox();k=a.checkboxOffset=e.itemWidth||a.legendItemWidth||k+l+c.width+m+(P?20:0);this.itemHeight=l=Math.round(a.legendItemHeight||c.height);g&&this.itemX-u+k>(r||b.chartWidth-2*t-u-e.x)&&(this.itemX=u,this.itemY+=G+this.lastLineHeight+C,this.lastLineHeight=
0);this.maxItemWidth=Math.max(this.maxItemWidth,k);this.lastItemY=G+this.itemY+C;this.lastLineHeight=Math.max(l,this.lastLineHeight);a._legendItemPos=[this.itemX,this.itemY];g?this.itemX+=k:(this.itemY+=G+l+C,this.lastLineHeight=l);this.offsetWidth=r||Math.max((g?this.itemX-u-m:k)+t,this.offsetWidth)},getAllItems:function(){var a=[];e(this.chart.series,function(b){var c=b&&b.options;b&&d(c.showInLegend,p(c.linkedTo)?!1:void 0,!0)&&(a=a.concat(b.legendItems||("point"===c.legendType?b.data:b)))});return a},
adjustMargins:function(a,b){var c=this.chart,h=this.options,g=h.align.charAt(0)+h.verticalAlign.charAt(0)+h.layout.charAt(0);h.floating||e([/(lth|ct|rth)/,/(rtv|rm|rbv)/,/(rbh|cb|lbh)/,/(lbv|lm|ltv)/],function(e,q){e.test(g)&&!p(a[q])&&(c[m[q]]=Math.max(c[m[q]],c.legend[(q+1)%2?"legendHeight":"legendWidth"]+[1,-1,-1,1][q]*h[q%2?"x":"y"]+d(h.margin,12)+b[q]))})},render:function(){var a=this,b=a.chart,d=b.renderer,k=a.group,q,l,t,m,w=a.box,p=a.options,r=a.padding;a.itemX=a.initialItemX;a.itemY=a.initialItemY;
a.offsetWidth=0;a.lastItemY=0;k||(a.group=k=d.g("legend").attr({zIndex:7}).add(),a.contentGroup=d.g().attr({zIndex:1}).add(k),a.scrollGroup=d.g().add(a.contentGroup));a.renderTitle();q=a.getAllItems();z(q,function(a,b){return(a.options&&a.options.legendIndex||0)-(b.options&&b.options.legendIndex||0)});p.reversed&&q.reverse();a.allItems=q;a.display=l=!!q.length;a.lastLineHeight=0;e(q,function(b){a.renderItem(b)});t=(p.width||a.offsetWidth)+r;m=a.lastItemY+a.lastLineHeight+a.titleHeight;m=a.handleOverflow(m);
m+=r;w||(a.box=w=d.rect().addClass("highcharts-legend-box").attr({r:p.borderRadius}).add(k),w.isNew=!0);0<t&&0<m&&(w[w.isNew?"attr":"animate"](w.crisp({x:0,y:0,width:t,height:m},w.strokeWidth())),w.isNew=!1);w[l?"show":"hide"]();"none"===k.getStyle("display")&&(t=m=0);a.legendWidth=t;a.legendHeight=m;e(q,function(b){a.positionItem(b)});l&&k.align(g({width:t,height:m},p),!0,"spacingBox");b.isResizing||this.positionCheckboxes()},handleOverflow:function(a){var b=this,c=this.chart,g=c.renderer,q=this.options,
k=q.y,c=c.spacingBox.height+("top"===q.verticalAlign?-k:k)-this.padding,k=q.maxHeight,l,t=this.clipRect,m=q.navigation,p=d(m.animation,!0),r=m.arrowSize||12,C=this.nav,G=this.pages,u=this.padding,f,y=this.allItems,z=function(a){a?t.attr({height:a}):t&&(b.clipRect=t.destroy(),b.contentGroup.clip());b.contentGroup.div&&(b.contentGroup.div.style.clip=a?"rect("+u+"px,9999px,"+(u+a)+"px,0)":"auto")};"horizontal"!==q.layout||"middle"===q.verticalAlign||q.floating||(c/=2);k&&(c=Math.min(c,k));G.length=0;
a>c&&!1!==m.enabled?(this.clipHeight=l=Math.max(c-20-this.titleHeight-u,0),this.currentPage=d(this.currentPage,1),this.fullHeight=a,e(y,function(a,b){var c=a._legendItemPos[1];a=Math.round(a.legendItem.getBBox().height);var d=G.length;if(!d||c-G[d-1]>l&&(f||c)!==G[d-1])G.push(f||c),d++;b===y.length-1&&c+a-G[d-1]>l&&G.push(c);c!==f&&(f=c)}),t||(t=b.clipRect=g.clipRect(0,u,9999,0),b.contentGroup.clip(t)),z(l),C||(this.nav=C=g.g().attr({zIndex:1}).add(this.group),this.up=g.symbol("triangle",0,0,r,r).on("click",
function(){b.scroll(-1,p)}).add(C),this.pager=g.text("",15,10).addClass("highcharts-legend-navigation").add(C),this.down=g.symbol("triangle-down",0,0,r,r).on("click",function(){b.scroll(1,p)}).add(C)),b.scroll(0),a=c):C&&(z(),C.hide(),this.scrollGroup.attr({translateY:1}),this.clipHeight=0);return a},scroll:function(a,d){var c=this.pages,e=c.length;a=this.currentPage+a;var h=this.clipHeight,g=this.pager,k=this.padding;a>e&&(a=e);0<a&&(void 0!==d&&b(d,this.chart),this.nav.attr({translateX:k,translateY:h+
this.padding+7+this.titleHeight,visibility:"visible"}),this.up.attr({"class":1===a?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"}),g.attr({text:a+"/"+e}),this.down.attr({x:18+this.pager.getBBox().width,"class":a===e?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"}),d=-c[a-1]+this.initialItemY,this.scrollGroup.animate({translateY:d}),this.currentPage=a,this.positionCheckboxes(d))}};a.LegendSymbolMixin={drawRectangle:function(a,b){var c=a.options,e=c.symbolHeight||
a.fontMetrics.f,c=c.squareSymbol;b.legendSymbol=this.chart.renderer.rect(c?(a.symbolWidth-e)/2:0,a.baseline-e+1,c?e:a.symbolWidth,e,d(a.options.symbolRadius,e/2)).addClass("highcharts-point").attr({zIndex:3}).add(b.legendGroup)},drawLineMarker:function(a){var b=this.options.marker,c=a.symbolWidth,d=this.chart.renderer,e=this.legendGroup,g=a.baseline-Math.round(.3*a.fontMetrics.b);this.legendLine=d.path(["M",0,g,"L",c,g]).addClass("highcharts-graph").attr({}).add(e);b&&!1!==b.enabled&&(a=0===this.symbol.indexOf("url")?
0:b.radius,this.legendSymbol=b=d.symbol(this.symbol,c/2-a,g-a,2*a,2*a,b).addClass("highcharts-point").add(e),b.isMarker=!0)}};(/Trident\/7\.0/.test(u.navigator.userAgent)||l)&&t(x.prototype,"positionItem",function(a,b){var c=this,d=function(){b._legendItemPos&&a.call(c,b)};d();setTimeout(d)})})(L);(function(a){var x=a.addEvent,A=a.animObject,F=a.attr,H=a.doc,p=a.Axis,e=a.createElement,g=a.defaultOptions,l=a.discardElement,m=a.charts,k=a.css,d=a.defined,b=a.each,z=a.error,u=a.extend,t=a.fireEvent,
c=a.getStyle,h=a.grep,n=a.isNumber,E=a.isObject,q=a.isString,D=a.Legend,B=a.marginNames,I=a.merge,w=a.Pointer,K=a.pick,r=a.pInt,C=a.removeEvent,G=a.seriesTypes,N=a.splat,f=a.svg,y=a.syncTimeout,R=a.win,P=a.Renderer,Q=a.Chart=function(){this.getArgs.apply(this,arguments)};a.chart=function(a,b,c){return new Q(a,b,c)};Q.prototype={callbacks:[],getArgs:function(){var a=[].slice.call(arguments);if(q(a[0])||a[0].nodeName)this.renderTo=a.shift();this.init(a[0],a[1])},init:function(b,c){var f,d=b.series;
b.series=null;f=I(g,b);f.series=b.series=d;this.userOptions=b;this.respRules=[];b=f.chart;d=b.events;this.margin=[];this.spacing=[];this.bounds={h:{},v:{}};this.callback=c;this.isResizing=0;this.options=f;this.axes=[];this.series=[];this.hasCartesianSeries=b.showAxes;var e;this.index=m.length;m.push(this);a.chartCount++;if(d)for(e in d)x(this,e,d[e]);this.xAxis=[];this.yAxis=[];this.pointCount=this.colorCounter=this.symbolCounter=0;this.firstRender()},initSeries:function(a){var b=this.options.chart;
(b=G[a.type||b.type||b.defaultSeriesType])||z(17,!0);b=new b;b.init(this,a);return b},isInsidePlot:function(a,b,c){var f=c?b:a;a=c?a:b;return 0<=f&&f<=this.plotWidth&&0<=a&&a<=this.plotHeight},redraw:function(c){var f=this.axes,d=this.series,e=this.pointer,h=this.legend,g=this.isDirtyLegend,k,q,r=this.hasCartesianSeries,n=this.isDirtyBox,l=d.length,m=l,G=this.renderer,C=G.isHidden(),p=[];a.setAnimation(c,this);C&&this.cloneRenderTo();for(this.layOutTitles();m--;)if(c=d[m],c.options.stacking&&(k=!0,
c.isDirty)){q=!0;break}if(q)for(m=l;m--;)c=d[m],c.options.stacking&&(c.isDirty=!0);b(d,function(a){a.isDirty&&"point"===a.options.legendType&&(a.updateTotals&&a.updateTotals(),g=!0);a.isDirtyData&&t(a,"updatedData")});g&&h.options.enabled&&(h.render(),this.isDirtyLegend=!1);k&&this.getStacks();r&&b(f,function(a){a.updateNames();a.setScale()});this.getMargins();r&&(b(f,function(a){a.isDirty&&(n=!0)}),b(f,function(a){var b=a.min+","+a.max;a.extKey!==b&&(a.extKey=b,p.push(function(){t(a,"afterSetExtremes",
u(a.eventArgs,a.getExtremes()));delete a.eventArgs}));(n||k)&&a.redraw()}));n&&this.drawChartBox();b(d,function(a){(n||a.isDirty)&&a.visible&&a.redraw()});e&&e.reset(!0);G.draw();t(this,"redraw");C&&this.cloneRenderTo(!0);b(p,function(a){a.call()})},get:function(a){var b=this.axes,c=this.series,f,d;for(f=0;f<b.length;f++)if(b[f].options.id===a)return b[f];for(f=0;f<c.length;f++)if(c[f].options.id===a)return c[f];for(f=0;f<c.length;f++)for(d=c[f].points||[],b=0;b<d.length;b++)if(d[b].id===a)return d[b];
return null},getAxes:function(){var a=this,c=this.options,f=c.xAxis=N(c.xAxis||{}),c=c.yAxis=N(c.yAxis||{});b(f,function(a,b){a.index=b;a.isX=!0});b(c,function(a,b){a.index=b});f=f.concat(c);b(f,function(b){new p(a,b)})},getSelectedPoints:function(){var a=[];b(this.series,function(b){a=a.concat(h(b.points||[],function(a){return a.selected}))});return a},getSelectedSeries:function(){return h(this.series,function(a){return a.selected})},setTitle:function(a,c,f){var d=this,e=d.options,h;h=e.title=I(e.title,
a);e=e.subtitle=I(e.subtitle,c);b([["title",a,h],["subtitle",c,e]],function(a,b){var c=a[0],f=d[c],e=a[1];a=a[2];f&&e&&(d[c]=f=f.destroy());a&&a.text&&!f&&(d[c]=d.renderer.text(a.text,0,0,a.useHTML).attr({align:a.align,"class":"highcharts-"+c,zIndex:a.zIndex||4}).add(),d[c].update=function(a){d.setTitle(!b&&a,b&&a)})});d.layOutTitles(f)},layOutTitles:function(a){var c=0,f,d=this.renderer,e=this.spacingBox;b(["title","subtitle"],function(a){var b=this[a],f=this.options[a],h;b&&(h=d.fontMetrics(h,b).b,
b.css({width:(f.width||e.width+f.widthAdjust)+"px"}).align(u({y:c+h+("title"===a?-3:2)},f),!1,"spacingBox"),f.floating||f.verticalAlign||(c=Math.ceil(c+b.getBBox().height)))},this);f=this.titleOffset!==c;this.titleOffset=c;!this.isDirtyBox&&f&&(this.isDirtyBox=f,this.hasRendered&&K(a,!0)&&this.isDirtyBox&&this.redraw())},getChartSize:function(){var a=this.options.chart,b=a.width,a=a.height,f=this.renderToClone||this.renderTo;d(b)||(this.containerWidth=c(f,"width"));d(a)||(this.containerHeight=c(f,
"height"));this.chartWidth=Math.max(0,b||this.containerWidth||600);this.chartHeight=Math.max(0,K(a,19<this.containerHeight?this.containerHeight:400))},cloneRenderTo:function(a){var b=this.renderToClone,c=this.container;if(a){if(b){for(;b.childNodes.length;)this.renderTo.appendChild(b.firstChild);l(b);delete this.renderToClone}}else c&&c.parentNode===this.renderTo&&this.renderTo.removeChild(c),this.renderToClone=b=this.renderTo.cloneNode(0),k(b,{position:"absolute",top:"-9999px",display:"block"}),
b.style.setProperty&&b.style.setProperty("display","block","important"),H.body.appendChild(b),c&&b.appendChild(c)},setClassName:function(a){this.container.className="highcharts-container "+(a||"")},getContainer:function(){var b,c=this.options,f=c.chart,d,h;b=this.renderTo;var g=a.uniqueKey(),k;b||(this.renderTo=b=f.renderTo);q(b)&&(this.renderTo=b=H.getElementById(b));b||z(13,!0);d=r(F(b,"data-highcharts-chart"));n(d)&&m[d]&&m[d].hasRendered&&m[d].destroy();F(b,"data-highcharts-chart",this.index);
b.innerHTML="";f.skipClone||b.offsetWidth||this.cloneRenderTo();this.getChartSize();d=this.chartWidth;h=this.chartHeight;this.container=b=e("div",{id:g},void 0,this.renderToClone||b);this._cursor=b.style.cursor;this.renderer=new (a[f.renderer]||P)(b,d,h,null,f.forExport,c.exporting&&c.exporting.allowHTML);this.setClassName(f.className);for(k in c.defs)this.renderer.definition(c.defs[k]);this.renderer.chartIndex=this.index},getMargins:function(a){var b=this.spacing,c=this.margin,f=this.titleOffset;
this.resetMargins();f&&!d(c[0])&&(this.plotTop=Math.max(this.plotTop,f+this.options.title.margin+b[0]));this.legend.display&&this.legend.adjustMargins(c,b);this.extraBottomMargin&&(this.marginBottom+=this.extraBottomMargin);this.extraTopMargin&&(this.plotTop+=this.extraTopMargin);a||this.getAxisMargins()},getAxisMargins:function(){var a=this,c=a.axisOffset=[0,0,0,0],f=a.margin;a.hasCartesianSeries&&b(a.axes,function(a){a.visible&&a.getOffset()});b(B,function(b,e){d(f[e])||(a[b]+=c[e])});a.setChartSize()},
reflow:function(a){var b=this,f=b.options.chart,e=b.renderTo,h=d(f.width),g=f.width||c(e,"width"),f=f.height||c(e,"height"),e=a?a.target:R;if(!h&&!b.isPrinting&&g&&f&&(e===R||e===H)){if(g!==b.containerWidth||f!==b.containerHeight)clearTimeout(b.reflowTimeout),b.reflowTimeout=y(function(){b.container&&b.setSize(void 0,void 0,!1)},a?100:0);b.containerWidth=g;b.containerHeight=f}},initReflow:function(){var a=this,b;b=x(R,"resize",function(b){a.reflow(b)});x(a,"destroy",b)},setSize:function(c,f,d){var e=
this,h=e.renderer;e.isResizing+=1;a.setAnimation(d,e);e.oldChartHeight=e.chartHeight;e.oldChartWidth=e.chartWidth;void 0!==c&&(e.options.chart.width=c);void 0!==f&&(e.options.chart.height=f);e.getChartSize();e.setChartSize(!0);h.setSize(e.chartWidth,e.chartHeight,d);b(e.axes,function(a){a.isDirty=!0;a.setScale()});e.isDirtyLegend=!0;e.isDirtyBox=!0;e.layOutTitles();e.getMargins();e.setResponsive&&e.setResponsive(!1);e.redraw(d);e.oldChartHeight=null;t(e,"resize");y(function(){e&&t(e,"endResize",null,
function(){--e.isResizing})},A(void 0).duration)},setChartSize:function(a){var c=this.inverted,f=this.renderer,d=this.chartWidth,e=this.chartHeight,h=this.options.chart,g=this.spacing,k=this.clipOffset,q,r,n,l;this.plotLeft=q=Math.round(this.plotLeft);this.plotTop=r=Math.round(this.plotTop);this.plotWidth=n=Math.max(0,Math.round(d-q-this.marginRight));this.plotHeight=l=Math.max(0,Math.round(e-r-this.marginBottom));this.plotSizeX=c?l:n;this.plotSizeY=c?n:l;this.plotBorderWidth=h.plotBorderWidth||0;
this.spacingBox=f.spacingBox={x:g[3],y:g[0],width:d-g[3]-g[1],height:e-g[0]-g[2]};this.plotBox=f.plotBox={x:q,y:r,width:n,height:l};d=2*Math.floor(this.plotBorderWidth/2);c=Math.ceil(Math.max(d,k[3])/2);f=Math.ceil(Math.max(d,k[0])/2);this.clipBox={x:c,y:f,width:Math.floor(this.plotSizeX-Math.max(d,k[1])/2-c),height:Math.max(0,Math.floor(this.plotSizeY-Math.max(d,k[2])/2-f))};a||b(this.axes,function(a){a.setAxisSize();a.setAxisTranslation()})},resetMargins:function(){var a=this,c=a.options.chart;
b(["margin","spacing"],function(f){var d=c[f],e=E(d)?d:[d,d,d,d];b(["Top","Right","Bottom","Left"],function(b,d){a[f][d]=K(c[f+b],e[d])})});b(B,function(b,c){a[b]=K(a.margin[c],a.spacing[c])});a.axisOffset=[0,0,0,0];a.clipOffset=[0,0,0,0]},drawChartBox:function(){var a=this.options.chart,b=this.renderer,c=this.chartWidth,f=this.chartHeight,d=this.chartBackground,e=this.plotBackground,h=this.plotBorder,g,k,q=this.plotLeft,r=this.plotTop,n=this.plotWidth,l=this.plotHeight,t=this.plotBox,m=this.clipRect,
G=this.clipBox,C="animate";d||(this.chartBackground=d=b.rect().addClass("highcharts-background").add(),C="attr");g=k=d.strokeWidth();d[C]({x:k/2,y:k/2,width:c-k-g%2,height:f-k-g%2,r:a.borderRadius});C="animate";e||(C="attr",this.plotBackground=e=b.rect().addClass("highcharts-plot-background").add());e[C](t);m?m.animate({width:G.width,height:G.height}):this.clipRect=b.clipRect(G);C="animate";h||(C="attr",this.plotBorder=h=b.rect().addClass("highcharts-plot-border").attr({zIndex:1}).add());h[C](h.crisp({x:q,
y:r,width:n,height:l},-h.strokeWidth()));this.isDirtyBox=!1},propFromSeries:function(){var a=this,c=a.options.chart,f,d=a.options.series,e,h;b(["inverted","angular","polar"],function(b){f=G[c.type||c.defaultSeriesType];h=c[b]||f&&f.prototype[b];for(e=d&&d.length;!h&&e--;)(f=G[d[e].type])&&f.prototype[b]&&(h=!0);a[b]=h})},linkSeries:function(){var a=this,c=a.series;b(c,function(a){a.linkedSeries.length=0});b(c,function(b){var c=b.options.linkedTo;q(c)&&(c=":previous"===c?a.series[b.index-1]:a.get(c))&&
c.linkedParent!==b&&(c.linkedSeries.push(b),b.linkedParent=c,b.visible=K(b.options.visible,c.options.visible,b.visible))})},renderSeries:function(){b(this.series,function(a){a.translate();a.render()})},renderLabels:function(){var a=this,c=a.options.labels;c.items&&b(c.items,function(b){var f=u(c.style,b.style),d=r(f.left)+a.plotLeft,e=r(f.top)+a.plotTop+12;delete f.left;delete f.top;a.renderer.text(b.html,d,e).attr({zIndex:2}).css(f).add()})},render:function(){var a=this.axes,c=this.renderer,f=this.options,
d,e,h;this.setTitle();this.legend=new D(this,f.legend);this.getStacks&&this.getStacks();this.getMargins(!0);this.setChartSize();f=this.plotWidth;d=this.plotHeight-=21;b(a,function(a){a.setScale()});this.getAxisMargins();e=1.1<f/this.plotWidth;h=1.05<d/this.plotHeight;if(e||h)b(a,function(a){(a.horiz&&e||!a.horiz&&h)&&a.setTickInterval(!0)}),this.getMargins();this.drawChartBox();this.hasCartesianSeries&&b(a,function(a){a.visible&&a.render()});this.seriesGroup||(this.seriesGroup=c.g("series-group").attr({zIndex:3}).add());
this.renderSeries();this.renderLabels();this.addCredits();this.setResponsive&&this.setResponsive();this.hasRendered=!0},addCredits:function(a){var b=this;a=I(!0,this.options.credits,a);a.enabled&&!this.credits&&(this.credits=this.renderer.text(a.text+(this.mapCredits||""),0,0).addClass("highcharts-credits").on("click",function(){a.href&&(R.location.href=a.href)}).attr({align:a.position.align,zIndex:8}).add().align(a.position),this.credits.update=function(a){b.credits=b.credits.destroy();b.addCredits(a)})},
destroy:function(){var c=this,f=c.axes,d=c.series,e=c.container,h,g=e&&e.parentNode;t(c,"destroy");m[c.index]=void 0;a.chartCount--;c.renderTo.removeAttribute("data-highcharts-chart");C(c);for(h=f.length;h--;)f[h]=f[h].destroy();this.scroller&&this.scroller.destroy&&this.scroller.destroy();for(h=d.length;h--;)d[h]=d[h].destroy();b("title subtitle chartBackground plotBackground plotBGImage plotBorder seriesGroup clipRect credits pointer rangeSelector legend resetZoomButton tooltip renderer".split(" "),
function(a){var b=c[a];b&&b.destroy&&(c[a]=b.destroy())});e&&(e.innerHTML="",C(e),g&&l(e));for(h in c)delete c[h]},isReadyToRender:function(){var a=this;return f||R!=R.top||"complete"===H.readyState?!0:(H.attachEvent("onreadystatechange",function(){H.detachEvent("onreadystatechange",a.firstRender);"complete"===H.readyState&&a.firstRender()}),!1)},firstRender:function(){var a=this,c=a.options;if(a.isReadyToRender()){a.getContainer();t(a,"init");a.resetMargins();a.setChartSize();a.propFromSeries();
a.getAxes();b(c.series||[],function(b){a.initSeries(b)});a.linkSeries();t(a,"beforeRender");w&&(a.pointer=new w(a,c));a.render();a.renderer.draw();if(!a.renderer.imgCount&&a.onload)a.onload();a.cloneRenderTo(!0)}},onload:function(){b([this.callback].concat(this.callbacks),function(a){a&&void 0!==this.index&&a.apply(this,[this])},this);t(this,"load");!1!==this.options.chart.reflow&&this.initReflow();this.onload=null}}})(L);(function(a){var x,A=a.each,F=a.extend,H=a.erase,p=a.fireEvent,e=a.format,g=
a.isArray,l=a.isNumber,m=a.pick,k=a.removeEvent;x=a.Point=function(){};x.prototype={init:function(a,b,e){var d=a.chart.options.chart.colorCount;this.series=a;this.applyOptions(b,e);a.options.colorByPoint?(b=a.colorCounter,a.colorCounter++,a.colorCounter===d&&(a.colorCounter=0)):b=a.colorIndex;this.colorIndex=m(this.colorIndex,b);a.chart.pointCount++;return this},applyOptions:function(a,b){var d=this.series,e=d.options.pointValKey||d.pointValKey;a=x.prototype.optionsToObject.call(this,a);F(this,a);
this.options=this.options?F(this.options,a):a;a.group&&delete this.group;e&&(this.y=this[e]);this.isNull=m(this.isValid&&!this.isValid(),null===this.x||!l(this.y,!0));this.selected&&(this.state="select");"name"in this&&void 0===b&&d.xAxis&&d.xAxis.hasNames&&(this.x=d.xAxis.nameToX(this));void 0===this.x&&d&&(this.x=void 0===b?d.autoIncrement(this):b);return this},optionsToObject:function(a){var b={},d=this.series,e=d.options.keys,k=e||d.pointArrayMap||["y"],c=k.length,h=0,n=0;if(l(a)||null===a)b[k[0]]=
a;else if(g(a))for(!e&&a.length>c&&(d=typeof a[0],"string"===d?b.name=a[0]:"number"===d&&(b.x=a[0]),h++);n<c;)e&&void 0===a[h]||(b[k[n]]=a[h]),h++,n++;else"object"===typeof a&&(b=a,a.dataLabels&&(d._hasPointLabels=!0),a.marker&&(d._hasPointMarkers=!0));return b},getClassName:function(){return"highcharts-point"+(this.selected?" highcharts-point-select":"")+(this.negative?" highcharts-negative":"")+(this.isNull?" highcharts-null-point":"")+(void 0!==this.colorIndex?" highcharts-color-"+this.colorIndex:
"")+(this.options.className?" "+this.options.className:"")},getZone:function(){var a=this.series,b=a.zones,a=a.zoneAxis||"y",e=0,g;for(g=b[e];this[a]>=g.value;)g=b[++e];g&&g.color&&!this.options.color&&(this.color=g.color);return g},destroy:function(){var a=this.series.chart,b=a.hoverPoints,e;a.pointCount--;b&&(this.setState(),H(b,this),b.length||(a.hoverPoints=null));if(this===a.hoverPoint)this.onMouseOut();if(this.graphic||this.dataLabel)k(this),this.destroyElements();this.legendItem&&a.legend.destroyItem(this);
for(e in this)this[e]=null},destroyElements:function(){for(var a=["graphic","dataLabel","dataLabelUpper","connector","shadowGroup"],b,e=6;e--;)b=a[e],this[b]&&(this[b]=this[b].destroy())},getLabelConfig:function(){return{x:this.category,y:this.y,color:this.color,key:this.name||this.category,series:this.series,point:this,percentage:this.percentage,total:this.total||this.stackTotal}},tooltipFormatter:function(a){var b=this.series,d=b.tooltipOptions,g=m(d.valueDecimals,""),k=d.valuePrefix||"",c=d.valueSuffix||
"";A(b.pointArrayMap||["y"],function(b){b="{point."+b;if(k||c)a=a.replace(b+"}",k+b+"}"+c);a=a.replace(b+"}",b+":,."+g+"f}")});return e(a,{point:this,series:this.series})},firePointEvent:function(a,b,e){var d=this,g=this.series.options;(g.point.events[a]||d.options&&d.options.events&&d.options.events[a])&&this.importEvents();"click"===a&&g.allowPointSelect&&(e=function(a){d.select&&d.select(null,a.ctrlKey||a.metaKey||a.shiftKey)});p(this,a,b,e)},visible:!0}})(L);(function(a){var x=a.addEvent,A=a.animObject,
F=a.arrayMax,H=a.arrayMin,p=a.correctFloat,e=a.Date,g=a.defaultOptions,l=a.defined,m=a.each,k=a.erase,d=a.error,b=a.extend,z=a.fireEvent,u=a.grep,t=a.isArray,c=a.isNumber,h=a.isString,n=a.merge,E=a.pick,q=a.removeEvent,D=a.splat,B=a.stableSort,I=a.SVGElement,w=a.syncTimeout,K=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:{lineWidthPlus:1,marker:{},halo:{size:10}},select:{marker:{}}},stickyTracking:!0,turboThreshold:1E3},{isCartesian:!0,pointClass:a.Point,sorted:!0,requireSorting:!0,directTouch:!1,axisTypes:["xAxis","yAxis"],colorCounter:0,parallelArrays:["x","y"],coll:"series",init:function(a,c){var d=this,e,f,h=a.series,g,k=function(a,b){return E(a.options.index,
a._i)-E(b.options.index,b._i)};d.chart=a;d.options=c=d.setOptions(c);d.linkedSeries=[];d.bindAxes();b(d,{name:c.name,state:"",visible:!1!==c.visible,selected:!0===c.selected});f=c.events;for(e in f)x(d,e,f[e]);if(f&&f.click||c.point&&c.point.events&&c.point.events.click||c.allowPointSelect)a.runTrackerClick=!0;d.getColor();d.getSymbol();m(d.parallelArrays,function(a){d[a+"Data"]=[]});d.setData(c.data,!1);d.isCartesian&&(a.hasCartesianSeries=!0);h.length&&(g=h[h.length-1]);d._i=E(g&&g._i,-1)+1;h.push(d);
B(h,k);this.yAxis&&B(this.yAxis.series,k);m(h,function(a,b){a.index=b;a.name=a.name||"Series "+(b+1)})},bindAxes:function(){var a=this,b=a.options,c=a.chart,e;m(a.axisTypes||[],function(f){m(c[f],function(c){e=c.options;if(b[f]===e.index||void 0!==b[f]&&b[f]===e.id||void 0===b[f]&&0===e.index)c.series.push(a),a[f]=c,c.isDirty=!0});a[f]||a.optionalAxis===f||d(18,!0)})},updateParallelArrays:function(a,b){var d=a.series,e=arguments,f=c(b)?function(c){var f="y"===c&&d.toYData?d.toYData(a):a[c];d[c+"Data"][b]=
f}:function(a){Array.prototype[b].apply(d[a+"Data"],Array.prototype.slice.call(e,2))};m(d.parallelArrays,f)},autoIncrement:function(){var a=this.options,b=this.xIncrement,c,d=a.pointIntervalUnit,b=E(b,a.pointStart,0);this.pointInterval=c=E(this.pointInterval,a.pointInterval,1);d&&(a=new e(b),"day"===d?a=+a[e.hcSetDate](a[e.hcGetDate]()+c):"month"===d?a=+a[e.hcSetMonth](a[e.hcGetMonth]()+c):"year"===d&&(a=+a[e.hcSetFullYear](a[e.hcGetFullYear]()+c)),c=a-b);this.xIncrement=b+c;return b},setOptions:function(a){var b=
this.chart,c=b.options.plotOptions,b=b.userOptions||{},d=b.plotOptions||{},f=c[this.type];this.userOptions=a;c=n(f,c.series,a);this.tooltipOptions=n(g.tooltip,g.plotOptions[this.type].tooltip,b.tooltip,d.series&&d.series.tooltip,d[this.type]&&d[this.type].tooltip,a.tooltip);null===f.marker&&delete c.marker;this.zoneAxis=c.zoneAxis;a=this.zones=(c.zones||[]).slice();!c.negativeColor&&!c.negativeFillColor||c.zones||a.push({value:c[this.zoneAxis+"Threshold"]||c.threshold||0,className:"highcharts-negative"});
a.length&&l(a[a.length-1].value)&&a.push({});return c},getCyclic:function(a,b,c){var d,f=this.userOptions,e=a+"Index",h=a+"Counter",g=c?c.length:E(this.chart.options.chart[a+"Count"],this.chart[a+"Count"]);b||(d=E(f[e],f["_"+e]),l(d)||(f["_"+e]=d=this.chart[h]%g,this.chart[h]+=1),c&&(b=c[d]));void 0!==d&&(this[e]=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(a,b,e,g){var f=this,k=f.points,q=k&&k.length||0,r,n=f.options,l=f.chart,p=null,w=f.xAxis,C=n.turboThreshold,D=this.xData,B=this.yData,u=(r=f.pointArrayMap)&&r.length;a=a||[];r=a.length;b=E(b,!0);if(!1!==g&&r&&q===r&&!f.cropped&&!f.hasGroupedData&&f.visible)m(a,function(a,b){k[b].update&&a!==n.data[b]&&k[b].update(a,!1,null,!1)});else{f.xIncrement=null;f.colorCounter=0;m(this.parallelArrays,function(a){f[a+"Data"].length=0});if(C&&r>C){for(e=0;null===p&&e<r;)p=a[e],e++;if(c(p))for(e=
0;e<r;e++)D[e]=this.autoIncrement(),B[e]=a[e];else if(t(p))if(u)for(e=0;e<r;e++)p=a[e],D[e]=p[0],B[e]=p.slice(1,u+1);else for(e=0;e<r;e++)p=a[e],D[e]=p[0],B[e]=p[1];else d(12)}else for(e=0;e<r;e++)void 0!==a[e]&&(p={series:f},f.pointClass.prototype.applyOptions.apply(p,[a[e]]),f.updateParallelArrays(p,e));h(B[0])&&d(14,!0);f.data=[];f.options.data=f.userOptions.data=a;for(e=q;e--;)k[e]&&k[e].destroy&&k[e].destroy();w&&(w.minRange=w.userMinRange);f.isDirty=l.isDirtyBox=!0;f.isDirtyData=!!k;e=!1}"point"===
n.legendType&&(this.processData(),this.generatePoints());b&&l.redraw(e)},processData:function(a){var b=this.xData,c=this.yData,e=b.length,f;f=0;var h,g,k=this.xAxis,q,r=this.options;q=r.cropThreshold;var n=this.getExtremesFromAll||r.getExtremesFromAll,l=this.isCartesian,r=k&&k.val2lin,m=k&&k.isLog,t,p;if(l&&!this.isDirty&&!k.isDirty&&!this.yAxis.isDirty&&!a)return!1;k&&(a=k.getExtremes(),t=a.min,p=a.max);if(l&&this.sorted&&!n&&(!q||e>q||this.forceCrop))if(b[e-1]<t||b[0]>p)b=[],c=[];else if(b[0]<t||
b[e-1]>p)f=this.cropData(this.xData,this.yData,t,p),b=f.xData,c=f.yData,f=f.start,h=!0;for(q=b.length||1;--q;)e=m?r(b[q])-r(b[q-1]):b[q]-b[q-1],0<e&&(void 0===g||e<g)?g=e:0>e&&this.requireSorting&&d(15);this.cropped=h;this.cropStart=f;this.processedXData=b;this.processedYData=c;this.closestPointRange=g},cropData:function(a,b,c,d){var f=a.length,e=0,h=f,g=E(this.cropShoulder,1),k;for(k=0;k<f;k++)if(a[k]>=c){e=Math.max(0,k-g);break}for(c=k;c<f;c++)if(a[c]>d){h=c+g;break}return{xData:a.slice(e,h),yData:b.slice(e,
h),start:e,end:h}},generatePoints:function(){var a=this.options.data,b=this.data,c,d=this.processedXData,f=this.processedYData,e=this.pointClass,h=d.length,g=this.cropStart||0,k,q=this.hasGroupedData,n,l=[],m;b||q||(b=[],b.length=a.length,b=this.data=b);for(m=0;m<h;m++)k=g+m,q?(n=(new e).init(this,[d[m]].concat(D(f[m]))),n.dataGroup=this.groupMap[m]):(n=b[k])||void 0===a[k]||(b[k]=n=(new e).init(this,a[k],d[m])),n.index=k,l[m]=n;if(b&&(h!==(c=b.length)||q))for(m=0;m<c;m++)m!==g||q||(m+=h),b[m]&&(b[m].destroyElements(),
b[m].plotX=void 0);this.data=b;this.points=l},getExtremes:function(a){var b=this.yAxis,d=this.processedXData,e,f=[],h=0;e=this.xAxis.getExtremes();var g=e.min,k=e.max,q,n,r,l;a=a||this.stackedYData||this.processedYData||[];e=a.length;for(l=0;l<e;l++)if(n=d[l],r=a[l],q=(c(r,!0)||t(r))&&(!b.isLog||r.length||0<r),n=this.getExtremesFromAll||this.options.getExtremesFromAll||this.cropped||(d[l+1]||n)>=g&&(d[l-1]||n)<=k,q&&n)if(q=r.length)for(;q--;)null!==r[q]&&(f[h++]=r[q]);else f[h++]=r;this.dataMin=H(f);
this.dataMax=F(f)},translate:function(){this.processedXData||this.processData();this.generatePoints();var a=this.options,b=a.stacking,d=this.xAxis,e=d.categories,f=this.yAxis,h=this.points,g=h.length,k=!!this.modifyValue,q=a.pointPlacement,n="between"===q||c(q),m=a.threshold,t=a.startFromThreshold?m:0,w,B,D,u,z=Number.MAX_VALUE;"between"===q&&(q=.5);c(q)&&(q*=E(a.pointRange||d.pointRange));for(a=0;a<g;a++){var I=h[a],K=I.x,x=I.y;B=I.low;var A=b&&f.stacks[(this.negStacks&&x<(t?0:m)?"-":"")+this.stackKey],
F;f.isLog&&null!==x&&0>=x&&(I.isNull=!0);I.plotX=w=p(Math.min(Math.max(-1E5,d.translate(K,0,0,0,1,q,"flags"===this.type)),1E5));b&&this.visible&&!I.isNull&&A&&A[K]&&(u=this.getStackIndicator(u,K,this.index),F=A[K],x=F.points[u.key],B=x[0],x=x[1],B===t&&u.key===A[K].base&&(B=E(m,f.min)),f.isLog&&0>=B&&(B=null),I.total=I.stackTotal=F.total,I.percentage=F.total&&I.y/F.total*100,I.stackY=x,F.setOffset(this.pointXOffset||0,this.barW||0));I.yBottom=l(B)?f.translate(B,0,1,0,1):null;k&&(x=this.modifyValue(x,
I));I.plotY=B="number"===typeof x&&Infinity!==x?Math.min(Math.max(-1E5,f.translate(x,0,1,0,1)),1E5):void 0;I.isInside=void 0!==B&&0<=B&&B<=f.len&&0<=w&&w<=d.len;I.clientX=n?p(d.translate(K,0,0,0,1,q)):w;I.negative=I.y<(m||0);I.category=e&&void 0!==e[I.x]?e[I.x]:I.x;I.isNull||(void 0!==D&&(z=Math.min(z,Math.abs(w-D))),D=w)}this.closestPointRangePx=z},getValidPoints:function(a,b){var c=this.chart;return u(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,f=b.inverted,e=this.clipBox,h=e||b.clipBox,g=this.sharedClipKey||["_sharedClip",a&&a.duration,a&&a.easing,h.height,c.xAxis,c.yAxis].join(),k=b[g],q=b[g+"m"];k||(a&&(h.width=0,b[g+"m"]=q=d.clipRect(-99,f?-b.plotLeft:-b.plotTop,99,f?b.chartWidth:b.chartHeight)),b[g]=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(q),
this.sharedClipKey=g);a||(k.count[this.index]&&(delete k.count[this.index],--k.count.length),0===k.count.length&&g&&b[g]&&(e||(b[g]=b[g].destroy()),b[g+"m"]&&(b[g+"m"]=b[g+"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},c),b[d+"m"]&&b[d+"m"].animate({width:b.plotSizeX+99},c),this.animate=null)},afterAnimate:function(){this.setClip();z(this,"afterAnimate")},drawPoints:function(){var a=
this.points,b=this.chart,d,e,f,h,g=this.options.marker,k,q,n,l,m=this.markerGroup,t=E(g.enabled,this.xAxis.isRadial?!0:null,this.closestPointRangePx>2*g.radius);if(!1!==g.enabled||this._hasPointMarkers)for(e=a.length;e--;)f=a[e],d=f.plotY,h=f.graphic,k=f.marker||{},q=!!f.marker,n=t&&void 0===k.enabled||k.enabled,l=f.isInside,n&&c(d)&&null!==f.y?(d=E(k.symbol,this.symbol),f.hasImage=0===d.indexOf("url"),n=this.markerAttribs(f,f.selected&&"select"),h?h[l?"show":"hide"](!0).animate(n):l&&(0<n.width||
f.hasImage)&&(f.graphic=h=b.renderer.symbol(d,n.x,n.y,n.width,n.height,q?k:g).add(m)),h&&h.addClass(f.getClassName(),!0)):h&&(f.graphic=h.destroy())},markerAttribs:function(a,b){var c=this.options.marker,d=a&&a.options,f=d&&d.marker||{},d=E(f.radius,c.radius);b&&(c=c.states[b],b=f.states&&f.states[b],d=E(b&&b.radius,c&&c.radius,d+(c&&c.radiusPlus||0)));a.hasImage&&(d=0);a={x:Math.floor(a.plotX)-d,y:a.plotY-d};d&&(a.width=a.height=2*d);return a},destroy:function(){var a=this,b=a.chart,c=/AppleWebKit\/533/.test(K.navigator.userAgent),
d,f=a.data||[],e,h,g;z(a,"destroy");q(a);m(a.axisTypes||[],function(b){(g=a[b])&&g.series&&(k(g.series,a),g.isDirty=g.forceRedraw=!0)});a.legendItem&&a.chart.legend.destroyItem(a);for(d=f.length;d--;)(e=f[d])&&e.destroy&&e.destroy();a.points=null;clearTimeout(a.animationTimeout);for(h in a)a[h]instanceof I&&!a[h].survive&&(d=c&&"group"===h?"hide":"destroy",a[h][d]());b.hoverSeries===a&&(b.hoverSeries=null);k(b.series,a);for(h in a)delete a[h]},getGraphPath:function(a,b,c){var d=this,f=d.options,e=
f.step,h,g=[],k=[],q;a=a||d.points;(h=a.reversed)&&a.reverse();(e={right:1,center:2}[e]||e&&3)&&h&&(e=4-e);!f.connectNulls||b||c||(a=this.getValidPoints(a));m(a,function(h,n){var m=h.plotX,r=h.plotY,t=a[n-1];(h.leftCliff||t&&t.rightCliff)&&!c&&(q=!0);h.isNull&&!l(b)&&0<n?q=!f.connectNulls:h.isNull&&!b?q=!0:(0===n||q?n=["M",h.plotX,h.plotY]:d.getPointSpline?n=d.getPointSpline(a,h,n):e?(n=1===e?["L",t.plotX,r]:2===e?["L",(t.plotX+m)/2,t.plotY,"L",(t.plotX+m)/2,r]:["L",m,t.plotY],n.push("L",m,r)):n=
["L",m,r],k.push(h.x),e&&k.push(h.x),g.push.apply(g,n),q=!1)});g.xMap=k;return d.graphPath=g},drawGraph:function(){var a=this,b=(this.gappedPath||this.getGraphPath).call(this),c=[["graph","highcharts-graph"]];m(this.zones,function(a,b){c.push(["zone-graph-"+b,"highcharts-graph highcharts-zone-graph-"+b+" "+(a.className||"")])});m(c,function(c,d){d=c[0];var f=a[d];f?(f.endX=b.xMap,f.animate({d:b})):b.length&&(a[d]=a.chart.renderer.path(b).addClass(c[1]).attr({zIndex:1}).add(a.group));f&&(f.startX=
b.xMap,f.isArea=b.isArea)})},applyZones:function(){var a=this,b=this.chart,c=b.renderer,d=this.zones,f,e,h=this.clips||[],g,k=this.graph,q=this.area,n=Math.max(b.chartWidth,b.chartHeight),l=this[(this.zoneAxis||"y")+"Axis"],t,p,w=b.inverted,B,D,u,z,I=!1;d.length&&(k||q)&&l&&void 0!==l.min&&(p=l.reversed,B=l.horiz,k&&k.hide(),q&&q.hide(),t=l.getExtremes(),m(d,function(d,m){f=p?B?b.plotWidth:0:B?0:l.toPixels(t.min);f=Math.min(Math.max(E(e,f),0),n);e=Math.min(Math.max(Math.round(l.toPixels(E(d.value,
t.max),!0)),0),n);I&&(f=e=l.toPixels(t.max));D=Math.abs(f-e);u=Math.min(f,e);z=Math.max(f,e);l.isXAxis?(g={x:w?z:u,y:0,width:D,height:n},B||(g.x=b.plotHeight-g.x)):(g={x:0,y:w?z:u,width:n,height:D},B&&(g.y=b.plotWidth-g.y));h[m]?h[m].animate(g):(h[m]=c.clipRect(g),k&&a["zone-graph-"+m].clip(h[m]),q&&a["zone-area-"+m].clip(h[m]));I=d.value>t.max}),this.clips=h)},invertGroups:function(a){function b(){var b={width:c.yAxis.len,height:c.xAxis.len};m(["group","markerGroup"],function(d){c[d]&&c[d].attr(b).invert(a)})}
var c=this,d;c.xAxis&&(d=x(c.chart,"resize",b),x(c,"destroy",d),b(a),c.invertGroups=b)},plotGroup:function(a,b,c,d,f){var e=this[a],h=!e;h&&(this[a]=e=this.chart.renderer.g(b).attr({zIndex:d||.1}).add(f),e.addClass("highcharts-series-"+this.index+" highcharts-"+this.type+"-series highcharts-color-"+this.colorIndex+" "+(this.options.className||"")));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,f=!!a.animate&&b.renderer.isSVG&&A(d.animation).duration,e=a.visible?"inherit":"hidden",h=d.zIndex,g=a.hasRendered,k=b.seriesGroup,q=b.inverted;c=a.plotGroup("group","series",e,h,k);a.markerGroup=a.plotGroup("markerGroup","markers",e,h,k);f&&a.animate(!0);c.inverted=a.isCartesian?q:!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(q);!1===d.clip||a.sharedClipKey||g||c.clip(b.clipRect);f&&a.animate();g||(a.animationTimeout=w(function(){a.afterAnimate()},f));a.isDirty=a.isDirtyData=!1;a.hasRendered=!0},redraw:function(){var a=this.chart,b=this.isDirty||this.isDirtyData,c=this.group,d=this.xAxis,f=this.yAxis;c&&(a.inverted&&c.attr({width:a.plotWidth,height:a.plotHeight}),c.animate({translateX:E(d&&d.left,
a.plotLeft),translateY:E(f&&f.top,a.plotTop)}));this.translate();this.render();b&&delete this.kdTree},kdDimensions:1,kdAxisArray:["clientX","plotY"],searchPoint:function(a,b){var c=this.xAxis,d=this.yAxis,f=this.chart.inverted;return this.searchKDTree({clientX:f?c.len-a.chartY+c.pos:a.chartX-c.pos,plotY:f?d.len-a.chartX+d.pos:a.chartY-d.pos},b)},buildKDTree:function(){function a(c,d,e){var f,h;if(h=c&&c.length)return f=b.kdAxisArray[d%e],c.sort(function(a,b){return a[f]-b[f]}),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)}}var b=this,c=b.kdDimensions;delete b.kdTree;w(function(){b.kdTree=a(b.getValidPoints(null,!b.directTouch),c,c)},b.options.kdNow?0:1)},searchKDTree:function(a,b){function c(a,b,g,k){var q=b.point,n=d.kdAxisArray[g%k],m,t,p=q;t=l(a[f])&&l(q[f])?Math.pow(a[f]-q[f],2):null;m=l(a[e])&&l(q[e])?Math.pow(a[e]-q[e],2):null;m=(t||0)+(m||0);q.dist=l(m)?Math.sqrt(m):Number.MAX_VALUE;q.distX=l(t)?Math.sqrt(t):Number.MAX_VALUE;n=a[n]-q[n];m=0>n?"left":"right";
t=0>n?"right":"left";b[m]&&(m=c(a,b[m],g+1,k),p=m[h]<p[h]?m:q);b[t]&&Math.sqrt(n*n)<p[h]&&(a=c(a,b[t],g+1,k),p=a[h]<p[h]?a:p);return p}var d=this,f=this.kdAxisArray[0],e=this.kdAxisArray[1],h=b?"distX":"dist";this.kdTree||this.buildKDTree();if(this.kdTree)return c(a,this.kdTree,this.kdDimensions,this.kdDimensions)}})})(L);(function(a){function x(a,d,b,e,g){var k=a.chart.inverted;this.axis=a;this.isNegative=b;this.options=d;this.x=e;this.total=null;this.points={};this.stack=g;this.rightCliff=this.leftCliff=
0;this.alignOptions={align:d.align||(k?b?"left":"right":"center"),verticalAlign:d.verticalAlign||(k?"middle":b?"bottom":"top"),y:m(d.y,k?4:b?14:-6),x:m(d.x,k?b?-6:6:0)};this.textAlign=d.textAlign||(k?b?"right":"left":"center")}var A=a.Axis,F=a.Chart,H=a.correctFloat,p=a.defined,e=a.destroyObjectProperties,g=a.each,l=a.format,m=a.pick;a=a.Series;x.prototype={destroy:function(){e(this,this.axis)},render:function(a){var d=this.options,b=d.format,b=b?l(b,this):d.formatter.call(this);this.label?this.label.attr({text:b,
visibility:"hidden"}):this.label=this.axis.chart.renderer.text(b,null,null,d.useHTML).css(d.style).attr({align:this.textAlign,rotation:d.rotation,visibility:"hidden"}).add(a)},setOffset:function(a,d){var b=this.axis,e=b.chart,g=e.inverted,k=b.reversed,k=this.isNegative&&!k||!this.isNegative&&k,c=b.translate(b.usePercentage?100:this.total,0,0,0,1),b=b.translate(0),b=Math.abs(c-b);a=e.xAxis[0].translate(this.x)+a;var h=e.plotHeight,g={x:g?k?c:c-b:a,y:g?h-a-d:k?h-c-b:h-c,width:g?b:d,height:g?d:b};if(d=
this.label)d.align(this.alignOptions,null,g),g=d.alignAttr,d[!1===this.options.crop||e.isInsidePlot(g.x,g.y)?"show":"hide"](!0)}};F.prototype.getStacks=function(){var a=this;g(a.yAxis,function(a){a.stacks&&a.hasVisibleSeries&&(a.oldStacks=a.stacks)});g(a.series,function(d){!d.options.stacking||!0!==d.visible&&!1!==a.options.chart.ignoreHiddenSeries||(d.stackKey=d.type+m(d.options.stack,""))})};A.prototype.buildStacks=function(){var a=this.series,d,b=m(this.options.reversedStacks,!0),e=a.length,g;
if(!this.isXAxis){this.usePercentage=!1;for(g=e;g--;)a[b?g:e-g-1].setStackedPoints();for(g=e;g--;)d=a[b?g:e-g-1],d.setStackCliffs&&d.setStackCliffs();if(this.usePercentage)for(g=0;g<e;g++)a[g].setPercentStacks()}};A.prototype.renderStackTotals=function(){var a=this.chart,d=a.renderer,b=this.stacks,e,g,l=this.stackTotalGroup;l||(this.stackTotalGroup=l=d.g("stack-labels").attr({visibility:"visible",zIndex:6}).add());l.translate(a.plotLeft,a.plotTop);for(e in b)for(g in a=b[e],a)a[g].render(l)};A.prototype.resetStacks=
function(){var a=this.stacks,d,b;if(!this.isXAxis)for(d in a)for(b in a[d])a[d][b].touched<this.stacksTouched?(a[d][b].destroy(),delete a[d][b]):(a[d][b].total=null,a[d][b].cum=0)};A.prototype.cleanStacks=function(){var a,d,b;if(!this.isXAxis)for(d in this.oldStacks&&(a=this.stacks=this.oldStacks),a)for(b in a[d])a[d][b].cum=a[d][b].total};a.prototype.setStackedPoints=function(){if(this.options.stacking&&(!0===this.visible||!1===this.chart.options.chart.ignoreHiddenSeries)){var a=this.processedXData,
d=this.processedYData,b=[],e=d.length,g=this.options,l=g.threshold,c=g.startFromThreshold?l:0,h=g.stack,g=g.stacking,n=this.stackKey,E="-"+n,q=this.negStacks,D=this.yAxis,B=D.stacks,I=D.oldStacks,w,K,r,C,G,A,f;D.stacksTouched+=1;for(G=0;G<e;G++)A=a[G],f=d[G],w=this.getStackIndicator(w,A,this.index),C=w.key,r=(K=q&&f<(c?0:l))?E:n,B[r]||(B[r]={}),B[r][A]||(I[r]&&I[r][A]?(B[r][A]=I[r][A],B[r][A].total=null):B[r][A]=new x(D,D.options.stackLabels,K,A,h)),r=B[r][A],null!==f&&(r.points[C]=r.points[this.index]=
[m(r.cum,c)],p(r.cum)||(r.base=C),r.touched=D.stacksTouched,0<w.index&&!1===this.singleStacks&&(r.points[C][0]=r.points[this.index+","+A+",0"][0])),"percent"===g?(K=K?n:E,q&&B[K]&&B[K][A]?(K=B[K][A],r.total=K.total=Math.max(K.total,r.total)+Math.abs(f)||0):r.total=H(r.total+(Math.abs(f)||0))):r.total=H(r.total+(f||0)),r.cum=m(r.cum,c)+(f||0),null!==f&&(r.points[C].push(r.cum),b[G]=r.cum);"percent"===g&&(D.usePercentage=!0);this.stackedYData=b;D.oldStacks={}}};a.prototype.setPercentStacks=function(){var a=
this,d=a.stackKey,b=a.yAxis.stacks,e=a.processedXData,l;g([d,"-"+d],function(d){for(var c=e.length,g,k;c--;)if(g=e[c],l=a.getStackIndicator(l,g,a.index,d),g=(k=b[d]&&b[d][g])&&k.points[l.key])k=k.total?100/k.total:0,g[0]=H(g[0]*k),g[1]=H(g[1]*k),a.stackedYData[c]=g[1]})};a.prototype.getStackIndicator=function(a,d,b,e){!p(a)||a.x!==d||e&&a.key!==e?a={x:d,index:0,key:e}:a.index++;a.key=[b,d,a.index].join();return a}})(L);(function(a){var x=a.addEvent,A=a.Axis,F=a.createElement,H=a.css,p=a.defined,e=
a.each,g=a.erase,l=a.extend,m=a.fireEvent,k=a.inArray,d=a.isNumber,b=a.isObject,z=a.merge,u=a.pick,t=a.Point,c=a.Series,h=a.seriesTypes,n=a.setAnimation,E=a.splat;l(a.Chart.prototype,{addSeries:function(a,b,c){var d,e=this;a&&(b=u(b,!0),m(e,"addSeries",{options:a},function(){d=e.initSeries(a);e.isDirtyLegend=!0;e.linkSeries();b&&e.redraw(c)}));return d},addAxis:function(a,b,c,d){var e=b?"xAxis":"yAxis",g=this.options;a=z(a,{index:this[e].length,isX:b});new A(this,a);g[e]=E(g[e]||{});g[e].push(a);
u(c,!0)&&this.redraw(d)},showLoading:function(a){var b=this,c=b.options,d=b.loadingDiv,e=function(){d&&H(d,{left:b.plotLeft+"px",top:b.plotTop+"px",width:b.plotWidth+"px",height:b.plotHeight+"px"})};d||(b.loadingDiv=d=F("div",{className:"highcharts-loading highcharts-loading-hidden"},null,b.container),b.loadingSpan=F("span",{className:"highcharts-loading-inner"},null,d),x(b,"redraw",e));d.className="highcharts-loading";b.loadingSpan.innerHTML=a||c.lang.loading;b.loadingShown=!0;e()},hideLoading:function(){var a=
this.loadingDiv;a&&(a.className="highcharts-loading highcharts-loading-hidden");this.loadingShown=!1},propsRequireDirtyBox:"backgroundColor borderColor borderWidth margin marginTop marginRight marginBottom marginLeft spacing spacingTop spacingRight spacingBottom spacingLeft borderRadius plotBackgroundColor plotBackgroundImage plotBorderColor plotBorderWidth plotShadow shadow".split(" "),propsRequireUpdateSeries:"chart.inverted chart.polar chart.ignoreHiddenSeries chart.type colors plotOptions".split(" "),
update:function(a,b){var c,g={credits:"addCredits",title:"setTitle",subtitle:"setSubtitle"},h=a.chart,q,n;if(h){z(!0,this.options.chart,h);"className"in h&&this.setClassName(h.className);if("inverted"in h||"polar"in h)this.propFromSeries(),q=!0;for(c in h)h.hasOwnProperty(c)&&(-1!==k("chart."+c,this.propsRequireUpdateSeries)&&(n=!0),-1!==k(c,this.propsRequireDirtyBox)&&(this.isDirtyBox=!0))}for(c in a){if(this[c]&&"function"===typeof this[c].update)this[c].update(a[c],!1);else if("function"===typeof this[g[c]])this[g[c]](a[c]);
"chart"!==c&&-1!==k(c,this.propsRequireUpdateSeries)&&(n=!0)}a.plotOptions&&z(!0,this.options.plotOptions,a.plotOptions);e(["xAxis","yAxis","series"],function(b){a[b]&&e(E(a[b]),function(a){var c=p(a.id)&&this.get(a.id)||this[b][0];c&&c.coll===b&&c.update(a,!1)},this)},this);q&&e(this.axes,function(a){a.update({},!1)});n&&e(this.series,function(a){a.update({},!1)});a.loading&&z(!0,this.options.loading,a.loading);c=h&&h.width;h=h&&h.height;d(c)&&c!==this.chartWidth||d(h)&&h!==this.chartHeight?this.setSize(c,
h):u(b,!0)&&this.redraw()},setSubtitle:function(a){this.setTitle(void 0,a)}});l(t.prototype,{update:function(a,c,d,e){function g(){h.applyOptions(a);null===h.y&&q&&(h.graphic=q.destroy());b(a,!0)&&(q&&q.element&&a&&a.marker&&a.marker.symbol&&(h.graphic=q.destroy()),a&&a.dataLabels&&h.dataLabel&&(h.dataLabel=h.dataLabel.destroy()));n=h.index;k.updateParallelArrays(h,n);f.data[n]=b(f.data[n],!0)?h.options:a;k.isDirty=k.isDirtyData=!0;!k.fixedBox&&k.hasCartesianSeries&&(l.isDirtyBox=!0);"point"===f.legendType&&
(l.isDirtyLegend=!0);c&&l.redraw(d)}var h=this,k=h.series,q=h.graphic,n,l=k.chart,f=k.options;c=u(c,!0);!1===e?g():h.firePointEvent("update",{options:a},g)},remove:function(a,b){this.series.removePoint(k(this,this.series.data),a,b)}});l(c.prototype,{addPoint:function(a,b,c,d){var e=this.options,g=this.data,h=this.chart,k=this.xAxis&&this.xAxis.names,q=e.data,n,f,l=this.xData,m,t;b=u(b,!0);n={series:this};this.pointClass.prototype.applyOptions.apply(n,[a]);t=n.x;m=l.length;if(this.requireSorting&&
t<l[m-1])for(f=!0;m&&l[m-1]>t;)m--;this.updateParallelArrays(n,"splice",m,0,0);this.updateParallelArrays(n,m);k&&n.name&&(k[t]=n.name);q.splice(m,0,a);f&&(this.data.splice(m,0,null),this.processData());"point"===e.legendType&&this.generatePoints();c&&(g[0]&&g[0].remove?g[0].remove(!1):(g.shift(),this.updateParallelArrays(n,"shift"),q.shift()));this.isDirtyData=this.isDirty=!0;b&&h.redraw(d)},removePoint:function(a,b,c){var d=this,e=d.data,g=e[a],h=d.points,k=d.chart,q=function(){h&&h.length===e.length&&
h.splice(a,1);e.splice(a,1);d.options.data.splice(a,1);d.updateParallelArrays(g||{series:d},"splice",a,1);g&&g.destroy();d.isDirty=!0;d.isDirtyData=!0;b&&k.redraw()};n(c,k);b=u(b,!0);g?g.firePointEvent("remove",null,q):q()},remove:function(a,b,c){function d(){e.destroy();g.isDirtyLegend=g.isDirtyBox=!0;g.linkSeries();u(a,!0)&&g.redraw(b)}var e=this,g=e.chart;!1!==c?m(e,"remove",null,d):d()},update:function(a,b){var c=this,d=this.chart,g=this.userOptions,k=this.type,q=a.type||g.type||d.options.chart.type,
n=h[k].prototype,m=["group","markerGroup","dataLabelsGroup"],t;if(q&&q!==k||void 0!==a.zIndex)m.length=0;e(m,function(a){m[a]=c[a];delete c[a]});a=z(g,{animation:!1,index:this.index,pointStart:this.xData[0]},{data:this.options.data},a);this.remove(!1,null,!1);for(t in n)this[t]=void 0;l(this,h[q||k].prototype);e(m,function(a){c[a]=m[a]});this.init(d,a);d.linkSeries();u(b,!0)&&d.redraw(!1)}});l(A.prototype,{update:function(a,b){var c=this.chart;a=c.options[this.coll][this.options.index]=z(this.userOptions,
a);this.destroy(!0);this.init(c,l(a,{events:void 0}));c.isDirtyBox=!0;u(b,!0)&&c.redraw()},remove:function(a){for(var b=this.chart,c=this.coll,d=this.series,h=d.length;h--;)d[h]&&d[h].remove(!1);g(b.axes,this);g(b[c],this);b.options[c].splice(this.options.index,1);e(b[c],function(a,b){a.options.index=b});this.destroy();b.isDirtyBox=!0;u(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 x=a.each,A=
a.map,F=a.pick,H=a.Series,p=a.seriesType;p("area","line",{softThreshold:!1,threshold:0},{singleStacks:!1,getStackPoints:function(){var a=[],g=[],l=this.xAxis,m=this.yAxis,k=m.stacks[this.stackKey],d={},b=this.points,p=this.index,u=m.series,t=u.length,c,h=F(m.options.reversedStacks,!0)?1:-1,n,E;if(this.options.stacking){for(n=0;n<b.length;n++)d[b[n].x]=b[n];for(E in k)null!==k[E].total&&g.push(E);g.sort(function(a,b){return a-b});c=A(u,function(){return this.visible});x(g,function(b,e){var q=0,u,w;
if(d[b]&&!d[b].isNull)a.push(d[b]),x([-1,1],function(a){var q=1===a?"rightNull":"leftNull",l=0,m=k[g[e+a]];if(m)for(n=p;0<=n&&n<t;)u=m.points[n],u||(n===p?d[b][q]=!0:c[n]&&(w=k[b].points[n])&&(l-=w[1]-w[0])),n+=h;d[b][1===a?"rightCliff":"leftCliff"]=l});else{for(n=p;0<=n&&n<t;){if(u=k[b].points[n]){q=u[1];break}n+=h}q=m.toPixels(q,!0);a.push({isNull:!0,plotX:l.toPixels(b,!0),plotY:q,yBottom:q})}})}return a},getGraphPath:function(a){var e=H.prototype.getGraphPath,l=this.options,m=l.stacking,k=this.yAxis,
d,b,p=[],u=[],t=this.index,c,h=k.stacks[this.stackKey],n=l.threshold,E=k.getThreshold(l.threshold),q,l=l.connectNulls||"percent"===m,D=function(b,d,e){var g=a[b];b=m&&h[g.x].points[t];var q=g[e+"Null"]||0;e=g[e+"Cliff"]||0;var l,w,g=!0;e||q?(l=(q?b[0]:b[1])+e,w=b[0]+e,g=!!q):!m&&a[d]&&a[d].isNull&&(l=w=n);void 0!==l&&(u.push({plotX:c,plotY:null===l?E:k.getThreshold(l),isNull:g}),p.push({plotX:c,plotY:null===w?E:k.getThreshold(w),doCurve:!1}))};a=a||this.points;m&&(a=this.getStackPoints());for(d=0;d<
a.length;d++)if(b=a[d].isNull,c=F(a[d].rectPlotX,a[d].plotX),q=F(a[d].yBottom,E),!b||l)l||D(d,d-1,"left"),b&&!m&&l||(u.push(a[d]),p.push({x:d,plotX:c,plotY:q})),l||D(d,d+1,"right");d=e.call(this,u,!0,!0);p.reversed=!0;b=e.call(this,p,!0,!0);b.length&&(b[0]="L");b=d.concat(b);e=e.call(this,u,!1,l);b.xMap=d.xMap;this.areaPath=b;return e},drawGraph:function(){this.areaPath=[];H.prototype.drawGraph.apply(this);var a=this,g=this.areaPath,l=this.options,m=[["area","highcharts-area"]];x(this.zones,function(a,
d){m.push(["zone-area-"+d,"highcharts-area highcharts-zone-area-"+d+" "+a.className])});x(m,function(e){var d=e[0],b=a[d];b?(b.endX=g.xMap,b.animate({d:g})):(b=a[d]=a.chart.renderer.path(g).addClass(e[1]).attr({zIndex:0}).add(a.group),b.isArea=!0);b.startX=g.xMap;b.shiftUnit=l.step?2:1})},drawLegendSymbol:a.LegendSymbolMixin.drawRectangle})})(L);(function(a){var x=a.pick;a=a.seriesType;a("spline","line",{},{getPointSpline:function(a,F,H){var p=F.plotX,e=F.plotY,g=a[H-1];H=a[H+1];var l,m,k,d;if(g&&
!g.isNull&&!1!==g.doCurve&&H&&!H.isNull&&!1!==H.doCurve){a=g.plotY;k=H.plotX;H=H.plotY;var b=0;l=(1.5*p+g.plotX)/2.5;m=(1.5*e+a)/2.5;k=(1.5*p+k)/2.5;d=(1.5*e+H)/2.5;k!==l&&(b=(d-m)*(k-p)/(k-l)+e-d);m+=b;d+=b;m>a&&m>e?(m=Math.max(a,e),d=2*e-m):m<a&&m<e&&(m=Math.min(a,e),d=2*e-m);d>H&&d>e?(d=Math.max(H,e),m=2*e-d):d<H&&d<e&&(d=Math.min(H,e),m=2*e-d);F.rightContX=k;F.rightContY=d}F=["C",x(g.rightContX,g.plotX),x(g.rightContY,g.plotY),x(l,p),x(m,e),p,e];g.rightContX=g.rightContY=null;return F}})})(L);
(function(a){var x=a.seriesTypes.area.prototype,A=a.seriesType;A("areaspline","spline",a.defaultPlotOptions.area,{getStackPoints:x.getStackPoints,getGraphPath:x.getGraphPath,setStackCliffs:x.setStackCliffs,drawGraph:x.drawGraph,drawLegendSymbol:a.LegendSymbolMixin.drawRectangle})})(L);(function(a){var x=a.animObject,A=a.each,F=a.extend,H=a.isNumber,p=a.merge,e=a.pick,g=a.Series,l=a.seriesType,m=a.svg;l("column","line",{borderRadius:0,groupPadding:.2,marker:null,pointPadding:.1,minPointLength:0,cropThreshold:50,
pointRange:null,states:{hover:{halo:!1}},dataLabels:{align:null,verticalAlign:null,y:null},softThreshold:!1,startFromThreshold:!0,stickyTracking:!1,tooltip:{distance:6},threshold:0},{cropShoulder:0,directTouch:!0,trackerGroups:["group","dataLabelsGroup"],negStacks:!0,init:function(){g.prototype.init.apply(this,arguments);var a=this,d=a.chart;d.hasRendered&&A(d.series,function(b){b.type===a.type&&(b.isDirty=!0)})},getColumnMetrics:function(){var a=this,d=a.options,b=a.xAxis,g=a.yAxis,l=b.reversed,
m,c={},h=0;!1===d.grouping?h=1:A(a.chart.series,function(b){var d=b.options,e=b.yAxis,k;b.type===a.type&&b.visible&&g.len===e.len&&g.pos===e.pos&&(d.stacking?(m=b.stackKey,void 0===c[m]&&(c[m]=h++),k=c[m]):!1!==d.grouping&&(k=h++),b.columnIndex=k)});var n=Math.min(Math.abs(b.transA)*(b.ordinalSlope||d.pointRange||b.closestPointRange||b.tickInterval||1),b.len),p=n*d.groupPadding,q=(n-2*p)/h,d=Math.min(d.maxPointWidth||b.len,e(d.pointWidth,q*(1-2*d.pointPadding)));a.columnMetrics={width:d,offset:(q-
d)/2+(p+((a.columnIndex||0)+(l?1:0))*q-n/2)*(l?-1:1)};return a.columnMetrics},crispCol:function(a,d,b,e){var g=this.chart,k=this.borderWidth,c=-(k%2?.5:0),k=k%2?.5:1;g.inverted&&g.renderer.isVML&&(k+=1);b=Math.round(a+b)+c;a=Math.round(a)+c;e=Math.round(d+e)+k;c=.5>=Math.abs(d)&&.5<e;d=Math.round(d)+k;e-=d;c&&e&&(--d,e+=1);return{x:a,y:d,width:b-a,height:e}},translate:function(){var a=this,d=a.chart,b=a.options,l=a.dense=2>a.closestPointRange*a.xAxis.transA,l=a.borderWidth=e(b.borderWidth,l?0:1),
m=a.yAxis,t=a.translatedThreshold=m.getThreshold(b.threshold),c=e(b.minPointLength,5),h=a.getColumnMetrics(),n=h.width,p=a.barW=Math.max(n,1+2*l),q=a.pointXOffset=h.offset;d.inverted&&(t-=.5);b.pointPadding&&(p=Math.ceil(p));g.prototype.translate.apply(a);A(a.points,function(b){var g=e(b.yBottom,t),h=999+Math.abs(g),h=Math.min(Math.max(-h,b.plotY),m.len+h),k=b.plotX+q,l=p,r=Math.min(h,g),u,D=Math.max(h,g)-r;Math.abs(D)<c&&c&&(D=c,u=!m.reversed&&!b.negative||m.reversed&&b.negative,r=Math.abs(r-t)>
c?g-c:t-(u?c:0));b.barX=k;b.pointWidth=n;b.tooltipPos=d.inverted?[m.len+m.pos-d.plotLeft-h,a.xAxis.len-k-l/2,D]:[k+l/2,h+m.pos-d.plotTop,D];b.shapeType="rect";b.shapeArgs=a.crispCol.apply(a,b.isNull?[b.plotX,m.len/2,0,0]:[k,r,l,D])})},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,b=d.renderer,e=a.options.animationLimit||250,g;A(a.points,
function(k){var c=k.graphic;if(H(k.plotY)&&null!==k.y)if(g=k.shapeArgs,c)c[d.pointCount<e?"animate":"attr"](p(g));else k.graphic=b[k.shapeType](g).attr({"class":k.getClassName()}).add(k.group||a.group);else c&&(k.graphic=c.destroy())})},animate:function(a){var d=this,b=this.yAxis,e=d.options,g=this.chart.inverted,k={};m&&(a?(k.scaleY=.001,a=Math.min(b.pos+b.len,Math.max(b.pos,b.toPixels(e.threshold))),g?k.translateX=a-b.len:k.translateY=a,d.group.attr(k)):(k[g?"translateX":"translateY"]=b.pos,d.group.animate(k,
F(x(d.options.animation),{step:function(a,b){d.group.attr({scaleY:Math.max(.001,b.pos)})}})),d.animate=null))},remove:function(){var a=this,d=a.chart;d.hasRendered&&A(d.series,function(b){b.type===a.type&&(b.isDirty=!0)});g.prototype.remove.apply(a,arguments)}})})(L);(function(a){a=a.seriesType;a("bar","column",null,{inverted:!0})})(L);(function(a){var x=a.Series;a=a.seriesType;a("scatter","line",{lineWidth:0,marker:{enabled:!0},tooltip:{headerFormat:'\x3cspan style\x3d"color:{point.color}"\x3e\u25cf\x3c/span\x3e \x3cspan style\x3d"font-size: 0.85em"\x3e {series.name}\x3c/span\x3e\x3cbr/\x3e',
pointFormat:"x: \x3cb\x3e{point.x}\x3c/b\x3e\x3cbr/\x3ey: \x3cb\x3e{point.y}\x3c/b\x3e\x3cbr/\x3e"}},{sorted:!1,requireSorting:!1,noSharedTooltip:!0,trackerGroups:["group","markerGroup","dataLabelsGroup"],takeOrdinalPosition:!1,kdDimensions:2,drawGraph:function(){this.options.lineWidth&&x.prototype.drawGraph.call(this)}})})(L);(function(a){var x=a.pick,A=a.relativeLength;a.CenteredSeriesMixin={getCenter:function(){var a=this.options,H=this.chart,p=2*(a.slicedOffset||0),e=H.plotWidth-2*p,H=H.plotHeight-
2*p,g=a.center,g=[x(g[0],"50%"),x(g[1],"50%"),a.size||"100%",a.innerSize||0],l=Math.min(e,H),m,k;for(m=0;4>m;++m)k=g[m],a=2>m||2===m&&/%$/.test(k),g[m]=A(k,[e,H,l,g[2]][m])+(a?p:0);g[3]>g[2]&&(g[3]=g[2]);return g}}})(L);(function(a){var x=a.addEvent,A=a.defined,F=a.each,H=a.extend,p=a.inArray,e=a.noop,g=a.pick,l=a.Point,m=a.Series,k=a.seriesType,d=a.setAnimation;k("pie","line",{center:[null,null],clip:!1,colorByPoint:!0,dataLabels:{distance:30,enabled:!0,formatter:function(){return null===this.y?
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,d=b.points,e=b.startAngleRad;a||(F(d,function(a){var c=a.graphic,d=a.shapeArgs;c&&(c.attr({r:a.startR||b.center[3]/2,start:e,
end:e}),c.animate({r:d.r,start:d.start,end:d.end},b.options.animation))}),b.animate=null)},updateTotals:function(){var a,d=0,e=this.points,g=e.length,c,h=this.options.ignoreHiddenPoint;for(a=0;a<g;a++)c=e[a],0>c.y&&(c.y=null),d+=h&&!c.visible?0:c.y;this.total=d;for(a=0;a<g;a++)c=e[a],c.percentage=0<d&&(c.visible||!h)?c.y/d*100:0,c.total=d},generatePoints:function(){m.prototype.generatePoints.call(this);this.updateTotals()},translate:function(a){this.generatePoints();var b=0,d=this.options,e=d.slicedOffset,
c=e+(d.borderWidth||0),h,k,l,q=d.startAngle||0,m=this.startAngleRad=Math.PI/180*(q-90),q=(this.endAngleRad=Math.PI/180*(g(d.endAngle,q+360)-90))-m,p=this.points,x=d.dataLabels.distance,d=d.ignoreHiddenPoint,w,A=p.length,r;a||(this.center=a=this.getCenter());this.getX=function(b,c){l=Math.asin(Math.min((b-a[1])/(a[2]/2+x),1));return a[0]+(c?-1:1)*Math.cos(l)*(a[2]/2+x)};for(w=0;w<A;w++){r=p[w];h=m+b*q;if(!d||r.visible)b+=r.percentage/100;k=m+b*q;r.shapeType="arc";r.shapeArgs={x:a[0],y:a[1],r:a[2]/
2,innerR:a[3]/2,start:Math.round(1E3*h)/1E3,end:Math.round(1E3*k)/1E3};l=(k+h)/2;l>1.5*Math.PI?l-=2*Math.PI:l<-Math.PI/2&&(l+=2*Math.PI);r.slicedTranslation={translateX:Math.round(Math.cos(l)*e),translateY:Math.round(Math.sin(l)*e)};h=Math.cos(l)*a[2]/2;k=Math.sin(l)*a[2]/2;r.tooltipPos=[a[0]+.7*h,a[1]+.7*k];r.half=l<-Math.PI/2||l>Math.PI/2?1:0;r.angle=l;c=Math.min(c,x/5);r.labelPos=[a[0]+h+Math.cos(l)*x,a[1]+k+Math.sin(l)*x,a[0]+h+Math.cos(l)*c,a[1]+k+Math.sin(l)*c,a[0]+h,a[1]+k,0>x?"center":r.half?
"right":"left",l]}},drawGraph:null,drawPoints:function(){var a=this,d=a.chart.renderer,e,g,c;F(a.points,function(b){null!==b.y&&(g=b.graphic,c=b.shapeArgs,e=b.sliced?b.slicedTranslation:{},g?g.setRadialReference(a.center).animate(H(c,e)):(b.graphic=g=d[b.shapeType](c).addClass(b.getClassName()).setRadialReference(a.center).attr(e).add(a.group),b.visible||g.attr({visibility:"hidden"})))})},searchPoint:e,sortByAngle:function(a,d){a.sort(function(a,b){return void 0!==a.angle&&(b.angle-a.angle)*d})},
drawLegendSymbol:a.LegendSymbolMixin.drawRectangle,getCenter:a.CenteredSeriesMixin.getCenter,getSymbol:e},{init:function(){l.prototype.init.apply(this,arguments);var a=this,d;a.name=g(a.name,"Slice");d=function(b){a.slice("select"===b.type)};x(a,"select",d);x(a,"unselect",d);return a},setVisible:function(a,d){var b=this,e=b.series,c=e.chart,h=e.options.ignoreHiddenPoint;d=g(d,h);a!==b.visible&&(b.visible=b.options.visible=a=void 0===a?!b.visible:a,e.options.data[p(b,e.data)]=b.options,F(["graphic",
"dataLabel","connector","shadowGroup"],function(c){if(b[c])b[c][a?"show":"hide"](!0)}),b.legendItem&&c.legend.colorizeItem(b,a),a||"hover"!==b.state||b.setState(""),h&&(e.isDirty=!0),d&&c.redraw())},slice:function(a,e,k){var b=this.series;d(k,b.chart);g(e,!0);this.sliced=this.options.sliced=a=A(a)?a:!this.sliced;b.options.data[p(this,b.data)]=this.options;this.graphic.animate(a?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,start:b.start,end:b.end})}})})(L);(function(a){var x=a.addEvent,A=a.arrayMax,F=a.defined,H=a.each,p=a.extend,e=a.format,g=a.map,l=a.merge,m=a.noop,k=a.pick,d=a.relativeLength,b=a.Series,z=a.seriesTypes,u=a.stableSort;a.distribute=function(a,b){function c(a,b){return a.target-b.target}var d,e=!0,k=a,l=[],m;m=0;for(d=a.length;d--;)m+=a[d].size;if(m>b){u(a,function(a,b){return(b.rank||0)-(a.rank||0)});for(m=d=0;m<=
b;)m+=a[d].size,d++;l=a.splice(d-1,a.length)}u(a,c);for(a=g(a,function(a){return{size:a.size,targets:[a.target]}});e;){for(d=a.length;d--;)e=a[d],m=(Math.min.apply(0,e.targets)+Math.max.apply(0,e.targets))/2,e.pos=Math.min(Math.max(0,m-e.size/2),b-e.size);d=a.length;for(e=!1;d--;)0<d&&a[d-1].pos+a[d-1].size>a[d].pos&&(a[d-1].size+=a[d].size,a[d-1].targets=a[d-1].targets.concat(a[d].targets),a[d-1].pos+a[d-1].size>b&&(a[d-1].pos=b-a[d-1].size),a.splice(d,1),e=!0)}d=0;H(a,function(a){var b=0;H(a.targets,
function(){k[d].pos=a.pos+b;b+=k[d].size;d++})});k.push.apply(k,l);u(k,c)};b.prototype.drawDataLabels=function(){var a=this,b=a.options,d=b.dataLabels,g=a.points,m,q,p=a.hasRendered||0,B,u,w=k(d.defer,!0),z=a.chart.renderer;if(d.enabled||a._hasPointLabels)a.dlProcessOptions&&a.dlProcessOptions(d),u=a.plotGroup("dataLabelsGroup","data-labels",w&&!p?"hidden":"visible",d.zIndex||6),w&&(u.attr({opacity:+p}),p||x(a,"afterAnimate",function(){a.visible&&u.show(!0);u[b.animation?"animate":"attr"]({opacity:1},
{duration:200})})),q=d,H(g,function(b){var c,g=b.dataLabel,h,f,n=b.connector,p=!0;m=b.dlOptions||b.options&&b.options.dataLabels;c=k(m&&m.enabled,q.enabled)&&null!==b.y;if(g&&!c)b.dataLabel=g.destroy();else if(c){d=l(q,m);c=d.rotation;h=b.getLabelConfig();B=d.format?e(d.format,h):d.formatter.call(h,d);if(g)F(B)?(g.attr({text:B}),p=!1):(b.dataLabel=g=g.destroy(),n&&(b.connector=n.destroy()));else if(F(B)){g={r:d.borderRadius||0,rotation:c,padding:d.padding,zIndex:1};for(f in g)void 0===g[f]&&delete g[f];
g=b.dataLabel=z[c?"text":"label"](B,0,-9999,d.shape,null,null,d.useHTML,null,"data-label").attr(g);g.addClass("highcharts-data-label-color-"+b.colorIndex+" "+(d.className||""));g.add(u)}g&&a.alignDataLabel(b,g,d,null,p)}})};b.prototype.alignDataLabel=function(a,b,d,e,g){var c=this.chart,h=c.inverted,l=k(a.plotX,-9999),m=k(a.plotY,-9999),n=b.getBBox(),t,r=d.rotation,u=d.align,x=this.visible&&(a.series.forceDL||c.isInsidePlot(l,Math.round(m),h)||e&&c.isInsidePlot(l,h?e.x+1:e.y+e.height-1,h)),z="justify"===
k(d.overflow,"justify");x&&(t=c.renderer.fontMetrics(void 0,b).b,e=p({x:h?c.plotWidth-m:l,y:Math.round(h?c.plotHeight-l:m),width:0,height:0},e),p(d,{width:n.width,height:n.height}),r?(z=!1,h=c.renderer.rotCorr(t,r),h={x:e.x+d.x+e.width/2+h.x,y:e.y+d.y+{top:0,middle:.5,bottom:1}[d.verticalAlign]*e.height},b[g?"attr":"animate"](h).attr({align:u}),l=(r+720)%360,l=180<l&&360>l,"left"===u?h.y-=l?n.height:0:"center"===u?(h.x-=n.width/2,h.y-=n.height/2):"right"===u&&(h.x-=n.width,h.y-=l?0:n.height)):(b.align(d,
null,e),h=b.alignAttr),z?this.justifyDataLabel(b,d,h,n,e,g):k(d.crop,!0)&&(x=c.isInsidePlot(h.x,h.y)&&c.isInsidePlot(h.x+n.width,h.y+n.height)),d.shape&&!r&&b.attr({anchorX:a.plotX,anchorY:a.plotY}));x||(b.attr({y:-9999}),b.placed=!1)};b.prototype.justifyDataLabel=function(a,b,d,e,g,k){var c=this.chart,h=b.align,l=b.verticalAlign,q,m,n=a.box?0:a.padding||0;q=d.x+n;0>q&&("right"===h?b.align="left":b.x=-q,m=!0);q=d.x+e.width-n;q>c.plotWidth&&("left"===h?b.align="right":b.x=c.plotWidth-q,m=!0);q=d.y+
n;0>q&&("bottom"===l?b.verticalAlign="top":b.y=-q,m=!0);q=d.y+e.height-n;q>c.plotHeight&&("top"===l?b.verticalAlign="bottom":b.y=c.plotHeight-q,m=!0);m&&(a.placed=!k,a.align(b,null,g))};z.pie&&(z.pie.prototype.drawDataLabels=function(){var d=this,c=d.data,e,l=d.chart,m=d.options.dataLabels,q=k(m.connectorPadding,10),p=k(m.connectorWidth,1),B=l.plotWidth,u=l.plotHeight,w,x=m.distance,r=d.center,z=r[2]/2,G=r[1],F=0<x,f,y,L,P,Q=[[],[]],J,v,M,O,S=[0,0,0,0];d.visible&&(m.enabled||d._hasPointLabels)&&(b.prototype.drawDataLabels.apply(d),
H(c,function(a){a.dataLabel&&a.visible&&(Q[a.half].push(a),a.dataLabel._pos=null)}),H(Q,function(b,c){var h,k,n=b.length,p,t,w;if(n)for(d.sortByAngle(b,c-.5),0<x&&(h=Math.max(0,G-z-x),k=Math.min(G+z+x,l.plotHeight),p=g(b,function(a){if(a.dataLabel)return w=a.dataLabel.getBBox().height||21,{target:a.labelPos[1]-h+w/2,size:w,rank:a.y}}),a.distribute(p,k+w-h)),O=0;O<n;O++)e=b[O],L=e.labelPos,f=e.dataLabel,M=!1===e.visible?"hidden":"inherit",t=L[1],p?void 0===p[O].pos?M="hidden":(P=p[O].size,v=h+p[O].pos):
v=t,J=m.justify?r[0]+(c?-1:1)*(z+x):d.getX(v<h+2||v>k-2?t:v,c),f._attr={visibility:M,align:L[6]},f._pos={x:J+m.x+({left:q,right:-q}[L[6]]||0),y:v+m.y-10},L.x=J,L.y=v,null===d.options.size&&(y=f.width,J-y<q?S[3]=Math.max(Math.round(y-J+q),S[3]):J+y>B-q&&(S[1]=Math.max(Math.round(J+y-B+q),S[1])),0>v-P/2?S[0]=Math.max(Math.round(-v+P/2),S[0]):v+P/2>u&&(S[2]=Math.max(Math.round(v+P/2-u),S[2])))}),0===A(S)||this.verifyDataLabelOverflow(S))&&(this.placeDataLabels(),F&&p&&H(this.points,function(a){var b;
w=a.connector;if((f=a.dataLabel)&&f._pos&&a.visible){M=f._attr.visibility;if(b=!w)a.connector=w=l.renderer.path().addClass("highcharts-data-label-connector highcharts-color-"+a.colorIndex).add(d.dataLabelsGroup);w[b?"attr":"animate"]({d:d.connectorPath(a.labelPos)});w.attr("visibility",M)}else w&&(a.connector=w.destroy())}))},z.pie.prototype.connectorPath=function(a){var b=a.x,d=a.y;return k(this.options.dataLabels.softConnector,!0)?["M",b+("left"===a[6]?5:-5),d,"C",b,d,2*a[2]-a[4],2*a[3]-a[5],a[2],
a[3],"L",a[4],a[5]]:["M",b+("left"===a[6]?5:-5),d,"L",a[2],a[3],"L",a[4],a[5]]},z.pie.prototype.placeDataLabels=function(){H(this.points,function(a){var b=a.dataLabel;b&&a.visible&&((a=b._pos)?(b.attr(b._attr),b[b.moved?"animate":"attr"](a),b.moved=!0):b&&b.attr({y:-9999}))})},z.pie.prototype.alignDataLabel=m,z.pie.prototype.verifyDataLabelOverflow=function(a){var b=this.center,e=this.options,g=e.center,k=e.minSize||80,l,m;null!==g[0]?l=Math.max(b[2]-Math.max(a[1],a[3]),k):(l=Math.max(b[2]-a[1]-a[3],
k),b[0]+=(a[3]-a[1])/2);null!==g[1]?l=Math.max(Math.min(l,b[2]-Math.max(a[0],a[2])),k):(l=Math.max(Math.min(l,b[2]-a[0]-a[2]),k),b[1]+=(a[0]-a[2])/2);l<b[2]?(b[2]=l,b[3]=Math.min(d(e.innerSize||0,l),l),this.translate(b),this.drawDataLabels&&this.drawDataLabels()):m=!0;return m});z.column&&(z.column.prototype.alignDataLabel=function(a,c,d,e,g){var h=this.chart.inverted,m=a.series,n=a.dlBox||a.shapeArgs,p=k(a.below,a.plotY>k(this.translatedThreshold,m.yAxis.len)),w=k(d.inside,!!this.options.stacking);
n&&(e=l(n),0>e.y&&(e.height+=e.y,e.y=0),n=e.y+e.height-m.yAxis.len,0<n&&(e.height-=n),h&&(e={x:m.yAxis.len-e.y-e.height,y:m.xAxis.len-e.x-e.width,width:e.height,height:e.width}),w||(h?(e.x+=p?0:e.width,e.width=0):(e.y+=p?e.height:0,e.height=0)));d.align=k(d.align,!h||w?"center":p?"right":"left");d.verticalAlign=k(d.verticalAlign,h||w?"middle":p?"top":"bottom");b.prototype.alignDataLabel.call(this,a,c,d,e,g)})})(L);(function(a){var x=a.Chart,A=a.each,F=a.pick,H=a.addEvent;x.prototype.callbacks.push(function(a){function e(){var e=
[];A(a.series,function(a){var g=a.options.dataLabels,k=a.dataLabelCollections||["dataLabel"];(g.enabled||a._hasPointLabels)&&!g.allowOverlap&&a.visible&&A(k,function(d){A(a.points,function(a){a[d]&&(a[d].labelrank=F(a.labelrank,a.shapeArgs&&a.shapeArgs.height),e.push(a[d]))})})});a.hideOverlappingLabels(e)}e();H(a,"redraw",e)});x.prototype.hideOverlappingLabels=function(a){var e=a.length,g,l,m,k,d,b,p,u,t,c=function(a,b,c,d,e,g,k,l){return!(e>a+c||e+k<a||g>b+d||g+l<b)};for(l=0;l<e;l++)if(g=a[l])g.oldOpacity=
g.opacity,g.newOpacity=1;a.sort(function(a,b){return(b.labelrank||0)-(a.labelrank||0)});for(l=0;l<e;l++)for(m=a[l],g=l+1;g<e;++g)if(k=a[g],m&&k&&m.placed&&k.placed&&0!==m.newOpacity&&0!==k.newOpacity&&(d=m.alignAttr,b=k.alignAttr,p=m.parentGroup,u=k.parentGroup,t=2*(m.box?0:m.padding),d=c(d.x+p.translateX,d.y+p.translateY,m.width-t,m.height-t,b.x+u.translateX,b.y+u.translateY,k.width-t,k.height-t)))(m.labelrank<k.labelrank?m:k).newOpacity=0;A(a,function(a){var b,c;a&&(c=a.newOpacity,a.oldOpacity!==
c&&a.placed&&(c?a.show(!0):b=function(){a.hide()},a.alignAttr.opacity=c,a[a.isOld?"animate":"attr"](a.alignAttr,null,b)),a.isOld=!0)})}})(L);(function(a){var x=a.addEvent,A=a.Chart,F=a.createElement,H=a.css,p=a.defaultOptions,e=a.defaultPlotOptions,g=a.each,l=a.extend,m=a.fireEvent,k=a.hasTouch,d=a.inArray,b=a.isObject,z=a.Legend,u=a.merge,t=a.pick,c=a.Point,h=a.Series,n=a.seriesTypes,E=a.svg;a=a.TrackerMixin={drawTrackerPoint:function(){var a=this,b=a.chart,c=b.pointer,d=function(a){for(var c=a.target,
d;c&&!d;)d=c.point,c=c.parentNode;if(void 0!==d&&d!==b.hoverPoint)d.onMouseOver(a)};g(a.points,function(a){a.graphic&&(a.graphic.element.point=a);a.dataLabel&&(a.dataLabel.element.point=a)});a._hasTracking||(g(a.trackerGroups,function(b){if(a[b]&&(a[b].addClass("highcharts-tracker").on("mouseover",d).on("mouseout",function(a){c.onTrackerMouseOut(a)}),k))a[b].on("touchstart",d)}),a._hasTracking=!0)},drawTrackerGraph:function(){var a=this,b=a.options.trackByArea,c=[].concat(b?a.areaPath:a.graphPath),
d=c.length,e=a.chart,h=e.pointer,l=e.renderer,m=e.options.tooltip.snap,n=a.tracker,p,f=function(){if(e.hoverSeries!==a)a.onMouseOver()},t="rgba(192,192,192,"+(E?.0001:.002)+")";if(d&&!b)for(p=d+1;p--;)"M"===c[p]&&c.splice(p+1,0,c[p+1]-m,c[p+2],"L"),(p&&"M"===c[p]||p===d)&&c.splice(p,0,"L",c[p-2]+m,c[p-1]);n?n.attr({d:c}):a.graph&&(a.tracker=l.path(c).attr({"stroke-linejoin":"round",visibility:a.visible?"visible":"hidden",stroke:t,fill:b?t:"none","stroke-width":a.graph.strokeWidth()+(b?0:2*m),zIndex:2}).add(a.group),
g([a.tracker,a.markerGroup],function(a){a.addClass("highcharts-tracker").on("mouseover",f).on("mouseout",function(a){h.onTrackerMouseOut(a)});if(k)a.on("touchstart",f)}))}};n.column&&(n.column.prototype.drawTracker=a.drawTrackerPoint);n.pie&&(n.pie.prototype.drawTracker=a.drawTrackerPoint);n.scatter&&(n.scatter.prototype.drawTracker=a.drawTrackerPoint);l(z.prototype,{setItemEvents:function(a,b,c){var d=this.chart,e="highcharts-legend-"+(a.series?"point":"series")+"-active";(c?b:a.legendGroup).on("mouseover",
function(){a.setState("hover");d.seriesGroup.addClass(e)}).on("mouseout",function(){d.seriesGroup.removeClass(e);a.setState()}).on("click",function(b){var c=function(){a.setVisible&&a.setVisible()};b={browserEvent:b};a.firePointEvent?a.firePointEvent("legendItemClick",b,c):m(a,"legendItemClick",b,c)})},createCheckboxForItem:function(a){a.checkbox=F("input",{type:"checkbox",checked:a.selected,defaultChecked:a.selected},this.options.itemCheckboxStyle,this.chart.container);x(a.checkbox,"click",function(b){m(a.series||
a,"checkboxClick",{checked:b.target.checked,item:a},function(){a.select()})})}});l(A.prototype,{showResetZoom:function(){var a=this,b=p.lang,c=a.options.chart.resetZoomButton,d=c.theme,e=d.states,g="chart"===c.relativeTo?null:"plotBox";this.resetZoomButton=a.renderer.button(b.resetZoom,null,null,function(){a.zoomOut()},d,e&&e.hover).attr({align:c.position.align,title:b.resetZoomTitle}).addClass("highcharts-reset-zoom").add().align(c.position,!1,g)},zoomOut:function(){var a=this;m(a,"selection",{resetSelection:!0},
function(){a.zoom()})},zoom:function(a){var c,d=this.pointer,e=!1,h;!a||a.resetSelection?g(this.axes,function(a){c=a.zoom()}):g(a.xAxis.concat(a.yAxis),function(a){var b=a.axis;d[b.isXAxis?"zoomX":"zoomY"]&&(c=b.zoom(a.min,a.max),b.displayBtn&&(e=!0))});h=this.resetZoomButton;e&&!h?this.showResetZoom():!e&&b(h)&&(this.resetZoomButton=h.destroy());c&&this.redraw(t(this.options.chart.animation,a&&a.animation,100>this.pointCount))},pan:function(a,b){var c=this,d=c.hoverPoints,e;d&&g(d,function(a){a.setState()});
g("xy"===b?[1,0]:[1],function(b){b=c[b?"xAxis":"yAxis"][0];var d=b.horiz,g=a[d?"chartX":"chartY"],d=d?"mouseDownX":"mouseDownY",h=c[d],k=(b.pointRange||0)/2,f=b.getExtremes(),l=b.toValue(h-g,!0)+k,k=b.toValue(h+b.len-g,!0)-k,h=h>g;b.series.length&&(h||l>Math.min(f.dataMin,f.min))&&(!h||k<Math.max(f.dataMax,f.max))&&(b.setExtremes(l,k,!1,!1,{trigger:"pan"}),e=!0);c[d]=g});e&&c.redraw(!1);H(c.container,{cursor:"move"})}});l(c.prototype,{select:function(a,b){var c=this,e=c.series,h=e.chart;a=t(a,!c.selected);
c.firePointEvent(a?"select":"unselect",{accumulate:b},function(){c.selected=c.options.selected=a;e.options.data[d(c,e.data)]=c.options;c.setState(a&&"select");b||g(h.getSelectedPoints(),function(a){a.selected&&a!==c&&(a.selected=a.options.selected=!1,e.options.data[d(a,e.data)]=a.options,a.setState(""),a.firePointEvent("unselect"))})})},onMouseOver:function(a,b){var c=this.series,d=c.chart,e=d.tooltip,g=d.hoverPoint;if(this.series){if(!b){if(g&&g!==this)g.onMouseOut();if(d.hoverSeries!==c)c.onMouseOver();
d.hoverPoint=this}!e||e.shared&&!c.noSharedTooltip?e||this.setState("hover"):(this.setState("hover"),e.refresh(this,a));this.firePointEvent("mouseOver")}},onMouseOut:function(){var a=this.series.chart,b=a.hoverPoints;this.firePointEvent("mouseOut");b&&-1!==d(this,b)||(this.setState(),a.hoverPoint=null)},importEvents:function(){if(!this.hasImportedEvents){var a=u(this.series.options.point,this.options).events,b;this.events=a;for(b in a)x(this,b,a[b]);this.hasImportedEvents=!0}},setState:function(a,
b){var c=Math.floor(this.plotX),d=this.plotY,g=this.series,h=g.options.states[a]||{},k=e[g.type].marker&&g.options.marker,l=k&&!1===k.enabled,m=k&&k.states&&k.states[a]||{},n=!1===m.enabled,f=g.stateMarkerGraphic,q=this.marker||{},p=g.chart,u=g.halo,x,z=k&&g.markerAttribs;a=a||"";if(!(a===this.state&&!b||this.selected&&"select"!==a||!1===h.enabled||a&&(n||l&&!1===m.enabled)||a&&q.states&&q.states[a]&&!1===q.states[a].enabled)){z&&(x=g.markerAttribs(this,a));if(this.graphic)this.state&&this.graphic.removeClass("highcharts-point-"+
this.state),a&&this.graphic.addClass("highcharts-point-"+a),x&&this.graphic.animate(x,t(p.options.chart.animation,m.animation,k.animation)),f&&f.hide();else{if(a&&m)if(k=q.symbol||g.symbol,f&&f.currentSymbol!==k&&(f=f.destroy()),f)f[b?"animate":"attr"]({x:x.x,y:x.y});else k&&(g.stateMarkerGraphic=f=p.renderer.symbol(k,x.x,x.y,x.width,x.height).add(g.markerGroup),f.currentSymbol=k);f&&(f[a&&p.isInsidePlot(c,d,p.inverted)?"show":"hide"](),f.element.point=this)}(c=h.halo)&&c.size?(u||(g.halo=u=p.renderer.path().add(z?
g.markerGroup:g.group)),u[b?"animate":"attr"]({d:this.haloPath(c.size)}),u.attr({"class":"highcharts-halo highcharts-color-"+t(this.colorIndex,g.colorIndex)})):u&&u.animate({d:this.haloPath(0)});this.state=a}},haloPath:function(a){return this.series.chart.renderer.symbols.circle(Math.floor(this.plotX)-a,this.plotY-a,2*a,2*a)}});l(h.prototype,{onMouseOver:function(){var a=this.chart,b=a.hoverSeries;if(b&&b!==this)b.onMouseOut();this.options.events.mouseOver&&m(this,"mouseOver");this.setState("hover");
a.hoverSeries=this},onMouseOut:function(){var a=this.options,b=this.chart,c=b.tooltip,d=b.hoverPoint;b.hoverSeries=null;if(d)d.onMouseOut();this&&a.events.mouseOut&&m(this,"mouseOut");!c||a.stickyTracking||c.shared&&!this.noSharedTooltip||c.hide();this.setState()},setState:function(a){var b=this;a=a||"";b.state!==a&&(g([b.group,b.markerGroup],function(c){c&&(b.state&&c.removeClass("highcharts-series-"+b.state),a&&c.addClass("highcharts-series-"+a))}),b.state=a)},setVisible:function(a,b){var c=this,
d=c.chart,e=c.legendItem,h,k=d.options.chart.ignoreHiddenSeries,l=c.visible;h=(c.visible=a=c.options.visible=c.userOptions.visible=void 0===a?!l:a)?"show":"hide";g(["group","dataLabelsGroup","markerGroup","tracker","tt"],function(a){if(c[a])c[a][h]()});if(d.hoverSeries===c||(d.hoverPoint&&d.hoverPoint.series)===c)c.onMouseOut();e&&d.legend.colorizeItem(c,a);c.isDirty=!0;c.options.stacking&&g(d.series,function(a){a.options.stacking&&a.visible&&(a.isDirty=!0)});g(c.linkedSeries,function(b){b.setVisible(a,
!1)});k&&(d.isDirtyBox=!0);!1!==b&&d.redraw();m(c,h)},show:function(){this.setVisible(!0)},hide:function(){this.setVisible(!1)},select:function(a){this.selected=a=void 0===a?!this.selected:a;this.checkbox&&(this.checkbox.checked=a);m(this,a?"select":"unselect")},drawTracker:a.drawTrackerGraph})})(L);(function(a){var x=a.Chart,A=a.each,F=a.inArray,H=a.isObject,p=a.pick,e=a.splat;x.prototype.setResponsive=function(a){var e=this.options.responsive;e&&e.rules&&A(e.rules,function(e){this.matchResponsiveRule(e,
a)},this)};x.prototype.matchResponsiveRule=function(e,l){var g=this.respRules,k=e.condition,d;d=k.callback||function(){return this.chartWidth<=p(k.maxWidth,Number.MAX_VALUE)&&this.chartHeight<=p(k.maxHeight,Number.MAX_VALUE)&&this.chartWidth>=p(k.minWidth,0)&&this.chartHeight>=p(k.minHeight,0)};void 0===e._id&&(e._id=a.uniqueKey());d=d.call(this);!g[e._id]&&d?e.chartOptions&&(g[e._id]=this.currentOptions(e.chartOptions),this.update(e.chartOptions,l)):g[e._id]&&!d&&(this.update(g[e._id],l),delete g[e._id])};
x.prototype.currentOptions=function(a){function g(a,d,b){var k,l;for(k in a)if(-1<F(k,["series","xAxis","yAxis"]))for(a[k]=e(a[k]),b[k]=[],l=0;l<a[k].length;l++)b[k][l]={},g(a[k][l],d[k][l],b[k][l]);else H(a[k])?(b[k]={},g(a[k],d[k]||{},b[k])):b[k]=d[k]||null}var m={};g(a,this.options,m);return m}})(L);return L});
