PageSourceSearch

https://bitcoincloudmining.center/include/highcharts/highcharts.js

js bitcoincloudmining.center collected 2026-10-04 11:31:18 UTC 266,585 bytes, 5,264 lines download raw bytes

1/*
2 Highcharts JS v4.1.8 (2015-08-20)
3
4 (c) 2009-2014 Torstein Honsi
5
6 License: www.highcharts.com/license
7 */
8(function () {
9    function A() {
10        var a, b = arguments, c, d = {}, e = function (a, b) {
11            var c, d;
12            typeof a !== "object" && (a = {});
13            for (d in b)b.hasOwnProperty(d) && (c = b[d], a[d] = c && typeof c === "object" && Object.prototype.toString.call(c) !== "[object Array]" && d !== "renderTo" && typeof c.nodeType !== "number" ? e(a[d] || {}, c) : b[d]);
14            return a
15        };
16        b[0] === !0 && (d = b[1], b = Array.prototype.slice.call(b, 2));
17        c = b.length;
18        for (a = 0; a < c; a++)d = e(d, b[a]);
19        return d
20    }
21
22    function F(a, b) {
23        return parseInt(a, b || 10)
24    }
25
26    function Aa(a) {
27        return typeof a === "string"
28    }
29
30    function da(a) {
31        return a &&
32            typeof a === "object"
33    }
34
35    function Fa(a) {
36        return Object.prototype.toString.call(a) === "[object Array]"
37    }
38
39    function qa(a) {
40        return typeof a === "number"
41    }
42
43    function Ba(a) {
44        return W.log(a) / W.LN10
45    }
46
47    function ia(a) {
48        return W.pow(10, a)
49    }
50
51    function ja(a, b) {
52        for (var c = a.length; c--;)if (a[c] === b) {
53            a.splice(c, 1);
54            break
55        }
56    }
57
58    function s(a) {
59        return a !== v && a !== null
60    }
61
62    function J(a, b, c) {
63        var d, e;
64        if (Aa(b))s(c) ? a.setAttribute(b, c) : a && a.getAttribute && (e = a.getAttribute(b)); else if (s(b) && da(b))for (d in b)a.setAttribute(d, b[d]);
65        return e
66    }
67
68    function ra(a) {
69        return Fa(a) ?
70            a : [a]
71    }
72
73    function L(a, b) {
74        if (xa && !ca && b && b.opacity !== v)b.filter = "alpha(opacity=" + b.opacity * 100 + ")";
75        r(a.style, b)
76    }
77
78    function $(a, b, c, d, e) {
79        a = C.createElement(a);
80        b && r(a, b);
81        e && L(a, {padding: 0, border: O, margin: 0});
82        c && L(a, c);
83        d && d.appendChild(a);
84        return a
85    }
86
87    function ka(a, b) {
88        var c = function () {
89            return v
90        };
91        c.prototype = new a;
92        r(c.prototype, b);
93        return c
94    }
95
96    function Ga(a, b) {
97        return Array((b || 2) + 1 - String(a).length).join(0) + a
98    }
99
100    function Va(a) {
101        return (bb && bb(a) || mb || 0) * 6E4
102    }
103
104    function Ha(a, b) {
105        for (var c = "{", d = !1, e, f, g, h, i, j = []; (c = a.indexOf(c)) !== -1;) {
106            e = a.slice(0, c);
107            if (d) {
108                f = e.split(":");
109                g = f.shift().split(".");
110                i = g.length;
111                e = b;
112                for (h = 0; h < i; h++)e = e[g[h]];
113                if (f.length)f = f.join(":"), g = /\.([0-9])/, h = S.lang, i = void 0, /f$/.test(f) ? (i = (i = f.match(g)) ? i[1] : -1, e !== null && (e = B.numberFormat(e, i, h.decimalPoint, f.indexOf(",") > -1 ? h.thousandsSep : ""))) : e = Ma(f, e)
114            }
115            j.push(e);
116            a = a.slice(c + 1);
117            c = (d = !d) ? "}" : "{"
118        }
119        j.push(a);
120        return j.join("")
121    }
122
123    function nb(a) {
124        return W.pow(10, V(W.log(a) / W.LN10))
125    }
126
127    function ob(a, b, c, d, e) {
128        var f, g = a, c = p(c, 1);
129        f = a / c;
130        b || (b = [1, 2, 2.5, 5, 10], d === !1 && (c ===
131        1 ? b = [1, 2, 5, 10] : c <= 0.1 && (b = [1 / c])));
132        for (d = 0; d < b.length; d++)if (g = b[d], e && g * c >= a || !e && f <= (b[d] + (b[d + 1] || b[d])) / 2)break;
133        g *= c;
134        return g
135    }
136
137    function pb(a, b) {
138        var c = a.length, d, e;
139        for (e = 0; e < c; e++)a[e].ss_i = e;
140        a.sort(function (a, c) {
141            d = b(a, c);
142            return d === 0 ? a.ss_i - c.ss_i : d
143        });
144        for (e = 0; e < c; e++)delete a[e].ss_i
145    }
146
147    function Na(a) {
148        for (var b = a.length, c = a[0];
148 b--;)a[b] < c && (c = a[b]);
149        return c
150    }
151
152    function Ca(a) {
153        for (var b = a.length, c = a[0]; b--;)a[b] > c && (c = a[b]);
154        return c
155    }
156
157    function Oa(a, b) {
158        for (var c in a)a[c] && a[c] !== b && a[c].destroy && a[c].destroy(),
159            delete a[c]
160    }
161
162    function Pa(a) {
163        cb || (cb = $(Ia));
164        a && cb.appendChild(a);
165        cb.innerHTML = ""
166    }
167
168    function la(a, b) {
169        var c = "Highcharts error #" + a + ": www.highcharts.com/errors/" + a;
170        if (b)throw c;
171        K.console && console.log(c)
172    }
173
174    function ea(a, b) {
175        return parseFloat(a.toPrecision(b || 14))
176    }
177
178    function Qa(a, b) {
179        b.renderer.globalAnimation = p(a, b.animation)
180    }
181
182    function Cb() {
183        var a = S.global, b = a.useUTC, c = b ? "getUTC" : "get", d = b ? "setUTC" : "set";
184        ya = a.Date || window.Date;
185        mb = b && a.timezoneOffset;
186        bb = b && a.getTimezoneOffset;
187        db = function (a, c, d, h, i, j) {
188            var k;
189            b ? (k =
190                ya.UTC.apply(0, arguments), k += Va(k)) : k = (new ya(a, c, p(d, 1), p(h, 0), p(i, 0), p(j, 0))).getTime();
191            return k
192        };
193        qb = c + "Minutes";
194        rb = c + "Hours";
195        sb = c + "Day";
196        Wa = c + "Date";
197        Xa = c + "Month";
198        Ya = c + "FullYear";
199        Db = d + "Milliseconds";
200        Eb = d + "Seconds";
201        Fb = d + "Minutes";
202        Gb = d + "Hours";
203        tb = d + "Date";
204        ub = d + "Month";
205        vb = d + "FullYear"
206    }
207
208    function P() {
209    }
210
211    function Ra(a, b, c, d) {
212        this.axis = a;
213        this.pos = b;
214        this.type = c || "";
215        this.isNew = !0;
216        !c && !d && this.addLabel()
217    }
218
219    function Hb(a, b, c, d, e) {
220        var f = a.chart.inverted;
221        this.axis = a;
222        this.isNegative = c;
223        this.options = b;
224        this.x = d;
225        this.total =
226            null;
227        this.points = {};
228        this.stack = e;
229        this.alignOptions = {
230            align: b.align || (f ? c ? "left" : "right" : "center"),
231            verticalAlign: b.verticalAlign || (f ? "middle" : c ? "bottom" : "top"),
232            y: p(b.y, f ? 4 : c ? 14 : -6),
233            x: p(b.x, f ? c ? -6 : 6 : 0)
234        };
235        this.textAlign = b.textAlign || (f ? c ? "right" : "left" : "center")
236    }
237
238    var v, C = document, K = window, W = Math, w = W.round, V = W.floor, sa = W.ceil, t = W.max, z = W.min, N = W.abs, X = W.cos, aa = W.sin, ma = W.PI, ga = ma * 2 / 360, za = navigator.userAgent, Ib = K.opera, xa = /(msie|trident)/i.test(za) && !Ib, eb = C.documentMode === 8, fb = /AppleWebKit/.test(za), Ja =
239        /Firefox/.test(za), Jb = /(Mobile|Android|Windows Phone)/.test(za), Da = "http://www.w3.org/2000/svg", ca = !!C.createElementNS && !!C.createElementNS(Da, "svg").createSVGRect, Nb = Ja && parseInt(za.split("Firefox/")[1], 10) < 4, fa = !ca && !xa && !!C.createElement("canvas").getContext, Za, $a, Kb = {}, wb = 0, cb, S, Ma, xb, E, ta = function () {
240        return v
241    }, Y = [], ab = 0, Ia = "div", O = "none", Ob = /^[0-9]+$/, gb = ["plotTop", "marginRight", "marginBottom", "plotLeft"], Pb = "stroke-width", ya, db, mb, bb, qb, rb, sb, Wa, Xa, Ya, Db, Eb, Fb, Gb, tb, ub, vb, M = {}, B;
242    B = K.Highcharts =
243        K.Highcharts ? la(16, !0) : {};
244    B.seriesTypes = M;
245    var r = B.extend = function (a, b) {
246        var c;
247        a || (a = {});
248        for (c in b)a[c] = b[c];
249        return a
250    }, p = B.pick = function () {
251        var a = arguments, b, c, d = a.length;
252        for (b = 0; b < d; b++)if (c = a[b], c !== v && c !== null)return c
253    }, Sa = B.wrap = function (a, b, c) {
254        var d = a[b];
255        a[b] = function () {
256            var a = Array.prototype.slice.call(arguments);
257            a.unshift(d);
258            return c.apply(this, a)
259        }
260    };
261    Ma = function (a, b, c) {
262        if (!s(b) || isNaN(b))return S.lang.invalidDate || "";
263        var a = p(a, "%Y-%m-%d %H:%M:%S"), d = new ya(b - Va(b)), e, f = d[rb](), g = d[sb](), h = d[Wa](),
264            i = d[Xa](), j = d[Ya](), k = S.lang, m = k.weekdays, d = r({
265                a: m[g].substr(0, 3),
266                A: m[g],
267                d: Ga(h),
268                e: h,
269                w: g,
270                b: k.shortMonths[i],
271                B: k.months[i],
272                m: Ga(i + 1),
273                y: j.toString().substr(2, 2),
274                Y: j,
275                H: Ga(f),
276                k: f,
277                I: Ga(f % 12 || 12),
278                l: f % 12 || 12,
279                M: Ga(d[qb]()),
280                p: f < 12 ? "AM" : "PM",
281                P: f < 12 ? "am" : "pm",
282                S: Ga(d.getSeconds()),
283                L: Ga(w(b % 1E3), 3)
284            }, B.dateFormats);
285        for (e in d)for (; a.indexOf("%" + e) !== -1;)a = a.replace("%" + e, typeof d[e] === "function" ? d[e](b) : d[e]);
286        return c ? a.substr(0, 1).toUpperCase() + a.substr(1) : a
287    };
288    E = {
289        millisecond: 1, second: 1E3, minute: 6E4, hour: 36E5, day: 864E5,
290        week: 6048E5, month: 24192E5, year: 314496E5
291    };
292    B.numberFormat = function (a, b, c, d) {
293        var e = S.lang, a = +a || 0, f = b === -1 ? z((a.toString().split(".")[1] || "").length, 20) : isNaN(b = N(b)) ? 2 : b, b = c === void 0 ? e.decimalPoint : c, d = d === void 0 ? e.thousandsSep : d, e = a < 0 ? "-" : "", c = String(F(a = N(a).toFixed(f))), g = c.length > 3 ? c.length % 3 : 0;
294        return e + (g ? c.substr(0, g) + d : "") + c.substr(g).replace(/(\d{3})(?=\d)/g, "$1" + d) + (f ? b + N(a - c).toFixed(f).slice(2) : "")
295    };
296    xb = {
297        init: function (a, b, c) {
298            var b = b || "", d = a.shift, e = b.indexOf("C") > -1, f = e ? 7 : 3, g, b = b.split(" "),
299                c = [].concat(c), h, i, j = function (a) {
300                    for (g = a.length; g--;)a[g] === "M" && a.splice(g + 1, 0, a[g + 1], a[g + 2], a[g + 1], a[g + 2])
301                };
302            e && (j(b), j(c));
303            a.isArea && (h = b.splice(b.length - 6, 6), i = c.splice(c.length - 6, 6));
304            if (d <= c.length / f && b.length === c.length)for (; d--;)c = [].concat(c).splice(0, f).concat(c);
305            a.shift = 0;
306            if (b.length)for (a = c.length; b.length < a;)d = [].concat(b).splice(b.length - f, f), e && (d[f - 6] = d[f - 2], d[f - 5] = d[f - 1]), b = b.concat(d);
307            h && (b = b.concat(h), c = c.concat(i));
308            return [b, c]
309        }, step: function (a, b, c, d) {
310            var e = [], f = a.length;
311            if (c === 1)e =
312                d; else if (f === b.length && c < 1)for (; f--;)d = parseFloat(a[f]), e[f] = isNaN(d) ? a[f] : c * parseFloat(b[f] - d) + d; else e = b;
313            return e
314        }
315    };
316    (function (a) {
317        K.HighchartsAdapter = K.HighchartsAdapter || a && {
318                init: function (b) {
319                    var c = a.fx;
320                    a.extend(a.easing, {
321                        easeOutQuad: function (a, b, c, g, h) {
322                            return -g * (b /= h) * (b - 2) + c
323                        }
324                    });
325                    a.each(["cur", "_default", "width", "height", "opacity"], function (b, e) {
326                        var f = c.step, g;
327                        e === "cur" ? f = c.prototype : e === "_default" && a.Tween && (f = a.Tween.propHooks[e], e = "set");
328                        (g = f[e]) && (f[e] = function (a) {
329                            var c, a = b ? a : this;
330                            if (a.prop !==
331                                "align")return c = a.elem, c.attr ? c.attr(a.prop, e === "cur" ? v : a.now) : g.apply(this, arguments)
332                        })
333                    });
334                    Sa(a.cssHooks.opacity, "get", function (a, b, c) {
335                        return b.attr ? b.opacity || 0 : a.call(this, b, c)
336                    });
337                    this.addAnimSetter("d", function (a) {
338                        var c = a.elem, f;
339                        if (!a.started)f = b.init(c, c.d, c.toD), a.start = f[0], a.end = f[1], a.started = !0;
340                        c.attr("d", b.step(a.start, a.end, a.pos, c.toD))
341                    });
342                    this.each = Array.prototype.forEach ? function (a, b) {
343                        return Array.prototype.forEach.call(a, b)
344                    } : function (a, b) {
345                        var c, g = a.length;
346                        for (c = 0; c < g; c++)if (b.call(a[c],
347                                a[c], c, a) === !1)return c
348                    };
349                    a.fn.highcharts = function () {
350                        var a = "Chart", b = arguments, c, g;
351                        if (this[0]) {
352                            Aa(b[0]) && (a = b[0], b = Array.prototype.slice.call(b, 1));
353                            c = b[0];
354                            if (c !== v)c.chart = c.chart || {}, c.chart.renderTo = this[0], new B[a](c, b[1]), g = this;
355                            c === v && (g = Y[J(this[0], "data-highcharts-chart")])
356                        }
357                        return g
358                    }
359                }, addAnimSetter: function (b, c) {
360                    a.Tween ? a.Tween.propHooks[b] = {set: c} : a.fx.step[b] = c
361                }, getScript: a.getScript, inArray: a.inArray, adapterRun: function (b, c) {
362                    return a(b)[c]()
363                }, grep: a.grep, map: function (a, c) {
364                    for (var d = [], e =
365                        0, f = a.length; e < f; e++)d[e] = c.call(a[e], a[e], e, a);
366                    return d
367                }, offset: function (b) {
368                    return a(b).offset()
369                }, addEvent: function (b, c, d) {
370                    a(b).bind(c, d)
371                }, removeEvent: function (b, c, d) {
372                    var e = C.removeEventListener ? "removeEventListener" : "detachEvent";
373                    C[e] && b && !b[e] && (b[e] = function () {
374                    });
375                    a(b).unbind(c, d)
376                }, fireEvent: function (b, c, d, e) {
377                    var f = a.Event(c), g = "detached" + c, h;
378                    !xa && d && (delete d.layerX, delete d.layerY, delete d.returnValue);
379                    r(f, d);
380                    b[c] && (b[g] = b[c], b[c] = null);
381                    a.each(["preventDefault", "stopPropagation"], function (a,
382                                                                            b) {
383                        var c = f[b];
384                        f[b] = function () {
385                            try {
386                                c.call(f)
387                            } catch (a) {
388                                b === "preventDefault" && (h = !0)
389                            }
390                        }
391                    });
392                    a(b).trigger(f);
393                    b[g] && (b[c] = b[g], b[g] = null);
394                    e && !f.isDefaultPrevented() && !h && e(f)
395                }
395, washMouseEvent: function (a) {
396                    var c = a.originalEvent || a;
397                    if (c.pageX === v)c.pageX = a.pageX, c.pageY = a.pageY;
398                    return c
399                }, animate: function (b, c, d) {
400                    var e = a(b);
401                    if (!b.style)b.style = {};
402                    if (c.d)b.toD = c.d, c.d = 1;
403                    e.stop();
404                    c.opacity !== v && b.attr && (c.opacity += "px");
405                    b.hasAnim = 1;
406                    e.animate(c, d)
407                }, stop: function (b) {
408                    b.hasAnim && a(b).stop()
409                }
410            }
411    })(K.jQuery);
412    var U = K.HighchartsAdapter,
413        D = U || {};
414    U && U.init.call(U, xb);
415    var hb = D.adapterRun, Qb = D.getScript, Ka = D.inArray, o = B.each = D.each, ib = D.grep, Rb = D.offset, Ta = D.map, H = D.addEvent, Z = D.removeEvent, I = D.fireEvent, Sb = D.washMouseEvent, jb = D.animate, kb = D.stop;
416    S = {
417        colors: "#7cb5ec,#434348,#90ed7d,#f7a35c,#8085e9,#f15c80,#e4d354,#2b908f,#f45b5b,#91e8e1".split(","),
418        symbols: ["circle", "diamond", "square", "triangle", "triangle-down"],
419        lang: {
420            loading: "Loading...",
421            months: "January,February,March,April,May,June,July,August,September,October,November,December".split(","),
422            shortMonths: "Jan,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec".split(","),
423            weekdays: "Sunday,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday".split(","),
424            decimalPoint: ".",
425            numericSymbols: "k,M,G,T,P,E".split(","),
426            resetZoom: "Reset zoom",
427            resetZoomTitle: "Reset zoom level 1:1",
428            thousandsSep: " "
429        },
430        global: {
431            useUTC: !0,
432            canvasToolsURL: "http://code.highcharts.com/4.1.8/modules/canvas-tools.js",
433            VMLRadialGradientURL: "http://code.highcharts.com/4.1.8/gfx/vml-radial-gradient.png"
434        },
435        chart: {
436            borderColor: "#4572A7",
437            borderRadius: 0,
438            defaultSeriesType: "line",
439            ignoreHiddenSeries: !0,
440            spacing: [10, 10, 15, 10],
441            backgroundColor: '',
442            plotBorderColor: "#C0C0C0",
443            resetZoomButton: {theme: {zIndex: 20}, position: {align: "right", x: -10, y: 10}}
444        },
445        title: {text: "Chart title", align: "center", margin: 15, style: {color: "#333333", fontSize: "18px"}},
446        subtitle: {text: "", align: "center", style: {color: "#555555"}},
447        plotOptions: {
448            line: {
449                allowPointSelect: !1,
450                showCheckbox: !1,
451                animation: {duration: 1E3},
452                events: {},
453                lineWidth: 2,
454                marker: {
455                    lineWidth: 0, radius: 4, lineColor: "#FFFFFF", states: {
456                        hover: {
457                            enabled: !0,
458                            lineWidthPlus: 1, radiusPlus: 2
459                        }, select: {fillColor: "#FFFFFF", lineColor: "#000000", lineWidth: 2}
460                    }
461                },
462                point: {events: {}},
463                dataLabels: {
464                    align: "center",
465                    formatter: function () {
466                        return this.y === null ? "" : B.numberFormat(this.y, -1)
467                    },
468                    style: {
469                        color: "contrast",
470                        fontSize: "11px",
471                        fontWeight: "bold",
472                        textShadow: "0 0 6px contrast, 0 0 3px contrast"
473                    },
474                    verticalAlign: "bottom",
475                    x: 0,
476                    y: 0,
477                    padding: 5
478                },
479                cropThreshold: 300,
480                pointRange: 0,
481                states: {hover: {lineWidthPlus: 1, marker: {}, halo: {size: 10, opacity: 0.25}}, select: {marker: {}}},
482                stickyTracking: !0,
483                turboThreshold: 1E3
484            }
485        },
486        labels: {style: {position: "absolute", color: "#3E576F"}},
487        legend: {
488            enabled: !0,
489            align: "center",
490            layout: "horizontal",
491            labelFormatter: function () {
492                return this.name
493            },
494            borderColor: "#909090",
495            borderRadius: 0,
496            navigation: {activeColor: "#274b6d", inactiveColor: "#CCC"},
497            shadow: !1,
498            itemStyle: {color: "#333333", fontSize: "12px", fontWeight: "bold"},
499            itemHoverStyle: {color: "#000"},
500            itemHiddenStyle: {color: "#CCC"},
501            itemCheckboxStyle: {position: "absolute", width: "13px", height: "13px"},
502            symbolPadding: 5,
503            verticalAlign: "bottom",
504            x: 0,
505            y: 0,
506            title: {style: {fontWeight: "bold"}}
507        },
508        loading: {
509            labelStyle: {fontWeight: "bold", position: "relative", top: "45%"},
510            style: {position: "absolute", backgroundColor: "white", opacity: 0.5, textAlign: "center"}
511        },
512        tooltip: {
513            enabled: !0,
514            animation: ca,
515            backgroundColor: "rgba(249, 249, 249, .85)",
516            borderWidth: 1,
517            borderRadius: 3,
518            dateTimeLabelFormats: {
519                millisecond: "%A, %b %e, %H:%M:%S.%L",
520                second: "%A, %b %e, %H:%M:%S",
521                minute: "%A, %b %e, %H:%M",
522                hour: "%A, %b %e, %H:%M",
523                day: "%A, %b %e, %Y",
524                week: "Week from %A, %b %e, %Y",
525                month: "%B %Y",
526                year: "%Y"
527            },
528            footerFormat: "",
529            headerFormat: '<span style="font-size: 10px">{point.key}</span><br/>',
530            pointFormat: '<span style="color:{point.color}">\u25cf</span> {series.name}: <b>{point.y}</b><br/>',
531            shadow: !0,
532            snap: Jb ? 25 : 10,
533            style: {color: "#333333", cursor: "default", fontSize: "12px", padding: "8px", whiteSpace: "nowrap"}
534        },
535        credits: {
536            enabled: 0,
537            text: "Highcharts.com",
538            href: "http://www.highcharts.com",
539            position: {align: "right", x: -10, verticalAlign: "bottom", y: -5},
540            style: {cursor: "pointer", color: "#909090", fontSize: "9px"}
541        }
542    };
543    var ba = S.plotOptions, U = ba.line;
544    Cb();
545    var Tb = /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*\)/,
546        Ub = /#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/, Vb = /rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/, na = function (a) {
547            var b = [], c, d;
548            (function (a) {
549                a && a.stops ? d = Ta(a.stops, function (a) {
550                    return na(a[1])
551                }) : (c = Tb.exec(a)) ? b = [F(c[1]), F(c[2]), F(c[3]), parseFloat(c[4], 10)] : (c = Ub.exec(a)) ? b = [F(c[1], 16), F(c[2], 16), F(c[3], 16), 1] : (c = Vb.exec(a)) && (b = [F(c[1]), F(c[2]), F(c[3]), 1])
552            })(a);
553            return {
554                get: function (c) {
555                    var f;
556                    d ? (f = A(a), f.stops = [].concat(f.stops), o(d, function (a, b) {
557                        f.stops[b] = [f.stops[b][0], a.get(c)]
558                    })) :
559                        f = b && !isNaN(b[0]) ? c === "rgb" ? "rgb(" + b[0] + "," + b[1] + "," + b[2] + ")" : c === "a" ? b[3] : "rgba(" + b.join(",") + ")" : a;
560                    return f
561                }, brighten: function (a) {
562                    if (d)o(d, function (b) {
563                        b.brighten(a)
564                    }); else if (qa(a) && a !== 0) {
565                        var c;
566                        for (c = 0; c < 3; c++)b[c] += F(a * 255), b[c] < 0 && (b[c] = 0), b[c] > 255 && (b[c] = 255)
567                    }
568                    return this
569                }, rgba: b, setOpacity: function (a) {
570                    b[3] = a;
571                    return this
572                }, raw: a
573            }
574        };
575    P.prototype = {
576        opacity: 1,
577        textProps: "fontSize,fontWeight,fontFamily,fontStyle,color,lineHeight,width,textDecoration,textOverflow,textShadow".split(","),
578        init: function (a,
579                        b) {
580            this.element = b === "span" ? $(b) : C.createElementNS(Da, b);
581            this.renderer = a
582        },
583        animate: function (a, b, c) {
584            b = p(b, this.renderer.globalAnimation, !0);
585            kb(this);
586            if (b) {
587                b = A(b, {});
588                if (c)b.complete = c;
589                jb(this, a, b)
590            } else this.attr(a, null, c);
591            return this
592        },
593        colorGradient: function (a, b, c) {
594            var d = this.renderer, e, f, g, h, i, j, k, m, l, n, q = [];
595            a.linearGradient ? f = "linearGradient" : a.radialGradient && (f = "radialGradient");
596            if (f) {
597                g = a[f];
598                h = d.gradients;
599                j = a.stops;
600                l = c.radialReference;
601                Fa(g) && (a[f] = g = {x1: g[0], y1: g[1], x2: g[2], y2: g[3], gradientUnits: "userSpaceOnUse"});
602                f === "radialGradient" && l && !s(g.gradientUnits) && (g = A(g, {
603                    cx: l[0] - l[2] / 2 + g.cx * l[2],
604                    cy: l[1] - l[2] / 2 + g.cy * l[2],
605                    r: g.r * l[2],
606                    gradientUnits: "userSpaceOnUse"
607                }));
608                for (n in g)n !== "id" && q.push(n, g[n]);
609                for (n in j)q.push(j[n]);
610                q = q.join(",");
611                h[q] ? a = h[q].attr("id") : (g.id = a = "highcharts-" + wb++, h[q] = i = d.createElement(f).attr(g).add(d.defs), i.stops = [], o(j, function (a) {
612                    a[1].indexOf("rgba") === 0 ? (e = na(a[1]), k = e.get("rgb"), m = e.get("a")) : (k = a[1], m = 1);
613                    a = d.createElement("stop").attr({offset: a[0], "stop-color": k, "stop-opacity": m}).add(i);
614                    i.stops.push(a)
615                }));
616                c.setAttribute(b, "url(" + d.url + "#" + a + ")")
617            }
618        },
619        applyTextShadow: function (a) {
620            var b = this.element, c, d = a.indexOf("contrast") !== -1, e = {}, f = this.renderer.forExport || b.style.textShadow !== v && !xa;
621            if (d)e.textShadow = a = a.replace(/contrast/g, this.renderer.getContrast(b.style.fill));
622            if (fb)e.textRendering = "geometricPrecision";
623            f ? L(b, e) : (this.fakeTS = !0, this.ySetter = this.xSetter, c = [].slice.call(b.getElementsByTagName("tspan")), o(a.split(/\s?,\s?/g), function (a) {
624                var d = b.firstChild, e, f, a = a.split(" ");
625                e = a[a.length -
626                1];
627                (f = a[a.length - 2]) && o(c, function (a, c) {
628                    var g;
629                    c === 0 && (a.setAttribute("x", b.getAttribute("x")), c = b.getAttribute("y"), a.setAttribute("y", c || 0), c === null && b.setAttribute("y", 0));
630                    g = a.cloneNode(1);
631                    J(g, {
632                        "class": "highcharts-text-shadow",
633                        fill: e,
634                        stroke: e,
635                        "stroke-opacity": 1 / t(F(f), 3),
636                        "stroke-width": f,
637                        "stroke-linejoin": "round"
638                    });
639                    b.insertBefore(g, d)
640                })
641            }))
642        },
643        attr: function (a, b, c) {
644            var d, e = this.element, f, g = this, h;
645            typeof a === "string" && b !== v && (d = a, a = {}, a[d] = b);
646            if (typeof a === "string")g = (this[a + "Getter"] || this._defaultGetter).call(this,
647                a, e); else {
648                for (d in a) {
649                    b = a[d];
650                    h = !1;
651                    this.symbolName && /^(x|y|width|height|r|start|end|innerR|anchorX|anchorY)/.test(d) && (f || (this.symbolAttr(a), f = !0), h = !0);
652                    if (this.rotation && (d === "x" || d === "y"))this.doTransform = !0;
653                    h || (this[d + "Setter"] || this._defaultSetter).call(this, b, d, e);
654                    this.shadows && /^(width|height|visibility|x|y|d|transform|cx|cy|r)$/.test(d) && this.updateShadows(d, b)
655                }
656                if (this.doTransform)this.updateTransform(), this.doTransform = !1
657            }
658            c && c();
659            return g
660        },
661        updateShadows: function (a, b) {
662            for (var c = this.shadows,
663                     d = c.length; d--;)c[d].setAttribute(a, a === "height" ? t(b - (c[d].cutHeight || 0), 0) : a === "d" ? this.d : b)
664        },
665        addClass: function (a) {
666            var b = this.element, c = J(b, "class") || "";
667            c.indexOf(a) === -1 && J(b, "class", c + " " + a);
668            return this
669        },
670        symbolAttr: function (a) {
671            var b = this;
672            o("x,y,r,start,end,width,height,innerR,anchorX,anchorY".split(","), function (c) {
673                b[c] = p(a[c], b[c])
674            });
675            b.attr({d: b.renderer.symbols[b.symbolName](b.x, b.y, b.width, b.height, b)})
676        },
677        clip: function (a) {
678            return this.attr("clip-path", a ? "url(" + this.renderer.url + "#" + a.id + ")" : O)
679        },
680        crisp: function (a) {
681            var b, c = {}, d, e = a.strokeWidth || this.strokeWidth || 0;
682            d = w(e) % 2 / 2;
683            a.x = V(a.x || this.x || 0) + d;
684            a.y = V(a.y || this.y || 0) + d;
685            a.width = V((a.width || this.width || 0) - 2 * d);
686            a.height = V((a.height || this.height || 0) - 2 * d);
687            a.strokeWidth = e;
688            for (b in a)this[b] !== a[b] && (this[b] = c[b] = a[b]);
689            return c
690        },
691        css: function (a) {
692            var b = this.styles, c = {}, d = this.element, e, f, g = "";
693            e = !b;
694            if (a && a.color)a.fill = a.color;
695            if (b)for (f in a)a[f] !== b[f] && (c[f] = a[f], e = !0);
696            if (e) {
697                e = this.textWidth = a && a.width && d.nodeName.toLowerCase() === "text" && F(a.width) ||
698                    this.textWidth;
699                b && (a = r(b, c));
700                this.styles = a;
701                e && (fa || !ca && this.renderer.forExport) && delete a.width;
702                if (xa && !ca)L(this.element, a); else {
703                    b = function (a, b) {
704                        return "-" + b.toLowerCase()
705                    };
706                    for (f in a)g += f.replace(/([A-Z])/g, b) + ":" + a[f] + ";";
707                    J(d, "style", g)
708                }
709                e && this.added && this.renderer.buildText(this)
710            }
711            return this
712        },
713        on: function (a, b) {
714            var c = this, d = c.element;
715            $a && a === "click" ? (d.ontouchstart = function (a) {
716                c.touchEventFired = ya.now();
717                a.preventDefault();
718                b.call(d, a)
719            }, d.onclick = function (a) {
720                (za.indexOf("Android") === -1 || ya.now() -
721                (c.touchEventFired || 0) > 1100) && b.call(d, a)
722            }) : d["on" + a] = b;
723            return this
724        },
725        setRadialReference: function (a) {
726            this.element.radialReference = a;
727            return this
728        },
729        translate: function (a, b) {
730            return this.attr({translateX: a, translateY: b})
731        },
732        invert: function () {
733            this.inverted = !0;
734            this.updateTransform();
735            return this
736        },
737        updateTransform: function () {
738            var a = this.translateX || 0, b = this.translateY || 0, c = this.scaleX, d = this.scaleY, e = this.inverted, f = this.rotation, g = this.element;
739            e && (a += this.attr("width"), b += this.attr("height"));
740            a = ["translate(" + a +
741            "," + b + ")"];
742            e ? a.push("rotate(90) scale(-1,1)") : f && a.push("rotate(" + f + " " + (g.getAttribute("x") || 0) + " " + (g.getAttribute("y") || 0) + ")");
743            (s(c) || s(d)) && a.push("scale(" + p(c, 1) + " " + p(d, 1) + ")");
744            a.length && g.setAttribute("transform", a.join(" "))
745        },
746        toFront: function () {
747            var a = this.element;
748            a.parentNode.appendChild(a);
749            return this
750        },
751        align: function (a, b, c) {
752            var d, e, f, g, h = {};
753            e = this.renderer;
754            f = e.alignedObjects;
755            if (a) {
756                if (this.alignOptions = a, this.alignByTranslate = b, !c || Aa(c))this.alignTo = d = c || "renderer", ja(f, this), f.push(this),
757                    c = null
758            } else a = this.alignOptions, b = this.alignByTranslate, d = this.alignTo;
759            c = p(c, e[d], e);
760            d = a.align;
761            e = a.verticalAlign;
762            f = (c.x || 0) + (a.x || 0);
763            g = (c.y || 0) + (a.y || 0);
764            if (d === "right" || d === "center")f += (c.width - (a.width || 0)) / {right: 1, center: 2}[d];
765            h[b ? "translateX" : "x"] = w(f);
766            if (e === "bottom" || e === "middle")g += (c.height - (a.height || 0)) / ({bottom: 1, middle: 2}[e] || 1);
767            h[b ? "translateY" : "y"] = w(g);
768            this[this.placed ? "animate" : "attr"](h);
769            this.placed = !0;
770            this.alignAttr = h;
771            return this
772        },
773        getBBox: function (a) {
774            var b, c = this.renderer, d, e = this.rotation,
775                f = this.element, g = this.styles, h = e * ga;
776            d = this.textStr;
777            var i, j = f.style, k, m;
778            d !== v && (m = ["", e || 0, g && g.fontSize, f.style.width].join(","), m = d === "" || Ob.test(d) ? "num:" + d.toString().length + m : d + m);
779            m && !a && (b = c.cache[m]);
780            if (!b) {
781                if (f.namespaceURI === Da || c.forExport) {
782                    try {
783                        k = this.fakeTS && function (a) {
784                                o(f.querySelectorAll(".highcharts-text-shadow"), function (b) {
785                                    b.style.display = a
786                                })
787                            }, Ja && j.textShadow ? (i = j.textShadow, j.textShadow = "") : k && k(O), b = f.getBBox ? r({}, f.getBBox()) : {
788                            width: f.offsetWidth,
789                            height: f.offsetHeight
790                        }, i ? j.textShadow =
791                            i : k && k("")
792                    } catch (l) {
793                    }
794                    if (!b || b.width < 0)b = {width: 0, height: 0}
795                } else b = this.htmlGetBBox();
796                if (c.isSVG) {
797                    a = b.width;
798                    d = b.height;
799                    if (xa && g && g.fontSize === "11px" && d.toPrecision(3) === "16.9")b.height = d = 14;
800                    if (e)b.width = N(d * aa(h)) + N(a * X(h)), b.height = N(d * X(h)) + N(a * aa(h))
801                }
802                m && (c.cache[m] = b)
803            }
804            return b
805        },
806        show: function (a) {
807            return this.attr({visibility: a ? "inherit" : "visible"})
808        },
809        hide: function () {
810            return this.attr({visibility: "hidden"})
811        },
812        fadeOut: function (a) {
813            var b = this;
814            b.animate({opacity: 0}, {
815                duration: a || 150, complete: function () {
816                    b.attr({y: -9999})
817                }
818            })
819        },
820        add: function (a) {
821            var b = this.renderer, c = this.element, d;
822            if (a)this.parentGroup = a;
823            this.parentInverted = a && a.inverted;
824            this.textStr !== void 0 && b.buildText(this);
825            this.added = !0;
826            if (!a || a.handleZ || this.zIndex)d = this.zIndexSetter();
827            d || (a ? a.element : b.box).appendChild(c);
828            if (this.onAdd)this.onAdd();
829            return this
830        },
831        safeRemoveChild: function (a) {
832            var b = a.parentNode;
833            b && b.removeChild(a)
834        },
835        destroy: function () {
836            var a = this, b = a.element || {}, c = a.shadows, d = a.renderer.isSVG && b.nodeName === "SPAN" && a.parentGroup, e, f;
837            b.onclick = b.onmouseout =
838                b.onmouseover = b.onmousemove = b.point = null;
839            kb(a);
840            if (a.clipPath)a.clipPath = a.clipPath.destroy();
841            if (a.stops) {
842                for (f = 0; f < a.stops.length; f++)a.stops[f] = a.stops[f].destroy();
843                a.stops = null
844            }
845            a.safeRemoveChild(b);
846            for (c && o(c, function (b) {
847                a.safeRemoveChild(b)
848            }); d && d.div && d.div.childNodes.length === 0;)b = d.parentGroup, a.safeRemoveChild(d.div), delete d.div, d = b;
849            a.alignTo && ja(a.renderer.alignedObjects, a);
850            for (e in a)delete a[e];
851            return null
852        },
853        shadow: function (a, b, c) {
854            var d = [], e, f, g = this.element, h, i, j, k;
855            if (a) {
856                i = p(a.width, 3);
857                j = (a.opacity || 0.15) / i;
858                k = this.parentInverted ? "(-1,-1)" : "(" + p(a.offsetX, 1) + ", " + p(a.offsetY, 1) + ")";
859                for (e = 1; e <= i; e++) {
860                    f = g.cloneNode(0);
861                    h = i * 2 + 1 - 2 * e;
862                    J(f, {
863                        isShadow: "true",
864                        stroke: a.color || "black",
865                        "stroke-opacity": j * e,
866                        "stroke-width": h,
867                        transform: "translate" + k,
868                        fill: O
869                    });
870                    if (c)J(f, "height", t(J(f, "height") - h, 0)), f.cutHeight = h;
871                    b ? b.element.appendChild(f) : g.parentNode.insertBefore(f, g);
872                    d.push(f)
873                }
874                this.shadows = d
875            }
876            return this
877        },
878        xGetter: function (a) {
879            this.element.nodeName === "circle" && (a = {x: "cx", y: "cy"}[a] || a);
880            return this._defaultGetter(a)
881        },
882        _defaultGetter: function (a) {
883            a = p(this[a], this.element ? this.element.getAttribute(a) : null, 0);
884            /^[\-0-9\.]+$/.test(a) && (a = parseFloat(a));
885            return a
886        },
887        dSetter: function (a, b, c) {
888            a && a.join && (a = a.join(" "));
889            /(NaN| {2}|^$)/.test(a) && (a = "M 0 0");
890            c.setAttribute(b, a);
891            this[b] = a
892        },
893        dashstyleSetter: function (a) {
894            var b;
895            if (a = a && a.toLowerCase()) {
896                a = a.replace("shortdashdotdot", "3,1,1,1,1,1,").replace("shortdashdot", "3,1,1,1").replace("shortdot", "1,1,").replace("shortdash", "3,1,").replace("longdash", "8,3,").replace(/dot/g, "1,3,").replace("dash",
897                    "4,3,").replace(/,$/, "").split(",");
898                for (b = a.length; b--;)a[b] = F(a[b]) * this["stroke-width"];
899                a = a.join(",").replace("NaN", "none");
900                this.element.setAttribute("stroke-dasharray", a)
901            }
902        },
903        alignSetter: function (a) {
904            this.element.setAttribute("text-anchor", {left: "start", center: "middle", right: "end"}[a])
905        },
906        opacitySetter: function (a, b, c) {
907            this[b] = a;
908            c.setAttribute(b, a)
909        },
910        titleSetter: function (a) {
911            var b = this.element.getElementsByTagName("title")[0];
912            b || (b = C.createElementNS(Da, "title"), this.element.appendChild(b));
913            b.appendChild(C.createTextNode(String(p(a),
914                "").replace(/<[^>]*>/g, "")))
915        },
916        textSetter: function (a) {
917            if (a !== this.textStr)delete this.bBox, this.textStr = a, this.added && this.renderer.buildText(this)
918        },
919        fillSetter: function (a, b, c) {
920            typeof a === "string" ? c.setAttribute(b, a) : a && this.colorGradient(a, b, c)
921        },
922        visibilitySetter: function (a, b, c) {
923            a === "inherit" ? c.removeAttribute(b) : c.setAttribute(b, a)
924        },
925        zIndexSetter: function (a, b) {
926            var c = this.renderer, d = this.parentGroup, c = (d || c).element || c.box, e, f, g = this.element, h;
927            e = this.added;
928            var i;
929            s(a) && (g.setAttribute(b, a), a = +a, this[b] ===
930            a && (e = !1), this[b] = a);
931            if (e) {
932                if ((a = this.zIndex) && d)d.handleZ = !0;
933                d = c.childNodes;
934                for (i = 0; i < d.length && !h; i++)if (e = d[i], f = J(e, "zIndex"), e !== g && (F(f) > a || !s(a) && s(f)))c.insertBefore(g, e), h = !0;
935                h || c.appendChild(g)
936            }
937            return h
938        },
939        _defaultSetter: function (a, b, c) {
940            c.setAttribute(b, a)
941        }
942    };
943    P.prototype.yGetter = P.prototype.xGetter;
944    P.prototype.translateXSetter = P.prototype.translateYSetter = P.prototype.rotationSetter = P.prototype.verticalAlignSetter = P.prototype.scaleXSetter = P.prototype.scaleYSetter = function (a, b) {
945        this[b] = a;
946        this.doTransform = !0
947    };
948    P.prototype["stroke-widthSetter"] = P.prototype.strokeSetter = function (a, b, c) {
949        this[b] = a;
950        if (this.stroke && this["stroke-width"])this.strokeWidth = this["stroke-width"], P.prototype.fillSetter.call(this, this.stroke, "stroke", c), c.setAttribute("stroke-width", this["stroke-width"]), this.hasStroke = !0; else if (b === "stroke-width" && a === 0 && this.hasStroke)c.removeAttribute("stroke"), this.hasStroke = !1
951    };
952    var ua = function () {
953        this.init.apply(this, arguments)
954    };
955    ua.prototype = {
956        Element: P, init: function (a, b, c, d, e) {
957            var f = location,
958                g, d = this.createElement("svg").attr({version: "1.1"}).css(this.getStyle(d));
959            g = d.element;
960            a.appendChild(g);
961            a.innerHTML.indexOf("xmlns") === -1 && J(g, "xmlns", Da);
962            this.isSVG = !0;
963            this.box = g;
964            this.boxWrapper = d;
965            this.alignedObjects = [];
966            this.url = (Ja || fb) && C.getElementsByTagName("base").length ? f.href.replace(/#.*?$/, "").replace(/([\('\)])/g, "\\$1").replace(/ /g, "%20") : "";
967            this.createElement("desc").add().element.appendChild(C.createTextNode("Created with Highcharts 4.1.8"));
968            this.defs = this.createElement("defs").add();
969            this.forExport = e;
970            this.gradients = {};
971            this.cache = {};
972            this.setSize(b, c, !1);
973            var h;
974            if (Ja && a.getBoundingClientRect)this.subPixelFix = b = function () {
975                L(a, {left: 0, top: 0});
976                h = a.getBoundingClientRect();
977                L(a, {left: sa(h.left) - h.left + "px", top: sa(h.top) - h.top + "px"})
978            }, b(), H(K, "resize", b)
979        }, getStyle: function (a) {
980            return this.style = r({
981                fontFamily: '"Lucida Grande", "Lucida Sans Unicode", Arial, Helvetica, sans-serif',
982                fontSize: "12px"
983            }, a)
984        }, isHidden: function () {
985            return !this.boxWrapper.getBBox().width
986        }, destroy: function () {
987            var a = this.defs;
988            this.box = null;
989            this.boxWrapper = this.boxWrapper.destroy();
990            Oa(this.gradients || {});
991            this.gradients = null;
992            if (a)this.defs = a.destroy();
993            this.subPixelFix && Z(K, "resize", this.subPixelFix);
994            return this.alignedObjects = null
995        }, createElement: function (a) {
996            var b = new this.Element;
997            b.init(this, a);
998            return b
999        }, draw: function () {
1000        }, buildText: function (a) {
1001            for (var b = a.element, c = this, d = c.forExport, e = p(a.textStr, "").toString(), f = e.indexOf("<") !== -1, g = b.childNodes, h, i, j = J(b, "x"), k = a.styles, m = a.textWidth, l = k && k.lineHeight, n = k && k.textShadow,
1002                     q = k && k.textOverflow === "ellipsis", x = g.length, T = m && !a.added && this.box, Q = function (a) {
1003                    return l ? F(l) : c.fontMetrics(/(px|em)$/.test(a && a.style.fontSize) ? a.style.fontSize : k && k.fontSize || c.style.fontSize || 12, a).h
1004                }, u = function (a) {
1005                    return a.replace(/&lt;/g, "<").replace(/&gt;/g, ">")
1006                }; x--;)b.removeChild(g[x]);
1007            !f && !n && !q && e.indexOf(" ") === -1 ? b.appendChild(C.createTextNode(u(e))) : (h = /<.*style="([^"]+)".*>/, i = /<.*href="(http[^"]+)".*>/, T && T.appendChild(b), e = f ? e.replace(/<(b|strong)>/g, '<span style="font-weight:bold">').replace(/<(i|em)>/g,
1008                '<span style="font-style:italic">').replace(/<a/g, "<span").replace(/<\/(b|strong|i|em|a)>
1008/g, "</span>").split(/<br.*?>/g) : [e], e[e.length - 1] === "" && e.pop(), o(e, function (e, f) {
1009                var g, l = 0, e = e.replace(/<span/g, "|||<span").replace(/<\/span>/g, "</span>|||");
1010                g = e.split("|||");
1011                o(g, function (e) {
1012                    if (e !== "" || g.length === 1) {
1013                        var n = {}, x = C.createElementNS(Da, "tspan"), p;
1014                        h.test(e) && (p = e.match(h)[1].replace(/(;| |^)color([ :])/, "$1fill$2"), J(x, "style", p));
1015                        i.test(e) && !d && (J(x, "onclick", 'location.href="' + e.match(i)[1] + '"'),
1016                            L(x, {cursor: "pointer"}));
1017                        e = u(e.replace(/<(.|\n)*?>/g, "") || " ");
1018                        if (e !== " ") {
1019                            x.appendChild(C.createTextNode(e));
1020                            if (l)n.dx = 0; else if (f && j !== null)n.x = j;
1021                            J(x, n);
1022                            b.appendChild(x);
1023                            !l && f && (!ca && d && L(x, {display: "block"}), J(x, "dy", Q(x)));
1024                            if (m) {
1025                                for (var n = e.replace(/([^\^])-/g, "$1- ").split(" "), o = g.length > 1 || f || n.length > 1 && k.whiteSpace !== "nowrap", T, y, s, t = [], v = Q(x), w = 1, r = a.rotation, z = e, A = z.length; (o || q) && (n.length || t.length);)a.rotation = 0, T = a.getBBox(!0), s = T.width, !ca && c.forExport && (s = c.measureSpanWidth(x.firstChild.data,
1026                                    a.styles)), T = s > m, y === void 0 && (y = T), q && y ? (A /= 2, z === "" || !T && A < 0.5 ? n = [] : (T && (y = !0), z = e.substring(0, z.length + (T ? -1 : 1) * sa(A)), n = [z + (m > 3 ? "\u2026" : "")], x.removeChild(x.firstChild))) : !T || n.length === 1 ? (n = t, t = [], n.length && (w++, x = C.createElementNS(Da, "tspan"), J(x, {
1027                                    dy: v,
1028                                    x: j
1029                                }), p && J(x, "style", p), b.appendChild(x)), s > m && (m = s)) : (x.removeChild(x.firstChild), t.unshift(n.pop())), n.length && x.appendChild(C.createTextNode(n.join(" ").replace(/- /g, "-")));
1030                                y && a.attr("title", a.textStr);
1031                                a.rotation = r
1032                            }
1033                            l++
1034                        }
1035                    }
1036                })
1037            }), T && T.removeChild(b),
1038            n && a.applyTextShadow && a.applyTextShadow(n))
1039        }, getContrast: function (a) {
1040            a = na(a).rgba;
1041            return a[0] + a[1] + a[2] > 384 ? "#000000" : "#FFFFFF"
1042        }, button: function (a, b, c, d, e, f, g, h, i) {
1043            var j = this.label(a, b, c, i, null, null, null, null, "button"), k = 0, m, l, n, q, x, p, a = {
1044                x1: 0,
1045                y1: 0,
1046                x2: 0,
1047                y2: 1
1048            }, e = A({
1049                "stroke-width": 1,
1050                stroke: "#CCCCCC",
1051                fill: {linearGradient: a, stops: [[0, "#FEFEFE"], [1, "#F6F6F6"]]},
1052                r: 2,
1053                padding: 5,
1054                style: {color: "black"}
1055            }, e);
1056            n = e.style;
1057            delete e.style;
1058            f = A(e, {stroke: "#68A", fill: {linearGradient: a, stops: [[0, "#FFF"], [1, "#ACF"]]}}, f);
1059            q = f.style;
1060            delete f.style;
1061            g = A(e, {stroke: "#68A", fill: {linearGradient: a, stops: [[0, "#9BD"], [1, "#CDF"]]}}, g);
1062            x = g.style;
1063            delete g.style;
1064            h = A(e, {style: {color: "#CCC"}}, h);
1065            p = h.style;
1066            delete h.style;
1067            H(j.element, xa ? "mouseover" : "mouseenter", function () {
1068                k !== 3 && j.attr(f).css(q)
1069            });
1070            H(j.element, xa ? "mouseout" : "mouseleave", function () {
1071                k !== 3 && (m = [e, f, g][k], l = [n, q, x][k], j.attr(m).css(l))
1072            });
1073            j.setState = function (a) {
1074                (j.state = k = a) ? a === 2 ? j.attr(g).css(x) : a === 3 && j.attr(h).css(p) : j.attr(e).
1074css(n)
1075            };
1076            return j.on("click", function (a) {
1077                k !==
1078                3 && d.call(j, a)
1079            }).attr(e).css(r({cursor: "default"}, n))
1080        }, crispLine: function (a, b) {
1081            a[1] === a[4] && (a[1] = a[4] = w(a[1]) - b % 2 / 2);
1082            a[2] === a[5] && (a[2] = a[5] = w(a[2]) + b % 2 / 2);
1083            return a
1084        }, path: function (a) {
1085            var b = {fill: O};
1086            Fa(a) ? b.d = a : da(a) && r(b, a);
1087            return this.createElement("path").attr(b)
1088        }, circle: function (a, b, c) {
1089            a = da(a) ? a : {x: a, y: b, r: c};
1090            b = this.createElement("circle");
1091            b.xSetter = function (a) {
1092                this.element.setAttribute("cx", a)
1093            };
1094            b.ySetter = function (a) {
1095                this.element.setAttribute("cy", a)
1096            };
1097            return b.attr(a)
1098        }, arc: function (a, b, c, d, e,
1099                          f) {
1100            if (da(a))b = a.y, c = a.r, d = a.innerR, e = a.start, f = a.end, a = a.x;
1101            a = this.symbol("arc", a || 0, b || 0, c || 0, c || 0, {innerR: d || 0, start: e || 0, end: f || 0});
1102            a.r = c;
1103            return a
1104        }, rect: function (a, b, c, d, e, f) {
1105            var e = da(a) ? a.r : e, g = this.createElement("rect"), a = da(a) ? a : a === v ? {} : {
1106                x: a,
1107                y: b,
1108                width: t(c, 0),
1109                height: t(d, 0)
1110            };
1111            if (f !== v)a.strokeWidth = f, a = g.crisp(a);
1112            if (e)a.r = e;
1113            g.rSetter = function (a) {
1114                J(this.element, {rx: a, ry: a})
1115            };
1116            return g.attr(a)
1117        }, setSize: function (a, b, c) {
1118            var d = this.alignedObjects, e = d.length;
1119            this.width = a;
1120            this.height = b;
1121            for (this.boxWrapper[p(c,
1122                !0) ? "animate" : "attr"]({width: a, height: b}); e--;)d[e].align()
1123        }, g: function (a) {
1124            var b = this.createElement("g");
1125            return s(a) ? b.attr({"class": "highcharts-" + a}) : b
1126        }, image: function (a, b, c, d, e) {
1127            var f = {preserveAspectRatio: O};
1128            arguments.length > 1 && r(f, {x: b, y: c, width: d, height: e});
1129            f = this.createElement("image").attr(f);
1130            f.element.setAttributeNS ? f.element.setAttributeNS("http://www.w3.org/1999/xlink", "href", a) : f.element.setAttribute("hc-svg-href", a);
1131            return f
1132        }, symbol: function (a, b, c, d, e, f) {
1133            var g, h = this.symbols[a], h = h && h(w(b),
1134                    w(c), d, e, f), i = /^url\((.*?)\)$/, j, k;
1135            if (h)g = this.path(h), r(g, {
1136                symbolName: a,
1137                x: b,
1138                y: c,
1139                width: d,
1140                height: e
1141            }), f && r(g, f); else if (i.test(a))k = function (a, b) {
1142                a.element && (a.attr({
1143                    width: b[0],
1144                    height: b[1]
1145                }), a.alignByTranslate || a.translate(w((d - b[0]) / 2), w((e - b[1]) / 2)))
1146            }, j = a.match(i)[1], a = Kb[j] || f && f.width && f.height && [f.width, f.height], g = this.image(j).attr({
1147                x: b,
1148                y: c
1149            }), g.isImg = !0, a ? k(g, a) : (g.attr({width: 0, height: 0}), $("img", {
1150                onload: function () {
1151                    k(g, Kb[j] = [this.width, this.height])
1152                }, src: j
1153            }));
1154            return g
1155        }, symbols: {
1156            circle: function (a,
1157                              b, c, d) {
1158                var e = 0.166 * c;
1159                return ["M", a + c / 2, b, "C", a + c + e, b, a + c + e, b + d, a + c / 2, b + d, "C", a - e, b + d, a - e, b, a + c / 2, b, "Z"]
1160            }, square: function (a, b, c, d) {
1161                return ["M", a, b, "L", a + c, b, a + c, b + d, a, b + d, "Z"]
1162            }, triangle: function (a, b, c, d) {
1163                return ["M", a + c / 2, b, "L", a + c, b + d, a, b + d, "Z"]
1164            }, "triangle-down": function (a, b, c, d) {
1165                return ["M", a, b, "L", a + c, b, a + c / 2, b + d, "Z"]
1166            }, diamond: function (a, b, c, d) {
1167                return ["M", a + c / 2, b, "L", a + c, b + d / 2, a + c / 2, b + d, a, b + d / 2, "Z"]
1168            }, arc: function (a, b, c, d, e) {
1169                var f = e.start, c = e.r || c || d, g = e.end - 0.001, d = e.innerR, h = e.open, i = X(f), j = aa(f),
1170                    k = X(g), g = aa(g), e = e.end - f < ma ? 0 : 1;
1171                return ["M", a + c * i, b + c * j, "A", c, c, 0, e, 1, a + c * k, b + c * g, h ? "M" : "L", a + d * k, b + d * g, "A", d, d, 0, e, 0, a + d * i, b + d * j, h ? "" : "Z"]
1172            }, callout: function (a, b, c, d, e) {
1173                var f = z(e && e.r || 0, c, d), g = f + 6, h = e && e.anchorX, e = e && e.anchorY, i;
1174                i = ["M", a + f, b, "L", a + c - f, b, "C", a + c, b, a + c, b, a + c, b + f, "L", a + c, b + d - f, "C", a + c, b + d, a + c, b + d, a + c - f, b + d, "L", a + f, b + d, "C", a, b + d, a, b + d, a, b + d - f, "L", a, b + f, "C", a, b, a, b, a + f, b];
1175                h && h > c && e > b + g && e < b + d - g ? i.splice(13, 3, "L", a + c, e - 6, a + c + 6, e, a + c, e + 6, a + c, b + d - f) : h && h < 0 && e > b + g && e < b + d - g ? i.splice(33, 3, "L",
1176                    a, e + 6, a - 6, e, a, e - 6, a, b + f) : e && e > d && h > a + g && h < a + c - g ? i.splice(23, 3, "L", h + 6, b + d, h, b + d + 6, h - 6, b + d, a + f, b + d) : e && e < 0 && h > a + g && h < a + c - g && i.splice(3, 3, "L", h - 6, b, h, b - 6, h + 6, b, c - f, b);
1177                return i
1178            }
1179        }, clipRect: function (a, b, c, d) {
1180            var e = "highcharts-" + wb++, f = this.createElement("clipPath").attr({id: e}).add(this.defs), a = this.rect(a, b, c, d, 0).add(f);
1181            a.id = e;
1182            a.clipPath = f;
1183            a.count = 0;
1184            return a
1185        }, text: function (a, b, c, d) {
1186            var e = fa || !ca && this.forExport, f = {};
1187            if (d && !this.forExport)return this.html(a, b, c);
1188            f.x = Math.round(b || 0);
1189            if (c)f.y = Math.round(c);
1190            if (a || a === 0)f.text = a;
1191            a = this.createElement("text").attr(f);
1192            e && a.css({position: "absolute"});
1193            if (!d)a.xSetter = function (a, b, c) {
1194                var d = c.getElementsByTagName("tspan"), e, f = c.getAttribute(b), l;
1195                for (l = 0; l < d.length; l++)e = d[l], e.getAttribute(b) === f && e.setAttribute(b, a);
1196                c.setAttribute(b, a)
1197            };
1198            return a
1199        }, fontMetrics: function (a, b) {
1200            var c, d, a = a || this.style.fontSize;
1201            b && K.getComputedStyle && (b = b.element || b, a = (c = K.getComputedStyle(b, "")) && c.fontSize);
1202            a = /px/.test(a) ? F(a) : /em/.test(a) ? parseFloat(a) * 12 : 12;
1203            c = a < 24 ? a + 3 : w(a * 1.2);
1204            d = w(c * 0.8);
1205            return {h: c, b: d, f: a}
1206        }, rotCorr: function (a, b, c) {
1207            var d = a;
1208            b && c && (d = t(d * X(b * ga), 4));
1209            return {x: -a / 3 * aa(b * ga), y: d}
1210        }, label: function (a, b, c, d, e, f, g, h, i) {
1211            function j() {
1212                var a, b;
1213                a = q.element.style;
1214                p = (t === void 0 || yb === void 0 || n.styles.textAlign) && s(q.textStr) && q.getBBox();
1215                n.width = (t || p.width || 0) + 2 * u + y;
1216                n.height = (yb || p.height || 0) + 2 * u;
1217                B = u + l.fontMetrics(a && a.fontSize, q).b;
1218                if (D) {
1219                    if (!x)a = w(-Q * u) + C, b = (h ? -B : 0) + C, n.box = x = d ? l.symbol(d, a, b, n.width, n.height, G) : l.rect(a, b, n.width, n.height, 0, G[Pb]), x.isImg || x.attr("fill",
1220                        O), x.add(n);
1221                    x.isImg || x.attr(r({width: w(n.width), height: w(n.height)}, G));
1222                    G = null
1223                }
1224            }
1225
1226            function k() {
1227                var a = n.styles, a = a && a.textAlign, b = y + u * (1 - Q), c;
1228                c = h ? 0 : B;
1229                if (s(t) && p && (a === "center" || a === "right"))b += {center: 0.5, right: 1}[a] * (t - p.width);
1230                if (b !== q.x || c !== q.y)q.attr("x", b), c !== v && q.attr("y", c);
1231                q.x = b;
1232                q.y = c
1233            }
1234
1235            function m(a, b) {
1236                x ? x.attr(a, b) : G[a] = b
1237            }
1238
1239            var l = this, n = l.g(i), q = l.text("", 0, 0, g).attr({zIndex: 1}), x, p, Q = 0, u = 3, y = 0, t, yb, zb, z, C = 0, G = {}, B, D;
1240            n.onAdd = function () {
1241                q.add(n);
1242                n.attr({text: a || a === 0 ? a : "", x: b, y: c});
1243                x && s(e) && n.attr({
1244                    anchorX: e,
1245                    anchorY: f
1246                })
1247            };
1248            n.widthSetter = function (a) {
1249                t = a
1250            };
1251            n.heightSetter = function (a) {
1252                yb = a
1253            };
1254            n.paddingSetter = function (a) {
1255                if (s(a) && a !== u)u = n.padding = a, k()
1256            };
1257            n.paddingLeftSetter = function (a) {
1258                s(a) && a !== y && (y = a, k())
1259            };
1260            n.alignSetter = function (a) {
1261                Q = {left: 0, center: 0.5, right: 1}[a]
1262            };
1263            n.textSetter = function (a) {
1264                a !== v && q.textSetter(a);
1265                j();
1266                k()
1267            };
1268            n["stroke-widthSetter"] = function (a, b) {
1269                a && (D = !0);
1270                C = a % 2 / 2;
1271                m(b, a)
1272            };
1273            n.strokeSetter = n.fillSetter = n.rSetter = function (a, b) {
1274                b === "fill" && a && (D = !0);
1275                m(b, a)
1276            };
1277            n.anchorXSetter = function (a, b) {
1278                e = a;
1279                m(b, w(a) -
1280                    C - zb)
1281            };
1282            n.anchorYSetter = function (a, b) {
1283                f = a;
1284                m(b, a - z)
1285            };
1286            n.xSetter = function (a) {
1287                n.x = a;
1288                Q && (a -= Q * ((t || p.width) + u));
1289                zb = w(a);
1290                n.attr("translateX", zb)
1291            };
1292            n.ySetter = function (a) {
1293                z = n.y = w(a);
1294                n.attr("translateY", z)
1295            };
1296            var F = n.css;
1297            return r(n, {
1298                css: function (a) {
1299                    if (a) {
1300                        var b = {}, a = A(a);
1301                        o(n.textProps, function (c) {
1302                            a[c] !== v && (b[c] = a[c], delete a[c])
1303                        });
1304                        q.css(b)
1305                    }
1306                    return F.call(n, a)
1307                }, getBBox: function () {
1308                    return {width: p.width + 2 * u, height: p.height + 2 * u, x: p.x - u, y: p.y - u}
1309                }, shadow: function (a) {
1310                    x && x.shadow(a);
1311                    return n
1312                }, destroy: function () {
1313                    Z(n.element,
1314                        "mouseenter");
1315                    Z(n.element, "mouseleave");
1316                    q && (q = q.destroy());
1317                    x && (x = x.destroy());
1318                    P.prototype.destroy.call(n);
1319                    n = l = j = k = m = null
1320                }
1321            })
1322        }
1323    };
1324    Za = ua;
1325    r(P.prototype, {
1326        htmlCss: function (a) {
1327            var b = this.element;
1328            if (b = a && b.tagName === "SPAN" && a.width)delete a.width, this.textWidth = b, this.updateTransform();
1329            if (a && a.textOverflow === "ellipsis")a.whiteSpace = "nowrap", a.overflow = "hidden";
1330            this.styles = r(this.styles, a);
1331            L(this.element, a);
1332            return this
1333        }, htmlGetBBox: function () {
1334            var a = this.element;
1335            if (a.nodeName === "text")a.style.position = "absolute";
1336            return {x: a.offsetLeft, y: a.offsetTop, width: a.offsetWidth, height: a.offsetHeight}
1337        }, htmlUpdateTransform: function () {
1338            if (this.added) {
1339                var a = this.renderer, b = this.element, c = this.translateX || 0, d = this.translateY || 0, e = this.x || 0, f = this.y || 0, g = this.textAlign || "left", h = {
1340                    left: 0,
1341                    center: 0.5,
1342                    right: 1
1343                }[g], i = this.shadows, j = this.styles;
1344                L(b, {marginLeft: c, marginTop: d});
1345                i && o(i, function (a) {
1346                    L(a, {marginLeft: c + 1, marginTop: d + 1})
1347                });
1348                this.inverted && o(b.childNodes, function (c) {
1349                    a.invertChild(c, b)
1350                });
1351                if (b.tagName === "SPAN") {
1352                    var k = this.rotation,
1353                        m, l = F(this.textWidth), n = [k, g, b.innerHTML, this.textWidth, this.textAlign].join(",");
1354                    if (n !== this.cTT) {
1355                        m = a.fontMetrics(b.style.fontSize).b;
1356                        s(k) && this.setSpanRotation(k, h, m);
1357                        i = p(this.elemWidth, b.offsetWidth);
1358                        if (i > l && /[ \-]/.test(b.textContent || b.innerText))L(b, {
1359                            width: l + "px",
1360                            display: "block",
1361                            whiteSpace: j && j.whiteSpace || "normal"
1362                        }), i = l;
1363                        this.getSpanCorrection(i, m, h, k, g)
1364                    }
1365                    L(b, {left: e + (this.xCorr || 0) + "px", top: f + (this.yCorr || 0) + "px"});
1366                    if (fb)m = b.offsetHeight;
1367                    this.cTT = n
1368                }
1369            } else this.alignOnAdd = !0
1370        }, setSpanRotation: function (a,
1371                                      b, c) {
1372            var d = {}, e = xa ? "-ms-transform" : fb ? "-webkit-transform" : Ja ? "MozTransform" : Ib ? "-o-transform" : "";
1373            d[e] = d.transform = "rotate(" + a + "deg)";
1374            d[e + (Ja ? "Origin" : "-origin")] = d.transformOrigin = b * 100 + "% " + c + "px";
1375            L(this.element, d)
1376        }, getSpanCorrection: function (a, b, c) {
1377            this.xCorr = -a * c;
1378            this.yCorr = -b
1379        }
1380    });
1381    r(ua.prototype, {
1382        html: function (a, b, c) {
1383            var d = this.createElement("span"), e = d.element, f = d.renderer;
1384            d.textSetter = function (a) {
1385                a !== e.innerHTML && delete this.bBox;
1386                e.innerHTML = this.textStr = a;
1387                d.htmlUpdateTransform()
1388            };
1389            d.xSetter = d.ySetter =
1390                d.alignSetter = d.rotationSetter = function (a, b) {
1391                    b === "align" && (b = "textAlign");
1392                    d[b] = a;
1393                    d.htmlUpdateTransform()
1394                };
1395            d.attr({text: a, x: w(b), y: w(c)}).css({
1396                position: "absolute",
1397                fontFamily: this.style.fontFamily,
1398                fontSize: this.style.fontSize
1399            });
1400            e.style.whiteSpace = "nowrap";
1401            d.css = d.htmlCss;
1402            if (f.isSVG)d.add = function (a) {
1403                var b, c = f.box.parentNode, j = [];
1404                if (this.parentGroup = a) {
1405                    if (b = a.div, !b) {
1406                        for (; a;)j.push(a), a = a.parentGroup;
1407                        o(j.reverse(), function (a) {
1408                            var d, e = J(a.element, "class");
1409                            e && (e = {className: e});
1410                            b = a.div = a.div || $(Ia, e, {
1411                                    position: "absolute",
1412                                    left: (a.translateX || 0) + "px", top: (a.translateY || 0) + "px"
1413                                }, b || c);
1414                            d = b.style;
1415                            r(a, {
1416                                translateXSetter: function (b, c) {
1417                                    d.left = b + "px";
1418                                    a[c] = b;
1419                                    a.doTransform = !0
1420                                }, translateYSetter: function (b, c) {
1421                                    d.top = b + "px";
1422                                    a[c] = b;
1423                                    a.doTransform = !0
1424                                }
1425                            });
1426                            Sa(a, "visibilitySetter", function (a, b, c, e) {
1427                                a.call(this, b, c, e);
1428                                d[c] = b
1429                            })
1430                        })
1431                    }
1432                } else b = c;
1433                b.appendChild(e);
1434                d.added = !0;
1435                d.alignOnAdd && d.htmlUpdateTransform();
1436                return d
1437            };
1438            return d
1439        }
1440    });
1441    if (!ca && !fa) {
1442        D = {
1443            init: function (a, b) {
1444                var c = ["<", b, ' filled="f" stroked="f"'], d = ["position: ", "absolute", ";"], e = b ===
1445                    Ia;
1446                (b === "shape" || e) && d.push("left:0;top:0;width:1px;height:1px;");
1447                d.push("visibility: ", e ? "hidden" : "visible");
1448                c.push(' style="', d.join(""), '"/>');
1449                if (b)c = e || b === "span" || b === "img" ? c.join("") : a.prepVML(c), this.element = $(c);
1450                this.renderer = a
1451            }, add: function (a) {
1452                var b = this.renderer, c = this.element, d = b.box, d = a ? a.element || a : d;
1453                a && a.inverted && b.invertChild(c, d);
1454                d.appendChild(c);
1455                this.added = !0;
1456                this.alignOnAdd && !this.deferUpdateTransform && this.updateTransform();
1457                if (this.onAdd)this.onAdd();
1458                return this
1459            }, updateTransform: P.prototype.htmlUpdateTransform,
1460            setSpanRotation: function () {
1461                var a = this.rotation, b = X(a * ga), c = aa(a * ga);
1462                L(this.element, {filter: a ? ["progid:DXImageTransform.Microsoft.Matrix(M11=", b, ", M12=", -c, ", M21=", c, ", M22=", b, ", sizingMethod='auto expand')"].join("") : O})
1463            }, getSpanCorrection: function (a, b, c, d, e) {
1464                var f = d ? X(d * ga) : 1, g = d ? aa(d * ga) : 0, h = p(this.elemHeight, this.element.offsetHeight), i;
1465                this.xCorr = f < 0 && -a;
1466                this.yCorr = g < 0 && -h;
1467                i = f * g < 0;
1468                this.xCorr += g * b * (i ? 1 - c : c);
1469                this.yCorr -= f * b * (d ? i ? c : 1 - c : 1);
1470                e && e !== "left" && (this.xCorr -= a * c * (f < 0 ? -1 : 1), d && (this.yCorr -=
1471                    h * c * (g < 0 ? -1 : 1)), L(this.element, {textAlign: e}))
1472            }, pathToVML: function (a) {
1473                for (var b = a.length, c = []; b--;)if (qa(a[b]))c[b] = w(a[b] * 10) - 5; else if (a[b] === "Z")c[b] = "x"; else if (c[b] = a[b], a.isArc && (a[b] === "wa" || a[b] === "at"))c[b + 5] === c[b + 7] && (c[b + 7] += a[b + 7] > a[b + 5] ? 1 : -1), c[b + 6] === c[b + 8] && (c[b + 8] += a[b + 8] > a[b + 6] ? 1 : -1);
1474                return c.join(" ") || "x"
1475            }, clip: function (a) {
1476                var b = this, c;
1477                a ? (c = a.members, ja(c, b), c.push(b), b.destroyClip = function () {
1478                    ja(c, b)
1479                }, a = a.getCSS(b)) : (b.destroyClip && b.destroyClip(), a = {clip: eb ? "inherit" : "rect(auto)"});
1480                return b.css(a)
1481            }, css: P.prototype.htmlCss, safeRemoveChild: function (a) {
1482                a.parentNode && Pa(a)
1483            }, destroy: function () {
1484                this.destroyClip && this.destroyClip();
1485                return P.prototype.destroy.apply(this)
1486            }, on: function (a, b) {
1487                this.element["on" + a] = function () {
1488                    var a = K.event;
1489                    a.target = a.srcElement;
1490                    b(a)
1491                };
1492                return this
1493            }, cutOffPath: function (a, b) {
1494                var c, a = a.split(/[ ,]/);
1495                c = a.length;
1496                if (c === 9 || c === 11)a[c - 4] = a[c - 2] = F(a[c - 2]) - 10 * b;
1497                return a.join(" ")
1498            }, shadow: function (a, b, c) {
1499                var d = [], e, f = this.element, g = this.renderer, h, i = f.style, j, k = f.path,
1500                    m, l, n, q;
1501                k && typeof k.value !== "string" && (k = "x");
1502                l = k;
1503                if (a) {
1504                    n = p(a.width, 3);
1505                    q = (a.opacity || 0.15) / n;
1506                    for (e = 1; e <= 3; e++) {
1507                        m = n * 2 + 1 - 2 * e;
1508                        c && (l = this.cutOffPath(k.value, m + 0.5));
1509                        j = ['<shape isShadow="true" strokeweight="', m, '" filled="false" path="', l, '" coordsize="10 10" style="', f.style.cssText, '" />'];
1510                        h = $(g.prepVML(j), null, {left: F(i.left) + p(a.offsetX, 1), top: F(i.top) + p(a.offsetY, 1)});
1511                        if (c)h.cutOff = m + 1;
1512                        j = ['<stroke color="', a.color || "black", '" opacity="', q * e, '"/>'];
1513                        $(g.prepVML(j), null, null, h);
1514                        b ? b.element.appendChild(h) :
1515                            f.parentNode.insertBefore(h, f);
1516                        d.push(h)
1517                    }
1518                    this.shadows = d
1519                }
1520                return this
1521            }, updateShadows: ta, setAttr: function (a, b) {
1522                eb ? this.element[a] = b : this.element.setAttribute(a, b)
1523            }, classSetter: function (a) {
1524                this.element.className = a
1525            }, dashstyleSetter: function (a, b, c) {
1526                (c.getElementsByTagName("stroke")[0] || $(this.renderer.prepVML(["<stroke/>"]), null, null, c))[b] = a || "solid";
1527                this[b] = a
1528            }, dSetter: function (a, b, c) {
1529                var d = this.shadows, a = a || [];
1530                this.d = a.join && a.join(" ");
1531                c.path = a = this.pathToVML(a);
1532                if (d)for (c = d.length; c--;)d[c].path = d[c].cutOff ?
1533                    this.cutOffPath(a, d[c].cutOff) : a;
1534                this.setAttr(b, a)
1535            }, fillSetter: function (a, b, c) {
1536                var d = c.nodeName;
1537                if (d === "SPAN")c.style.color = a; else if (d !== "IMG")c.filled = a !== O, this.setAttr("fillcolor", this.renderer.color(a, c, b, this))
1538            }, opacitySetter: ta, rotationSetter: function (a, b, c) {
1539                c = c.style;
1540                this[b] = c[b] = a;
1541                c.left = -w(aa(a * ga) + 1) + "px";
1542                c.top = w(X(a * ga)) + "px"
1543            }, strokeSetter: function (a, b, c) {
1544                this.setAttr("strokecolor", this.renderer.color(a, c, b))
1545            }, "stroke-widthSetter": function (a, b, c) {
1546                c.stroked = !!a;
1547                this[b] = a;
1548                qa(a) && (a += "px");
1549                this.setAttr("strokeweight", a)
1550            }, titleSetter: function (a, b) {
1551                this.setAttr(b, a)
1552            }, visibilitySetter: function (a, b, c) {
1553                a === "inherit" && (a = "visible");
1554                this.shadows && o(this.shadows, function (c) {
1555                    c.style[b] = a
1556                });
1557                c.nodeName === "DIV" && (a = a === "hidden" ? "-999em" : 0, eb || (c.style[b] = a ? "visible" : "hidden"), b = "top");
1558                c.style[b] = a
1559            }, xSetter: function (a, b, c) {
1560                this[b] = a;
1561                b === "x" ? b = "left" : b === "y" && (b = "top");
1562                this.updateClipping ? (this[b] = a, this.updateClipping()) : c.style[b] = a
1563            }, zIndexSetter: function (a, b, c) {
1564                c.style[b] = a
1565            }
1566        };
1567        B.VMLElement = D = ka(P,
1568            D);
1569        D.prototype.ySetter = D.prototype.widthSetter = D.prototype.heightSetter = D.prototype.xSetter;
1570        var La = {
1571            Element: D, isIE8: za.indexOf("MSIE 8.0") > -1, init: function (a, b, c, d) {
1572                var e;
1573                this.alignedObjects = [];
1574                d = this.createElement(Ia).css(r(this.getStyle(d), {position: "relative"}));
1575                e = d.element;
1576                a.appendChild(d.element);
1577                this.isVML = !0;
1578                this.box = e;
1579                this.boxWrapper = d;
1580                this.cache = {};
1581                this.setSize(b, c, !1);
1582                if (!C.namespaces.hcv) {
1583                    C.namespaces.add("hcv", "urn:schemas-microsoft-com:vml");
1584                    try {
1585                        C.createStyleSheet().cssText = "hcv\\:fill, hcv\\:path, hcv\\:sh
1585ape, hcv\\:stroke{ behavior:url(#default#VML); display: inline-block; } "
1586                    } catch (f) {
1587                        C.styleSheets[0].cssText +=
1588                            "hcv\\:fill, hcv\\:path, hcv\\:shape, hcv\\:stroke{ behavior:url(#default#VML); display: inline-block; } "
1589                    }
1590                }
1591            }, isHidden: function () {
1592                return !this.box.offsetWidth
1593            }, clipRect: function (a, b, c, d) {
1594                var e = this.createElement(), f = da(a);
1595                return r(e, {
1596                    members: [],
1597                    count: 0,
1598                    left: (f ? a.x : a) + 1,
1599                    top: (f ? a.y : b) + 1,
1600                    width: (f ? a.width : c) - 1,
1601                    height: (f ? a.height : d) - 1,
1602                    getCSS: function (a) {
1603                        var b = a.element, c = b.nodeName, a = a.inverted, d = this.top - (c === "shape" ? b.offsetTop : 0), e = this.left, b = e + this.width, f = d + this.height, d = {
1604                            clip: "rect(" + w(a ? e : d) + "px," +
1605                            w(a ? f : b) + "px," + w(a ? b : f) + "px," + w(a ? d : e) + "px)"
1606                        };
1607                        !a && eb && c === "DIV" && r(d, {width: b + "px", height: f + "px"});
1608                        return d
1609                    },
1610                    updateClipping: function () {
1611                        o(e.members, function (a) {
1612                            a.element && a.css(e.getCSS(a))
1613                        })
1614                    }
1615                })
1616            }, color: function (a, b, c, d) {
1617                var e = this, f, g = /^rgba/, h, i, j = O;
1618                a && a.linearGradient ? i = "gradient" : a && a.radialGradient && (i = "pattern");
1619                if (i) {
1620                    var k, m, l = a.linearGradient || a.radialGradient, n, q, x, p, Q, u = "", a = a.stops, y, t = [], s = function () {
1621                        h = ['<fill colors="' + t.join(",") + '" opacity="', x, '" o:opacity2="', q, '" type="', i, '" ', u,
1622                            'focus="100%" method="any" />'];
1623                        $(e.prepVML(h), null, null, b)
1624                    };
1625                    n = a[0];
1626                    y = a[a.length - 1];
1627                    n[0] > 0 && a.unshift([0, n[1]]);
1628                    y[0] < 1 && a.push([1, y[1]]);
1629                    o(a, function (a, b) {
1630                        g.test(a[1]) ? (f = na(a[1]), k = f.get("rgb"), m = f.get("a")) : (k = a[1], m = 1);
1631                        t.push(a[0] * 100 + "% " + k);
1632                        b ? (x = m, p = k) : (q = m, Q = k)
1633                    });
1634                    if (c === "fill")if (i === "gradient")c = l.x1 || l[0] || 0, a = l.y1 || l[1] || 0, n = l.x2 || l[2] || 0, l = l.y2 || l[3] || 0, u = 'angle="' + (90 - W.atan((l - a) / (n - c)) * 180 / ma) + '"', s(); else {
1635                        var j = l.r, v = j * 2, w = j * 2, r = l.cx, z = l.cy, A = b.radialReference, C, j = function () {
1636                            A && (C = d.getBBox(),
1637                                r += (A[0] - C.x) / C.width - 0.5, z += (A[1] - C.y) / C.height - 0.5, v *= A[2] / C.width, w *= A[2] / C.height);
1638                            u = 'src="' + S.global.VMLRadialGradientURL + '" size="' + v + "," + w + '" origin="0.5,0.5" position="' + r + "," + z + '" color2="' + Q + '" ';
1639                            s()
1640                        };
1641                        d.added ? j() : d.onAdd = j;
1642                        j = p
1643                    } else j = k
1644                } else if (g.test(a) && b.tagName !== "IMG")f = na(a), h = ["<", c, ' opacity="', f.get("a"), '"/>'], $(this.prepVML(h), null, null, b), j = f.get("rgb"); else {
1645                    j = b.getElementsByTagName(c);
1646                    if (j.length)j[0].opacity = 1, j[0].type = "solid";
1647                    j = a
1648                }
1649                return j
1650            }, prepVML: function (a) {
1651                var b = this.isIE8,
1652                    a = a.join("");
1653                b ? (a = a.replace("/>", ' xmlns="urn:schemas-microsoft-com:vml" />'), a = a.indexOf('style="') === -1 ? a.replace("/>", ' style="display:inline-block;behavior:url(#default#VML);" />') : a.replace('style="', 'style="display:inline-block;behavior:url(#default#VML);')) : a = a.replace("<", "<hcv:");
1654                return a
1655            }, text: ua.prototype.html, path: function (a) {
1656                var b = {coordsize: "10 10"};
1657                Fa(a) ? b.d = a : da(a) && r(b, a);
1658                return this.createElement("shape").attr(b)
1659            }, circle: function (a, b, c) {
1660                var d = this.symbol("circle");
1661                if (da(a))c = a.r,
1662                    b = a.y, a = a.x;
1663                d.isCircle = !0;
1664                d.r = c;
1665                return d.attr({x: a, y: b})
1666            }, g: function (a) {
1667                var b;
1668                a && (b = {className: "highcharts-" + a, "class": "highcharts-" + a});
1669                return this.createElement(Ia).attr(b)
1670            }, image: function (a, b, c, d, e) {
1671                var f = this.createElement("img").attr({src: a});
1672                arguments.length > 1 && f.attr({x: b, y: c, width: d, height: e});
1673                return f
1674            }, createElement: function (a) {
1675                return a === "rect" ? this.symbol(a) : ua.prototype.createElement.call(this, a)
1676            }, invertChild: function (a, b) {
1677                var c = this, d = b.style, e = a.tagName === "IMG" && a.style;
1678                L(a, {
1679                    flip: "x",
1680                    left: F(d.width) - (e ? F(e.top) : 1), top: F(d.height) - (e ? F(e.left) : 1), rotation: -90
1681                });
1682                o(a.childNodes, function (b) {
1683                    c.invertChild(b, a)
1684                })
1685            }, symbols: {
1686                arc: function (a, b, c, d, e) {
1687                    var f = e.start, g = e.end, h = e.r || c || d, c = e.innerR, d = X(f), i = aa(f), j = X(g), k = aa(g);
1688                    if (g - f === 0)return ["x"];
1689                    f = ["wa", a - h, b - h, a + h, b + h, a + h * d, b + h * i, a + h * j, b + h * k];
1690                    e.open && !c && f.push("e", "M", a, b);
1691                    f.push("at", a - c, b - c, a + c, b + c, a + c * j, b + c * k, a + c * d, b + c * i, "x", "e");
1692                    f.isArc = !0;
1693                    return f
1694                }, circle: function (a, b, c, d, e) {
1695                    e && (c = d = 2 * e.r);
1696                    e && e.isCircle && (a -= c / 2, b -= d / 2);
1697                    return ["wa",
1698                        a, b, a + c, b + d, a + c, b + d / 2, a + c, b + d / 2, "e"]
1699                }, rect: function (a, b, c, d, e) {
1700                    return ua.prototype.symbols[!s(e) || !e.r ? "square" : "callout"].call(0, a, b, c, d, e)
1701                }
1702            }
1703        };
1704        B.VMLRenderer = D = function () {
1705            this.init.apply(this, arguments)
1706        };
1707        D.prototype = A(ua.prototype, La);
1708        Za = D
1709    }
1710    ua.prototype.measureSpanWidth = function (a, b) {
1711        var c = C.createElement("span"), d;
1712        d = C.createTextNode(a);
1713        c.appendChild(d);
1714        L(c, b);
1715        this.box.appendChild(c);
1716        d = c.offsetWidth;
1717        Pa(c);
1718        return d
1719    };
1720    var Lb;
1721    if (fa)B.CanVGRenderer = D = function () {
1722        Da = "http://www.w3.org/1999/xhtml"
1723    }, D.prototype.symbols =
1724    {}, Lb = function () {
1725        function a() {
1726            var a = b.length, d;
1727            for (d = 0; d < a; d++)b[d]();
1728            b = []
1729        }
1730
1731        var b = [];
1732        return {
1733            push: function (c, d) {
1734                b.length === 0 && Qb(d, a);
1735                b.push(c)
1736            }
1737        }
1738    }(), Za = D;
1739    Ra.prototype = {
1740        addLabel: function () {
1741            var a = this.axis, b = a.options, c = a.chart, d = a.categories, e = a.names, f = this.pos, g = b.labels, h = a.tickPositions, i = f === h[0], j = f === h[h.length - 1], e = d ? p(d[f], e[f], f) : f, d = this.label, h = h.info, k;
1742            a.isDatetimeAxis && h && (k = b.dateTimeLabelFormats[h.higherRanks[f] || h.unitName]);
1743            this.isFirst = i;
1744            this.isLast = j;
1745            b = a.labelFormatter.call({
1746                axis: a,
1747                chart: c, isFirst: i, isLast: j, dateTimeLabelFormat: k, value: a.isLog ? ea(ia(e)) : e
1748            });
1749            s(d) ? d && d.attr({text: b}) : (this.labelLength = (this.label = d = s(b) && g.enabled ? c.renderer.text(b, 0, 0, g.useHTML).css(A(g.style)).add(a.labelGroup) : null) && d.getBBox().width, this.rotation = 0)
1750        }, getLabelSize: function () {
1751            return this.label ? this.label.getBBox()[this.axis.horiz ? "height" : "width"] : 0
1752        }, handleOverflow: function (a) {
1753            var b = this.axis, c = a.x, d = b.chart.chartWidth, e = b.chart.spacing, f = p(b.labelLeft, z(b.pos, e[3])), e = p(b.labelRight, t(b.pos +
1754                b.len, d - e[1])), g = this.label, h = this.rotation, i = {
1755                left: 0,
1756                center: 0.5,
1757                right: 1
1758            }[b.labelAlign], j = g.getBBox().width, k = b.slotWidth, m = 1, l, n = {};
1759            if (h)h < 0 && c - i * j < f ? l = w(c / X(h * ga) - f) : h > 0 && c + i * j > e && (l = w((d - c) / X(h * ga))); else if (d = c + (1 - i) * j, c - i * j < f ? k = a.x + k * (1 - i) - f : d > e && (k = e - a.x + k * i, m = -1), k = z(b.slotWidth, k), k < b.slotWidth && b.labelAlign === "center" && (a.x += m * (b.slotWidth - k - i * (b.slotWidth - z(j, k)))), j > k || b.autoRotation && g.styles.width)l = k;
1760            if (l) {
1761                n.width = l;
1762                if (!b.options.labels.style.textOverflow)n.textOverflow = "ellipsis";
1763                g.css(n)
1764            }
1765        },
1766        getPosition: function (a, b, c, d) {
1767            var e = this.axis, f = e.chart, g = d && f.oldChartHeight || f.chartHeight;
1768            return {
1769                x: a ? e.translate(b + c, null, null, d) + e.transB : e.left + e.offset + (e.opposite ? (d && f.oldChartWidth || f.chartWidth) - e.right - e.left : 0),
1770                y: a ? g - e.bottom + e.offset - (e.opposite ? e.height : 0) : g - e.translate(b + c, null, null, d) - e.transB
1771            }
1772        }, getLabelPosition: function (a, b, c, d, e, f, g, h) {
1773            var i = this.axis, j = i.transA, k = i.reversed, m = i.staggerLines, l = i.tickRotCorr || {
1774                    x: 0,
1775                    y: 0
1776                }, c = p(e.y, l.y + (i.side === 2 ? 8 : -(c.getBBox().height / 2))), a = a + e.x + l.x -
1777                (f && d ? f * j * (k ? -1 : 1) : 0), b = b + c - (f && !d ? f * j * (k ? 1 : -1) : 0);
1778            m && (b += g / (h || 1) % m * (i.labelOffset / m));
1779            return {x: a, y: w(b)}
1780        }, getMarkPath: function (a, b, c, d, e, f) {
1781            return f.crispLine(["M", a, b, "L", a + (e ? 0 : -c), b + (e ? c : 0)], d)
1782        }, render: function (a, b, c) {
1783            var d = this.axis, e = d.options, f = d.chart.renderer, g = d.horiz, h = this.type, i = this.label, j = this.pos, k = e.labels, m = this.gridLine, l = h ? h + "Grid" : "grid", n = h ? h + "Tick" : "tick", q = e[l + "LineWidth"], x = e[l + "LineColor"], o = e[l + "LineDashStyle"], Q = e[n + "Length"], l = p(e[n + "Width"], !h && d.isXAxis ? 1 : 0), u = e[n +
1784            "Color"], y = e[n + "Position"], n = this.mark, t = k.step, s = !0, w = d.tickmarkOffset, r = this.getPosition(g, j, w, b), z = r.x, r = r.y, C = g && z === d.pos + d.len || !g && r === d.pos ? -1 : 1, c = p(c, 1);
1785            this.isActive = !0;
1786            if (q) {
1787                j = d.getPlotLinePath(j + w, q * C, b, !0);
1788                if (m === v) {
1789                    m = {stroke: x, "stroke-width": q};
1790                    if (o)m.dashstyle = o;
1791                    if (!h)m.zIndex = 1;
1792                    if (b)m.opacity = 0;
1793                    this.gridLine = m = q ? f.path(j).attr(m).add(d.gridGroup) : null
1794                }
1795                if (!b && m && j)m[this.isNew ? "attr" : "animate"]({d: j, opacity: c})
1796            }
1797            if (l && Q)y === "inside" && (Q = -Q), d.opposite && (Q = -Q), h = this.getMarkPath(z, r,
1798                Q, l * C, g, f), n ? n.animate({d: h, opacity: c}) : this.mark = f.path(h).attr({
1799                stroke: u,
1800                "stroke-width": l,
1801                opacity: c
1802            }).add(d.axisGroup);
1803            if (i && !isNaN(z))i.xy = r = this.getLabelPosition(z, r, i, g, k, w, a, t), this.isFirst && !this.isLast && !p(e.showFirstLabel, 1) || this.isLast && !this.isFirst && !p(e.showLastLabel, 1) ? s = !1 : g && !d.isRadial && !k.step && !k.rotation && !b && c !== 0 && this.handleOverflow(r), t && a % t && (s = !1), s && !isNaN(r.y) ? (r.opacity = c, i[this.isNew ? "attr" : "animate"](r), this.isNew = !1) : i.attr("y", -9999)
1804        }, destroy: function () {
1805            Oa(this, this.axis)
1806        }
1807    };
1808    B.PlotLineOrBand = function (a, b) {
1809        this.axis = a;
1810        if (b)this.options = b, this.id = b.id
1811    };
1812    B.PlotLineOrBand.prototype = {
1813        render: function () {
1814            var a = this, b = a.axis, c = b.horiz, d = a.options, e = d.label, f = a.label, g = d.width, h = d.to, i = d.from, j = s(i) && s(h), k = d.value, m = d.dashStyle, l = a.svgElem, n = [], q, x = d.color, p = d.zIndex, o = d.events, u = {}, y = b.chart.renderer;
1815            b.isLog && (i = Ba(i), h = Ba(h), k = Ba(k));
1816            if (g) {
1817                if (n = b.getPlotLinePath(k, g), u = {stroke: x, "stroke-width": g}, m)u.dashstyle = m
1818            } else if (j) {
1819                n = b.getPlotBandPath(i, h, d);
1820                if (x)u.fill = x;
1821                if (d.borderWidth)u.stroke =
1822                    d.borderColor, u["stroke-width"] = d.borderWidth
1823            } else return;
1824            if (s(p))u.zIndex = p;
1825            if (l)if (n)l.animate({d: n}, null, l.onGetPath); else {
1826                if (l.hide(), l.onGetPath = function () {
1827                        l.show()
1828                    }, f)a.label = f = f.destroy()
1829            } else if (n && n.length && (a.svgElem = l = y.path(n).attr(u).add(), o))for (q in d = function (b) {
1830                l.on(b, function (c) {
1831                    o[b].apply(a, [c])
1832                })
1833            }, o)d(q);
1834            if (e && s(e.text) && n && n.length && b.width > 0 && b.height > 0) {
1835                e = A({
1836                    align: c && j && "center",
1837                    x: c ? !j && 4 : 10,
1838                    verticalAlign: !c && j && "middle",
1839                    y: c ? j ? 16 : 10 : j ? 6 : -4,
1840                    rotation: c && !j && 90
1841                }, e);
1842                if (!f) {
1843                    u = {
1844                        align: e.textAlign ||
1845                        e.align, rotation: e.rotation
1846                    };
1847                    if (s(p))u.zIndex = p;
1848                    a.label = f = y.text(e.text, 0, 0, e.useHTML).attr(u).css(e.style).add()
1849                }
1850                b = [n[1], n[4], j ? n[6] : n[1]];
1851                j = [n[2], n[5], j ? n[7] : n[2]];
1852                n = Na(b);
1853                c = Na(j);
1854                f.align(e, !1, {x: n, y: c, width: Ca(b) - n, height: Ca(j) - c});
1855                f.show()
1856            } else f && f.hide();
1857            return a
1858        }, destroy: function () {
1859            ja(this.axis.plotLinesAndBands, this);
1860            delete this.axis;
1861            Oa(this)
1862        }
1863    };
1864    var ha = B.Axis = function () {
1865        this.init.apply(this, arguments)
1866    };
1867    ha.prototype = {
1868        defaultOptions: {
1869            dateTimeLabelFormats: {
1870                millisecond: "%H:%M:%S.%L", second: "%H:%M:%S",
1871                minute: "%H:%M", hour: "%H:%M", day: "%e. %b", week: "%e. %b", month: "%b '%y", year: "%Y"
1872            },
1873            endOnTick: !1,
1874            gridLineColor: "#D8D8D8",
1875            labels: {enabled: !0, style: {color: "#606060", cursor: "default", fontSize: "11px"}, x: 0, y: 15},
1876            lineColor: "#C0D0E0",
1877            lineWidth: 1,
1878            minPadding: 0.01,
1879            maxPadding: 0.01,
1880            minorGridLineColor: "#E0E0E0",
1881            minorGridLineWidth: 1,
1882            minorTickColor: "#A0A0A0",
1883            minorTickLength: 2,
1884            minorTickPosition: "outside",
1885            startOfWeek: 1,
1886            startOnTick: !1,
1887            tickColor: "#C0D0E0",
1888            tickLength: 10,
1889            tickmarkPlacement: "between",
1890            tickPixelInterval: 100,
1891            tickPosition: "outside",
1892            title: {align: "middle", style: {color: "#707070"}},
1893            type: "linear"
1894        },
1895        defaultYAxisOptions: {
1896            endOnTick: !0,
1897            gridLineWidth: 1,
1898            tickPixelInterval: 72,
1899            showLastLabel: !0,
1900            labels: {x: -8, y: 3},
1901            lineWidth: 0,
1902            maxPadding: 0.05,
1903            minPadding: 0.05,
1904            startOnTick: !0,
1905            title: {rotation: 270, text: "Values"},
1906            stackLabels: {
1907                enabled: !1, formatter: function () {
1908                    return B.numberFormat(this.total, -1)
1909                }, style: A(ba.line.dataLabels.style, {color: "#000000"})
1910            }
1911        },
1912        defaultLeftAxisOptions: {labels: {x: -15, y: null}, title: {rotation: 270}},
1913        defaultRightAxisOptions: {
1914            labels: {
1915                x: 15,
1916                y: null
1917            }, title: {rotation: 90}
1918        },
1919        defaultBottomAxisOptions: {labels: {autoRotation: [-45], x: 0, y: null}, title: {rotation: 0}},
1920        defaultTopAxisOptions: {labels: {autoRotation: [-45], x: 0, y: -15}, title: {rotation: 0}},
1921        init: function (a, b) {
1922            var c = b.isX;
1923            this.chart = a;
1924            this.horiz = a.inverted ? !c : c;
1925            this.coll = (this.isXAxis = c) ? "xAxis" : "yAxis";
1926            this.opposite = b.opposite;
1927            this.side = b.side || (this.horiz ? this.opposite ? 0 : 2 : this.opposite ? 1 : 3);
1928            this.setOptions(b);
1929            var d = this.options, e = d.type;
1930            this.labelFormatter = d.labels.formatter || this.defaultLabelFormatter;
1931            this.userOptions = b;
1932            this.minPixelPadding = 0;
1933            this.reversed = d.reversed;
1934            this.zoomEnabled = d.zoomEnabled !== !1;
1935            this.categories = d.categories || e === "category";
1936            this.names = this.names || [];
1937            this.isLog = e === "logarithmic";
1938            this.isDatetimeAxis = e === "datetime";
1939            this.isLinked = s(d.linkedTo);
1940            this.ticks = {};
1941            this.labelEdge = [];
1942            this.minorTicks = {};
1943            this.plotLinesAndBands = [];
1944            this.alternateBands = {};
1945            this.len = 0;
1946            this.minRange = this.userMinRange = d.minRange || d.maxZoom;
1947            this.range = d.range;
1948            this.offset = d.offset || 0;
1949            this.stacks = {};
1950            this.oldStacks =
1951            {};
1952            this.stacksTouched = 0;
1953            this.min = this.max = null;
1954            this.crosshair = p(d.crosshair, ra(a.options.tooltip.crosshairs)[c ? 0 : 1], !1);
1955            var f, d = this.options.events;
1956            Ka(this, a.axes) === -1 && (c && !this.isColorAxis ? a.axes.splice(a.xAxis.length, 0, this) : a.axes.push(this), a[this.coll].push(this));
1957            this.series = this.series || [];
1958            if (a.inverted && c && this.reversed === v)this.reversed = !0;
1959            this.removePlotLine = this.removePlotBand = this.removePlotBandOrLine;
1960            for (f in d)H(this, f, d[f]);
1961            if (this.isLog)this.val2lin = Ba, this.lin2val = ia
1962        },
1963        setOptions: function (a) {
1964            this.options =
1965                A(this.defaultOptions, this.isXAxis ? {} : this.defaultYAxisOptions, [this.defaultTopAxisOptions, this.defaultRightAxisOptions, this.defaultBottomAxisOptions, this.defaultLeftAxisOptions][this.side], A(S[this.coll], a))
1966        },
1967        defaultLabelFormatter: function () {
1968            var a = this.axis, b = this.value, c = a.categories, d = this.dateTimeLabelFormat, e = S.lang.numericSymbol
1968s, f = e && e.length, g, h = a.options.labels.format, a = a.isLog ? b : a.tickInterval;
1969            if (h)g = Ha(h, this); else if (c)g = b; else if (d)g = Ma(d, b); else if (f && a >= 1E3)for (; f-- && g === v;)c = Math.pow(1E3,
1970                f + 1), a >= c && b * 10 % c === 0 && e[f] !== null && (g = B.numberFormat(b / c, -1) + e[f]);
1971            g === v && (g = N(b) >= 1E4 ? B.numberFormat(b, -1) : B.numberFormat(b, -1, v, ""));
1972            return g
1973        },
1974        getSeriesExtremes: function () {
1975            var a = this, b = a.chart;
1976            a.hasVisibleSeries = !1;
1977            a.dataMin = a.dataMax = a.ignoreMinPadding = a.ignoreMaxPadding = null;
1978            a.buildStacks && a.buildStacks();
1979            o(a.series, function (c) {
1980                if (c.visible || !b.options.chart.ignoreHiddenSeries) {
1981                    var d;
1982                    d = c.options.threshold;
1983                    var e;
1984                    a.hasVisibleSeries = !0;
1985                    a.isLog && d <= 0 && (d = null);
1986                    if (a.isXAxis) {
1987                        if (d = c.xData, d.length)a.dataMin =
1988                            z(p(a.dataMin, d[0]), Na(d)), a.dataMax = t(p(a.dataMax, d[0]), Ca(d))
1989                    } else {
1990                        c.getExtremes();
1991                        e = c.dataMax;
1992                        c = c.dataMin;
1993                        if (s(c) && s(e))a.dataMin = z(p(a.dataMin, c), c), a.dataMax = t(p(a.dataMax, e), e);
1994                        if (s(d))if (a.dataMin >= d)a.dataMin = d, a.ignoreMinPadding = !0; else if (a.dataMax < d)a.dataMax = d, a.ignoreMaxPadding = !0
1995                    }
1996                }
1997            })
1998        },
1999        translate: function (a, b, c, d, e, f) {
2000            var g = this.linkedParent || this, h = 1, i = 0, j = d ? g.oldTransA : g.transA, d = d ? g.oldMin : g.min, k = g.minPixelPadding, e = (g.doPostTranslate || g.isLog && e) && g.lin2val;
2001            if (!j)j = g.transA;
2002            if (c)h *= -1, i = g.len;
2003            g.reversed && (h *= -1, i -= h * (g.sector || g.len));
2004            b ? (a = a * h + i, a -= k, a = a / j + d, e && (a = g.lin2val(a))) : (e && (a = g.val2lin(a)), f === "between" && (f = 0.5), a = h * (a - d) * j + i + h * k + (qa(f) ? j * f * g.pointRange : 0));
2005            return a
2006        },
2007        toPixels: function (a, b) {
2008            return this.translate(a, !1, !this.horiz, null, !0) + (b ? 0 : this.pos)
2009        },
2010        toValue: function (a, b) {
2011            return this.translate(a - (b ? 0 : this.pos), !0, !this.horiz, null, !0)
2012        },
2013        getPlotLinePath: function (a, b, c, d, e) {
2014            var f = this.chart, g = this.left, h = this.top, i, j, k = c && f.oldChartHeight || f.chartHeight, m = c && f.oldChartWidth ||
2015                f.chartWidth, l;
2016            i = this.transB;
2017            var n = function (a, b, c) {
2018                if (a < b || a > c)d ? a = z(t(b, a), c) : l = !0;
2019                return a
2020            }, e = p(e, this.translate(a, null, null, c)), a = c = w(e + i);
2021            i = j = w(k - e - i);
2022            isNaN(e) ? l = !0 : this.horiz ? (i = h, j = k - this.bottom, a = c = n(a, g, g + this.width)) : (a = g, c = m - this.right, i = j = n(i, h, h + this.height));
2023            return l && !d ? null : f.renderer.crispLine(["M", a, i, "L", c, j], b || 1)
2024        },
2025        getLinearTickPositions: function (a, b, c) {
2026            var d, e = ea(V(b / a) * a), f = ea(sa(c / a) * a), g = [];
2027            if (b === c && qa(b))return [b];
2028            for (b = e; b <= f;) {
2029                g.push(b);
2030                b = ea(b + a);
2031                if (b === d)break;
2032                d = b
2033            }
2034            return g
2035        },
2036        getMinorTickPositions: function () {
2037            var a = this.options, b = this.tickPositions, c = this.minorTickInterval, d = [], e, f = this.pointRangePadding || 0;
2038            e = this.min - f;
2039            var f = this.max + f, g = f - e;
2040            if (g && g / c < this.len / 3)if (this.isLog) {
2041                f = b.length;
2042                for (e = 1; e < f; e++)d = d.concat(this.getLogTickPositions(c, b[e - 1], b[e], !0))
2043            } else if (this.isDatetimeAxis && a.minorTickInterval === "auto")d = d.
2043concat(this.getTimeTicks(this.normalizeTimeTickInterval(c), e, f, a.startOfWeek)); else for (b = e + (b[0] - e) % c; b <= f; b += c)d.push(b);
2044            d.length !== 0 && this.trimTicks(d,
2045                a.startOnTick, a.endOnTick);
2046            return d
2047        },
2048        adjustForMinRange: function () {
2049            var a = this.options, b = this.min, c = this.max, d, e = this.dataMax - this.dataMin >= this.minRange, f, g, h, i, j;
2050            if (this.isXAxis && this.minRange === v && !this.isLog)s(a.min) || s(a.max) ? this.minRange = null : (o(this.series, function (a) {
2051                i = a.xData;
2052                for (g = j = a.xIncrement ? 1 : i.length - 1; g > 0; g--)if (h = i[g] - i[g - 1], f === v || h < f)f = h
2053            }), this.minRange = z(f * 5, this.dataMax - this.dataMin));
2054            if (c - b < this.minRange) {
2055                var k = this.minRange;
2056                d = (k - c + b) / 2;
2057                d = [b - d, p(a.min, b - d)];
2058                if (e)d[2] = this.dataMin;
2059                b = Ca(d);
2060                c = [b + k, p(a.max, b + k)];
2061                if (e)c[2] = this.dataMax;
2062                c = Na(c);
2063                c - b < k && (d[0] = c - k, d[1] = p(a.min, c - k), b = Ca(d))
2064            }
2065            this.min = b;
2066            this.max = c
2067        },
2068        setAxisTranslation: function (a) {
2069            var b = this, c = b.max - b.min, d = b.axisPointRange || 0, e, f = 0, g = 0, h = b.linkedParent, i = !!b.categories, j = b.transA, k = b.isXAxis;
2070            if (k || i || d)if (h ? (f = h.minPointOffset, g = h.pointRangePadding) : o(b.series, function (a) {
2071                    var h = i ? 1 : k ? a.pointRange : b.axisPointRange || 0, j = a.options.pointPlacement, q = a.closestPointRange;
2072                    h > c && (h = 0);
2073                    d = t(d, h);
2074                    b.single || (f = t(f, Aa(j) ? 0 : h / 2), g = t(g,
2075                        j === "on" ? 0 : h));
2076                    !a.noSharedTooltip && s(q) && (e = s(e) ? z(e, q) : q)
2077                }), h = b.ordinalSlope && e ? b.ordinalSlope / e : 1, b.minPointOffset = f *= h, b.pointRangePadding = g *= h, b.pointRange = z(d, c), k)b.closestPointRange = e;
2078            if (a)b.oldTransA = j;
2079            b.translationSlope = b.transA = j = b.len / (c + g || 1);
2080            b.transB = b.horiz ? b.left : b.bottom;
2081            b.minPixelPadding = j * f
2082        },
2083        minFromRange: function () {
2084            return this.max - this.range
2085        },
2086        setTickInterval: function (a) {
2087            var b = this, c = b.chart, d = b.options, e = b.isLog, f = b.isDatetimeAxis, g = b.isXAxis, h = b.isLinked, i = d.maxPadding, j = d.minPadding,
2088                k = d.tickInterval, m = d.tickPixelInterval, l = b.categories;
2089            !f && !l && !h && this.getTickAmount();
2090            h ? (b.linkedParent = c[b.coll][d.linkedTo], c = b.linkedParent.getExtremes(), b.min = p(c.min, c.dataMin), b.max = p(c.max, c.dataMax), d.type !== b.linkedParent.options.type && la(11, 1)) : (b.min = p(b.userMin, d.min, b.dataMin), b.max = p(b.userMax, d.max, b.dataMax));
2091            if (e)!a && z(b.min, p(b.dataMin, b.min)) <= 0 && la(10, 1), b.min = ea(Ba(b.min), 15), b.max = ea(Ba(b.max), 15);
2092            if (b.range && s(b.max))b.userMin = b.min = t(b.min, b.minFromRange()), b.userMax = b.max,
2093                b.range = null;
2094            b.beforePadding && b.beforePadding();
2095            b.adjustForMinRange();
2096            if (!l && !b.axisPointRange && !b.usePercentage && !h && s(b.min) && s(b.max) && (c = b.max - b.min)) {
2097                if (!s(d.min) && !s(b.userMin) && j && (b.dataMin < 0 || !b.ignoreMinPadding))b.min -= c * j;
2098                if (!s(d.max) && !s(b.userMax) && i && (b.dataMax > 0 || !b.ignoreMaxPadding))b.max += c * i
2099            }
2100            if (qa(d.floor))b.min = t(b.min, d.floor);
2101            if (qa(d.ceiling))b.max = z(b.max, d.ceiling);
2102            b.tickInterval = b.min === b.max || b.min === void 0 || b.max === void 0 ? 1 : h && !k && m === b.linkedParent.options.tickPixelInterval ?
2103                k = b.linkedParent.tickInterval : p(k, this.tickAmount ? (b.max - b.min) / t(this.tickAmount - 1, 1) : void 0, l ? 1 : (b.max - b.min) * m / t(b.len, m));
2104            g && !a && o(b.series, function (a) {
2105                a.processData(b.min !== b.oldMin || b.max !== b.oldMax)
2106            });
2107            b.setAxisTranslation(!0);
2108            b.beforeSetTickPositions && b.beforeSetTickPositions();
2109            if (b.postProcessTickInterval)b.tickInterval = b.postProcessTickInterval(b.tickInterval);
2110            if (b.pointRange)b.tickInterval = t(b.pointRange, b.tickInterval);
2111            a = p(d.minTickInterval, b.isDatetimeAxis && b.closestPointRange);
2112            if (!k &&
2113                b.tickInterval < a)b.tickInterval = a;
2114            if (!f && !e && !k)b.tickInterval = ob(b.tickInterval, null, nb(b.tickInterval), p(d.allowDecimals, !(b.tickInterval > 0.5 && b.tickInterval < 5 && b.max > 1E3 && b.max < 9999)), !!this.tickAmount);
2115            if (!this.tickAmount && this.len)b.tickInterval = b.unsquish();
2116            this.setTickPositions()
2117        },
2118        setTickPositions: function () {
2119            var a = this.options, b, c = a.tickPositions, d = a.tickPositioner, e = a.startOnTick, f = a.endOnTick, g;
2120            this.tickmarkOffset = this.categories && a.tickmarkPlacement === "between" && this.tickInterval === 1 ? 0.5 :
2121                0;
2122            this.minorTickInterval = a.minorTickInterval === "auto" && this.tickInterval ? this.tickInterval / 5 : a.minorTickInterval;
2123            this.tickPositions = b = c && c.slice();
2124            if (!b && (b = this.isDatetimeAxis ? this.getTimeTicks(this.normalizeTimeTickInterval(this.tickInterval, a.units), this.min, this.max, a.startOfWeek, this.ordinalPositions, this.closestPointRange, !0) : this.isLog ? this.getLogTickPositions(this.tickInterval, this.min, this.max) : this.getLinearTickPositions(this.tickInterval, this.min, this.max), b.length > this.len && (b = [b[0], b.pop()]),
2125                    this.tickPositions = b, d && (d = d.apply(this, [this.min, this.max]))))this.tickPositions = b = d;
2126            if (!this.isLinked)this.trimTicks(b, e, f), this.min === this.max && s(this.min) && !this.tickAmount && (g = !0, this.min -= 0.5, this.max += 0.5), this.single = g, !c && !d && this.adjustTickAmount()
2127        },
2128        trimTicks: function (a, b, c) {
2129            var d = a[0], e = a[a.length - 1], f = this.minPointOffset || 0;
2130            b ? this.min = d : this.min - f > d && a.shift();
2131            c ? this.max = e : this.max + f < e && a.pop();
2132            a.length === 0 && s(d) && a.push((e + d) / 2)
2133        },
2134        getTickAmount: function () {
2135            var a = {}, b, c = this.options, d = c.tickAmount,
2136                e = c.tickPixelInterval;
2137            !s(c.tickInterval) && this.len < e && !this.isRadial && !this.isLog && c.startOnTick && c.endOnTick && (d = 2);
2138            !d && this.chart.options.chart.alignTicks !== !1 && c.alignTicks !== !1 && (o(this.chart[this.coll], function (c) {
2139                var d = c.options, e = c.horiz, d = [e ? d.left : d.top, e ? d.width : d.height, d.pane].join(",");
2140                a[d] ? c.series.length && (b = !0) : a[d] = 1
2141            }), b && (d = sa(this.len / e) + 1));
2142            if (d < 4)this.finalTickAmt = d, d = 5;
2143            this.tickAmount = d
2144        },
2145        adjustTickAmount: function () {
2146            var a = this.tickInterval, b = this.tickPositions, c = this.tickAmount,
2147                d = this.finalTickAmt, e = b && b.length;
2148            if (e < c) {
2149                for (; b.length < c;)b.push(ea(b[b.length - 1] + a));
2150                this.transA *= (e - 1) / (c - 1);
2151                this.max = b[b.length - 1]
2152            } else e > c && (this.tickInterval *= 2, this.setTickPositions());
2153            if (s(d)) {
2154                for (a = c = b.length; a--;)(d === 3 && a % 2 === 1 || d <= 2 && a > 0 && a < c - 1) && b.splice(a, 1);
2155                this.finalTickAmt = v
2156            }
2157        },
2158        setScale: function () {
2159            var a, b;
2160            this.oldMin = this.min;
2161            this.oldMax = this.max;
2162            this.oldAxisLength = this.len;
2163            this.setAxisSize();
2164            b = this.len !== this.oldAxisLength;
2165            o(this.series, function (b) {
2166                if (b.isDirtyData || b.isDirty || b.xAxis.isDirty)a = !0
2167            });
2168            if (b || a || this.isLinked || this.forceRedraw || this.userMin !== this.oldUserMin || this.userMax !== this.oldUserMax) {
2169                if (this.resetStacks && this.resetStacks(), this.forceRedraw = !1, this.get
2169SeriesExtremes(), this.setTickInterval(), this.oldUserMin = this.userMin, this.oldUserMax = this.userMax, !this.isDirty)this.isDirty = b || this.min !== this.oldMin || this.max !== this.oldMax
2170            } else this.cleanStacks && this.cleanStacks()
2171        },
2172        setExtremes: function (a, b, c, d, e) {
2173            var f = this, g = f.chart, c = p(c, !0);
2174            o(f.series, function (a) {
2175                delete a.kdTree
2176            });
2177            e = r(e, {min: a, max: b});
2178            I(f, "setExtremes", e, function () {
2179                f.userMin = a;
2180                f.userMax = b;
2181                f.eventArgs = e;
2182                c && g.redraw(d)
2183            })
2184        },
2185        zoom: function (a, b) {
2186            var c = this.dataMin, d = this.dataMax, e = this.options, f = z(c, p(e.min, c)), e = t(d, p(e.max, d));
2187            this.allowZoomOutside || (s(c) && a <= f && (a = f), s(d) && b >= e && (b = e));
2188            this.displayBtn = a !== v || b !== v;
2189            this.setExtremes(a, b, !1, v, {trigger: "zoom"});
2190            return !0
2191        },
2192        setAxisSize: function () {
2193            var a = this.chart, b = this.options, c = b.offsetLeft || 0, d = this.horiz, e = p(b.width, a.plotWidth - c + (b.offsetRight || 0)), f = p(b.height,
2194                a.plotHeight), g = p(b.top, a.plotTop), b = p(b.left, a.plotLeft + c), c = /%$/;
2195            c.test(f) && (f = parseFloat(f) / 100 * a.plotHeight);
2196            c.test(g) && (g = parseFloat(g) / 100 * a.plotHeight + a.plotTop);
2197            this.left = b;
2198            this.top = g;
2199            this.width = e;
2200            this.height = f;
2201            this.bottom = a.chartHeight - f - g;
2202            this.right = a.chartWidth - e - b;
2203            this.len = t(d ? e : f, 0);
2204            this.pos = d ? b : g
2205        },
2206        getExtremes: function () {
2207            var a = this.isLog;
2208            return {
2209                min: a ? ea(ia(this.min)) : this.min,
2210                max: a ? ea(ia(this.max)) : this.max,
2211                dataMin: this.dataMin,
2212                dataMax: this.dataMax,
2213                userMin: this.userMin,
2214                userMax: this.userMax
2215            }
2216        },
2217        getThreshold: function (a) {
2218            var b = this.isLog, c = b ? ia(this.min) : this.min, b = b ? ia(this.max) : this.max;
2219            a === null ? a = b < 0 ? b : c : c > a ? a = c : b < a && (a = b);
2220            return this.translate(a, 0, 1, 0, 1)
2221        },
2222        autoLabelAlign: function (a) {
2223            a = (p(a, 0) - this.side * 90 + 720) % 360;
2224            return a > 15 && a < 165 ? "right" : a > 195 && a < 345 ? "left" : "center"
2225        },
2226        unsquish: function () {
2227            var a = this.ticks, b = this.options.labels, c = this.horiz, d = this.tickInterval, e = d, f = this.len / (((this.categories ? 1 : 0) + this.max - this.min) / d), g, h = b.rotation, i = this.chart.renderer.fontMetrics(b.style.fontSize,
2228                a[0] && a[0].label), j, k = Number.MAX_VALUE, m, l = function (a) {
2229                a /= f || 1;
2230                a = a > 1 ? sa(a) : 1;
2231                return a * d
2232            };
2233            c ? (m = s(h) ? [h] : f < p(b.autoRotationLimit, 80) && !b.staggerLines && !b.step && b.autoRotation) && o(m, function (a) {
2234                var b;
2235                if (a === h || a && a >= -90 && a <= 90)j = l(N(i.h / aa(ga * a))), b = j + N(a / 360), b < k && (k = b, g = a, e = j)
2236            }) : b.step || (e = l(i.h));
2237            this.autoRotation = m;
2238            this.labelRotation = g;
2239            return e
2240        },
2241        renderUnsquish: function () {
2242            var a = this.chart, b = a.renderer, c = this.tickPositions, d = this.ticks, e = this.options.labels, f = this.horiz, g = a.margin, h = this.categories ?
2243                c.length : c.length - 1, i = this.slotWidth = f && !e.step && !e.rotation && (this.staggerLines || 1) * a.plotWidth / h || !f && (g[3] && g[3] - a.spacing[3] || a.chartWidth * 0.33), j = t(1, w(i - 2 * (e.padding || 5))), k = {}, g = b.fontMetrics(e.style.fontSize, d[0] && d[0].label), h = e.style.textOverflow, m, l = 0;
2244            if (!Aa(e.rotation))k.rotation = e.rotation || 0;
2245            if (this.autoRotation)o(c, function (a) {
2246                if ((a = d[a]) && a.labelLength > l)l = a.labelLength
2247            }), l > j && l > g.h ? k.rotation = this.labelRotation : this.labelRotation = 0; else if (i && (m = {width: j + "px"}, !h)) {
2248                m.textOverflow =
2249                    "clip";
2250                for (i = c.length; !f && i--;)if (j = c[i], j = d[j].label)if (j.styles.textOverflow === "ellipsis" && j.css({textOverflow: "clip"}), j.getBBox().height > this.len / c.length - (g.h - g.f))j.specCss = {textOverflow: "ellipsis"}
2251            }
2252            if (k.rotation && (m = {width: (l >
2252 a.chartHeight * 0.5 ? a.chartHeight * 0.33 : a.chartHeight) + "px"}, !h))m.textOverflow = "ellipsis";
2253            this.labelAlign = k.align = e.align || this.autoLabelAlign(this.labelRotation);
2254            o(c, function (a) {
2255                var b = (a = d[a]) && a.label;
2256                if (b)m && b.css(A(m, b.specCss)), delete b.specCss, b.attr(k), a.rotation =
2257                    k.rotation
2258            });
2259            this.tickRotCorr = b.rotCorr(g.b, this.labelRotation || 0, this.side === 2)
2260        },
2261        hasData: function () {
2262            return this.hasVisibleSeries || s(this.min) && s(this.max) && !!this.tickPositions
2263        },
2264        getOffset: function () {
2265            var a = this, b = a.chart, c = b.renderer, d = a.options, e = a.tickPositions, f = a.ticks, g = a.horiz, h = a.side, i = b.inverted ? [1, 0, 3, 2][h] : h, j, k, m = 0, l, n = 0, q = d.title, x = d.labels, T = 0, Q = b.axisOffset, b = b.clipOffset, u = [-1, 1, 1, -1][h], y;
2266            j = a.hasData();
2267            a.showAxis = k = j || p(d.showEmpty, !0);
2268            a.staggerLines = a.horiz && x.staggerLines;
2269            if (!a.axisGroup)a.gridGroup =
2270                c.g("grid").attr({zIndex: d.gridZIndex || 1}).add(), a.axisGroup = c.g("axis").attr({zIndex: d.zIndex || 2}).add(), a.labelGroup = c.g("axis-labels").attr({zIndex: x.zIndex || 7}).addClass("highcharts-" + a.coll.toLowerCase() + "-labels").add();
2271            if (j || a.isLinked) {
2272                if (o(e, function (b) {
2273                        f[b] ? f[b].addLabel() : f[b] = new Ra(a, b)
2274                    }), a.renderUnsquish(), o(e, function (b) {
2275                        if (h === 0 || h === 2 || {
2276                                1: "left",
2277                                3: "right"
2278                            }[h] === a.labelAlign)T = t(f[b].getLabelSize(), T)
2279                    }), a.staggerLines)T *= a.staggerLines, a.labelOffset = T
2280            } else for (y in f)f[y].destroy(),
2281                delete f[y];
2282            if (q && q.text && q.enabled !== !1) {
2283                if (!a.axisTitle)a.axisTitle = c.text(q.text, 0, 0, q.useHTML).attr({
2284                    zIndex: 7,
2285                    rotation: q.rotation || 0,
2286                    align: q.textAlign || {low: "left", middle: "center", high: "right"}[q.align]
2287                }).addClass("highcharts-" + this.coll.toLowerCase() + "-title").css(q.style).add(a.axisGroup), a.axisTitle.isNew = !0;
2288                if (k)m = a.axisTitle.getBBox()[g ? "height" : "width"], l = q.offset, n = s(l) ? 0 : p(q.margin, g ? 5 : 10);
2289                a.axisTitle[k ? "show" : "hide"]()
2290            }
2291            a.offset = u * p(d.offset, Q[h]);
2292            a.tickRotCorr = a.tickRotCorr || {x: 0, y: 0};
2293            c = h === 2 ? a.tickRotCorr.y : 0;
2294            g = T + n + (T && u * (g ? p(x.y, a.tickRotCorr.y + 8) : x.x) - c);
2295            a.axisTitleMargin = p(l, g);
2296            Q[h] = t(Q[h], a.axisTitleMargin + m + u * a.offset, g);
2297            d = d.offset ? 0 : V(d.lineWidth / 2) * 2;
2298            b[i] = t(b[i], d)
2299        },
2300        getLinePath: function (a) {
2301            var b = this.chart, c = this.opposite, d = this.offset, e = this.horiz, f = this.left + (c ? this.width : 0) + d, d = b.chartHeight - this.bottom - (c ? this.height : 0) + d;
2302            c && (a *= -1);
2303            return b.renderer.crispLine(["M", e ? this.left : f, e ? d : this.top, "L", e ? b.chartWidth - this.right : f, e ? d : b.chartHeight - this.bottom], a)
2304        },
2305        getTitlePosition: function () {
2306            var a =
2307                this.horiz, b = this.left, c = this.top, d = this.len, e = this.options.title, f = a ? b : c, g = this.opposite, h = this.offset, i = e.x || 0, j = e.y || 0, k = F(e.style.fontSize || 12), d = {
2308                low: f + (a ? 0 : d),
2309                middle: f + d / 2,
2310                high: f + (a ? d : 0)
2311            }[e.align], b = (a ? c + this.height : b) + (a ? 1 : -1) * (g ? -1 : 1) * this.axisTitleMargin + (this.side === 2 ? k : 0);
2312            return {x: a ? d + i : b + (g ? this.width : 0) + h + i, y: a ? b + j - (g ? this.height : 0) + h : d + j}
2313        },
2314        render: function () {
2315            var a = this, b = a.chart, c = b.renderer, d = a.options, e = a.isLog, f = a.isLinked, g = a.tickPositions, h = a.axisTitle, i = a.ticks, j = a.minorTicks, k =
2316                a.alternateBands, m = d.stackLabels, l = d.alternateGridColor, n = a.tickmarkOffset, q = d.lineWidth, x, p 
2316= b.hasRendered && s(a.oldMin) && !isNaN(a.oldMin), Q = a.showAxis, u = c.globalAnimation, y, t;
2317            a.labelEdge.length = 0;
2318            a.overlap = !1;
2319            o([i, j, k], function (a) {
2320                for (var b in a)a[b].isActive = !1
2321            });
2322            if (a.hasData() || f) {
2323                a.minorTickInterval && !a.categories && o(a.getMinorTickPositions(), function (b) {
2324                    j[b] || (j[b] = new Ra(a, b, "minor"));
2325                    p && j[b].isNew && j[b].render(null, !0);
2326                    j[b].render(null, !1, 1)
2327                });
2328                if (g.length && (o(g, function (b, c) {
2329                        if (!f || b >= a.min &&
2330                            b <= a.max)i[b] || (i[b] = new Ra(a, b)), p && i[b].isNew && i[b].render(c, !0, 0.1), i[b].render(c)
2331                    }), n && (a.min === 0 || a.single)))i[-1] || (i[-1] = new Ra(a, -1, null, !0)), i[-1].render(-1);
2332                l && o(g, function (b, c) {
2333                    if (c % 2 === 0 && b < a.max)k[b] || (k[b] = new B.PlotLineOrBand(a)), y = b + n, t = g[c + 1] !== v ? g[c + 1] + n : a.max, k[b].options = {
2334                        from: e ? ia(y) : y,
2335                        to: e ? ia(t) : t,
2336                        color: l
2337                    }, k[b].render(), k[b].isActive = !0
2338                });
2339                if (!a._addedPlotLB)o((d.plotLines || []).concat(d.plotBands || []), function (b) {
2340                    a.addPlotBandOrLine(b)
2341                }), a._addedPlotLB = !0
2342            }
2343            o([i, j, k], function (a) {
2344                var c,
2345                    d, e = [], f = u ? u.duration || 500 : 0, g = function () {
2346                        for (d = e.length; d--;)a[e[d]] && !a[e[d]].isActive && (a[e[d]].destroy(), delete a[e[d]])
2347                    };
2348                for (c in a)if (!a[c].isActive)a[c].render(c, !1, 0), a[c].isActive = !1, e.push(c);
2349                a === k || !b.hasRendered || !f ? g() : f && setTimeout(g, f)
2350            });
2351            if (q)x = a.getLinePath(q), a.axisLine ? a.axisLine.animate({d: x}) : a.axisLine = c.path(x).attr({
2352                stroke: d.lineColor,
2353                "stroke-width": q,
2354                zIndex: 7
2355            }).add(a.axisGroup), a.axisLine[Q ? "show" : "hide"]();
2356            if (h && Q)h[h.isNew ? "attr" : "animate"](a.getTitlePosition()), h.isNew = !1;
2357            m && m.enabled && a.renderStackTotals();
2358            a.isDirty = !1
2359        },
2360        redraw: function () {
2361            this.render();
2362            o(this.plotLinesAndBands, function (a) {
2363                a.render()
2364            });
2365            o(this.series, function (a) {
2366                a.isDirty = !0
2367            })
2368        },
2369        destroy: function (a) {
2370            var b = this, c = b.stacks, d, e = b.plotLinesAndBands;
2371            a || Z(b);
2372            for (d in c)Oa(c[d]), c[d] = null;
2373            o([b.ticks, b.minorTicks, b.alternateBands], function (a) {
2374                Oa(a)
2375            });
2376            for (a = e.length; a--;)e[a].destroy();
2377            o("stackTotalGroup,axisLine,axisTitle,axisGroup,cross,gridGroup,labelGroup".split(","), function (a) {
2378                b[a] && (b[a] = b[a].destroy())
2379            });
2380            this.cross && this.cross.destroy()
2381        },
2382        drawCrosshair: function (a, b) {
2383            var c, d = this.crosshair, e = d.animation;
2384            if (!this.crosshair || (s(b) || !p(this.crosshair.snap, !0)) === !1 || b && b.series && b.series[this.coll] !== this)this.hideCrosshair(); else if (p(d.snap, !0) ? s(b) && (c = this.isXAxis ? b.plotX : this.len - b.plotY) : c = this.horiz ? a.chartX - this.pos : this.len - a.chartY + this.pos, c = this.isRadial ? this.getPlotLinePath(this.isXAxis ? b.x : p(b.stackY, b.y)) || null : this.getPlotLinePath(null, null, null, null, c) || null, c === null)this.hideCrosshair();
2385            else if (this.cross)this.cross.attr({visibility: "visible"})[e ? "animate" : "attr"]({d: c}, e); else {
2386                e = this.categories && !this.isRadial;
2387                e = {
2388                    "stroke-width": d.width || (e ? this.transA : 1),
2389                    stroke: d.color || (e ? "rgba(155,200,255,0.2)" : "#C0C0C0"),
2390                    zIndex: d.zIndex || 2
2391                };
2392                if (d.dashStyle)e.dashstyle = d.dashStyle;
2393                this.cross = this.chart.renderer.path(c).attr(e).add()
2394            }
2395        },
2396        hideCrosshair: function () {
2397            this.cross && this.cross.hide()
2398        }
2399    };
2400    r(ha.prototype, {
2401        getPlotBandPath: function (a, b) {
2402            var c = this.getPlotLinePath(b, null, null, !0), d = this.getPlotLinePath(a,
2403                null, null, !0);
2404            d && c && d.toString() !== c.toString() ? d.push(c[4], c[5], c[1], c[2]) : d = null;
2405            return d
2406        }, addPlotBand: function (a) {
2407            return this.addPlotBandOrLine(a, "plotBands")
2408        }, addPlotLine: function (a) {
2409            return this.addPlotBandOrLine(a, "plotLines")
2410        }, addPlotBandOrLine: function (a, b) {
2411            var c = (new B.PlotLineOrBand(this, a)).render(), d = this.userOptions;
2412            c && (b && (d[b] = d[b] || [], d[b].push(a)), this.plotLinesAndBands.push(c));
2413            return c
2414        }, removePlotBandOrLine: function (a) {
2415            for (var b = this.plotLinesAndBands, c = this.options, d = this.userOptions,
2416                     e = b.length; e--;)b[e].id === a && b[e].destroy();
2417            o([c.plotLines || [], d.plotLines || [], c.plotBands || [], d.plotBands || []], function (b) {
2418                for (e = b.length; e--;)b[e].id === a && ja(b, b[e])
2419            })
2420        }
2421    });
2422    ha.prototype.getTimeTicks = function (a, b, c, d) {
2423        var e = [], f = {}, g = S.global.useUTC, h, i = new ya(b - Va(b)), j = a.unitRange, k = a.count;
2424        if (s(b)) {
2425            i[Db](j >= E.second ? 0 : k * V(i.getMilliseconds() / k));
2426            if (j >= E.second)i[Eb](j >= E.minute ? 0 : k * V(i.getSeconds() / k));
2427            if (j >= E.minute)i[Fb](j >= E.hour ? 0 : k * V(i[qb]() / k));
2428            if (j >= E.hour)i[Gb](j >= E.day ? 0 : k * V(i[rb]() / k));
2429            if (j >= E.day)i[tb](j >= E.month ? 1 : k * V(i[Wa]() / k));
2430            j >= E.month && (i[ub](j >= E.year ? 0 : k * V(i[Xa]() / k)), h = i[Ya]());
2431            j >= E.year && (h -= h % k, i[vb](h));
2432            if (j === E.week)i[tb](i[Wa]() - i[sb]() + p(d, 1));
2433            b = 1;
2434            if (mb || bb)i = i.getTime(), i = new ya(i + Va(i));
2435            h = i[Ya]();
2436            for (var d = i.getTime(), m = i[Xa](), l = i[Wa](), n = (E.day + (g ? Va(i) : i.getTimezoneOffset() * 6E4)) % E.day; d < c;)e.push(d), j === E.year ? d = db(h + b * k, 0) : j === E.month ? d = db(h, m + b * k) : !g && (j === E.day || j === E.week) ? d = db(h, m, l + b * k * (j === E.day ? 1 : 7)) : d += j * k, b++;
2437            e.push(d);
2438            o(ib(e, function (a) {
2439                return j <=
2440                    E.hour && a % E.day === n
2441            }), function (a) {
2442                f[a] = "day"
2443            })
2444        }
2445        e.info = r(a, {higherRanks: f, totalRange: j * k});
2446        return e
2447    };
2448    ha.prototype.normalizeTimeTickInterval = function (a, b) {
2449        var c = b || [["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 = c[c.length - 1], e = E[d[0]], f = d[1], g;
2450        for (g = 0; g < c.length; g++)if (d = c[g], e = E[d[0]], f = d[1], c[g + 1] && a <= (e * f[f.length - 1] + E[c[g + 1][0]]) / 2)break;
2451        e === E.year &&
2452        a < 5 * e && (f = [1, 2, 5]);
2453        c = ob(a / e, f, d[0] === "year" ? t(nb(a / e), 1) : 1);
2454        return {unitRange: e, count: c, unitName: d[0]}
2455    };
2456    ha.prototype.getLogTickPositions = function (a, b, c, d) {
2457        var e = this.options, f = this.len, g = [];
2458        if (!d)this._minorAutoInterval = null;
2459        if (a >= 0.5)a = w(a), g = this.getLinearTickPositions(a, b, c); else if (a >= 0.08)for (var f = V(b), h, i, j, k, m, e = a > 0.3 ? [1, 2, 4] : a > 0.15 ? [1, 2, 4, 6, 8] : [1, 2, 3, 4, 5, 6, 7, 8, 9]; f < c + 1 && !m; f++) {
2460            i = e.length;
2461            for (h = 0; h < i && !m; h++)j = Ba(ia(f) * e[h]), j > b && (!d || k <= c) && k !== v && g.push(k), k > c && (m = !0), k = j
2462        } else if (b = ia(b),
2463                c = ia(c), a = e[d ? "minorTickInterval" : "tickInterval"], a = p(a === "auto" ? null : a, this._minorAutoInterval, (c - b) * (e.tickPixelInterval / (d ? 5 : 1)) / ((d ? f / this.tickPositions.length : f) || 1)), a = ob(a, null, nb(a)), g = Ta(this.getLinearTickPositions(a, b, c), Ba), !d)this._minorAutoInterval = a / 5;
2464        if (!d)this.tickInterval = a;
2465        return g
2466    };
2467    var Mb = B.Tooltip = function () {
2468        this.init.apply(this, arguments)
2469    };
2470    Mb.prototype = {
2471        init: function (a, b) {
2472            var c = b.borderWidth, d = b.style, e = F(d.padding);
2473            this.chart = a;
2474            this.options = b;
2475            this.crosshairs = [];
2476            this.now = {
2477                x: 0,
2478                y: 0
2479            };
2480            this.isHidden = !0;
2481            this.label = a.renderer.label("", 0, 0, b.shape || "callout", null, null, b.useHTML, null, "tooltip").attr({
2482                padding: e,
2483                fill: b.backgroundColor,
2484                "stroke-width": c,
2485                r: b.borderRadius,
2486                zIndex: 8
2487            }).css(d).css({padding: 0}).add().attr({y: -9999});
2488            fa || this.label.shadow(b.shadow);
2489            this.shared = b.shared
2490        }, destroy: function () {
2491            if (this.label)this.label = this.label.destroy();
2492            clearTimeout(this.hideTimer);
2493            clearTimeout(this.tooltipTimeout)
2494        }, move: function (a, b, c, d) {
2495            var e = this, f = e.now, g = e.options.animation !== !1 && !e.isHidden &&
2496                (N(a - f.x) > 1 || N(b - f.y) > 1), h = e.followPointer || e.len > 1;
2497            r(f, {
2498                x: g ? (2 * f.x + a) / 3 : a,
2499                y: g ? (f.y + b) / 2 : b,
2500                anchorX: h ? v : g ? (2 * f.anchorX + c) / 3 : c,
2501                anchorY: h ? v : g ? (f.anchorY + d) / 2 : d
2502            });
2503            e.label.attr(f);
2504            if (g)clearTimeout(this.tooltipTimeout), this.tooltipTimeout = setTimeout(function () {
2505                e && e.move(a, b, c, d)
2506            }, 32)
2507        }, hide: function (a) {
2508            var b = this;
2509            clearTimeout(this.hideTimer);
2510            if (!this.isHidden)this.hideTimer = setTimeout(function () {
2511                b.label.fadeOut();
2512                b.isHidden = !0
2513            }, p(a, this.options.hideDelay, 500))
2514        }, getAnchor: function (a, b) {
2515            var c, d = this.chart,
2516                e = d.inverted, f = d.plotTop, g = d.plotLeft, h = 0, i = 0, j, k, a = ra(a);
2517            c = a[0].tooltipPos;
2518            this.followPointer && b && (b.chartX === v && (b = d.pointer.normalize(b)), c = [b.chartX - d.plotLeft, b.chartY - f]);
2519            c || (o(a, function (a) {
2520                j = a.series.yAxis;
2521                k = a.series.xAxis;
2522                h += a.plotX + (!e && k ? k.left - g : 0);
2523                i += (a.plotLow ? (a.plotLow + a.plotHigh) / 2 : a.plotY) + (!e && j ? j.top - f : 0)
2524            }), h /= a.length, i /= a.length, c = [e ? d.plotWidth - i : h, this.shared && !e && a.length > 1 && b ? b.chartY - f : e ? d.plotHeight - h : i]);
2525            return Ta(c, w)
2526        }, getPosition: function (a, b, c) {
2527            var d = this.chart, e = this.distance,
2528                f = {}
2528, g = c.h || 0, h, i = ["y", d.chartHeight, b, c.plotY + d.plotTop, d.plotTop, d.plotTop + d.plotHeight], j = ["x", d.chartWidth, a, c.plotX + d.plotLeft, d.plotLeft, d.plotLeft + d.plotWidth], k = p(c.ttBelow, d.inverted && !c.negative || !d.inverted && c.negative), m = function (a, b, c, d, h, i) {
2529                    var j = c < d - e, l = d + e + c < b, m = d - e - c;
2530                    d += e;
2531                    if (k && l)f[a] = d; else if (!k && j)f[a] = m; else if (j)f[a] = z(i - c, m - g < 0 ? m : m - g); else if (l)f[a] = t(h, d + g + c > b ? d : d + g); else return !1
2532                }, l = function (a, b, c, d) {
2533                    if (d < e || d > b - e)return !1; else f[a] = d < c / 2 ? 1 : d > b - c / 2 ? b - c - 2 : d - c / 2
2534                }, n = function (a) {
2535                    var b =
2536                        i;
2537                    i = j;
2538                    j = b;
2539                    h = a
2540                }, q = function () {
2541                    m.apply(0, i) !== !1 ? l.apply(0, j) === !1 && !h && (n(!0), q()) : h ? f.x = f.y = 0 : (n(!0), q())
2542                };
2543            (d.inverted || this.len > 1) && n();
2544            q();
2545            return f
2546        }, defaultFormatter: function (a) {
2547            var b = this.points || ra(this), c;
2548            c = [a.tooltipFooterHeaderFormatter(b[0])];
2549            c = c.concat(a.bodyFormatter(b));
2550            c.push(a.tooltipFooterHeaderFormatter(b[0], !0));
2551            return c.join("")
2552        }, refresh: function (a, b) {
2553            var c = this.chart, d = this.label, e = this.options, f, g, h, i = {}, j, k = [];
2554            j = e.formatter || this.defaultFormatter;
2555            var i = c.hoverPoints, m, l = this.shared;
2556            clearTimeout(this.hideTimer);
2557            this.followPointer = ra(a)[0].series.tooltipOptions.followPointer;
2558            h = this.getAnchor(a, b);
2559            f = h[0];
2560            g = h[1];
2561            l && (!a.series || !a.series.noSharedTooltip) ? (c.hoverPoints = a, i && o(i, function (a) {
2562                a.setState()
2563            }), o(a, function (a) {
2564                a.setState("hover");
2565                k.push(a.getLabelConfig())
2566            }), i = {
2567                x: a[0].category,
2568                y: a[0].y
2569            }, i.points = k, this.len = k.length, a = a[0]) : i = a.getLabelConfig();
2570            j = j.call(i, this);
2571            i = a.series;
2572            this.distance = p(i.tooltipOptions.distance, 16);
2573            j === !1 ? this.hide() : (this.isHidden && (kb(d), d.attr("opacity",
2574                1).show()), d.attr({text: j}), m = e.borderColor || a.color || i.color || "#606060", d.attr({stroke: m}), this.updatePosition({
2575                plotX: f,
2576                plotY: g,
2577                negative: a.negative,
2578                ttBelow: a.ttBelow,
2579                h: h[2] || 0
2580            }), this.isHidden = !1);
2581            I(c, "tooltipRefresh", {text: j, x: f + c.plotLeft, y: g + c.plotTop, borderColor: m})
2582        }, updatePosition: function (a) {
2583            var b = this.chart, c = this.label, c = (this.options.positioner || this.getPosition).call(this, c.width, c.height, a);
2584            this.move(w(c.x), w(c.y || 0), a.plotX + b.plotLeft, a.plotY + b.plotTop)
2585        }, getXDateFormat: function (a, b, c) {
2586            var d,
2587                b = b.dateTimeLabelFormats, e = c && c.closestPointRange, f, g = {
2588                    millisecond: 15,
2589                    second: 12,
2590                    minute: 9,
2591                    hour: 6,
2592                    day: 3
2593                }, h, i = "millisecond";
2594            if (e) {
2595                h = Ma("%m-%d %H:%M:%S.%L", a.x);
2596                for (f in E) {
2597                    if (e === E.week && +Ma("%w", a.x) === c.options.startOfWeek && h.substr(6) === "00:00:00.000") {
2598                        f = "week";
2599                        break
2600                    } else if (E[f] > e) {
2601                        f = i;
2602                        break
2603                    } else if (g[f] && h.substr(g[f]) !== "01-01 00:00:00.000".substr(g[f]))break;
2604                    f !== "week" && (i = f)
2605                }
2606                f && (d = b[f])
2607            } else d = b.day;
2608            return d || b.year
2609        }, tooltipFooterHeaderFormatter: function (a, b) {
2610            var c = b ? "footer" : "header", d = a.series,
2611                e = d.tooltipOptions, f = e.xDateFormat, g = d.xAxis, h = g && g.options.type === "datetime" && qa(a.key), c = e[c + "Format"];
2612            h && !f && (f = this.getXDateFormat(a, e, g));
2613            h && f && (c = c.replace("{point.key}", "{point.key:" + f + "}"));
2614            return Ha(c, {point: a, series: d})
2615        }, bodyFormatter: function (a) {
2616            return Ta(a, function (a) {
2617                var c = a.series.tooltipOptions;
2618                return (c.pointFormatter || a.point.tooltipFormatter).call(a.point, c.pointFormat)
2619            })
2620        }
2621    };
2622    var oa;
2623    $a = C.documentElement.ontouchstart !== v;
2624    var Ua = B.Pointer = function (a, b) {
2625        this.init(a, b)
2626    };
2627    Ua.prototype = {
2628        init: function (a,
2629                        b) {
2630            var c = b.chart, d = c.events, e = fa ? "" : c.zoomType, c = a.inverted, f;
2631            this.options = b;
2632            this.chart = a;
2633            this.zoomX = f = /x/.test(e);
2634            this.zoomY = e = /y/.test(e);
2635            this.zoomHor = f && !c || e && c;
2636            this.zoomVert = e && !c || f && c;
2637            this.hasZoom = f || e;
2638            this.runChartClick = d && !!d.click;
2639            this.pinchDown = [];
2640            this.lastValidTouch = {};
2641            if (B.Tooltip && b.tooltip.enabled)a.tooltip = new Mb(a, b.tooltip), this.followTouchMove = p(b.tooltip.followTouchMove, !0);
2642            this.setDOMEvents()
2643        }, normalize: function (a, b) {
2644            var c, d, a = a || window.event, a = Sb(a);
2645            if (!a.target)a.target = a.srcElement;
2646            d = a.touches ? a.touches.length ? a.touches.item(0) : a.changedTouches[0] : a;
2647            if (!b)this.chartPosition = b = Rb(this.chart.container);
2648            d.pageX === v ? (c = t(a.x, a.clientX - b.left), d = a.y) : (c = d.pageX - b.left, d = d.pageY - b.top);
2649            return r(a, {chartX: w(c), chartY: w(d)})
2650        }, getCoordinates: function (a) {
2651            var b = {xAxis: [], yAxis: []};
2652            o(this.chart.axes, function (c) {
2653                b[c.isXAxis ? "xAxis" : "yAxis"].push({axis: c, value: c.toValue(a[c.horiz ? "chartX" : "chartY"])})
2654            });
2655            return b
2656        }, runPointActions: function (a) {
2657            var b = this.chart, c = b.series, d = b.tooltip, e = d ? d.shared :
2658                !1, f = b.hoverPoint, g = b.hoverSeries, h, i = b.chartWidth, j, k, m = [], l, n;
2659            if (!e && !g)for (h = 0; h < c.length; h++)if (c[h].directTouch || !c[h].options.stickyTracking)c = [];
2660            !e && g && g.directTouch && f ? l = f : (o(c, function (b) {
2661                j = b.noSharedTooltip && e;
2662                k = !e && b.directTouch;
2663                b.visible && !j && !k && p(b.options.enableMouseTracking, !0) && (n = b.searchPoint(a, !j && b.kdDimensions === 1)) && m.push(n)
2664            }), o(m, function (a) {
2665                if (a && typeof a.dist === "number" && a.dist < i)i = a.dist, l = a
2666            }));
2667            if (l && (l !== this.prevKDPoint || d && d.isHidden)) {
2668                if (e && !l.series.noSharedTooltip) {
2669                    for (h =
2670                             m.length; h--;)(m[h].clientX !== l.clientX || m[h].series.noSharedTooltip) && m.splice(h, 1);
2671                    m.length && d && d.refresh(m, a);
2672                    o(m, function (b) {
2673                        b.onMouseOver(a, b !== (g && g.directTouch && f || l))
2674                    })
2675                } else if (d && d.refresh(l, a), !g || !g.directTouch)l.onMouseOver(a);
2676                this.prevKDPoint = l
2677            } else c = g && g.tooltipOptions.followPointer, d && c && !d.isHidden && (c = d.getAnchor([{}], a), d.updatePosition({
2678                plotX: c[0],
2679                plotY: c[1]
2680            }));
2681            if (d && !this._onDocumentMouseMove)this._onDocumentMouseMove = function (a) {
2682                if (Y[oa])Y[oa].pointer.onDocumentMouseMove(a)
2683            },
2684                H(C, "mousemove", this._onDocumentMouseMove);
2685            o(b.axes, function (b) {
2686                b.drawCrosshair(a, p(l, f))
2687            })
2688        }, reset: function (a, b) {
2689            var c = this.chart, d = c.hoverSeries, e = c.hoverPoint, f = c.hoverPoints, g = c.tooltip, h = g && g.shared ? f : e;
2690            (a = a && g && h) && ra(h)[0].plotX === v && (a = !1);
2691            if (a)g.refresh(h), e && (e.setState(e.state, !0), o(c.axes, function (a) {
2692                p(a.options.crosshair && a.options.crosshair.snap, !0) ? a.drawCrosshair(null, e) : a.hideCrosshair()
2693            })); else {
2694                if (e)e.onMouseOut();
2695                f && o(f, function (a) {
2696                    a.setState()
2697                });
2698                if (d)d.onMouseOut();
2699                g && g.hide(b);
2700                if (this._onDocumentMouseMove)Z(C, "mousemove", this._onDocumentMouseMove), this._onDocumentMouseMove = null;
2701                o(c.axes, function (a) {
2702                    a.hideCrosshair()
2703                });
2704                this.hoverX = c.hoverPoints = c.hoverPoint = null
2705            }
2706        }, scaleGroups: function (a, b) {
2707            var c = this.chart, d;
2708            o(c.series, function (e) {
2709                d = a || e.getPlotBox();
2710                e.xAxis && e.xAxis.zoomEnabled && (e.group.attr(d), e.markerGroup && (e.markerGroup.attr(d), e.markerGroup.clip(b ? c.clipRect : null)), e.dataLabelsGroup && e.dataLabelsGroup.attr(d))
2711            });
2712            c.clipRect.attr(b || c.clipBox)
2713        }, dragStart: function (a) {
2714            var b =
2715                this.chart;
2716            b.mouseIsDown = a.type;
2717            b.cancelClick = !1;
2718            b.mouseDownX = this.mouseDownX = a.chartX;
2719            b.mouseDownY = this.mouseDownY = a.chartY
2720        }, drag: function (a) {
2721            var b = this.chart, c = b.options.chart, d = a.chartX, e = a.chartY, f = this.zoomHor, g = this.zoomVert, h = b.plotLeft, i = b.plotTop, j = b.plotWidth, k = b.plotHeight, m, l = this.selectionMarker, n = this.mouseDownX, q = this.mouseDownY, x = c.panKey && a[c.panKey + "Key"];
2722            if (!l || !l.touch)if (d < h ? d = h : d > h + j && (d = h + j), e < i ? e = i : e > i + k && (e = i + k), this.hasDragged = Math.sqrt(Math.pow(n - d, 2) + Math.pow(q - e, 2)), this.hasDragged >
2723                10) {
2724                m = b.isInsidePlot(n - h, q - i);
2725                if (b.hasCartesianSeries && (this.zoomX || this.zoomY) && m && !x && !l)this.selectionMarker = l = b.renderer.rect(h, i, f ? 1 : j, g ? 1 : k, 0).attr({
2726                    fill: c.selectionMarkerFill || "rgba(69,114,167,0.25)",
2727                    zIndex: 7
2728                }).add();
2729                l && f && (d -= n, l.attr({width: N(d), x: (d > 0 ? 0 : d) + n}));
2730                l && g && (d = e - q, l.attr({height: N(d), y: (d > 0 ? 0 : d) + q}));
2731                m && !l && c.panning && b.pan(a, c.panning)
2732            }
2733        }, drop: function (a) {
2734            var b = this, c = this.chart, d = this.hasPinched;
2735            if (this.selectionMarker) {
2736                var e = {
2737                    xAxis: [], yAxis: [], originalEvent: a.originalEvent ||
2738                    a
2739                }, f = this.selectionMarker, g = f.attr ? f.attr("x") : f.x, h = f.attr ? f.attr("y") : f.y, i = f.attr ? f.attr("width") : f.width, j = f.attr ? f.attr("height") : f.height, k;
2740                if (this.hasDragged || d)o(c.axes, function (c) {
2741                    if (c.zoomEnabled && s(c.min) && (d || b[{xAxis: "zoomX", yAxis: "zoomY"}[c.coll]])) {
2742                        var f = c.horiz, n = a.type === "touchend" ? c.minPixelPadding : 0, q = c.toValue((f ? g : h) + n), f = c.toValue((f ? g + i : h + j) - n);
2743                        e[c.coll].push({axis: c, min: z(q, f), max: t(q, f)}
2743);
2744                        k = !0
2745                    }
2746                }), k && I(c, "selection", e, function (a) {
2747                    c.zoom(r(a, d ? {animation: !1} : null))
2748                });
2749                this.selectionMarker =
2750                    this.selectionMarker.destroy();
2751                d && this.scaleGroups()
2752            }
2753            if (c)L(c.container, {cursor: c._cursor}), c.cancelClick = this.hasDragged > 10, c.mouseIsDown = this.hasDragged = this.hasPinched = !1, this.pinchDown = []
2754        }, onContainerMouseDown: function (a) {
2755            a = this.normalize(a);
2756            a.preventDefault && a.preventDefault();
2757            this.dragStart(a)
2758        }, onDocumentMouseUp: function (a) {
2759            Y[oa] && Y[oa].pointer.drop(a)
2760        }, onDocumentMouseMove: function (a) {
2761            var b = this.chart, c = this.chartPosition, a = this.normalize(a, c);
2762            c && !this.inClass(a.target, "highcharts-tracker") && !b.isInsidePlot(a.chartX - b.plotLeft, a.chartY - b.plotTop) && this.reset()
2763        }, onContainerMouseLeave: function () {
2764            var a = Y[oa];
2765            if (a)a.pointer.reset(), a.pointer.chartPosition = null
2766        }, onContainerMouseMove: function (a) {
2767            var b = this.chart;
2768            oa = b.index;
2769            a = this.normalize(a);
2770            a.returnValue = !1;
2771            b.mouseIsDown === "mousedown" && this.drag(a);
2772            (this.inClass(a.target, "highcharts-tracker") || b.isInsidePlot(a.chartX - b.plotLeft, a.chartY - b.plotTop)) && !b.openMenu && this.runPointActions(a)
2773        }, inClass: function (a, b) {
2774            for (var c; a;) {
2775                if (c = J(a, "class"))if (c.indexOf(b) !== -1)return !0; else if (c.indexOf("highcharts-container") !== -1)return !1;
2776                a = a.parentNode
2777            }
2778        }, onTrackerMouseOut: function (a) {
2779            var b = this.chart.hoverSeries, c = (a = a.relatedTarget || a.toElement) && a.point && a.point.series;
2780            if (b && !b.options.stickyTracking && !this.inClass(a, "highcharts-tooltip") && c !== b)b.onMouseOut()
2781        }, onContainerClick: function (a) {
2782            var b = this.chart, c = b.hoverPoint, d = b.plotLeft, e = b.plotTop, a = this.normalize(a);
2783            a.originalEvent = a;
2784            b.cancelClick || (c && this.inClass(a.target, "highcharts-tracker") ? (I(c.series, "click",
2785                r(a, {point: c})), b.hoverPoint && c.firePointEvent("click", a)) : (r(a, this.getCoordinates(a)), b.isInsidePlot(a.chartX - d, a.chartY - e) && I(b, "click", a)))
2786        }, setDOMEvents: function () {
2787            var a = this, b = a.chart.container;
2788            b.onmousedown = function (b) {
2789                a.onContainerMouseDown(b)
2790            };
2791            b.onmousemove = function (b) {
2792                a.onContainerMouseMove(b)
2793            };
2794            b.onclick = function (b) {
2795                a.onContainerClick(b)
2796            };
2797            H(b, "mouseleave", a.onContainerMouseLeave);
2798            ab === 1 && H(C, "mouseup", a.onDocumentMouseUp);
2799            if ($a)b.ontouchstart = function (b) {
2800                a.onContainerTouchStart(b)
2801            }, b.ontouchmove =
2802                function (b) {
2803                    a.onContainerTouchMove(b)
2804                }, ab === 1 && H(C, "touchend", a.onDocumentTouchEnd)
2805        }, destroy: function () {
2806            var a;
2807            Z(this.chart.container, "mouseleave", this.onContainerMouseLeave);
2808            ab || (Z(C, "mouseup", this.onDocumentMouseUp), Z(C, "touchend", this.onDocumentTouchEnd));
2809            clearInterval(this.tooltipTimeout);
2810            for (a in this)this[a] = null
2811        }
2812    };
2813    r(B.Pointer.prototype, {
2814        pinchTranslate: function (a, b, c, d, e, f) {
2815            (this.zoomHor || this.pinchHor) && this.pinchTranslateDirection(!0, a, b, c, d, e, f);
2816            (this.zoomVert || this.pinchVert) && this.pinchTranslateDirection(!1,
2817                a, b, c, d, e, f)
2818        }, pinchTranslateDirection: function (a, b, c, d, e, f, g, h) {
2819            var i = this.chart, j = a ? "x" : "y", k = a ? "X" : "Y", m = "chart" + k, l = a ? "width" : "height", n = i["plot" + (a ? "Left" : "Top")], q, x, p = h || 1, o = i.inverted, u = i.bounds[a ? "h" : "v"], t = b.length === 1, s = b[0][m], r = c[0][m], w = !t && b[1][m], v = !t && c[1][m], z, c = function () {
2820                !t && N(s - w) > 20 && (p = h || N(r - v) / N(s - w));
2821                x = (n - r) / p + s;
2822                q = i["plot" + (a ? "Width" : "Height")] / p
2823            };
2824            c();
2825            b = x;
2826            b < u.min ? (b = u.min, z = !0) : b + q > u.max && (b = u.max - q, z = !0);
2827            z ? (r -= 0.8 * (r - g[j][0]), t || (v -= 0.8 * (v - g[j][1])), c()) : g[j] = [r, v];
2828            o || (f[j] =
2829                x - n, f[l] = q);
2830            f = o ? 1 / p : p;
2831            e[l] = q;
2832            e[j] = b;
2833            d[o ? a ? "scaleY" : "scaleX" : "scale" + k] = p;
2834            d["translate" + k] = f * n + (r - f * s)
2835        }, pinch: function (a) {
2836            var b = this, c = b.chart, d = b.pinchDown, e = a.touches, f = e.length, g = b.lastValidTouch, h = b.hasZoom, i = b.selectionMarker, j = {}, k = f === 1 && (b.inClass(a.target, "highcharts-tracker") && c.runTrackerClick || b.runChartClick), m = {};
2837            if (f > 1)b.initiated = !0;
2838            h && b.initiated && !k && a.preventDefault();
2839            Ta(e, function (a) {
2840                return b.normalize(a)
2841            });
2842            if (a.type === "touchstart")o(e, function (a, b) {
2843                d[b] = {chartX: a.chartX, chartY: a.chartY}
2844            }),
2845                g.x = [d[0].chartX, d[1] && d[1].chartX], g.y = [d[0].chartY, d[1] && d[1].chartY], o(c.axes, function (a) {
2846                if (a.zoomEnabled) {
2847                    var b = c.bounds[a.horiz ? "h" : "v"], d = a.minPixelPadding, e = a.toPixels(p(a.options.min, a.dataMin)), f = a.toPixels(p(a.options.max, a.dataMax)), g = z(e, f), e = t(e, f);
2848                    b.min = z(a.pos, g - d);
2849                    b.max = t(a.pos + a.len, e + d)
2850                }
2851            }), b.res = !0; else if (d.length) {
2852                if (!i)b.selectionMarker = i = r({destroy: ta, touch: !0}, c.plotBox);
2853                b.pinchTranslate(d, e, j, i, m, g);
2854                b.hasPinched = h;
2855                b.scaleGroups(j, m);
2856                if (!h && b.followTouchMove && f === 1)this.runPointActions(b.normalize(a));
2857                else if (b.res)b.res = !1, this.reset(!1, 0)
2858            }
2859        }, touch: function (a, b) {
2860            var c = this.chart;
2861            oa = c.index;
2862            a.touches.length === 1 ? (a = this.normalize(a), c.isInsidePlot(a.chartX - c.plotLeft, a.chartY - c.plotTop) && !c.openMenu ? (b && this.runPointActions(a), this.pinch(a)) : b && this.reset()) : a.touches.length === 2 && this.pinch(a)
2863        }, onContainerTouchStart: function (a) {
2864            this.touch(a, !0)
2865        }, onContainerTouchMove: function (a) {
2866            this.touch(a)
2867        }, onDocumentTouchEnd: function (a) {
2868            Y[oa] && Y[oa].pointer.drop(a)
2869        }
2870    });
2871    if (K.PointerEvent || K.MSPointerEvent) {
2872        var va =
2873        {}, Ab = !!K.PointerEvent, Wb = function () {
2874            var a, b = [];
2875            b.item = function (a) {
2876                return this[a]
2877            };
2878            for (a in va)va.hasOwnProperty(a) && b.push({pageX: va[a].pageX, pageY: va[a].pageY, target: va[a].target});
2879            return b
2880        }, Bb = function (a, b, c, d) {
2881            a = a.originalEvent || a;
2882            if ((a.pointerType === "touch" || a.pointerType === a.MSPOINTER_TYPE_TOUCH) && Y[oa])d(a), d = Y[oa].pointer, d[b]({
2883                type: c,
2884                target: a.currentTarget,
2885                preventDefault: ta,
2886                touches: Wb()
2887            })
2888        };
2889        r(Ua.prototype, {
2890            onContainerPointerDown: function (a) {
2891                Bb(a, "onContainerTouchStart", "touchstart", function (a) {
2892                    va[a.pointerId] =
2893                    {pageX: a.pageX, pageY: a.pageY, target: a.currentTarget}
2894                })
2895            }, onContainerPointerMove: function (a) {
2896                Bb(a, "onContainerTouchMove", "touchmove", function (a) {
2897                    va[a.pointerId] = {pageX: a.pageX, pageY: a.pageY};
2898                    if (!va[a.pointerId].target)va[a.pointerId].target = a.currentTarget
2899                })
2900            }, onDocumentPointerUp: function (a) {
2901                Bb(a, "onDocumentTouchEnd", "touchend", function (a) {
2902                    delete va[a.pointerId]
2903                })
2904            }, batchMSEvents: function (a) {
2905                a(this.chart.container, Ab ? "pointerdown" : "MSPointerDown", this.onContainerPointerDown);
2906                a(this.chart.container, Ab ?
2907                    "pointermove" : "MSPointerMove", this.onContainerPointerMove);
2908                a(C, Ab ? "pointerup" : "MSPointerUp", this.onDocumentPointerUp)
2909            }
2910        });
2911        Sa(Ua.prototype, "init", function (a, b, c) {
2912            a.call(this, b, c);
2913            this.hasZoom && L(b.container, {"-ms-touch-action": O, "touch-action": O})
2914        });
2915        Sa(Ua.prototype, "setDOMEvents", function (a) {
2916            a.apply(this);
2917            (this.hasZoom || this.followTouchMove) && this.batchMSEvents(H)
2918        });
2919        Sa(Ua.prototype, "destroy", function (a) {
2920            this.batchMSEvents(Z);
2921            a.call(this)
2922        })
2923    }
2924    var lb = B.Legend = function (a, b) {
2925        this.init(a, b)
2926    };
2927    lb.prototype =
2928    {
2929        init: function (a, b) {
2930            var c = this, d = b.itemStyle, e = b.itemMarginTop || 0;
2931            this.options = b;
2932            if (b.enabled)c.itemStyle = d, c.itemHiddenStyle = A(d, b.itemHiddenStyle), c.itemMarginTop = e, c.padding = d = p(b.padding, 8), c.initialItemX = d, c.initialItemY = d - 5, c.maxItemWidth = 0, c.chart = a, c.itemHeight = 0, c.symbolWi
2932dth = p(b.symbolWidth, 16), c.pages = [], c.render(), H(c.chart, "endResize", function () {
2933                c.positionCheckboxes()
2934            })
2935        }, colorizeItem: function (a, b) {
2936        var c = this.options, d = a.legendItem, e = a.legendLine, f = a.legendSymbol, g = this.itemHiddenStyle.color,
2937            c = b ? c.itemStyle.color : g, h = b ? a.legendColor || a.color || "#CCC" : g, g = a.options && a.options.marker, i = {fill: h}, j;
2938        d && d.css({fill: c, color: c});
2939        e && e.attr({stroke: h});
2940        if (f) {
2941            if (g && f.isMarker)for (j in i.stroke = h, g = a.convertAttribs(g), g)d = g[j], d !== v && (i[j] = d);
2942            f.attr(i)
2943        }
2944    }, positionItem: function (a) {
2945        var b = this.options, c = b.symbolPadding, b = !b.rtl, d = a._legendItemPos, e = d[0], d = d[1], f = a.checkbox;
2946        (a = a.legendGroup) && a.element && a.translate(b ? e : this.legendWidth - e - 2 * c - 4, d);
2947        if (f)f.x = e, f.y = d
2948    }, destroyItem: function (a) {
2949        var b = a.checkbox;
2950        o(["legendItem", "legendLine", "legendSymbol", "legendGroup"], function (b) {
2951            a[b] && (a[b] = a[b].destroy())
2952        });
2953        b && Pa(a.checkbox)
2954    }, destroy: function () {
2955        var a = this.group, b = this.box;
2956        if (b)this.box = b.destroy();
2957        if (a)this.group = a.destroy()
2958    }, positionCheckboxes: function (a) {
2959        var b = this.group.alignAttr, c, d = this.clipHeight || this.legendHeight;
2960        if (b)c = b.translateY, o(this.allItems, function (e) {
2961            var f = e.checkbox, g;
2962            f && (g = c + f.y + (a || 0) + 3, L(f, {
2963                left: b.translateX + e.checkboxOffset + f.x - 20 + "px",
2964                top: g + "px",
2965                display: g > c - 6 && g < c + d - 6 ? "" : O
2966            }))
2967        })
2968    },
2969        renderTitle: function () {
2970            var a = this.padding, b = this.options.title, c = 0;
2971            if (b.text) {
2972                if (!this.title)this.title = this.chart.renderer.label(b.text, a - 3, a - 4, null, null, null, null, null, "legend-title").attr({zIndex: 1}).css(b.style).add(this.group);
2973                a = this.title.getBBox();
2974                c = a.height;
2975                this.offsetWidth = a.width;
2976                this.contentGroup.attr({translateY: c})
2977            }
2978            this.titleHeight = c
2979        }, setText: function (a) {
2980        var b = this.options;
2981        a.legendItem.attr({text: b.labelFormat ? Ha(b.labelFormat, a) : b.labelFormatter.call(a)})
2982    }, renderItem: function (a) {
2983        var b =
2984            this.chart, c = b.renderer, d = this.options, e = d.layout === "horizontal", f = this.symbolWidth, g = d.symbolPadding, h = this.itemStyle, i = this.itemHiddenStyle, j = this.padding, k = e ? p(d.itemDistance, 20) : 0, m = !d.rtl, l = d.width, n = d.itemMarginBottom || 0, q = this.itemMarginTop, x = this.initialItemX, o = a.legendItem, s = a.series && a.series.drawLegendSymbol ? a.series : a, u = s.options, u = this.createCheckboxForItem && u && u.showCheckbox, y = d.useHTML;
2985        if (!o) {
2986            a.legendGroup = c.g("legend-item").attr({zIndex: 1}).add(this.scrollGroup);
2987            a.legendItem = o = c.text("",
2988                m ? f + g : -g, this.baseline || 0, y).css(A(a.visible ? h : i)).attr({
2989                    align: m ? "left" : "right",
2990                    zIndex: 2
2991                }).add(a.legendGroup);
2992            if (!this.baseline)this.fontMetrics = c.fontMetrics(h.fontSize, o), this.baseline = this.fontMetrics.f + 3 + q, o.attr("y", this.baseline);
2993            s.drawLegendSymbol(this, a);
2994            this.setItemEvents && this.setItemEvents(a, o, y, h, i);
2995            this.colorizeItem(a, a.visible);
2996            u && this.createCheckboxForItem(a)
2997        }
2998        this.setText(a);
2999        c = o.getBBox();
3000        f = a.checkboxOffset = d.itemWidth || a.legendItemWidth || f + g + c.width + k + (u ? 20 : 0);
3001        this.itemHeight = g = w(a.legendItemHeight ||
3002            c.height);
3003        if (e && this.itemX - x + f > (l || b.chartWidth - 2 * j - x - d.x))this.itemX = x, this.itemY += q + this.lastLineHeight + n, this.lastLineHeight = 0;
3004        this.maxItemWidth = t(this.maxItemWidth, f);
3005        this.lastItemY = q + this.itemY + n;
3006        this.lastLineHeight = t(g, this.lastLineHeight);
3007        a._legendItemPos = [this.itemX, this.itemY];
3008        e ? this.itemX += f : (this.itemY += q + g + n, this.lastLineHeight = g);
3009        this.offsetWidth = l || t((e ? this.itemX - x - k : f) + j, this.offsetWidth)
3010    }, getAllItems: function () {
3011        var a = [];
3012        o(this.chart.series, function (b) {
3013            var c = b.options;
3014            if (p(c.showInLegend,
3015                    !s(c.linkedTo) ? v : !1, !0))a = a.concat(b.legendItems || (c.legendT
3015ype === "point" ? b.data : b))
3016        });
3017        return a
3018    }, adjustMargins: function (a, b) {
3019        var c = this.chart, d = this.options, e = d.align.charAt(0) + d.verticalAlign.charAt(0) + d.layout.charAt(0);
3020        this.display && !d.floating && o([/(lth|ct|rth)/, /(rtv|rm|rbv)/, /(rbh|cb|lbh)/, /(lbv|lm|ltv)/], function (f, g) {
3021            f.test(e) && !s(a[g]) && (c[gb[g]] = t(c[gb[g]], c.legend[(g + 1) % 2 ? "legendHeight" : "legendWidth"] + [1, -1, -1, 1][g] * d[g % 2 ? "x" : "y"] + p(d.margin, 12) + b[g]))
3022        })
3023    }, render: function () {
3024        var a = this, b =
3025            a.chart, c = b.renderer, d = a.group, e, f, g, h, i = a.box, j = a.options, k = a.padding, m = j.borderWidth, l = j.backgroundColor;
3026        a.itemX = a.initialItemX;
3027        a.itemY = a.initialItemY;
3028        a.offsetWidth = 0;
3029        a.lastItemY = 0;
3030        if (!d)a.group = d = c.g("legend").attr({zIndex: 7}).add(), a.contentGroup = c.g().attr({zIndex: 1}).add(d), a.scrollGroup = c.g().add(a.contentGroup);
3031        a.renderTitle();
3032        e = a.getAllItems();
3033        pb(e, function (a, b) {
3034            return (a.options && a.options.legendIndex || 0) - (b.options && b.options.legendIndex || 0)
3035        });
3036        j.reversed && e.reverse();
3037        a.allItems = e;
3038        a.display =
3039            f = !!e.length;
3040        a.lastLineHeight = 0;
3041        o(e, function (b) {
3042            a.renderItem(b)
3043        });
3044        g = (j.width || a.offsetWidth) + k;
3045        h = a.lastItemY + a.lastLineHeight + a.titleHeight;
3046        h = a.handleOverflow(h);
3047        h += k;
3048        if (m || l) {
3049            if (i) {
3050                if (g > 0 && h > 0)i[i.isNew ? "attr" : "animate"](i.crisp({width: g, height: h})), i.isNew = !1
3051            } else a.box = i = c.rect(0, 0, g, h, j.borderRadius, m || 0).attr({
3052                stroke: j.borderColor,
3053                "stroke-width": m || 0,
3054                fill: l || O
3055            }).add(d).shadow(j.shadow), i.isNew = !0;
3056            i[f ? "show" : "hide"]()
3057        }
3058        a.legendWidth = g;
3059        a.legendHeight = h;
3060        o(e, function (b) {
3061            a.positionItem(b)
3062        });
3063        f && d.align(r({
3064            width: g,
3065            height: h
3066        }, j), !0, "spacingBox");
3067        b.isResizing || this.positionCheckboxes()
3068    }, handleOverflow: function (a) {
3069        var b = this, c = this.chart, d = c.renderer, e = this.options, f = e.y, f = c.spacingBox.height + (e.verticalAlign === "top" ? -f : f) - this.padding, g = e.maxHeight, h, i = this.clipRect, j = e.navigation, k = p(j.animation, !0), m = j.arrowSize || 12, l = this.nav, n = this.pages, q = this.padding, x, s = this.allItems, r = function (a) {
3070            i.attr({height: a});
3071            if (b.contentGroup.div)b.contentGroup.div.style.clip = "rect(" + q + "px,9999px," + (q + a) + "px,0)"
3072        };
3073        e.layout === "horizontal" &&
3074        (f /= 2);
3075        g && (f = z(f, g));
3076        n.length = 0;
3077        if (a > f) {
3078            this.clipHeight = h = t(f - 20 - this.titleHeight - q, 0);
3079            this.currentPage = p(this.currentPage, 1);
3080            this.fullHeight = a;
3081            o(s, function (a, b) {
3082                var c = a._legendItemPos[1], d = w(a.legendItem.getBBox().height), e = n.length;
3083                if (!e || c - n[e - 1] > h && (x || c) !== n[e - 1])n.push(x || c), e++;
3084                b === s.length - 1 && c + d - n[e - 1] > h && n.push(c);
3085                c !== x && (x = c)
3086            });
3087            if (!i)i = b.clipRect = d.clipRect(0, q, 9999, 0), b.contentGroup.clip(i);
3088            r(h);
3089            if (!l)this.nav = l = d.g().attr({zIndex: 1}).add(this.group), this.up = d.symbol("triangle", 0, 0, m,
3090                m).on("click", function () {
3091                    b.scroll(-1, k)
3092                }).add(l), this.pager = d.text("", 15, 10).css(j.style).add(l), this.down = d.symbol("triangle-down", 0, 0, m, m).on("click", function () {
3093                b.scroll(1, k)
3094            }).add(l);
3095            b.scroll(0);
3096            a = f
3097        } else if (l)r(c.chartHeight), l.hide(), this.scrollGroup.attr({translateY: 1}), this.clipHeight = 0;
3098        return a
3099    }, scroll: function (a, b) {
3100        var c = this.pages, d = c.length, e = this.currentPage + a, f = this.clipHeight, g = this.options.navigation, h = g.activeColor, g = g.inactiveColor, i = this.pager, j = this.padding;
3101        e > d && (e = d);
3102        if (e > 0)b !==
3103        v && Qa(b, this.chart), this.nav.attr({
3104            translateX: j,
3105            translateY: f + this.padding + 7 + this.titleHeight,
3106            visibility: "visible"
3107        }), this.up.attr({fill: e === 1 ? g : h}).css({cursor: e === 1 ? "default" : "pointer"}), i.attr({text: e + "/" + d}), this.down.attr({
3108            x: 18 + this.pager.getBBox().width,
3109            fill: e === d ? g : h
3110        }).css({cursor: e === d ? "default" : "pointer"}), c = -c[e - 1] + this.initialItemY, this.scrollGroup.animate({translateY: c}), this.currentPage = e, this.positionCheckboxes(c)
3111    }
3112    };
3113    La = B.LegendSymbolMixin = {
3114        drawRectangle: function (a, b) {
3115            var c = a.options.symbolHeight ||
3116                a.fontMetrics.f;
3117            b.legendSymbol = this.chart.renderer.rect(0, a.baseline - c + 1, a.symbolWi
3117dth, c, a.options.symbolRadius || 0).attr({zIndex: 3}).add(b.legendGroup)
3118        }, drawLineMarker: function (a) {
3119            var b = this.options, c = b.marker, d;
3120            d = a.symbolWidth;
3121            var e = this.chart.renderer, f = this.legendGroup, a = a.baseline - w(a.fontMetrics.b * 0.3), g;
3122            if (b.lineWidth) {
3123                g = {"stroke-width": b.lineWidth};
3124                if (b.dashStyle)g.dashstyle = b.dashStyle;
3125                this.legendLine = e.path(["M", 0, a, "L", d, a]).attr(g).add(f)
3126            }
3127            if (c && c.enabled !== !1)b = c.radius, this.legendSymbol =
3128                d = e.symbol(this.symbol, d / 2 - b, a - b, 2 * b, 2 * b).add(f), d.isMarker = !0
3129        }
3130    };
3131    (/Trident\/7\.0/.test(za) || Ja) && Sa(lb.prototype, "positionItem", function (a, b) {
3132        var c = this, d = function () {
3133            b._legendItemPos && a.call(c, b)
3134        };
3135        d();
3136        setTimeout(d)
3137    });
3138    D = B.Chart = function () {
3139        this.init.apply(this, arguments)
3140    };
3141    D.prototype = {
3142        callbacks: [], init: function (a, b) {
3143            var c, d = a.series;
3144            a.series = null;
3145            c = A(S, a);
3146            c.series = a.series = d;
3147            this.userOptions = a;
3148            d = c.chart;
3149            this.margin = this.splashArray("margin", d);
3150            this.spacing = this.splashArray("spacing", d);
3151            var e = d.events;
3152            this.bounds = {h: {}, v: {}};
3153            this.callback = b;
3154            this.isResizing = 0;
3155            this.options = c;
3156            this.axes = [];
3157            this.series = [];
3158            this.hasCartesianSeries = d.showAxes;
3159            var f = this, g;
3160            f.index = Y.length;
3161            Y.push(f);
3162            ab++;
3163            d.reflow !== !1 && H(f, "load", function () {
3164                f.initReflow()
3165            });
3166            if (e)for (g in e)H(f, g, e[g]);
3167            f.xAxis = [];
3168            f.yAxis = [];
3169            f.animation = fa ? !1 : p(d.animation, !0);
3170            f.pointCount = f.colorCounter = f.symbolCounter = 0;
3171            f.firstRender()
3172        }, initSeries: function (a) {
3173            var b = this.options.chart;
3174            (b = M[a.type || b.type || b.defaultSeriesType]) || la(17, !0);
3175            b = new b;
3176            b.init(this,
3177                a);
3178            return b
3179        }, isInsidePlot: function (a, b, c) {
3180            var d = c ? b : a, a = c ? a : b;
3181            return d >= 0 && d <= this.plotWidth && a >= 0 && a <= this.plotHeight
3182        }, redraw: function (a) {
3183            var b = this.axes, c = this.series, d = this.pointer, e = this.legend, f = this.isDirtyLegend, g, h, i = this.hasCartesianSeries, j = this.isDirtyBox, k = c.length, m = k, l = this.renderer, n = l.isHidden(), q = [];
3184            Qa(a, this);
3185            n && this.cloneRenderTo();
3186            for (this.layOutTitles(); m--;)if (a = c[m], a.options.stacking && (g = !0, a.isDirty)) {
3187                h = !0;
3188                break
3189            }
3190            if (h)for (m = k; m--;)if (a = c[m], a.options.stacking)a.isDirty = !0;
3191            o(c, function (a) {
3192                a.isDirty && a.options.legendType === "point" && (a.updateTotals && a.updateTotals(), f = !0)
3193            });
3194            if (f && e.options.enabled)e.render(), this.isDirtyLegend = !1;
3195            g && this.getStacks();
3196            if (i && !this.isResizing)this.maxTicks = null, o(b, function (a) {
3197                a.setScale()
3198            });
3199            this.getMargins();
3200            i && (o(b, function (a) {
3201                a.isDirty && (j = !0)
3202            }), o(b, function (a) {
3203                var b = a.min + "," + a.max;
3204                if (a.extKey !== b)a.extKey = b, q.push(function () {
3205                    I(a, "afterSetExtremes", r(a.eventArgs, a.getExtremes()));
3206                    delete a.eventArgs
3207                });
3208                (j || g) && a.redraw()
3209            }));
3210            j && this.drawChartBox();
3211            o(c, function (a) {
3212                a.isDirty && a.visible && (!a.isCartesian || a.xAxis) && a.redraw()
3213            });
3214            d && d.reset(!0);
3215            l.draw();
3216            I(this, "redraw");
3217            n && this.cloneRenderTo(!0);
3218            o(q, function (a) {
3219                a.call()
3220            })
3221        }, get: function (a) {
3222            var b = this.axes, c = this.series, d, e;
3223            for (d = 0; d < b.length; d++)if (b[d].options.id === a)return b[d];
3224            for (d = 0; d < c.length; d++)if (c[d].options.id === a)return c[d];
3225            for (d = 0; d < c.length; d++) {
3226                e = c[d].points || [];
3227                for (b = 0; b < e.length; b++)if (e[b].id === a)return e[b]
3228            }
3229            return null
3230        }, getAxes: function () {
3231            var a = this, b = this.options, c = b.xAxis = ra(b.xAxis ||
3232                {}), b = b.yAxis = ra(b.yAxis || {});
3233            o(c, function (a, b) {
3234                a.index = b;
3235                a.isX = !0
3236            });
3237            o(b, function (a, b) {
3238                a.index = b
3239            });
3240            c = c.concat(b);
3241            o(c, function (b) {
3242                new ha(a, b)
3243            })
3244        }, getSelectedPoints: function () {
3245            var a = [];
3246            o(this.series, function (b) {
3247                a = a.concat(ib(b.points || [], function (a) {
3248                    return a.selected
3249                }))
3250            });
3251            return a
3252        }, getSelectedSeries: function () {
3253            return ib(this.series, function (a) {
3254                return a.selected
3255            })
3256        }, setTitle: function (a, b, c) {
3257            var g;
3258            var d = this, e = d.options, f;
3259            f = e.title = A(e.title, a);
3260            g = e.subtitle = A(e.subtitle, b), e = g;
3261            o([["title", a, f], ["subtitle",
3262                b, e]], function (a) {
3263                var b = a[0], c = d[b], e = a[1], a = a[2];
3264                c && e && (d[b] = c = c.destroy());
3265                a && a.text && !c && (d[b] = d.renderer.text(a.text, 0, 0, a.useHTML).attr({
3266                    align: a.align,
3267                    "class": "highcharts-" + b,
3268                    zIndex: a.zIndex || 4
3269                }).css(a.style).add())
3270            });
3271            d.layOutTitles(c)
3272        }, layOutTitles: function (a) {
3273            var b = 0, c = this.title, d = this.subtitle, e = this.options, f = e.title, e = e.subtitle, g = this.renderer, h = this.spacingBox.width - 44;
3274            if (c && (c.css({width: (f.width || h) + "px"}).align(r({y: g.fontMetrics(f.style.fontSize, c).b - 3}, f), !1, "spacingBox"), !f.floating && !f.verticalAlign))b = c.getBBox().height;
3275            d && (d.css({width: (e.width || h) + "px"}).align(r({y: b + (f.margin - 13) + g.fontMetrics(f.style.fontSize, d).b}, e), !1, "spacingBox"), !e.floating && !e.verticalAlign && (b = sa(b 
3275+ d.getBBox().height)));
3276            c = this.titleOffset !== b;
3277            this.titleOffset = b;
3278            if (!this.isDirtyBox && c)this.isDirtyBox = c, this.hasRendered && p(a, !0) && this.isDirtyBox && this.redraw()
3279        }, getChartSize: function () {
3280            var a = this.options.chart, b = a.width, a = a.height, c = this.renderToClone || this.renderTo;
3281            if (!s(b))this.containerWidth = hb(c,
3282                "width");
3283            if (!s(a))this.containerHeight = hb(c, "height");
3284            this.chartWidth = t(0, b || this.containerWidth || 600);
3285            this.chartHeight = t(0, p(a, this.containerHeight > 19 ? this.containerHeight : 400))
3286        }, cloneRenderTo: function (a) {
3287            var b = this.renderToClone, c = this.container;
3288            a ? b && (this.renderTo.appendChild(c), Pa(b), delete this.renderToClone) : (c && c.parentNode === this.renderTo && this.renderTo.removeChild(c), this.renderToClone = b = this.renderTo.cloneNode(0), L(b, {
3289                position: "absolute",
3290                top: "-9999px",
3291                display: "block"
3292            }), b.style.setProperty &&
3293            b.style.setProperty("display", "block", "important"), C.body.appendChild(b), c && b.appendChild(c))
3294        }, getContainer: function () {
3295            var a, b = this.options.chart, c, d, e;
3296            this.renderTo = a = b.renderTo;
3297            e = "highcharts-" + wb++;
3298            if (Aa(a))this.renderTo = a = C.getElementById(a);
3299            a || la(13, !0);
3300            c = F(J(a, "data-highcharts-chart"));
3301            !isNaN(c) && Y[c] && Y[c].hasRendered && Y[c].destroy();
3302            J(a, "data-highcharts-chart", this.index);
3303            a.innerHTML = "";
3304            !b.skipClone && !a.offsetWidth && this.cloneRenderTo();
3305            this.getChartSize();
3306            c = this.chartWidth;
3307            d = this.chartHeight;
3308            this.container = a = $(Ia, {
3309                className: "highcharts-container" + (b.className ? " " + b.className : ""),
3310                id: e
3311            }, r({
3312                position: "relative",
3313                overflow: "hidden",
3314                width: c + "px",
3315                height: d + "px",
3316                textAlign: "left",
3317                lineHeight: "normal",
3318                zIndex: 0,
3319                "-webkit-tap-highlight-color": "rgba(0,0,0,0)"
3320            }, b.style), this.renderToClone || a);
3321            this._cursor = a.style.cursor;
3322            this.renderer = b.forExport ? new ua(a, c, d, b.style, !0) : new Za(a, c, d, b.style);
3323            fa && this.renderer.create(this, a, c, d);
3324            this.renderer.chartIndex = this.index
3325        }, getMargins: function (a) {
3326            var b = this.spacing,
3327                c = this.margin, d = this.titleOffset;
3328            this.resetMargins();
3329            if (d && !s(c[0]))this.plotTop = t(this.plotTop, d + this.options.title.margin + b[0]);
3330            this.legend.adjustMargins(c, b);
3331            this.extraBottomMargin && (this.marginBottom += this.extraBottomMargin);
3332            this.extraTopMargin && (this.plotTop += this.extraTopMargin);
3333            a || this.getAxisMargins()
3334        }, getAxisMargins: function () {
3335            var a = this, b = a.axisOffset = [0, 0, 0, 0], c = a.margin;
3336            a.hasCartesianSeries && o(a.axes, function (a) {
3337                a.getOffset()
3338            });
3339            o(gb, function (d, e) {
3340                s(c[e]) || (a[d] += b[e])
3341            });
3342            a.setChartSize()
3343        },
3344        reflow: function (a) {
3345            var b = this, c = b.options.chart, d = b.renderTo, e = c.width || hb(d, "width"), f = c.height || hb(d, "height"), c = a ? a.target : K, d = function () {
3346                if (b.container)b.setSize(e, f, !1), b.hasUserSize = null
3347            };
3348            if (!b.hasUserSize && !b.isPrinting && e && f && (c === K || c === C)) {
3349                if (e !== b.containerWidth || f !== b.containerHeight)clearTimeout(b.reflowTimeout), a ? b.reflowTimeout = setTimeout(d, 100) : d();
3350                b.containerWidth = e;
3351                b.containerHeight = f
3352            }
3353        }, initReflow: function () {
3354            var a = this, b = function (b) {
3355                a.reflow(b)
3356            };
3357            H(K, "resize", b);
3358            H(a, "destroy", function () {
3359                Z(K,
3360                    "resize", b)
3361            })
3362        }, setSize: function (a, b, c) {
3363            var d = this, e, f, g, h = d.renderer, i = h.globalAnimation;
3364            d.isResizing += 1;
3365            g = function () {
3366                d && I(d, "endResize", null, function () {
3367                    d.isResizing -= 1
3368                })
3369            };
3370            Qa(c, d);
3371            d.oldChartHeight = d.chartHeight;
3372            d.oldChartWidth = d.chartWidth;
3373            if (s(a))d.chartWidth = e = t(0, w(a)), d.hasUserSize = !!e;
3374            if (s(b))d.chartHeight = f = t(0, w(b));
3375            (i ? jb : L)(d.container, {width: e + "px", height: f + "px"}, i);
3376            d.setChartSize(!0);
3377            h.setSize(e, f, c);
3378            d.maxTicks = null;
3379            o(d.axes, function (a) {
3380                a.isDirty = !0;
3381                a.setScale()
3382            });
3383            o(d.series, function (a) {
3384                a.isDirty = !0
3385            });
3386            d.isDirtyLegend = !0;
3387            d.isDirtyBox = !0;
3388            d.layOutTitles();
3389            d.getMargins();
3390            d.redraw(c);
3391            d.oldChartHeight = null;
3392            I(d, "resize");
3393            i === !1 ? g() : setTimeout(g, i && i.duration || 500)
3394        }, setChartSize: function (a) {
3395            var b = this.inverted, c = this.renderer, d = this.chartWidth, e = this.chartHeight, f = this.options.chart, g = this.spacing, h = this.clipOffset, i, j, k, m;
3396            this.plotLeft = i = w(this.plotLeft);
3397            this.plotTop = j = w(this.plotTop);
3398            this.plotWidth = k = t(0, w(d - i - this.marginRight));
3399            this.plotHeight = m = t(0, w(e - j - this.marginBottom));
3400            this.plotSizeX = b ? m :
3401                k;
3402            this.plotSizeY = b ? k : m;
3403            this.plotBorderWidth = f.plotBorderWidth || 0;
3404            this.spacingBox = c.spacingBox = {x: g[3], y: g[0], width: d - g[3] - g[1], height: e - g[0] - g[2]};
3405            this.plotBox = c.plotBox = {x: i, y: j, width: k, height: m};
3406            d = 2 * V(this.plotBorderWidth / 2);
3407            b = sa(t(d, h[3]) / 2);
3408            c = sa(t(d, h[0]) / 2);
3409            this.clipBox = {
3410                x: b,
3411                y: c,
3412                width: V(this.plotSizeX - t(d, h[1]) / 2 - b),
3413                height: t(0, V(this.plotSizeY - t(d, h[2]) / 2 - c))
3414            };
3415            a || o(this.axes, function (a) {
3416                a.setAxisSize();
3417                a.setAxisTranslation()
3418            })
3419        }, resetMargins: function () {
3420            var a = this;
3421            o(gb, function (b, c) {
3422                a[b] = p(a.margin[c],
3423                    a.spacing[c])
3424            });
3425            a.axisOffset = [0, 0, 0, 0];
3426            a.clipOffset = [0, 0, 0, 0]
3427        }, drawChartBox: function () {
3428            var a = this.options.chart, b = this.renderer, c = this.chartWidth, d = this.chartHeight, e = this.chartBackground, f = this.plotBackgroun
3428d, g = this.plotBorder, h = this.plotBGImage, i = a.borderWidth || 0, j = a.backgroundColor, k = a.plotBackgroundColor, m = a.plotBackgroundImage, l = a.plotBorderWidth || 0, n, q = this.plotLeft, p = this.plotTop, o = this.plotWidth, t = this.plotHeight, u = this.plotBox, s = this.clipRect, r = this.clipBox;
3429            n = i + (a.shadow ? 8 : 0);
3430            if (i || j)if (e)e.animate(e.crisp({
3431                width: c -
3432                n, height: d - n
3433            })); else {
3434                e = {fill: j || O};
3435                if (i)e.stroke = a.borderColor, e["stroke-width"] = i;
3436                this.chartBackground = b.rect(n / 2, n / 2, c - n, d - n, a.borderRadius, i).attr(e).addClass("highcharts-background").add().shadow(a.shadow)
3437            }
3438            if (k)f ? f.animate(u) : this.plotBackground = b.rect(q, p, o, t, 0).attr({fill: k}).add().shadow(a.plotShadow);
3439            if (m)h ? h.animate(u) : this.plotBGImage = b.image(m, q, p, o, t).add();
3440            s ? s.animate({width: r.width, height: r.height}) : this.clipRect = b.clipRect(r);
3441            if (l)g ? g.animate(g.crisp({x: q, y: p, width: o, height: t, strokeWidth: -l})) :
3442                this.plotBorder = b.rect(q, p, o, t, 0, -l).attr({
3443                    stroke: a.plotBorderColor,
3444                    "stroke-width": l,
3445                    fill: O,
3446                    zIndex: 1
3447                }).add();
3448            this.isDirtyBox = !1
3449        }, propFromSeries: function () {
3450            var a = this, b = a.options.chart, c, d = a.options.series, e, f;
3451            o(["inverted", "angular", "polar"], function (g) {
3452                c = M[b.type || b.defaultSeriesType];
3453                f = a[g] || b[g] || c && c.prototype[g];
3454                for (e = d && d.length; !f && e--;)(c = M[d[e].type]) && c.prototype[g] && (f = !0);
3455                a[g] = f
3456            })
3457        }, linkSeries: function () {
3458            var a = this, b = a.series;
3459            o(b, function (a) {
3460                a.linkedSeries.length = 0
3461            });
3462            o(b, function (b) {
3463                var d =
3464                    b.options.linkedTo;
3465                if (Aa(d) && (d = d === ":previous" ? a.series[b.index - 1] : a.get(d)))d.linkedSeries.push(b), b.linkedParent = d, b.visible = p(b.options.visible, d.options.visible, b.visible)
3466            })
3467        }, renderSeries: function () {
3468            o(this.series, function (a) {
3469                a.translate();
3470                a.render()
3471            })
3472        }, renderLabels: function () {
3473            var a = this, b = a.options.labels;
3474            b.items && o(b.items, function (c) {
3475                var d = r(b.style, c.style), e = F(d.left) + a.plotLeft, f = F(d.top) + a.plotTop + 12;
3476                delete d.left;
3477                delete d.top;
3478                a.renderer.text(c.html, e, f).attr({zIndex: 2}).css(d).add()
3479            })
3480        },
3481        render: function () {
3482            var a = this.axes, b = this.renderer, c = this.options, d, e, f, g;
3483            this.setTitle();
3484            this.legend = new lb(this, c.legend);
3485            this.getStacks && this.getStacks();
3486            this.getMargins(!0);
3487            this.setChartSize();
3488            d = this.plotWidth;
3489            e = this.plotHeight -= 13;
3490            o(a, function (a) {
3491                a.setScale()
3492            });
3493            this.getAxisMargins();
3494            f = d / this.plotWidth > 1.1;
3495            g = e / this.plotHeight > 1.1;
3496            if (f || g)this.maxTicks = null, o(a, function (a) {
3497                (a.horiz && f || !a.horiz && g) && a.setTickInterval(!0)
3498            }), this.getMargins();
3499            this.drawChartBox();
3500            this.hasCartesianSeries && o(a, function (a) {
3501                a.render()
3502            });
3503            if (!this.seriesGroup)this.seriesGroup = b.g("series-group").attr({zIndex: 3}).add();
3504            this.renderSeries();
3505            this.renderLabels();
3506            this.showCredits(c.credits);
3507            this.hasRendered = !0
3508        }, showCredits: function (a) {
3509            if (a.enabled && !this.credits)this.credits = this.renderer.text(a.text, 0, 0).on("click", function () {
3510                if (a.href)location.href = a.href
3511            }).attr({align: a.position.align, zIndex: 8}).css(a.style).add().align(a.position)
3512        }, destroy: function () {
3513            var a = this, b = a.axes, c = a.series, d = a.container, e, f = d && d.parentNode;
3514            I(a, "destroy");
3515            Y[a.index] =
3516                v;
3517            ab--;
3518            a.renderTo.removeAttribute("data-highcharts-chart");
3519            Z(a);
3520            for (e = b.length; e--;)b[e] = b[e].destroy();
3521            for (e = c.length; e--;)c[e] = c[e].destroy();
3522            o("title,subtitle,chartBackground,plotBackground,plotBGImage,plotBorder,seriesGroup,clipRect,credits,pointer,scroller,rangeSelector,legend,resetZoomButton,tooltip,renderer".split(","), function (b) {
3523                var c = a[b];
3524                c && c.destroy && (a[b] = c.destroy())
3525            });
3526            if (d)d.innerHTML = "", Z(d), f && Pa(d);
3527            for (e in a)delete a[e]
3528        }, isReadyToRender: function () {
3529            var a = this;
3530            return !ca && K == K.top &&
3531            C.readyState !== "complete" || fa && !K.canvg ? (fa ? Lb.push(function () {
3532                a.firstRender()
3533            }, a.options.global.canvasToolsURL) : C.attachEvent("onreadystatechange", function () {
3534                C.detachEvent("onreadystatechange", a.firstRender);
3535                C.readyState === "complete" && a.firstRender()
3536            }), !1) : !0
3537        }, firstRender: function () {
3538            var a = this, b = a.options, c = a.callback;
3539            if (a.isReadyToRender()) {
3540                a.getContainer();
3541                I(a, "init");
3542                a.resetMargins();
3543                a.setChartSize();
3544                a.propFromSeries();
3545                a.getAxes();
3546                o(b.series || [], function (b) {
3547                    a.initSeries(b)
3548                });
3549                a.linkSeries();
3550                I(a,
3551                    "beforeRender");
3552                if (B.Pointer)a.pointer = new Ua(a, b);
3553                a.render();
3554                a.renderer.draw();
3555                c && c.apply(a, [a]);
3556                o(a.callbacks, function (b) {
3557                    a.index !== v && b.apply(a, [a])
3558                });
3559                I(a, "load");
3560                a.cloneRenderTo(!0)
3561            }
3562        }, splashArray: function (a, b) {
3563            var c = b[a], c = da(c) ? c : [c, c, c, c];
3564            return [p(b[a + "Top"], c[0]), p(b[a + "Right"], c[1]), p(b[a + "Bottom"], c[2]), p(b[a + "Left"], c[3])]
3565        }
3566    };
3567    var Xb = B.CenteredSeriesMixin = {
3568        getCenter: function () {
3569            var a = this.options, b = this.chart, c = 2 * (a.slicedOffset || 0), d = b.plotWidth - 2 * c, b = b.plotHeight - 2 * c, e = a.center, e = [p(e[0],
3570                "50%"), p(e[1], "50%"), a.size || "100%", a.innerSize || 0], f = z(d, b), g, h;
3571            for (g = 0; g < 4; ++g)h = e[g], a = g < 2 || g === 2 && /%$/.test(h), e[g] = (/%$/.test(h) ? [d, b, f, e[2]][g] * parseFloat(h) / 100 : parseFloat(h)) + (a ? c : 0);
3572            return e
3573        }
3574    }, Ea = function () {
3575    };
3576    Ea.prototype = {
3577        init: function (a, b, c) {
3578            this.series = a;
3579            this.color = a.color;
3580            this.applyOptions(b, c);
3581            this.pointAttr = {};
3582            if (a.options.colorByPoint && (b = a.options.colors || a.chart.options.colors, this.color = this.color || b[a.colorCounter++], a.colorCounter === b.length))a.colorCounter = 0;
3583            a.chart.pointCount++;
3584            return this
3585        }, applyOptions: function (a, b) {
3586            var c = this.series, d = c.options.pointValKey || c.pointValKey, a = Ea.prototype.optionsToObject.call(this, a);
3587            r(this, a);
3588            this.options = this.options ? r(this.options, a) : a;
3589            if (d)this.y = this[d];
3590            if (this.x === v && c)this.x = b === v ? c.autoIncrement() : b;
3591            return this
3592        }, optionsToObject: function (a) {
3593            var b = {}, c = this.series, d = c.options.keys, e = d || c.pointArrayMap || ["y"], f = e.length, g = 0, h = 0;
3594            if (typeof a === "number" || a === null)b[e[0]] = a; else if (Fa(a)) {
3595                if (!d && a.length > f) {
3596                    c = typeof a[0];
3597                    if (c === "string")b.name =
3598                        a[0]; else if (c === "number")b.x = a[0];
3599                    g++
3600                }
3601                for (; h < f;)b[e[h++]] = a[g++]
3602            } else if (typeof a === "object") {
3603                b = a;
3604                if (a.dataLabels)c._hasPointLabels = !0;
3605                if (a.marker)c._hasPointMarkers = !0
3606            }
3607            return b
3608        }, destroy: function () {
3609            var a = this.series.chart, b = a.hoverPoints, c;
3610            a.pointCount--;
3611            if (b && (this.setState(), ja(b, this), !b.length))a.hoverPoints = null;
3612            if (this === a.hoverPoint)this.onMouseOut();
3613            if (this.graphic || this.dataLabel)Z(this), this.destroyElements();
3614            this.legendItem && a.legend.destroyItem(this);
3615            for (c in this)this[c] = null
3616        }, destroyElements: function () {
3617            for (var a =
3618                "graphic,dataLabel,dataLabelUpper,group,connector,shadowGroup".split(","), b, c = 6; c--;)b = a[c], this[b] && (this[b] = this[b].destroy())
3619        }, getLabelConfig: function () {
3620            return {
3621                x: this.category,
3622                y: this.y,
3623                color: this.color,
3624                key: this.name || this.category,
3625                series: this.series,
3626                point: this,
3627                percentage: this.percentage,
3628                total: this.total || this.stackTotal
3629            }
3630        }, tooltipFormatter: function (a) {
3631            var b = this.series, c = b.tooltipOptions, d = p(c.valueDecimals, ""), e = c.valuePrefix || "", f = c.valueSuffix || "";
3632            o(b.pointArrayMap || ["y"], function (b) {
3633                b = "{point." +
3634                    b;
3635                if (e || f)a = a.replace(b + "}", e + b + "}" + f);
3636                a = a.replace(b + "}", b + ":,." + d + "f}")
3637            });
3638            return Ha(a, {point: this, series: this.series})
3639        }, firePointEvent: function (a, b, c) {
3640            var d = this, e = this.series.options;
3641            (e.point.events[a] || d.options && d.options.events && d.options.events[a]) && this.importEvents();
3642            a === "click" && e.allowPointSelect && (c = function (a) {
3643                d.select && d.select(null, a.ctrlKey || a.metaKey || a.shiftKey)
3644            });
3645            I(this, a, b, c)
3646        }
3647    };
3648    var R = B.Series = function () {
3649    };
3650    R.prototype = {
3651        isCartesian: !0,
3652        type: "line",
3653        pointClass: Ea,
3654        sorted: !0,
3655        requireSorting: !0,
3656        pointAttrToOptions: {stroke: "lineColor", "stroke-width": "lineWidth", fill: "fillColor", r: "radius"},
3657        axisTypes: ["xAxis", "yAxis"],
3658        colorCounter: 0,
3659        parallelArrays: ["x", "y"],
3660        init: function (a, b) {
3661            var c = this, d, e, f = a.series, g = function (a, b) {
3662                return p(a.options.index, a._i) - p(b.options.index, b._i)
3663            };
3664            c.chart = a;
3665            c.options = b = c.setOptions(b);
3666            c.linkedSeries = [];
3667            c.bindAxes();
3668            r(c, {name: b.name, state: "", pointAttr: {}, visible: b.visible !== !1, selected: b.selected === !0});
3669            if (fa)b.animation = !1;
3670            e = b.events;
3671            for (d in e)H(c, d, e[d]);
3672            if (e && e.click ||
3673                b.point && b.point.events && b.point.events.click || b.allowPointSelect)a.runTrackerClick = !0;
3674            c.getColor();
3675            c.getSymbol();
3676            o(c.parallelArrays, function (a) {
3677                c[a + "Data"] = []
3678            });
3679            c.setData(b.data, !1);
3680            if (c.isCartesian)a.hasCartesianSeries = !0;
3681            f.push(c);
3682            c._i = f.length - 1;
3683            pb(f, g);
3684            this.yAxis && pb(this.yAxis.series, g);
3685            o(f, function (a, b) {
3686                a.index = b;
3687                a.name = a.name || "Series " + (b + 1)
3688            })
3689        },
3690        bindAxes: function () {
3691            var a = this, b = a.options, c = a.chart, d;
3692            o(a.axisTypes || [], function (e) {
3693                o(c[e], function (c) {
3694                    d = c.options;
3695                    if (b[e] === d.index || b[e] !== v &&
3696                        b[e] === d.id || b[e] === v && d.index === 0)c.series.push(a), a[e] = c, c.isDirty = !0
3697                });
3698                !a[e] && a.optionalAxis !== e && la(18, !0)
3699            })
3700        },
3701        updateParallelArrays: function (a, b) {
3702            var c = a.series, d = arguments;
3703            o(c.parallelArrays, typeof b === "number" ? function (d) {
3704                var f = d === "y" && c.toYData ? c.toYData(a) : a[d];
3705                c[d + "Data"][b] = f
3706            } : function (a) {
3707                Array.prototype[b].apply(c[a + "Data"], Array.prototype.slice.call(d, 2))
3708            })
3709        },
3710        autoIncrement: function () {
3711            var a = this.options, b = this.xIncrement, c, d = a.pointIntervalUnit, b = p(b, a.pointStart, 0);
3712            this.pointInterval = c =
3713                p(this.pointInterval, a.pointInterval, 1);
3714            if (d === "month" || d === "year")a = new ya(b), a = d === "month" ? +a[ub](a[Xa]() + c) : +a[vb](a[Ya]() + c), c = a - b;
3715            this.xIncrement = b + c;
3716            return b
3717        },
3718        getSegments: function () {
3719            var a = -1, b = [], c, d = this.points, e = d.length;
3720            if (e)if (this.options.connectNulls) {
3721                for (c = e; c--;)d[c].y === null && d.splice(c, 1);
3722                d.length && (b = [d])
3723            } else o(d, function (c, g) {
3724                c.y === null ? (g > a + 1 && b.push(d.slice(a + 1, g)), a = g) : g === e - 1 && b.push(d.slice(a + 1, g + 1))
3725            });
3726            this.segments = b
3727        },
3728        setOptions: function (a) {
3729            var b = this.chart, c = b.options.plotOptions,
3730                b = b.userOptions || {}, d = b.plotOptions || {}, e = c[this.type];
3731            this.userOptions = a;
3732            c = A(e, c.series, a);
3733            this.tooltipOptions = A(S.tooltip, S.plotOptions[this.type].tooltip, b.tooltip, d.series && d.series.tooltip, d[this.type] && d[this.type].tooltip, a.tooltip);
3734            e.marker === null && delete c.marker;
3735            this.zoneAxis = c.zoneAxis;
3736            a = this.zones = (c.zones || []).slice();
3737            if ((c.negativeColor || c.negativeFillColor) && !c.zones)a.push({
3738                value: c[this.zoneAxis + "Threshold"] || c.threshold || 0,
3739                color: c.negativeColor,
3740                fillColor: c.negativeFillColor
3741            });
3742            a.length &&
3743            s(a[a.length - 1].value) && a.push({color: this.color, fillColor: this.fillColor});
3744            return c
3745        },
3746        getCyclic: function (a, b, c) {
3747            var d = this.userOptions, e = "_" + a + "Index", f = a + "Counter";
3748            b || (s(d[e]) ? b = d[e] : (d[e] = b = this.chart[f] % c.length, this.chart[f] += 1), b = c[b]);
3749            this[a] = b
3750        },
3751        getColor: function () {
3752            this.options.colorByPoint ? this.options.color = null : this.getCyclic("color", this.options.color || ba[this.type].color, this.chart.options.colors)
3753        },
3754        getSymbol: function () {
3755            var a = this.options.marker;
3756            this.getCyclic("symbol", a.symbol, this.chart.options.symbols);
3757            if (/^url/.test(this.symbol))a.radius = 0
3758        },
3759        drawLegendSymbol: La.drawLineMarker,
3760        setData: function (a, b, c, d) {
3761            var e = this, f = e.points, g = f && f.length || 0, h, i = e.options, j = e.chart, k = null, m = e.xAxis, l = m && !!m.categories, n = i.turboThreshold, q = this.xData, x = this.yData, t = (h = e.pointArrayMap) && h.length, a = a || [];
3762            h = a.length;
3763            b = p(b, !0);
3764            if (d !== !1 && h && g === h && !e.cropped && !e.hasGroupedData && e.visible)o(a, function (a, b) {
3765                f[b].update && f[b].update(a, !1, null, !1)
3766            }); else {
3767                e.xIncrement = null;
3768                e.pointRange = l ? 1 : i.pointRange;
3769                e.colorCounter = 0;
3770                o(this.parallelArrays,
3771                    function (a) {
3772                        e[a + "Data"].length = 0
3773                    });
3774                if (n && h > n) {
3775                    for (c = 0; k === null && c < h;)k = a[c], c++;
3776                    if (qa(k)) {
3777                        l = p(i.pointStart, 0);
3778                        i = p(i.pointInterval, 1);
3779                        for (c = 0; c < h; c++)q[c] = l, x[c] = a[c], l += i;
3780                        e.xIncrement = l
3781                    } else if (Fa(k))if (t)for (c = 0; c < h; c++)i = a[c], q[c] = i[0], x[c] = i.slice(1, t + 1); else for (c = 0; c < h; c++)i = a[c], q[c] = i[0], x[c] = i[1]; else la(12)
3782                } else for (c = 0; c < h; c++)if (a[c] !== v && (i = {series: e}, e.pointClass.prototype.applyOptions.apply(i, [a[c]]), e.updateParallelArrays(i, c), l && s(i.name)))m.names[i.x] = i.name;
3783                Aa(x[0]) && la(14, !0);
3784                e.data =
3785                    [];
3786                e.options.data = a;
3787                for (c = g; c--;)f[c] && f[c].destroy && f[c].destroy();
3788                if (m)m.minRange = m.userMinRange;
3789                e.isDirty = e.isDirtyData = j.isDirtyBox = !0;
3790                c = !1
3791            }
3792            b && j.redraw(c)
3793        },
3794        processData: function (a) {
3795            var b = this.xData, c = this.yData, d = b.length, e;
3796            e = 0;
3797            var f, g, h = this.xAxis, i, j = this.options;
3798            i = j.cropThreshold;
3799            var k = this.isCartesian, m, l;
3800            if (k && !this.isDirty && !h.isDirty && !this.yAxis.isDirty && !a)return !1;
3801            if (h)a = h.getExtremes(), m = a.min, l = a.max;
3802            if (k && this.sorted && (!i || d > i || this.forceCrop))if (b[d - 1] < m || b[0] > l)b = [], c = []; else if (b[0] <
3803                m || b[d - 1] > l)e = this.cropData(this.xData, this.yData, m, l), b = e.xData, c = e.yData, e = e.start, f = !0;
3804            for (i = b.length - 1; i >= 0; i--)d = b[i] - b[i - 1], d > 0 && (g === v || d < g) ? g = d : d < 0 && this.requireSorting && la(15);
3805            this.cropped = f;
3806            this.cropStart = e;
3807            this.processedXData = b;
3808            this.processedYData = c;
3809            if (j.pointRange === null)this.pointRange = g || 1;
3810            this.closestPointRange = g
3811        },
3812        cropData: function (a, b, c, d) {
3813            var e = a.length, f = 0, g = e, h = p(this.cropShoulder, 1), i;
3814            for (i = 0; i < e; i++)if (a[i] >= c) {
3815                f = t(0, i - h);
3816                break
3817            }
3818            for (; i < e; i++)if (a[i] > d) {
3819                g = i + h;
3820                break
3821            }
3822            return {
3823                xData: a.slice(f,
3824                    g), yData: b.slice(f, g), start: f, end: g
3825            }
3826        },
3827        generatePoints: function () {
3828            var a = this.options.data, b = this.data, c, d = this.processedXData, e = this.processedYData, f = this.pointClass, g = d.length, h = this.cropStart || 0, i, j = this.hasGroupedData, k, m = [], l;
3829            if (!b && !j)b = [], b.length = a.length, b = this.data = b;
3830            for (l = 0; l < g; l++)i = h + l, j ? m[l] = (new f).init(this, [d[l]].concat(ra(e[l]))) : (b[i] ? k = b[i] : a[i] !== v && (b[i] = k = (new f).init(this, a[i], d[l])), m[l] = k), m[l].index = i;
3831            if (b && (g !== (c = b.length) || j))for (l = 0; l < c; l++)if (l === h && !j && (l += g), b[l])b[l].destroyElements(),
3832                b[l].plotX = v;
3833            this.data = b;
3834            this.points = m
3835        },
3836        getExtremes: function (a) {
3837            var b = this.yAxis, c = this.processedXData, d, e = [], f = 0;
3838            d = this.xAxis.getExtremes();
3839            var g = d.min, h = d.max, i, j, k, m, a = a || this.stackedYData || this.processedYData;
3840            d = a.length;
3841            for (m = 0; m < d; m++)if (j = c[m], k = a[m], i = k !== null && k !== v && (!b.isLog || k.length || k > 0), j = this.getExtremesFromAll || this.options.getExtremesFromAll || this.cropped || (c[m + 1] || j) >= g && (c[m - 1] || j) <= h, i && j)if (i = k.length)for (; i--;)k[i] !== null && (e[f++] = k[i]); else e[f++] = k;
3842            this.dataMin = Na(e);
3843            this.dataMax =
3844                Ca(e)
3845        },
3846        translate: function () {
3847            this.processedXData || this.processData();
3848            this.generatePoints();
3849            for (var a = this.options, b = a.stacking, c = this.xAxis, d = c.categories, e = this.yAxis, f = this.points, g = f.length, h 
3849= !!this.modifyValue, i = a.pointPlacement, j = i === "between" || qa(i), k = a.threshold, m = a.startFromThreshold ? k : 0, l, n, q, o = Number.MAX_VALUE, a = 0; a < g; a++) {
3850                var r = f[a], w = r.x, u = r.y;
3851                n = r.low;
3852                var y = b && e.stacks[(this.negStacks && u < (m ? 0 : k) ? "-" : "") + this.stackKey];
3853                if (e.isLog && u !== null && u <= 0)r.y = u = null, la(10);
3854                r.plotX = l = z(t(-1E5, c.translate(w,
3855                    0, 0, 0, 1, i, this.type === "flags")), 1E5);
3856                if (b && this.visible && y && y[w])y = y[w], u = y.points[this.index + "," + a], n = u[0], u = u[1], n === m && (n = p(k, e.min)), e.isLog && n <= 0 && (n = null), r.total = r.stackTotal = y.total, r.percentage = y.total && r.y / y.total * 100, r.stackY = u, y.setOffset(this.pointXOffset || 0, this.barW || 0);
3857                r.yBottom = s(n) ? e.translate(n, 0, 1, 0, 1) : null;
3858                h && (u = this.modifyValue(u, r));
3859                r.plotY = n = typeof u === "number" && u !== Infinity ? z(t(-1E5, e.translate(u, 0, 1, 0, 1)), 1E5) : v;
3860                r.isInside = n !== v && n >= 0 && n <= e.len && l >= 0 && l <= c.len;
3861                r.clientX =
3862                    j ? c.translate(w, 0, 0, 0, 1) : l;
3863                r.negative = r.y < (k || 0);
3864                r.category = d && d[r.x] !== v ? d[r.x] : r.x;
3865                a && (o = z(o, N(l - q)));
3866                q = l
3867            }
3868            this.closestPointRangePx = o;
3869            this.getSegments()
3870        },
3871        setClip: function (a) {
3872            var b = this.chart, c = b.renderer, d = b.inverted, e = this.clipBox, f = e || b.clipBox, g = this.sharedClipKey || ["_sharedClip", a && a.duration, a && a.easing, f.height].join(","), h = b[g], i = b[g + "m"];
3873            if (!h) {
3874                if (a)f.width = 0, b[g + "m"] = i = c.clipRect(-99, d ? -b.plotLeft : -b.plotTop, 99, d ? b.chartWidth : b.chartHeight);
3875                b[g] = h = c.clipRect(f)
3876            }
3877            a && (h.count += 1);
3878            if (this.options.clip !== !1)this.group.clip(a || e ? h : b.clipRect), this.markerGroup.clip(i), this.sharedClipKey = g;
3879            a || (h.count -= 1, h.count <= 0 && g && b[g] && (e || (b[g] = b[g].destroy()), b[g + "m"] && (b[g + "m"] = b[g + "m"].destroy())))
3880        },
3881        animate: function (a) {
3882            var b = this.chart, c = this.options.animation, d;
3883            if (c && !da(c))c = ba[this.type].animation;
3884            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)
3885        },
3886        afterAnimate: function () {
3887            this.setClip();
3888            I(this, "afterAnimate")
3889        },
3890        drawPoints: function () {
3891            var a, b = this.points, c = this.chart, d, e, f, g, h, i, j, k, m = this.options.marker, l = this.pointAttr[""], n, q, o, t = this.markerGroup, s = p(m.enabled, this.xAxis.isRadial, this.closestPointRangePx > 2 * m.radius);
3892            if (m.enabled !== !1 || this._hasPointMarkers)for (f = b.length; f--;)if (g = b[f], d = V(g.plotX), e = g.plotY, k = g.graphic, n = g.marker || {}, q = !!g.marker, a = s && n.enabled === v || n.enabled, o = g.isInside, a && e !== v && !isNaN(e) && g.y !== null)if (a = g.pointAttr[g.selected ? "select" : ""] || l, h = a.r, i = p(n.symbol, this.symbol), j = i.indexOf("url") ===
3893                    0, k)k[o ? "show" : "hide"](!0).animate(r({x: d - h, y: e - h}, k.symbolName ? {
3894                width: 2 * h,
3895                height: 2 * h
3896            } : {})); else {
3897                if (o && (h > 0 || j))g.graphic = c.renderer.symbol(i, d - h, e - h, 2 * h, 2 * h, q ? n : m).attr(a).add(t)
3898            } else if (k)g.graphic = k.destroy()
3899        },
3900        convertAttribs: function (a, b, c, d) {
3901            var e = this.pointAttrToOptions, f, g, h = {}, a = a || {}, b = b || {}, c = c || {}, d = d || {};
3902            for (f in e)g = e[f], h[f] = p(a[g], b[f], c[f], d[f]);
3903            return h
3904        },
3905        getAttribs: function () {
3906            var a = this, b = a.options, c = ba[a.type].marker ? b.marker : b, d = c.states, e = d.hover, f, g = a.color, h = a.options.negativeColor;
3907            f = {stroke: g, fill: g};
3908            var i = a.points || [], j, k, m = [], l = a.pointAttrToOptions;
3909            j = a.hasPointSpecificOptions;
3910            var n = c.lineColor, q = c.fillColor;
3911            k = b.turboThreshold;
3912            var p = a.zones, t = a.zoneAxis || "y", w;
3913            b.marker ? (e.radius = e.radius || c.radius + e.radiusPlus, e.lineWidth = e.lineWidth || c.lineWidth + e.lineWidthPlus) : (e.color = e.color || na(e.color || g).brighten(e.brightness).get(), e.negativeColor = e.negativeColor || na(e.negativeColor || h).brighten(e.brightness).get());
3914            m[""] = a.convertAttribs(c, f);
3915            o(["hover", "select"], function (b) {
3916                m[b] =
3917                    a.convertAttribs(d[b], m[""])
3918            });
3919            a.pointAttr = m;
3920            g = i.length;
3921            if (!k || g < k || j)for (; g--;) {
3922                k = i[g];
3923                if ((c = k.options && k.options.marker || k.options) && c.enabled === !1)c.radius = 0;
3924                if (p.length) {
3925                    j = 0;
3926                    for (f = p[j]; k[t] >= f.value;)f = p[++j];
3927                    if (f.color)k.color = k.fillColor = f.color
3928                }
3929                j = b.colorByPoint || k.color;
3930                if (k.options)for (w in l)s(c[l[w]]) && (j = !0);
3931                if (j) {
3932                    c = c || {};
3933                    j = [];
3934                    d = c.states || {};
3935                    f = d.hover = d.hover || {};
3936                    if (!b.marker)f.color = f.color || !k.options.color && e[k.negative && h ? "negativeColor" : "color"] || na(k.color).brighten(f.brightness ||
3937                            e.brightness).get();
3938                    f = {color: k.color};
3939                    if (!q)f.fillColor = k.color;
3940                    if (!n)f.lineColor = k.color;
3941                    c.hasOwnProperty("color") && !c.color && delete c.color;
3942                    j[""] = a.convertAttribs(r(f, c), m[""]);
3943                    j.hover = a.convertAttribs(d.hover, m.hover, j[""]);
3944                    j.select = a.convertAttribs(d.select, m.select, j[""])
3945                } else j = m;
3946                k.pointAttr = j
3947            }
3948        },
3949        destroy: function () {
3950            var a = this, b = a.chart, c = /AppleWebKit\/533/.test(za), d, e = a.data || [], f, g, h;
3951            I(a, "destroy");
3952            Z(a);
3953            o(a.axisTypes || [], function (b) {
3954                if (h = a[b])ja(h.series, a), h.isDirty = h.forceRedraw = !0
3955            });
3956            a.legendItem &&
3957            a.chart.legend.destroyItem(a);
3958            for (d = e.length; d--;)(f = e[d]) && f.destroy && f.destroy();
3959            a.points = null;
3960            clearTimeout(a.animationTimeout);
3961            for (g in a)a[g]instanceof P && !a[g].survive && (d = c && g === "group" ? "hide" : "destroy", a[g][d]());
3962            if (b.hoverSeries === a)b.hoverSeries = null;
3963            ja(b.series, a);
3964            for (g in a)delete a[g]
3965        },
3966        getSegmentPath: function (a) {
3967            var b = this, c = [], d = b.options.step;
3968            o(a, function (e, f) {
3969                var g = e.plotX, h = e.plotY, i;
3970                b.getPointSpline ? c.push.apply(c, b.getPointSpline(a, e, f)) : (c.push(f ? "L" : "M"), d && f && (i = a[f - 1], d === "right" ?
3971                    c.push(i.plotX, h) : d === "center" ? c.push((i.plotX + g) / 2, i.plotY, (i.plotX + g) / 2, h) : c.push(g, i.plotY)), c.push(e.plotX, e.plotY))
3972            });
3973            return c
3974        },
3975        getGraphPath: function () {
3976            var a = this, b = [], c, d = [];
3977            o(a.segments, function (e) {
3978                c = a.getSegmentPath(e);
3979                e.length > 1 ? b = b.concat(c) : d.push(e[0])
3980            });
3981            a.singlePoints = d;
3982            return a.graphPath = b
3983        },
3984        drawGraph: function () {
3985            var a = this, b = this.options, c = [["graph", b.lineColor || this.color, b.dashStyle]], d = b.lineWidth, e = b.linecap !== "square", f = this.getGraphPath(), g = this.fillGraph && this.color || O;
3986            o(this.zones,
3987                function (d, e) {
3988                    c.push(["zoneGraph" + e, d.color || a.color, d.dashStyle || b.dashStyle])
3989                });
3990            o(c, function (c, i) {
3991                var j = c[0], k = a[j];
3992                if (k)k.animate({d: f}); else if ((d || g) && f.length)k = {
3993                    stroke: c[1],
3994                    "stroke-width": d,
3995                    fill: g,
3996                    zIndex: 1
3997                }, c[2] ? k.dashstyle = c[2] : e && (k["stroke-linecap"] = k["stroke-linejoin"] 
3997= "round"), a[j] = a.chart.renderer.path(f).attr(k).add(a.group).shadow(i < 2 && b.shadow)
3998            })
3999        },
4000        applyZones: function () {
4001            var a = this, b = this.chart, c = b.renderer, d = this.zones, e, f, g = this.clips || [], h, i = this.graph, j = this.area, k = t(b.chartWidth,
4002                b.chartHeight), m = this[(this.zoneAxis || "y") + "Axis"], l, n = m.reversed, q = b.inverted, x = m.horiz, r, s, u, y = !1;
4003            if (d.length && (i || j) && m.min !== v)i && i.hide(), j && j.hide(), l = m.getExtremes(), o(d, function (d, o) {
4004                e = n ? x ? b.plotWidth : 0 : x ? 0 : m.toPixels(l.min);
4005                e = z(t(p(f, e), 0), k);
4006                f = z(t(w(m.toPixels(p(d.value, l.max), !0)), 0), k);
4007                y && (e = f = m.toPixels(l.max));
4008                r = Math.abs(e - f);
4009                s = z(e, f);
4010                u = t(e, f);
4011                if (m.isXAxis) {
4012                    if (h = {x: q ? u : s, y: 0, width: r, height: k}, !x)h.x = b.plotHeight - h.x
4013                } else if (h = {x: 0, y: q ? u : s, width: k, height: r}, x)h.y = b.plotWidth - h.y;
4014                b.inverted &&
4015                c.isVML && (h = m.isXAxis ? {
4016                    x: 0,
4017                    y: n ? s : u,
4018                    height: h.width,
4019                    width: b.chartWidth
4020                } : {x: h.y - b.plotLeft - b.spacingBox.x, y: 0, width: h.height, height: b.chartHeight});
4021                g[o] ? g[o].animate(h) : (g[o] = c.clipRect(h), i && a["zoneGraph" + o].clip(g[o]), j && a["zoneArea" + o].clip(g[o]));
4022                y = d.value > l.max
4023            }), this.clips = g
4024        },
4025        invertGroups: function () {
4026            function a() {
4027                var a = {width: b.yAxis.len, height: b.xAxis.len};
4028                o(["group", "markerGroup"], function (c) {
4029                    b[c] && b[c].attr(a).invert()
4030                })
4031            }
4032
4033            var b = this, c = b.chart;
4034            if (b.xAxis)H(c, "resize", a), H(b, "destroy", function () {
4035                Z(c,
4036                    "resize", a)
4037            }), a(), b.invertGroups = a
4038        },
4039        plotGroup: function (a, b, c, d, e) {
4040            var f = this[a], g = !f;
4041            g && (this[a] = f = this.chart.renderer.g(b).attr({visibility: c, zIndex: d || 0.1}).add(e));
4042            f[g ? "attr" : "animate"](this.getPlotBox());
4043            return f
4044        },
4045        getPlotBox: function () {
4046            var a = this.chart, b = this.xAxis, c = this.yAxis;
4047            if (a.inverted)b = c, c = this.xAxis;
4048            return {translateX: b ? b.left : a.plotLeft, translateY: c ? c.top : a.plotTop, scaleX: 1, scaleY: 1}
4049        },
4050        render: function () {
4051            var a = this, b = a.chart, c, d = a.options, e = (c = d.animation) && !!a.animate && b.renderer.isSVG &&
4052                p(c.duration, 500) || 0, f = a.visible ? "visible" : "hidden", g = d.zIndex, h = a.hasRendered, i = b.seriesGroup;
4053            c = a.plotGroup("group", "series", f, g, i);
4054            a.markerGroup = a.plotGroup("markerGroup", "markers", f, g, i);
4055            e && a.animate(!0);
4056            a.getAttribs();
4057            c.inverted = a.isCartesian ? b.inverted : !1;
4058            a.drawGraph && (a.drawGraph(), a.applyZones());
4059            o(a.points, function (a) {
4060                a.redraw && a.redraw()
4061            });
4062            a.drawDataLabels && a.drawDataLabels();
4063            a.visible && a.drawPoints();
4064            a.drawTracker && a.options.enableMouseTracking !== !1 && a.drawTracker();
4065            b.inverted && a.invertGroups();
4066            d.clip !== !1 && !a.sharedClipKey && !h && c.clip(b.clipRect);
4067            e && a.animate();
4068            if (!h)e ? a.animationTimeout = setTimeout(function () {
4069                a.afterAnimate()
4070            }, e) : a.afterAnimate();
4071            a.isDirty = a.isDirtyData = !1;
4072            a.hasRendered = !0
4073        },
4074        redraw: function () {
4075            var a = this.chart, b = this.isDirtyData, c = this.isDirty, d = this.group, e = this.xAxis, f = this.yAxis;
4076            d && (a.inverted && d.attr({
4077                width: a.plotWidth,
4078                height: a.plotHeight
4079            }), d.animate({translateX: p(e && e.left, a.plotLeft), translateY: p(f && f.top, a.plotTop)}));
4080            this.translate();
4081            this.render();
4082            b && I(this, "updatedData");
4083            (c || b) && delete this.kdTree
4084        },
4085        kdDimensions: 1,
4086        kdAxisArray: ["clientX", "plotY"],
4087        searchPoint: function (a, b) {
4088            var c = this.xAxis, d = this.yAxis, e = this.chart.inverted;
4089            return this.searchKDTree({
4090                clientX: e ? c.len - a.chartY + c.pos : a.chartX - c.pos,
4091                plotY: e ? d.len - a.chartX + d.pos : a.chartY - d.pos
4092            }, b)
4093        },
4094        buildKDTree: function () {
4095            function a(b, d, g) {
4096                var h, i;
4097                if (i = b && b.length)return h = c.kdAxisArray[d % g], b.sort(function (a, b) {
4098                    return a[h] - b[h]
4099                }), i = Math.floor(i / 2), {
4100                    point: b[i],
4101                    left: a(b.slice(0, i), d + 1, g),
4102                    right: a(b.slice(i + 1), d + 1, g)
4103                }
4104            }
4105
4106            function b() {
4107                var b =
4108                    ib(c.points || [], function (a) {
4109                        return a.y !== null
4110                    });
4111                c.kdTree = a(b, d, d)
4112            }
4113
4114            var c = this, d = c.kdDimensions;
4115            delete c.kdTree;
4116            c.options.kdSync ? b() : setTimeout(b)
4117        },
4118        searchKDTree: function (a, b) {
4119            function c(a, b, j, k) {
4120                var m = b.point, l = d.kdAxisArray[j % k], n, q, p = m;
4121                q = s(a[e]) && s(m[e]) ? Math.pow(a[e] - m[e], 2) : null;
4122                n = s(a[f]) && s(m[f]) ? Math.pow(a[f] - m[f], 2) : null;
4123                n = (q || 0) + (n || 0);
4124                m.dist = s(n) ? Math.sqrt(n) : Number.MAX_VALUE;
4125                m.distX = s(q) ? Math.sqrt(q) : Number.MAX_VALUE;
4126                l = a[l] - m[l];
4127                n = l < 0 ? "left" : "right";
4128                q = l < 0 ? "right" : "left";
4129                b[n] && (n = c(a, b[n],
4130                    j + 1, k), p = n[g] < p[g] ? n : m);
4131                b[q] && Math.sqrt(l * l) < p[g] && (a = c(a, b[q], j + 1, k), p = a[g] < p[g] ? a : p);
4132                return p
4133            }
4134
4135            var d = this, e = this.kdAxisArray[0], f = this.kdAxisArray[1], g = b ? "distX" : "dist";
4136            this.kdTree || this.buildKDTree();
4137            if (this.kdTree)return c(a, this.kdTree, this.kdDimensions, this.kdDimensions)
4138        }
4139    };
4140    Hb.prototype = {
4141        destroy: function () {
4142            Oa(this, this.axis)
4143        }, render: function (a) {
4144            var b = this.options, c = b.format, c = c ? Ha(c, this) : b.formatter.call(this);
4145            this.label ? this.label.attr({
4146                text: c,
4147                visibility: "hidden"
4148            }) : this.label = this.axis.chart.renderer.text(c,
4149                null, null, b.useHTML).css(b.style).attr({
4150                    align: this.textAlign,
4151                    rotation: b.rotation,
4152                    visibility: "hidden"
4153                }).add(a)
4154        }, setOffset: function (a, b) {
4155            var c = this.axis, d = c.chart, e = d.inverted, f = c.reversed, f = this.isNegative && !f || !this.isNegative && f, g = c.translate(c.usePercentage ? 100 : this.total, 0, 0, 0, 1), c = c.translate(0), c = N(g - c), h = d.xAxis[0].translate(this.x) + a, i = d.plotHeight, f = {
4156                x: e ? f ? g : g - c : h,
4157                y: e ? i - h - b : f ? i - g - c : i - g,
4158                width: e ? c : b,
4159                height: e ? b : c
4160            };
4161            if (e = this.label)e.align(this.alignOptions, null, f), f = e.alignAttr, e[this.options.crop === !1 || d.isInsidePlot(f.x, f.y) ? "show" : "hide"](!0)
4162        }
4163    };
4164    D.prototype.getStacks = function () {
4165        var a = this;
4166        o(a.yAxis, function (a) {
4167            if (a.stacks && a.hasVisibleSeries)a.oldStacks = a.stacks
4168        });
4169        o(a.series, function (b) {
4170            if (b.options.stacking && (b.visible === !0 || a.options.chart.ignoreHiddenSeries === !1))b.stackKey = b.type + p(b.options.stack, "")
4171        })
4172    };
4173    ha.prototype.buildStacks = function () {
4174        var a = this.series, b = p(this.options.reversedStacks, !0), c = a.length;
4175        if (!this.isXAxis) {
4176            for (this.usePercentage = !1; c--;)a[b ? c : a.length - c - 1].setStackedPoints();
4177            if (this.usePercentage)for (c = 0; c < a.length; c++)a[c].setPercentStacks()
4178        }
4179    };
4180    ha.prototype.renderStackTotals = function () {
4181        var a = this.chart, b = a.renderer, c = this.stacks, d, e, f = this.stackTotalGroup;
4182        if (!f)this.stackTotalGroup = f = b.g("stack-labels").attr({visibility: "visible", zIndex: 6}).add();
4183        f.translate(a.plotLeft, a.plotTop);
4184        for (d in c)for (e in a = c[d], a)a[e].render(f)
4185    };
4186    ha.prototype.resetStacks = function () {
4187        var a = this.stacks, b, c;
4188        if (!this.isXAxis)for (b in a)for (c in a[b])a[b][c].touched < this.stacksTouched ? (a[b][c].destroy(),
4189            delete a[b][c]) : (a[b][c].total = null, a[b][c].cum = 0)
4190    };
4191    ha.prototype.cleanStacks = function () {
4192        var a, b, c;
4193        if (!this.isXAxis) {
4194            if (this.oldStacks)a = this.stacks = this.oldStacks;
4195            for (b in a)for (c in a[b])a[b][c].cum = a[b][c].total
4196        }
4197    };
4198    R.prototype.setStackedPoints = function () {
4199        if (this.options.stacking && !(this.visible !== !0 && this.chart.options.chart.ignoreHiddenSeries !== !1)) {
4200            var a = this.processedXData, b = this.processedYData, c = [], d = b.length, e = this.options, f = e.threshold, g = e.startFromThreshold ? f : 0, h = e.stack, e = e.stacking, i = this.stackKey,
4201                j = "-" + i, k = this.negStacks, m = this.yAxis, l = m.stacks, n = m.oldStacks, q, o, r, s, u, y;
4202            m.stacksTouched += 1;
4203            for (s = 0; s < d; s++) {
4204                u = a[s];
4205                y = b[s];
4206                r = this.index + "," + s;
4207                o = (q = k && y < (g ? 0 : f)) ? j : i;
4208                l[o] || (l[o] = {});
4209                if (!l[o][u])n[o] && n[o][u] ? (l[o][u] = n[o][u], l[o
4209][u].total = null) : l[o][u] = new Hb(m, m.options.stackLabels, q, u, h);
4210                o = l[o][u];
4211                o.points[r] = [p(o.cum, g)];
4212                o.touched = m.stacksTouched;
4213                e === "percent" ? (q = q ? i : j, k && l[q] && l[q][u] ? (q = l[q][u], o.total = q.total = t(q.total, o.total) + N(y) || 0) : o.total = ea(o.total + (N(y) || 0))) : o.total = ea(o.total + (y ||
4214                    0));
4215                o.cum = p(o.cum, g) + (y || 0);
4216                o.points[r].push(o.cum);
4217                c[s] = o.cum
4218            }
4219            if (e === "percent")m.usePercentage = !0;
4220            this.stackedYData = c;
4221            m.oldStacks = {}
4222        }
4223    };
4224    R.prototype.setPercentStacks = function () {
4225        var a = this, b = a.stackKey, c = a.yAxis.stacks, d = a.processedXData;
4226        o([b, "-" + b], function (b) {
4227            var e;
4228            for (var f = d.length, g, h; f--;)if (g = d[f], e = (h = c[b] && c[b][g]) && h.points[a.index + "," + f], g = e)h = h.total ? 100 / h.total : 0, g[0] = ea(g[0] * h), g[1] = ea(g[1] * h), a.stackedYData[f] = g[1]
4229        })
4230    };
4231    r(D.prototype, {
4232        addSeries: function (a, b, c) {
4233            var d, e = this;
4234            a && (b = p(b, !0),
4235                I(e, "addSeries", {options: a}, function () {
4236                    d = e.initSeries(a);
4237                    e.isDirtyLegend = !0;
4238                    e.linkSeries();
4239                    b && e.redraw(c)
4240                }));
4241            return d
4242        }, addAxis: function (a, b, c, d) {
4243            var e = b ? "xAxis" : "yAxis", f = this.options;
4244            new ha(this, A(a, {index: this[e].length, isX: b}));
4245            f[e] = ra(f[e] || {});
4246            f[e].push(a);
4247            p(c, !0) && this.redraw(d)
4248        }, showLoading: function (a) {
4249            var b = this, c = b.options, d = b.loadingDiv, e = c.loading, f = function () {
4250                d && L(d, {
4251                    left: b.plotLeft + "px",
4252                    top: b.plotTop + "px",
4253                    width: b.plotWidth + "px",
4254                    height: b.plotHeight + "px"
4255                })
4256            };
4257            if (!d)b.loadingDiv = d = $(Ia, {className: "highcharts-loading"},
4258                r(e.style, {
4259                    zIndex: 10,
4260                    display: O
4261                }), b.container), b.loadingSpan = $("span", null, e.labelStyle, d), H(b, "redraw", f);
4262            b.loadingSpan.innerHTML = a || c.lang.loading;
4263            if (!b.loadingShown)L(d, {
4264                opacity: 0,
4265                display: ""
4266            }), jb(d, {opacity: e.style.opacity}, {duration: e.showDuration || 0}), b.loadingShown = !0;
4267            f()
4268        }, hideLoading: function () {
4269            var a = this.options, b = this.loadingDiv;
4270            b && jb(b, {opacity: 0}, {
4271                duration: a.loading.hideDuration || 100, complete: function () {
4272                    L(b, {display: O})
4273                }
4274            });
4275            this.loadingShown = !1
4276        }
4277    });
4278    r(Ea.prototype, {
4279        update: function (a, b, c, d) {
4280            function e() {
4281                f.applyOptions(a);
4282                if (f.y === null && h)f.graphic = h.destroy();
4283                if (da(a) && !Fa(a))f.redraw = function () {
4284                    if (h && h.element && a && a.marker && a.marker.symbol)f.graphic = h.destroy();
4285                    if (a && a.dataLabels && f.dataLabel)f.dataLabel = f.dataLabel.destroy();
4286                    f.redraw = null
4287                };
4288                i = f.index;
4289                g.updateParallelArrays(f, i);
4290                if (m && f.name)m[f.x] = f.name;
4291                k.data[i] = f.options;
4292                g.isDirty = g.isDirtyData = !0;
4293                if (!g.fixedBox && g.hasCartesianSeries)j.isDirtyBox = !0;
4294                if (k.legendType === "point")j.isDirtyLegend = !0;
4295                b && j.redraw(c)
4296            }
4297
4298            var f = this, g = f.series, h = f.graphic, i, j = g.chart, k = g.options,
4299                m = g.xAxis && g.xAxis.names, b = p(b, !0);
4300            d === !1 ? e() : f.firePointEvent("update", {options: a}, e)
4301        }, remove: function (a, b) {
4302            this.series.removePoint(Ka(this, this.series.data), a, b)
4303        }
4304    });
4305    r(R.prototype, {
4306        addPoint: function (a, b, c, d) {
4307            var e = this, f = e.options, g = e.data, h = e.graph, i = e.area, j = e.chart, k = e.xAxis && e.xAxis.names, m = h && h.shift || 0, l = ["graph", "area"], h = f.data, n, q = e.xData;
4308            Qa(d, j);
4309            if (c) {
4310                for (d = e.zones.length; d--;)l.push("zoneGraph" + d, "zoneArea" + d);
4311                o(l, function (a) {
4312                    if (e[a])e[a].shift = m + 1
4313                })
4314            }
4315            if (i)i.isArea = !0;
4316            b = p(b, !0);
4317            i = {series: e};
4318            e.pointClass.prototype.applyOptions.apply(i, [a]);
4319            l = i.x;
4320            d = q.length;
4321            if (e.requireSorting && l < q[d - 1])for (n = !0; d && q[d - 1] > l;)d--;
4322            e.updateParallelArrays(i, "splice", d, 0, 0);
4323            e.updateParallelArrays(i, d);
4324            if (k && i.name)k[l] = i.name;
4325            h.splice(d, 0, a);
4326            n && (e.data.splice(d, 0, null), e.processData());
4327            f.legendType === "point" && e.generatePoints();
4328            c && (g[0] && g[0].remove ? g[0].remove(!1) : (g.shift(), e.updateParallelArrays(i, "shift"), h.shift()));
4329            e.isDirty = !0;
4330            e.isDirtyData = !0;
4331            b && (e.getAttribs(), j.redraw())
4332        }, removePoint: function (a, b,
4333                                  c) {
4334            var d = this, e = d.data, f = e[a], g = d.points, h = d.chart, i = function () {
4335                e.length === g.length && g.splice(a, 1);
4336                e.splice(a, 1);
4337                d.options.data.splice(a, 1);
4338                d.updateParallelArrays(f || {series: d}, "splice", a, 1);
4339                f && f.destroy();
4340                d.isDirty = !0;
4341                d.isDirtyData = !0;
4342                b && h.redraw()
4343            };
4344            Qa(c, h);
4345            b = p(b, !0);
4346            f ? f.firePointEvent("remove", null, i) : i()
4347        }, remove: function (a, b) {
4348            var c = this, d = c.chart, a = p(a, !0);
4349            if (!c.isRemoving)c.isRemoving = !0, I(c, "remove", null, function () {
4350                c.destroy();
4351                d.isDirtyLegend = d.isDirtyBox = !0;
4352                d.linkSeries();
4353                a && d.redraw(b)
4354            });
4355            c.isRemoving = !1
4356        }, update: function (a, b) {
4357            var c = this, d = this.chart, e = this.userOptions, f = this.type, g = M[f].prototype, h = ["group", "markerGroup", "dataLabelsGroup"], i;
4358            if (a.type && a.type !== f || a.zIndex !== void 0)h.length = 0;
4359            o(h, function (a) {
4360                h[a] = c[a];
4361                delete c[a]
4362            });
4363            a = A(e, {animation: !1, index: this.index, pointStart: this.xData[0]}, {data: this.options.data}, a);
4364            this.remove(!1);
4365            for (i in g)this[i] = v;
4366            r(this, M[a.type || f].prototype);
4367            o(h, function (a) {
4368                c[a] = h[a]
4369            });
4370            this.init(d, a);
4371            d.linkSeries();
4372            p(b, !0) && d.redraw(!1)
4373        }
4374    });
4375    r(ha.prototype, {
4376        update: function (a,
4377                          b) {
4378            var c = this.chart, a = c.options[this.coll][this.options.index] = A(this.userOptions, a);
4379            this.destroy(!0);
4380            this._addedPlotLB = this.chart._labelPanes = v;
4381            this.init(c, r(a, {events: v}));
4382            c.isDirtyBox = !0;
4383            p(b, !0) && c.redraw()
4384        }, remove: function (a) {
4385            for (var b = this.chart, c = this.coll, d = this.series, e = d.length; e--;)d[e] && d[e].remove(!1);
4386            ja(b.axes, this);
4387            ja(b[c], this);
4388            b.options[c].splice(this.options.index, 1);
4389            o(b[c], function (a, b) {
4390                a.options.index = b
4391            });
4392            this.destroy();
4393            b.isDirtyBox = !0;
4394            p(a, !0) && b.redraw()
4395        }, setTitle: function (a, b) {
4396            this.update({title: a},
4397                b)
4398        }, setCategories: function (a, b) {
4399            this.update({categories: a}, b)
4400        }
4401    });
4402    var wa = ka(R);
4403    M.line = wa;
4404    ba.area = A(U, {threshold: 0});
4405    var pa = ka(R, {
4406        type: "area", getSegments: function () {
4407            var a = this, b = [], c = [], d = [], e = this.xAxis, f = this.yAxis, g = f.stacks[this.stackKey], h = {}, i, j, k = this.points, m = this.options.connectNulls, l, n;
4408            if (this.options.stacking && !this.cropped) {
4409                for (l = 0; l < k.length; l++)h[k[l].x] = k[l];
4410                for (n in g)g[n].total !== null && d.push(+n);
4411                d.sort(function (a, b) {
4412                    return a - b
4413                });
4414                o(d, function (b) {
4415                    var d = 0, k;
4416                    if (!m || h[b] && h[b].y !== null)if (h[b])c.push(h[b]);
4417                    else {
4418                        for (l = a.index; l <= f.series.length; l++)if (k = g[b].points[l + "," + b]) {
4419                            d = k[1];
4420                            break
4421                        }
4422                        i = e.translate(b);
4423                        j = f.toPixels(d, !0);
4424                        c.push({y: null, plotX: i, clientX: i, plotY: j, yBottom: j, onMouseOver: ta})
4425                    }
4426                });
4427                c.length && b.push(c)
4428            } else R.prototype.getSegments.call(this), b = this.segments;
4429            this.segments = b
4430        }, getSegmentPath: function (a) {
4431            var b = R.prototype.getSegmentPath.call(this, a), c = [].concat(b), d, e = this.options;
4432            d = b.length;
4433            var f = this.yAxis.getThreshold(e.threshold), g;
4434            d === 3 && c.push("L", b[1], b[2]);
4435            if (e.stacking && !this.closedStacks)for (d =
4436                                                          a.length - 1; d >= 0; d--)g = p(a[d].yBottom, f), d < a.length - 1 && e.step && c.push(a[d + 1].plotX, g), c.push(a[d].plotX, g); else this.closeSegment(c, a, f);
4437            this.areaPath = this.areaPath.concat(c);
4438            return b
4439        }, closeSegment: function (a, b, c) {
4440            a.push("L", b[b.length - 1].plotX, c, "L", b[0].plotX, c)
4441        }, drawGraph: function () {
4442            this.areaPath = [];
4443            R.prototype.drawGraph.apply(this);
4444            var a = this, b = this.areaPath, c = this.options, d = [["area", this.color, c.fillColor]];
4445            o(this.zones, function (b, f) {
4446                d.push(["zoneArea" + f, b.color || a.color, b.fillColor || c.fillColor])
4447            });
4448            o(d, function (d) {
4449                var f = d[0], g = a[f];
4450                g ? g.animate({d: b}) : a[f] = a.chart.renderer.path(b).attr({
4451                    fill: p(d[2], na(d[1]).setOpacity(p(c.fillOpacity, 0.75)).get()),
4452                    zIndex: 0
4453                }).add(a.group)
4454            })
4455        }, drawLegendSymbol: La.drawRectangle
4456    });
4457    M.area = pa;
4458    ba.spline = A(U);
4459    wa = ka(R, {
4460        type: "spline", getPointSpline: function (a, b, c) {
4461            var d = b.plotX, e = b.plotY, f = a[c - 1], g = a[c + 1], h, i, j, k;
4462            if (f && g) {
4463                a = f.plotY;
4464                j = g.plotX;
4465                var g = g.plotY, m;
4466                h = (1.5 * d + f.plotX) / 2.5;
4467                i = (1.5 * e + a) / 2.5;
4468                j = (1.5 * d + j) / 2.5;
4469                k = (1.5 * e + g) / 2.5;
4470                m = (k - i) * (j - d) / (j - h) + e - k;
4471                i += m;
4472                k += m;
4473                i > a && i > e ?
4474                    (i = t(a, e), k = 2 * e - i) : i < a && i < e && (i = z(a, e), k = 2 * e - i);
4475                k > g && k > e ? (k = t(g, e), i = 2 * e - k) : k < g && k < e && (k = z(g, e), i = 2 * e - k);
4476                b.rightContX = j;
4477                b.rightContY = k
4478            }
4479            c ? (b = ["C", f.rightContX || f.plotX, f.rightContY || f.plotY, h || d, i || e, d, e], f.rightContX = f.rightContY = null) : b = ["M", d, e];
4480            return b
4481        }
4482    });
4483    M.spline = wa;
4484    ba.areaspline = A(ba.area);
4485    pa = pa.prototype;
4486    wa = ka(wa, {
4487        type: "areaspline",
4488        closedStacks: !0,
4489        getSegmentPath: pa.getSegmentPath,
4490        closeSegment: pa.closeSegment,
4491        drawGraph: pa.drawGraph,
4492        drawLegendSymbol: La.drawRectangle
4493    });
4494    M.areaspline = wa;
4495    ba.column =
4496        A(U, {
4497            borderColor: "#FFFFFF",
4498            borderRadius: 0,
4499            groupPadding: 0.2,
4500            marker: null,
4501            pointPadding: 0.1,
4502            minPointLength: 0,
4503            cropThreshold: 50,
4504            pointRange: null,
4505            states: {
4506                hover: {brightness: 0.1, shadow: !1, halo: !1},
4507                select: {color: "#C0C0C0", borderColor: "#000000", shadow: !1}
4508            },
4509            dataLabels: {align: null, verticalAlign: null, y: null},
4510            startFromThreshold: !0,
4511            stickyTracking: !1,
4512            tooltip: {distance: 6},
4513            threshold: 0
4514        });
4515    wa = ka(R, {
4516        type: "column",
4517        pointAttrToOptions: {stroke: "borderColor", fill: "color", r: "borderRadius"},
4518        cropShoulder: 0,
4519        directTouch: !0,
4520        trackerGroups: ["group",
4521            "dataLabelsGroup"],
4522        negStacks: !0,
4523        init: function () {
4524            R.prototype.init.apply(this, arguments);
4525            var a = this, b = a.chart;
4526            b.hasRendered && o(b.series, function (b) {
4527                if (b.type === a.type)b.isDirty = !0
4528            })
4529        },
4530        getColumnMetrics: function () {
4531            var a = this, b = a.options, c = a.xAxis, d = a.yAxis, e = c.reversed, f, g = {}, h, i = 0;
4532            b.grouping === !1 ? i = 1 : o(a.chart.series, function (b) {
4533                var c = b.options, e = b.yAxis;
4534                if (b.type === a.type && b.visible && d.len === e.len && d.pos === e.pos)c.stacking ? (f = b.stackKey, g[f] === v && (g[f] = i++), h = g[f]) : c.grouping !== !1 && (h = i++), b.columnIndex =
4535                    h
4536            });
4537            var j = z(N(c.transA) * (c.ordinalSlope || b.pointRange || c.closestPointRange || c.tickInterval || 1), c.len), k = j * b.groupPadding, m = (j - 2 * k) / i, b = z(b.maxPointWidth || c.len, p(b.pointWidth, m * (1 - 2 * b.pointPadding)));
4538            return a.columnMetrics = {
4539                width: b,
4540                offset: (m - b) / 2 + (k + ((e ? i - (a.columnIndex || 0) : a.columnIndex) || 0) * m - j / 2) * (e ? -1 : 1)
4541            }
4542        },
4543        translate: function () {
4544            var a = this, b = a.chart, c = a.options, d = a.borderWidth = p(c.borderWidth, a.closestPointRange * a.xAxis.transA < 2 ? 0 : 1), e = a.yAxis, f = a.translatedThreshold = e.getThreshold(c.threshold),
4545                g = p(c.minPointLength, 5), h = a.getColumnMetrics(), i = h.width, j = a.barW = t(i, 1 + 2 * d), k = a.pointXOffset = h.offset, m = -(d % 2 ? 0.5 : 0), l = d % 2 ? 0.5 : 1;
4546            b.inverted && (f -= 0.5, b.renderer.isVML && (l += 1));
4547            c.pointPadding && (j = sa(j));
4548            R.prototype.translate.apply(a);
4549            o(a.points, function (c) {
4550                var d = p(c.yBottom, f), h = 999 + N(d), h = z(t(-h, c.plotY), e.len + h), o = c.plotX + k, r = j, s = z(h, d), y, v;
4551                y = t(h, d) - s;
4552                N(y) < g && g && (y = g, v = !e.reversed && !c.negative || e.reversed && c.negative, s = w(N(s - f) > g ? d - g : f - (v ? g : 0)));
4553                c.barX = o;
4554                c.pointWidth = i;
4555                r = w(o + r) + m;
4556                o = w(o) + m;
4557                r -= o;
4558                d =
4559                    N(s) < 0.5;
4560                y = z(w(s + y) + l, 9E4);
4561                s = w(s) + l;
4562                y -= s;
4563                d && (s -= 1, y += 1);
4564                c.tooltipPos = b.inverted ? [e.len + e.pos - b.plotLeft - h, a.xAxis.len - o - r / 2, y] : [o + r / 2, h + e.pos - b.plotTop, y];
4565                c.shapeType = "rect";
4566                c.shapeArgs = {x: o, y: s, width: r, height: y}
4567            })
4568        },
4569        getSymbol: ta,
4570        drawLegendSymbol: La.drawRectangle,
4571        drawGraph: ta,
4572        drawPoints: function () {
4573            var a = this, b = this.chart, c = a.options, d = b.renderer, e = c.animationLimit || 250, f, g;
4574            o(a.points, function (h) {
4575                var i = h.plotY, j = h.graphic;
4576                if (i !== v && !isNaN(i) && h.y !== null)f = h.shapeArgs, i = s(a.borderWidth) ? {"stroke-width": a.borderWidth} :
4577                {}, g = h.pointAttr[h.selected ? "select" : ""] || a.pointAttr[""], j ? (kb(j), j.attr(i)[b.pointCount < e ? "animate" : "attr"](A(f))) : h.graphic = d[h.shapeType](f).attr(i).attr(g).add(a.group).shadow(c.shadow, null, c.stacking && !c.borderRadius); else if (j)h.graphic = j.destroy()
4578            })
4579        },
4580        animate: function (a) {
4581            var b = this.yAxis, c = this.options, d = this.chart.inverted, e = {};
4582            if (ca)a ? (e.scaleY = 0.001, a = z(b.pos + b.len, t(b.pos, b.toPi
4582xels(c.threshold))), d ? e.translateX = a - b.len : e.translateY = a, this.group.attr(e)) : (e.scaleY = 1, e[d ? "translateX" : "translateY"] =
4583                b.pos, this.group.animate(e, this.options.animation), this.animate = null)
4584        },
4585        remove: function () {
4586            var a = this, b = a.chart;
4587            b.hasRendered && o(b.series, function (b) {
4588                if (b.type === a.type)b.isDirty = !0
4589            });
4590            R.prototype.remove.apply(a, arguments)
4591        }
4592    });
4593    M.column = wa;
4594    ba.bar = A(ba.column);
4595    pa = ka(wa, {type: "bar", inverted: !0});
4596    M.bar = pa;
4597    ba.scatter = A(U, {
4598        lineWidth: 0,
4599        marker: {enabled: !0},
4600        tooltip: {
4601            headerFormat: '<span style="color:{point.color}">\u25cf</span> <span style="font-size: 10px;"> {series.name}</span><br/>',
4602            pointFormat: "x: <b>{point.x}</b><br/>y: <b>{point.y}</b><br/>"
4603        }
4604    });
4605    pa = ka(R, {
4606        type: "scatter",
4607        sorted: !1,
4608        requireSorting: !1,
4609        noSharedTooltip: !0,
4610        trackerGroups: ["group", "markerGroup", "dataLabelsGroup"],
4611        takeOrdinalPosition: !1,
4612        kdDimensions: 2,
4613        drawGraph: function () {
4614            this.options.lineWidth && R.prototype.drawGraph.call(this)
4615        }
4616    });
4617    M.scatter = pa;
4618    ba.pie = A(U, {
4619        borderColor: "#FFFFFF",
4620        borderWidth: 1,
4621        center: [null, null],
4622        clip: !1,
4623        colorByPoint: !0,
4624        dataLabels: {
4625            distance: 30, enabled: !0, formatter: function () {
4626                return this.y === null ? void 0 : this.point.name
4627            }, x: 0
4628        },
4629        ignoreHiddenPoint: !0,
4630        legendType: "point",
4631        marker: null,
4632        size: null,
4633        showInLegend: !1,
4634        slicedOffset: 10,
4635        states: {hover: {brightness: 0.1, shadow: !1}},
4636        stickyTracking: !1,
4637        tooltip: {followPointer: !0}
4638    });
4639    U = {
4640        type: "pie",
4641        isCartesian: !1,
4642        pointClass: ka(Ea, {
4643            init: function () {
4644                Ea.prototype.init.apply(this, arguments);
4645                var a = this, b;
4646                r(a, {visible: a.visible !== !1, name: p(a.name, "Slice")});
4647                b = function (b) {
4648                    a.slice(b.type === "select")
4649                };
4650                H(a, "select", b);
4651                H(a, "unselect", b);
4652                return a
4653            }, setVisible: function (a, b) {
4654                var c = this, d = c.series, e = d.chart, f = d.options.ignoreHiddenPoint, b = p(b, f);
4655                if (a !== c.visible) {
4656                    c.visible =
4657                        c.options.visible = a = a === v ? !c.visible : a;
4658                    d.options.data[Ka(c, d.data)] = c.options;
4659                    o(["graphic", "dataLabel", "connector", "shadowGroup"], function (b) {
4660                        if (c[b])c[b][a ? "show" : "hide"](!0)
4661                    });
4662                    c.legendItem && e.legend.colorizeItem(c, a);
4663                    !a && c.state === "hover" && c.setState("");
4664                    if (f)d.isDirty = !0;
4665                    b && e.redraw()
4666                }
4667            }, slice: function (a, b, c) {
4668                var d = this.series;
4669                Qa(c, d.chart);
4670                p(b, !0);
4671                this.sliced = this.options.sliced = a = s(a) ? a : !this.sliced;
4672                d.options.data[Ka(this, d.data)] = this.options;
4673                a = a ? this.slicedTranslation : {translateX: 0, translateY: 0};
4674                this.graphic.animate(a);
4675                this.shadowGroup && this.shadowGroup.animate(a)
4676            }, haloPath: function (a) {
4677                var b = this.shapeArgs, c = this.series.chart;
4678                return this.sliced || !this.visible ? [] : this.series.chart.renderer.symbols.arc(c.plotLeft + b.x, c.plotTop + b.y, b.r + a, b.r + a, {
4679                    innerR: this.shapeArgs.r,
4680                    start: b.start,
4681                    end: b.end
4682                })
4683            }
4684        }),
4685        requireSorting: !1,
4686        directTouch: !0,
4687        noSharedTooltip: !0,
4688        trackerGroups: ["group", "dataLabelsGroup"],
4689        axisTypes: [],
4690        pointAttrToOptions: {stroke: "borderColor", "stroke-width": "borderWidth", fill: "color"},
4691        animate: function (a) {
4692            var b =
4693                this, c = b.points, d = b.startAngleRad;
4694            if (!a)o(c, function (a) {
4695                var c = a.graphic, g = a.shapeArgs;
4696                c && (c.attr({r: a.startR || b.center[3] / 2, start: d, end: d}), c.animate({
4697                    r: g.r,
4698                    start: g.start,
4699                    end: g.end
4700                }, b.options.animation))
4701            }), b.animate = null
4702        },
4703        setData: function (a, b, c, d) {
4704            R.prototype.setData.call(this, a, !1, c, d);
4705            this.processData();
4706            this.generatePoints();
4707            p(b, !0) && this.chart.redraw(c)
4708        },
4709        updateTotals: function () {
4710            var a, b = 0, c = this.points, d = c.length, e, f = this.options.ignoreHiddenPoint;
4711            for (a = 0; a < d; a++)e = c[a], b += f && !e.visible ? 0 : e.y;
4712            this.total =
4713                b;
4714            for (a = 0; a < d; a++)e = c[a], e.percentage = b > 0 && (e.visible || !f) ? e.y / b * 100 : 0, e.total = b
4715        },
4716        generatePoints: function () {
4717            R.prototype.generatePoints.call(this);
4718            this.updateTotals()
4719        },
4720        translate: function (a) {
4721            this.generatePoints();
4722            var b = 0, c = this.options, d = c.slicedOffset, e = d + c.borderWidth, f, g, h, i = c.startAngle || 0, j = this.startAngleRad = ma / 180 * (i - 90), i = (this.endAngleRad = ma / 180 * (p(c.endAngle, i + 360) - 90
4722)) - j, k = this.points, m = c.dataLabels.distance, c = c.ignoreHiddenPoint, l, n = k.length, o;
4723            if (!a)this.center = a = this.getCenter();
4724            this.getX =
4725                function (b, c) {
4726                    h = W.asin(z((b - a[1]) / (a[2] / 2 + m), 1));
4727                    return a[0] + (c ? -1 : 1) * X(h) * (a[2] / 2 + m)
4728                };
4729            for (l = 0; l < n; l++) {
4730                o = k[l];
4731                f = j + b * i;
4732                if (!c || o.visible)b += o.percentage / 100;
4733                g = j + b * i;
4734                o.shapeType = "arc";
4735                o.shapeArgs = {
4736                    x: a[0],
4737                    y: a[1],
4738                    r: a[2] / 2,
4739                    innerR: a[3] / 2,
4740                    start: w(f * 1E3) / 1E3,
4741                    end: w(g * 1E3) / 1E3
4742                };
4743                h = (g + f) / 2;
4744                h > 1.5 * ma ? h -= 2 * ma : h < -ma / 2 && (h += 2 * ma);
4745                o.slicedTranslation = {translateX: w(X(h) * d), translateY: w(aa(h) * d)};
4746                f = X(h) * a[2] / 2;
4747                g = aa(h) * a[2] / 2;
4748                o.tooltipPos = [a[0] + f * 0.7, a[1] + g * 0.7];
4749                o.half = h < -ma / 2 || h > ma / 2 ? 1 : 0;
4750                o.angle = h;
4751                e = z(e, m / 2);
4752                o.labelPos =
4753                    [a[0] + f + X(h) * m, a[1] + g + aa(h) * m, a[0] + f + X(h) * e, a[1] + g + aa(h) * e, a[0] + f, a[1] + g, m < 0 ? "center" : o.half ? "right" : "left", h]
4754            }
4755        },
4756        drawGraph: null,
4757        drawPoints: function () {
4758            var a = this, b = a.chart.renderer, c, d, e = a.options.shadow, f, g, h;
4759            if (e && !a.shadowGroup)a.shadowGroup = b.g("shadow").add(a.group);
4760            o(a.points, function (i) {
4761                if (i.y !== null) {
4762                    d = i.graphic;
4763                    g = i.shapeArgs;
4764                    f = i.shadowGroup;
4765                    if (e && !f)f = i.shadowGroup = b.g("shadow").add(a.shadowGroup);
4766                    c = i.sliced ? i.slicedTranslation : {translateX: 0, translateY: 0};
4767                    f && f.attr(c);
4768                    if (d)d.animate(r(g, c));
4769                    else {
4770                        h = {"stroke-linejoin": "round"};
4771                        if (!i.visible)h.visibility = "hidden";
4772                        i.graphic = d = b[i.shapeType](g).setRadialReference(a.center).attr(i.pointAttr[i.selected ? "select" : ""]).attr(h).attr(c).add(a.group).shadow(e, f)
4773                    }
4774                }
4775            })
4776        },
4777        searchPoint: ta,
4778        sortByAngle: function (a, b) {
4779            a.sort(function (a, d) {
4780                return a.angle !== void 0 && (d.angle - a.angle) * b
4781            })
4782        },
4783        drawLegendSymbol: La.drawRectangle,
4784        getCenter: Xb.getCenter,
4785        getSymbol: ta
4786    };
4787    U = ka(R, U);
4788    M.pie = U;
4789    R.prototype.drawDataLabels = function () {
4790        var a = this, b = a.options, c = b.cursor, d = b.dataLabels,
4791            e = a.points, f, g, h = a.hasRendered || 0, i, j, k = a.chart.renderer;
4792        if (d.enabled || a._hasPointLabels)a.dlProcessOptions && a.dlProcessOptions(d), j = a.plotGroup("dataLabelsGroup", "data-labels", d.defer ? "hidden" : "visible", d.zIndex || 6), p(d.defer, !0) && (j.attr({opacity: +h}), h || H(a, "afterAnimate", function () {
4793            a.visible && j.show();
4794            j[b.animation ? "animate" : "attr"]({opacity: 1}, {duration: 200})
4795        })), g = d, o(e, function (e) {
4796            var h, n = e.dataLabel, o, t, w = e.connector, z = !0, u, y = {};
4797            f = e.dlOptions || e.options && e.options.dataLabels;
4798            h = p(f && f.enabled,
4799                g.enabled);
4800            if (n && !h)e.dataLabel = n.destroy(); else if (h) {
4801                d = A(g, f);
4802                u = d.style;
4803                h = d.rotation;
4804                o = e.getLabelConfig();
4805                i = d.format ? Ha(d.format, o) : d.formatter.call(o, d);
4806                u.color = p(d.color, u.color, a.color, "black");
4807                if (n)if (s(i))n.attr({text: i}), z = !1; else {
4808                    if (e.dataLabel = n = n.destroy(), w)e.connector = w.destroy()
4809                } else if (s(i)) {
4810                    n = {
4811                        fill: d.backgroundColor,
4812                        stroke: d.borderColor,
4813                        "stroke-width": d.borderWidth,
4814                        r: d.borderRadius || 0,
4815                        rotation: h,
4816                        padding: d.padding,
4817                        zIndex: 1
4818                    };
4819                    if (u.color === "contrast")y.color = d.inside || d.distance < 0 || b.stacking ?
4820                        k.getContrast(e.color || a.color) : "#000000";
4821                    if (c)y.cursor = c;
4822                    for (t in n)n[t] === v && delete n[t];
4823                    n = e.dataLabel = k[h ? "text" : "label"](i, 0, -999, d.shape, null, null, d.useHTML).attr(n).css(r(u, y)).add(j).shadow(d.shadow)
4824                }
4825                n && a.alignDataLabel(e, n, d, null, z)
4826            }
4827        })
4828    };
4829    R.prototype.alignDataLabel = function (a, b, c, d, e) {
4830        var f = this.chart, g = f.inverted, h = p(a.plotX, -999), i = p(a.plotY, -999), j = b.getBBox(), k = f.renderer.fontMetrics(c.style.fontSize).b, m = this.visible && (a.series.forceDL || f.isInsidePlot(h, w(i), g) || d && f.isInsidePlot(h, g ? d.x +
4831            1 : d.y + d.height - 1, g));
4832        if (m)d = r({
4833            x: g ? f.plotWidth - i : h,
4834            y: w(g ? f.plotHeight - h : i),
4835            width: 0,
4836            height: 0
4837        }, d), r(c, {
4838            width: j.width,
4839            height: j.height
4840        }), c.rotation ? (a = f.renderer.rotCorr(k, c.rotation), b[e ? "attr" : "animate"]({
4841            x: d.x + c.x + d.width / 2 + a.x,
4842            y: d.y + c.y + d.height / 2
4843        }).attr({align: c.align})) : (b.align(c, null, d), g = b.alignAttr, p(c.overflow, "justify") === "justify" ? this.justifyDataLabel(b, c, g, j, d, e) : p(c.crop, !0) && (m = f.isInsidePlot(g.x, g.y) && f.isInsidePlot(g.x + j.width, g.y + j.height)), c.shape && b.attr({
4844            anchorX: a.plotX,
4845            anchorY: a.plotY
4846        }));
4847        if (!m)b.attr({y: -999}), b.placed = !1
4848    };
4849    R.prototype.justifyDataLabel = function (a, b, c, d, e, f) {
4850        var g = this.chart, h = b.align, i = b.verticalAlign, j, k, m = a.box ? 0 : a.padding || 0;
4851        j = c.x + m;
4852        if (j < 0)h === "right" ? b.align = "left" : b.x = -j, k = !0;
4853        j = c.x + d.width - m;
4854        if (j > g.plotWidth)h === "left" ? b.align = "right" : b.x = g.plotWidth - j, k = !0;
4855        j = c.y + m;
4856        if (j < 0)i === "bottom" ? b.verticalAlign = "top" : b.y = -j, k = !0;
4857        j = c.y + d.height - m;
4858        if (j > g.plotHeight)i === "top" ? b.verticalAlign = "bottom" : b.y = g.plotHeight - j, k = !0;
4859        if (k)a.placed = !f, a.align(b, null, e)
4860    };
4861    if (M.pie)M.pie.prototype.drawDataLabels =
4862        function () {
4863            var a = this, b = a.data, c, d = a.chart, e = a.options.dataLabels, f = p(e.connectorPadding, 10), g = p(e.connectorWidth, 1), h = d.plotWidth, i = d.plotHeight, j, k, m = p(e.softConnector, !0), l = e.distance, n = a.center, q = n[2] / 2, r = n[1], s = l > 0, v, u, y, C = [[], []], A, B, D, F, G, E = [0, 0, 0, 0], L = function (a, b) {
4864                return b.y - a.y
4865            };
4866            if (a.visible && (e.enabled || a._hasPointLabels)) {
4867                R.prototype.drawDataLabels.apply(a);
4868                o(b, function (a) {
4869                    a.dataLabel && a.visible && C[a.half].push(a)
4870                });
4871                for (F = 2; F--;) {
4872                    var I = [], M = [], H = C[F], K = H.length, J;
4873                    if (K) {
4874                        a.sortByAngle(H,
4875                            F - 0.5);
4876                        for (G = b = 0; !b && H[G];)b = H[G] && H[G].dataLabel && (H[G].dataLabel.getBBox().height || 21), G++;
4877                        if (l > 0) {
4878                            u = z(r + q + l, d.plotHeight);
4879                            for (G = t(0, r - q - l); G <= u; G += b)I.push(G);
4880                            u = I.length;
4881                            if (K > u) {
4882                                c = [].concat(H);
4883                                c.sort(L);
4884                                for (G = K; G--;)c[G].rank = G;
4885                                for (G = K; G--;)H[G].rank >= u && H.splice(G, 1);
4886                                K = H.length
4887                            }
4888                            for (G = 0; G < K; G++) {
4889                                c = H[G];
4890                                y = c.labelPos;
4891                                c = 9999;
4892                                var P, O;
4893                                for (O = 0; O < u; O++)P = N(I[O] - y[1]), P < c && (c = P, J = O);
4894                                if (J < G && I[G] !== null)J = G; else for (u < K - G + J && I[G] !== null && (J = u - K + G); I[J] === null;)J++;
4895                                M.push({i: J, y: I[J]});
4896                                I[J] = null
4897                            }
4898                            M.sort(L)
4899                        }
4900                        for (G =
4901                                 0; G < K; G++) {
4902                            c = H[G];
4903                            y = c.labelPos;
4904                            v = c.dataLabel;
4905                            D = c.visible === !1 ? "hidden" : "inherit";
4906                            c = y[1];
4907                            if (l > 0) {
4908                                if (u = M.pop(), J = u.i, B = u.y, c > B && I[J + 1] !== null || c < B && I[J - 1] !== null)B = z(t(0, c), d.plotHeight)
4909                            } else B = c;
4910                            A = e.justify ? n[0] + (F ? -1 : 1) * (q + l) : a.getX(B === r - q - l || B === r + q + l ? c : B, F);
4911                            v._attr = {visibility: D, align: y[6]};
4912                            v._pos = {x: A + e.x + ({left: f, right: -f}[y[6]] || 0), y: B + e.y - 10};
4913                            v.connX = A;
4914                            v.connY = B;
4915                            if (this.options.size === null)u = v.width, A - u < f ? E[3] = t(w(u - A + f), E[3]) : A + u > h - f && (E[1] = t(w(A + u - h + f), E[1])), B - b / 2 < 0 ? E[0] = t(w(-B + b / 2), E[0]) :
4916                            B + b / 2 > i && (E[2] = t(w(B + b / 2 - i), E[2]))
4917                        }
4918                    }
4919                }
4920                if (Ca(E) === 0 || this.verifyDataLabelOverflow(E))this.placeDataLabels(), s && g && o(this.points, function (b) {
4921                    j = b.connector;
4922                    y = b.labelPos;
4923                    if ((v = b.dataLabel) && v._pos && b.visible)D = v._attr.visibility, A = v.connX, B = v.connY, k = m ? ["M", A + (y[6] === "left" ? 5 : -5), B, "C", A, B, 2 * y[2] - y[4], 2 * y[3] - y[5], y[2], y[3], "L", y[4], y[5]] : ["M", A + (y[6] === "left" ? 5 : -5), B, "L", y[2], y[3], "L", y[4], y[5]], j ? (j.animate({d: k}), j.attr("visibility", D)) : b.connector = j = a.chart.renderer.path(k).attr({
4924                        "stroke-width": g, stroke: e.connectorColor ||
4925                        b.color || "#606060", visibility: D
4926                    }).add(a.dataLabelsGroup); else if (j)b.connector = j.destroy()
4927                })
4928            }
4929        }, M.pie.prototype.placeDataLabels = function () {
4930        o(this.points, function (a) {
4931            var b = a.dataLabel;
4932            if (b && a.visible)(a = b._pos) ? (b.attr(b._attr), b[b.moved ? "animate" : "attr"](a), b.moved = !0) : b && b.attr({y: -999})
4933        })
4934    }, M.pie.prototype.alignDataLabel = ta, M.pie.prototype.verifyDataLabelOverflow = function (a) {
4935        var b = this.center, c = this.options, d = c.center, e = c.minSize || 80, f = e, g;
4936        d[0] !== null ? f = t(b[2] - t(a[1], a[3]), e) : (f = t(b[2] - a[1] - a[3],
4937            e), b[0] += (a[3] - a[1]) / 2);
4938        d[1] !== null ? f = t(z(f, b[2] - t(a[0], a[2])), e) : (f = t(z(f, b[2] - a[0] - a[2]), e), b[1] += (a[0] - a[2]) / 2);
4939        f < b[2] ? (b[2] = f, b[3] = /%$/.test(c.innerSize || 0) ? f * parseFloat(c.innerSize || 0) / 100 : parseFloat(c.innerSize || 0), this.translate(b), o(this.points, function (a) {
4940            if (a.dataLabel)a.dataLabel._pos = null
4941        }), this.drawDataLabels && this.drawDataLabels()) : g = !0;
4942        return g
4943    };
4944    if (M.column)M.column.prototype.alignDataLabel = function (a, b, c, d, e) {
4945        var f = this.chart.inverted, g = a.series, h = a.dlBox || a.shapeArgs, i = p(a.below,
4946            a.plotY > p(this.translatedThreshold, g.yAxis.len)), j = p(c.inside, !!this.options.stacking);
4947        if (h && (d = A(h), f && (d = {
4948                x: g.yAxis.len - d.y - d.height,
4949                y: g.xAxis.len - d.x - d.width,
4950                width: d.height,
4951                height: d.width
4952            }), !j))f ? (d.x += i ? 0 : d.width, d.width = 0) : (d.y += i ? d.height : 0, d.height = 0);
4953        c.align = p(c.align, !f || j ? "center" : i ? "right" : "left");
4954        c.verticalAlign = p(c.verticalAlign, f || j ? "middle" : i ? "top" : "bottom");
4955        R.prototype.alignDataLabel.call(this, a, b, c, d, e)
4956    };
4957    (function (a) {
4958        var b = a.Chart, c = a.each, d = a.pick, e = HighchartsAdapter.addEvent;
4959        b.prototype.callbacks.push(function (a) {
4960            function b() {
4961                var e =
4962                    [];
4963                c(a.series, function (a) {
4964                    var b = a.options.dataLabels, f = a.dataLabelCollections || ["dataLabel"];
4965                    (b.enabled || a._hasPointLabels) && !b.allowOverlap && a.visible && c(f, function (b) {
4966                        c(a.points, function (a) {
4967                            if (a[b])a[b].labelrank = d(a.labelrank, a.shapeArgs && a.shapeArgs.height), e.push(a[b])
4968                        })
4969                    })
4970                });
4971                a.hideOverlappingLabels(e)
4972            }
4973
4974            b();
4975            e(a, "redraw", b)
4976        });
4977        b.prototype.hideOverlappingLabels = function (a) {
4978            var b = a.length, d, e, j, k, m, l, n;
4979            for (e = 0; e < b; e++)if (d = a[e])d.oldOpacity = d.opacity, d.newOpacity = 1;
4980            a.sort(function (a, b) {
4981                return (b.labelrank ||
4982                    0) - (a.labelrank || 0)
4983            });
4984            for (e = 0; e < b; e++) {
4985                j = a[e];
4986                for (d = e + 1; d < b; ++d)if (k = a[d], j && k && j.placed && k.placed && j.newOpacity !== 0 && k.newOpacity !== 0 && (m = j.alignAttr, l = k.alignAttr, n = 2 * (j.box ? 0 : j.padding), m = !(l.x > m.x + (j.width - n) || l.x + (k.width - n) < m.x || l.y > m.y + (j.height - n) || l.y + (k.height - n) < m.y)))(j.labelrank < k.labelrank ? j : k).newOpacity = 0
4987            }
4988            c(a, function (a) {
4989                var b, c;
4990                if (a) {
4991                    c = a.newOpacity;
4992                    if (a.oldOpacity !== c && a.placed)c ? a.show(!0) : b = function () {
4993                        a.hide()
4994                    }, a.alignAttr.opacity = c, a[a.isOld ? "animate" : "attr"](a.alignAttr, null,
4995                        b);
4996                    a.isOld = !0
4997                }
4998            })
4999        }
5000    })(B);
5001    U = B.TrackerMixin = {
5002        drawTrackerPoint: function () {
5003            var a = this, b = a.chart, c = b.pointer, d = a.options.cursor, e = d && {cursor: d}, f = function (a) {
5004                for (var c = a.target, d; c && !d;)d = c.point, c = c.parentNode;
5005                if (d !== v && d !== b.hoverPoint)d.onMouseOver(a)
5006            };
5007            o(a.points, function (a) {
5008                if (a.graphic)a.graphic.element.point = a;
5009                if (a.dataLabel)a.dataLabel.element.point = a
5010            });
5011            if (!a._hasTracking)o(a.trackerGroups, function (b) {
5012                if (a[b] && (a[b].addClass("highcharts-tracker").on("mouseover", f).on("mouseout", function (a) {
5013                        c.onTrackerMouseOut(a)
5014                    }).css(e),
5015                        $a))a[b].on("touchstart", f)
5016            }), a._hasTracking = !0
5017        }, drawTrackerGraph: function () {
5018            var a = this, b = a.options, c = b.trackByArea, d = [].concat(c ? a.areaPath : a.graphPath), e = d.length, f = a.chart, g = f.pointer, h = f.renderer, i = f.options.tooltip.snap, j = a.tracker, k = b.cursor, m = k && {cursor: k}, k = a.singlePoints, l, n = function () {
5019                if (f.hoverSeries !== a)a.onMouseOver()
5020            }, p = "rgba(192,192,192," + (ca ? 1.0E-4 : 0.002) + ")";
5021            if (e && !c)for (l = e + 1; l--;)d[l] === "M" && d.splice(l + 1, 0, d[l + 1] - i, d[l + 2], "L"), (l && d[l] === "M" || l === e) && d.splice(l, 0, "L", d[l - 2] + i, d[l -
5022            1]);
5023            for (l = 0; l < k.length; l++)e = k[l], d.push("M", e.plotX - i, e.plotY, "L", e.plotX + i, e.plotY);
5024            j ? j.attr({d: d}) : (a.tracker = h.path(d).attr({
5025                "stroke-linejoin": "round",
5026                visibility: a.visible ? "visible" : "hidden",
5027                stroke: p,
5028                fill: c ? p : O,
5029                "stroke-width": b.lineWidth + (c ? 0 : 2 * i),
5030                zIndex: 2
5031            }).add(a.group), o([a.tracker, a.markerGroup], function (a) {
5032                a.addClass("highcharts-tracker").on("mouseover", n).on("mouseout", function (a) {
5033                    g.onTrackerMouseOut(a)
5034                }).css(m);
5035                if ($a)a.on("touchstart", n)
5036            }))
5037        }
5038    };
5039    if (M.column)wa.prototype.drawTracker = U.drawTrackerPoint;
5040    if (M.pie)M.pie.prototype.drawTracker = U.drawTrackerPoint;
5041    if (M.scatter)pa.prototype.drawTracker = U.drawTrackerPoint;
5042    r(lb.prototype, {
5043        setItemEvents: function (a, b, c, d, e) {
5044            var f = this;
5045            (c ? b : a.legendGroup).on("mouseover", function () {
5046                a.setState("hover");
5047                b.css(f.options.itemHoverStyle)
5048            }).on("mouseout", function () {
5049                b.css(a.visible ? d : e);
5050                a.setState()
5051            }).on("click", function (b) {
5052                var c = function () {
5053                    a.setVisible()
5054                }, b = {browserEvent: b};
5055                a.firePointEvent ? a.firePointEvent("legendItemClick", b, c) : I(a, "legendItemClick", b, c)
5056            })
5057        }, createCheckboxForItem: function (a) {
5058            a.checkbox =
5059                $("input", {
5060                    type: "checkbox",
5061                    checked: a.selected,
5062                    defaultChecked: a.selected
5063                }, this.options.itemCheckboxStyle, this.chart.container);
5064            H(a.checkbox, "click", function (b) {
5065                I(a.series || a, "checkboxClick", {checked: b.target.checked, item: a}, function () {
5066                    a.select()
5067                })
5068            })
5069        }
5070    });
5071    S.legend.itemStyle.cursor = "pointer";
5072    r(D.prototype, {
5073        showResetZoom: function () {
5074            var a = this, b = S.lang, c = a.options.chart.resetZoomButton, d = c.theme, e = d.states, f = c.relativeTo === "chart" ? null : "plotBox";
5075            this.resetZoomButton = a.renderer.button(b.resetZoom, null, null,
5076                function () {
5077                    a.zoomOut()
5078                }, d, e && e.hover).attr({
5079                    align: c.position.align,
5080                    title: b.resetZoomTitle
5081                }).add().align(c.position, !1, f)
5082        }, zoomOut: function () {
5083            var a = this;
5084            I(a, "selection", {resetSelection: !0}, function () {
5085                a.zoom()
5086            })
5087        }, zoom: function (a) {
5088            var b, c = this.pointer, d = !1, e;
5089            !a || a.resetSelection ? o(this.axes, function (a) {
5090                b = a.zoom()
5091            }) : o(a.xAxis.concat(a.yAxis), function (a) {
5092                var e = a.axis, h = e.isXAxis;
5093                if (c[h ? "zoomX" : "zoomY"] || c[h ? "pinchX" : "pinchY"])b = e.zoom(a.min, a.max), e.displayBtn && (d = !0)
5094            });
5095            e = this.resetZoomButton;
5096            if (d && !e)this.showResetZoom();
5097            else if (!d && da(e))this.resetZoomButton = e.destroy();
5098            b && this.redraw(p(this.options.chart.animation, a && a.animation, this.pointCount < 100))
5099        }, pan: function (a, b) {
5100            var c = this, d = c.hoverPoints, e;
5101            d && o(d, function (a) {
5102                a.setState()
5103            });
5104            o(b === "xy" ? [1, 0] : [1], function (b) {
5105                var d = a[b ? "chartX" : "chartY"], h = c[b ? "xAxis" : "yAxis"][0], i = c[b ? "mouseDownX" : "mouseDownY"], j = (h.pointRange || 0) / 2, k = h.getExtremes(), m = h.toValue(i - d, !0) + j, j = h.toValue(i + c[b ? "plotWidth" : "plotHeight"] - d, !0) - j, i = i > d;
5106                if (h.series.length && (i || m > z(k.dataMin, k.min)) &&
5107                    (!i || j < t(k.dataMax, k.max)))h.setExtremes(m, j, !1, !1, {trigger: "pan"}), e = !0;
5108                c[b ? "mouseDownX" : "mouseDownY"] = d
5109            });
5110            e && c.redraw(!1);
5111            L(c.container, {cursor: "move"})
5112        }
5113    });
5114    r(Ea.prototype, {
5115        select: function (a, b) {
5116            var c = this, d = c.series, e = d.chart, a = p(a, !c.selected);
5117            c.firePointEvent(a ? "select" : "unselect", {accumulate: b}, function () {
5118                c.selected = c.options.selected = a;
5119                d.options.data[Ka(c, d.data)] = c.options;
5120                c.setState(a && "select");
5121                b || o(e.getSelectedPoints(), function (a) {
5122                    if (a.selected && a !== c)a.selected = a.options.selected = !1, d.options.data[Ka(a,
5123                        d.data)] = a.options, a.setState(""), a.firePointEvent("unselect")
5124                })
5125            })
5126        }, onMouseOver: function (a, b) {
5127            var c = this.series, d = c.chart, e = d.tooltip, f = d.hoverPoint;
5128            if (d.hoverSeries !== c)c.onMouseOver();
5129            if (f && f !== this)f.onMouseOut();
5130            if (this.series && (this.firePointEvent("mouseOver"), e && (!e.shared || c.noSharedTooltip) && e.refresh(this, a), this.setState("hover"), !b))d.hoverPoint = this
5131        }, onMouseOut: function () {
5132            var a = this.series.chart, b = a.hoverPoints;
5133            this.firePointEvent("mouseOut");
5134            if (!b || Ka(this, b) === -1)this.setState(), a.hoverPoint =
5135                null
5136        }, importEvents: function () {
5137            if (!this.hasImportedEvents) {
5138                var a = A(this.series.options.point, this.options).events, b;
5139                this.events = a;
5140                for (b in a)H(this, b, a[b]);
5141                this.hasImportedEvents = !0
5142            }
5143        }, setState: function (a, b) {
5144            var c = this.plotX, d = this.plotY, e = this.series, f = e.options.states, g = ba[e.type].marker && e.options.marker, h = g && !g.enabled, i = g && g.states[a], j = i && i.enabled === !1, k = e.stateMarkerGraphic, m = this.marker || {}, l = e.chart, n = e.halo, o, a = a || "";
5145            o = this.pointAttr[a] || e.pointAttr[a];
5146            if (!(a === this.state && !b || this.selected &&
5147                a !== "select" || f[a] && f[a].enabled === !1 || a && (j || h && i.enabled === !1) || a && m.states && m.states[a] && m.states[a].enabled === !1)) {
5148                if (this.graphic)g = g && this.graphic.symbolName && o.r, this.graphic.attr(A(o, g ? {
5149                    x: c - g,
5150                    y: d - g,
5151                    width: 2 * g,
5152                    height: 2 * g
5153                } : {})), k && k.hide(); else {
5154                    if (a && i)if 
5154(g = i.radius, m = m.symbol || e.symbol, k && k.currentSymbol !== m && (k = k.destroy()), k)k[b ? "animate" : "attr"]({
5155                        x: c - g,
5156                        y: d - g
5157                    }); else if (m)e.stateMarkerGraphic = k = l.renderer.symbol(m, c - g, d - g, 2 * g, 2 * g).attr(o).add(e.markerGroup), k.currentSymbol = m;
5158                    if (k)k[a && l.isInsidePlot(c,
5159                        d, l.inverted) ? "show" : "hide"](), k.element.point = this
5160                }
5161                if ((c = f[a] && f[a].halo) && c.size) {
5162                    if (!n)e.halo = n = l.renderer.path().add(l.seriesGroup);
5163                    n.attr(r({fill: na(this.color || e.color).setOpacity(c.opacity).get()}, c.attributes))[b ? "animate" : "attr"]({d: this.haloPath(c.size)})
5164                } else n && n.attr({d: []});
5165                this.state = a
5166            }
5167        }, haloPath: function (a) {
5168            var b = this.series, c = b.chart, d = b.getPlotBox(), e = c.inverted;
5169            return c.renderer.symbols.circle(d.translateX + (e ? b.yAxis.len - this.plotY : this.plotX) - a, d.translateY + (e ? b.xAxis.len - this.plotX :
5170                    this.plotY) - a, a * 2, a * 2)
5171        }
5172    });
5173    r(R.prototype, {
5174        onMouseOver: function () {
5175            var a = this.chart, b = a.hoverSeries;
5176            if (b && b !== this)b.onMouseOut();
5177            this.options.events.mouseOver && I(this, "mouseOver");
5178            this.setState("hover");
5179            a.hoverSeries = this
5180        }, onMouseOut: function () {
5181            var a = this.options, b = this.chart, c = b.tooltip, d = b.hoverPoint;
5182            b.hoverSeries = null;
5183            if (d)d.onMouseOut();
5184            this && a.events.mouseOut && I(this, "mouseOut");
5185            c && !a.stickyTracking && (!c.shared || this.noSharedTooltip) && c.hide();
5186            this.setState()
5187        }, setState: function (a) {
5188            var b = this.options,
5189                c = this.graph, d = b.states, e = b.lineWidth, b = 0, a = a || "";
5190            if (this.state !== a && (this.state = a, !(d[a] && d[a].enabled === !1) && (a && (e = d[a].lineWidth || e + (d[a].lineWidthPlus || 0)), c && !c.dashstyle))) {
5191                a = {"stroke-width": e};
5192                for (c.attr(a); this["zoneGraph" + b];)this["zoneGraph" + b].attr(a), b += 1
5193            }
5194        }, setVisible: function (a, b) {
5195            var c = this, d = c.chart, e = c.legendItem, f, g = d.options.chart.ignoreHiddenSeries, h = c.visible;
5196            f = (c.visible = a = c.userOptions.visible = a === v ? !h : a) ? "show" : "hide";
5197            o(["group", "dataLabelsGroup", "markerGroup", "tracker"], function (a) {
5198                if (c[a])c[a][f]()
5199            });
5200            if (d.hoverSeries === c || (d.hoverPoint && d.hoverPoint.series) === c)c.onMouseOut();
5201            e && d.legend.colorizeItem(c, a);
5202            c.isDirty = !0;
5203            c.options.stacking && o(d.series, function (a) {
5204                if (a.options.stacking && a.visible)a.isDirty = !0
5205            });
5206            o(c.linkedSeries, function (b) {
5207                b.setVisible(a, !1)
5208            });
5209            if (g)d.isDirtyBox = !0;
5210            b !== !1 && d.redraw();
5211            I(c, f)
5212        }, show: function () {
5213            this.setVisible(!0)
5214        }, hide: function () {
5215            this.setVisible(!1)
5216        }, select: function (a) {
5217            this.selected = a = a === v ? !this.selected : a;
5218            if (this.checkbox)this.checkbox.checked = a;
5219            I(this, a ? "select" : "unselect")
5220        },
5221        drawTracker: U.drawTrackerGraph
5222    });
5223    r(B, {
5224        Color: na,
5225        Point: Ea,
5226        Tick: Ra,
5227        Renderer: Za,
5228        SVGElement: P,
5229        SVGRenderer: ua,
5230        arrayMin: Na,
5231        arrayMax: Ca,
5232        charts: Y,
5233        dateFormat: Ma,
5234        error: la,
5235        format: Ha,
5236        pathAnim: xb,
5237        getOptions: function () {
5238            return S
5239        },
5240        hasBidiBug: Nb,
5241        isTouchDevice: Jb,
5242        setOptions: function (a) {
5243            S = A(!0, S, a);
5244            Cb();
5245            return S
5246        },
5247        addEvent: H,
5248        removeEvent: Z,
5249        createElement: $,
5250        discardElement: Pa,
5251        css: L,
5252        each: o,
5253        map: Ta,
5254        merge: A,
5255        splat: ra,
5256        extendClass: ka,
5257        pInt: F,
5258        svg: ca,
5259        canvas: fa,
5260        vml: !ca && !fa,
5261        product: "Highcharts",
5262        version: "4.1.8"
5263    })
5264})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.