text: ﻿/*!
      *
      * Wijmo Library 5.20213.824
      * http://wijmo.com/
      *
      * Copyright(c) GrapeCity, Inc.  All rights reserved.
      *
      * Licensed under the GrapeCity Commercial License.
      * sales@wijmo.com
      * wijmo.com/products/wijmo-5/license/
      *
      */
  
  var wijmo,__extends=this&&this.__extends||function(){var extendStatics=function(t,e){return(extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)};return function(t,e){extendStatics(t,e);function __(){this.constructor=t}t.prototype=null===e?Object.create(e):(__.prototype=e.prototype,new __)}}();!function(t){var e;(function(e){"use strict";var i=function(e){__extends(Waterfall,e);function Waterfall(i){var r=e.call(this)||this;r._startLabel="Start";r._relativeData=!0;r._connectorLines=!1;r._showTotal=!1;r._totalLabel="Total";r._getXValues=!1;r._showIntermediateTotal=!1;r._intermediateTotalPos=[];r._chartType=t.chart.ChartType.Bar;r.tooltipContent="<b>{seriesName}</b><br/>{x} {value}";r.rendering.addHandler(r._rendering,r);r.initialize(i);return r}Object.defineProperty(Waterfall.prototype,"relativeData",{get:function(){return this._relativeData},set:function(e){if(e!=this._relativeData){this._relativeData=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"start",{get:function(){return this._start},set:function(e){if(e!=this._start){this._start=t.asNumber(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"startLabel",{get:function(){return this._startLabel},set:function(e){if(e!=this._startLabel){this._startLabel=t.asString(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"showTotal",{get:function(){return this._showTotal},set:function(e){if(e!=this._showTotal){this._showTotal=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"totalLabel",{get:function(){return this._totalLabel},set:function(e){if(e!=this._totalLabel){this._totalLabel=t.asString(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"showIntermediateTotal",{get:function(){return this._showIntermediateTotal},set:function(e){if(e!=this._showIntermediateTotal){this._showIntermediateTotal=t.asBoolean(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"intermediateTotalPositions",{get:function(){return this._intermediateTotalPositions},set:function(e){if(e!=this._intermediateTotalPositions){this._intermediateTotalPositions=t.asArray(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"intermediateTotalLabels",{get:function(){return this._intermediateTotalLabels},set:function(e){if(e!=this._intermediateTotalLabels){t.assert(null==e||t.isArray(e)||t.isString(e),"Array or string expected.");this._intermediateTotalLabels=e;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"connectorLines",{get:function(){return this._connectorLines},set:function(e){if(e!=this._connectorLines){this._connectorLines=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(Waterfall.prototype,"styles",{get:function(){return this._styles},set:function(t){if(t!=this._styles){this._styles=t;this._invalidate()}},enumerable:!0,configurable:!0});Waterfall.prototype.getValues=function(i){var r,n,a,s,o=this,l=[],u=0;r=e.prototype.getValues.call(this,i);if(0===i){if(!this._yValues){l=[];var h=null!=this.start?this.start:0,c=0,f=r&&r.length||0;if(this.relativeData){for(;c<f;c++){h+=isNaN(r[c])?0:r[c];l.push(h)}this._yValues=l}else{for(;c<f;c++){h=isNaN(r[c])?0:r[c];l.push(h)}this._yValues=l}if((n=this._yValues)&&n.length>0){if(this.showIntermediateTotal&&this.intermediateTotalPositions&&this.intermediateTotalPositions.length>0){this._intermediateTotalPos=n.slice();this.intermediateTotalPositions.reduceRight((function(t,e){var i=0===e?n[0]:n[e-1];if(n.length>e){n.splice(e,0,i);o._intermediateTotalPos.splice(e,0,!0)}else if(n.length===e){n.push(i);o._intermediateTotalPos.push(!0)}return 0}),0)}if(null!=this.start){n.splice(0,0,this.start);this._intermediateTotalPos.splice(0,0,!1)}this.showTotal&&n&&n.push(n[n.length-1])}}return this._yValues}if(!this._xValues&&this._getXValues){this._xValues=r&&r.slice();this._getXValues=!1;if(this._xValues&&this._xValues.length>1){f=this._xValues.length;s=this._xValues[f-1];u=Math.abs(this._xValues[f-1]-this._xValues[f-2])}if(this.chart&&this.chart._xlabels&&this.chart._xlabels.length){a=this.chart._xlabels;if(this.showIntermediateTotal&&this.intermediateTotalPositions&&this.intermediateTotalPositions.length>0){var p=this.intermediateTotalLabels;p&&this.intermediateTotalPositions.reduceRight((function(e,i,r){var n="";n=t.isString(p)?p:p[r]||"";a.length>i?a.splice(i,0,n):a.length===i&&a.push(n);if(u){s+=u;o._xValues.push(s)}return 0}),0)}if(null!=this.start){a.splice(0,0,this.startLabel);if(u){s+=u;this._xValues.push(s)}}if(this.showTotal){a.push(this.totalLabel);if(u){s+=u;this._xValues.push(s)}}}}return this._xValues};Waterfall.prototype.legendItemLength=function(){return this.showTotal?3:2};Waterfall.prototype.measureLegendItem=function(e,i){var r=this._getName(i);return r?this._measureLegendItem(e,r):new t.Size(0,0)};Waterfall.prototype.drawLegendItem=function(e,i,r){var n=this._getLegendStyles(r);this._getName(r)&&this._drawLegendItem(e,i,t.chart.ChartType.Bar,this._getName(r),n,this.symbolStyle)};Waterfall.prototype._clearValues=function(){e.prototype._clearValues.call(this);this._xValues=null;this._yValues=null;this._wfstyle=null;this._getXValues=!0;this._intermediateTotalPos=[];this.chart&&this.chart._performBind()};Waterfall.prototype._invalidate=function(){e.prototype._invalidate.call(this);this._clearValues()};Waterfall.prototype._getXOffset=function(){return null!=this.start?1:0};Waterfall.prototype._getYOffset=function(t){return this.getValues(0)[t+this._getXOffset()]};Waterfall.prototype._getValue=function(t){var e=t;if(null!=this.start){if(0==t)return this.start;t--}return this.showIntermediateTotal&&this.intermediateTotalPositions&&this._intermediateTotalPos[e],this.getValues(0)[e]};Waterfall.prototype._getItem=function(t){var i=null;null!=this.start&&(0==t?(i={})[this.binding]=this.start:t--);if(this.showIntermediateTotal&&this.intermediateTotalPositions){var r=this._intermediateTotalPos;if(!0===r[t]){(i={})[this.binding]=this.getValues(0)[t];return i}for(var n=t,a=0;a<t;a++)!0===r[a]&&n--;t=n}i||!(i=e.prototype._getItem.call(this,t))&&this.showTotal&&this._yValues&&this._yValues.length>0&&((i={})[this.binding]=this._yValues[this._yValues.length-1]);return i};Waterfall.prototype._rendering=function(t,e){var i=this;e.cancel=!0;this._wfstyle=null;var r,n,a,s,o,l,u=this.chart,h=this._getAxisY(),c=this._getAxisX(),f=h.origin||0,p=e.engine;this._barPlotter=u._getPlotter(this);a=this._barPlotter.rotated;this._barPlotter._getSymbolOrigin||(this._barPlotter._getSymbolOrigin=function(t,e,r){return 0===e?t:!0===i._intermediateTotalPos[e]?t:e===r-1&&i.showTotal?t:i._yValues[e-1]});this._barPlotter._getSymbolStyles||(this._barPlotter._getSymbolStyles=function(t,e){var r=i._getStyles();return 0===t&&null!=i.start?r.start:!0===i._intermediateTotalPos[t]?r.intermediateTotal:t===e-1&&i.showTotal?r.total:0==t?i._yValues[t]<0?r.falling:r.rising:i._yValues[t]<i._yValues[t-1]?r.falling:r.rising});this._barPlotter.plotSeries(p,c,h,t,u,0,1);if(this.connectorLines&&(s=this._barPlotter.hitTester._map[0])&&s.length){p.startGroup(Waterfall.CSS_CONNECTOR_LINE_GROUP);l=this._yValues[0]<f;o=s[0].rect;for(r=1,n=s.length;r<n;r++)if(!0!==this._intermediateTotalPos[r]||r===n-1){this._drawConnectorLine(p,a,o,s[r].rect,l);o=s[r].rect;l=this._yValues[r]<this._yValues[r-1]}p.endGroup()}};Waterfall.prototype._getStyles=function(){if(this._wfstyle)return this._wfstyle;var t=this._chart.series.indexOf(this),e=this._getSymbolFill(t),i=this._getSymbolStroke(t),r=this.styles||{};this._wfstyle={start:this._getStyleByKey(r,"start",e,i),intermediateTotal:this._getStyleByKey(r,"intermediateTotal",e,i),total:this._getStyleByKey(r,"total",e,i),falling:this._getStyleByKey(r,"falling","red","red"),rising:this._getStyleByKey(r,"rising","green","green")};return this._wfstyle};Waterfall.prototype._getStyleByKey=function(t,e,i,r){return{fill:t[e]&&t[e].fill?t[e].fill:i,stroke:t[e]&&t[e].stroke?t[e].stroke:r}};Waterfall.prototype._drawConnectorLine=function(e,i,r,n,a){var s=new t.Point,o=new t.Point,l=this.chart.axisY.reversed,u=this.chart.axisX.reversed;l^=a;if(i){if(l){s.x=r.left;o.x=r.left}else{s.x=r.left+r.width;o.x=r.left+r.width}if(u){s.y=r.top;o.y=n.top+n.height}else{s.y=r.top+r.height;o.y=n.top}}else{if(l){s.y=r.top+r.height;o.y=r.top+r.height}else{s.y=r.top;o.y=r.top}if(u){s.x=r.left+r.width;o.x=n.left}else{s.x=r.left;o.x=n.left+n.width}}e.drawLine(s.x,s.y,o.x,o.y,Waterfall.CSS_CONNECTOR_LINE,this.styles&&this.styles.connectorLines||{stroke:"black"})};Waterfall.prototype._getLegendStyles=function(t){if(t<0||null===this.styles)return null;var e=this._getStyles();return 0===t?e.rising:1===t?e.falling:e.total};Waterfall.prototype._getName=function(t){var e=void 0;if(this.name)if(this.name.indexOf(",")){var i=this.name.split(",");i&&i.length-1>=t&&(e=i[t].trim())}else e=this.name;return e};Waterfall.CSS_CONNECTOR_LINE_GROUP="water-fall-connector-lines";Waterfall.CSS_CONNECTOR_LINE="water-fall-connector-line";Waterfall.CSS_ENDLABEL="water-fall-end-label";return Waterfall}(t.chart.SeriesBase);e.Waterfall=i})((e=t.chart||(t.chart={})).analytics||(e.analytics={}))}(wijmo||(wijmo={}));!function(t){!function(e){!function(e){"use strict";var i=function(e){__extends(TrendLineBase,e);function TrendLineBase(i){var r=e.call(this)||this;r._chartType=t.chart.ChartType.Line;r._sampleCount=100;r.initialize(i);return r}Object.defineProperty(TrendLineBase.prototype,"sampleCount",{get:function(){return this._sampleCount},set:function(e){if((e=t.asNumber(e,!1,!0))!=this._sampleCount){this._sampleCount=e;this._invalidate()}},enumerable:!0,configurable:!0});TrendLineBase.prototype.approximate=function(t){return 0};TrendLineBase.prototype.getValues=function(t){var i=this.binding,r=this.bindingX;if(i!==this._bind){this._bind=i;this.binding=i}if(r!==this._bindX){this._bindX=r;this.bindingX=r}null==this._originYValues&&(this._originYValues=e.prototype.getValues.call(this,0));null==this._originXValues&&(this._originXValues=e.prototype.getValues.call(this,1));if(null==this._originXValues||null==this._originYValues)return null;e.prototype.getValues.call(this,t);null!=this._xValues&&null!=this._yValues||this._calculateValues();return 0===t?this._yValues||null:1===t?this._xValues||null:void 0};TrendLineBase.prototype._calculateValues=function(){};TrendLineBase.prototype._invalidate=function(){e.prototype._invalidate.call(this);this._clearCalculatedValues()};TrendLineBase.prototype._clearValues=function(){e.prototype._clearValues.call(this);this._originXValues=null;this._originYValues=null;this._clearCalculatedValues()};TrendLineBase.prototype._clearCalculatedValues=function(){this._xValues=null;this._yValues=null};return TrendLineBase}(t.chart.SeriesBase);e.TrendLineBase=i}(e.analytics||(e.analytics={}))}(t.chart||(t.chart={}))}(wijmo||(wijmo={}));!function(t){!function(e){!function(e){"use strict";var i;!function(t){t[t.Simple=0]="Simple";t[t.Weighted=1]="Weighted";t[t.Exponential=2]="Exponential";t[t.Triangular=3]="Triangular"}(i=e.MovingAverageType||(e.MovingAverageType={}));var r=function(e){__extends(MovingAverage,e);function MovingAverage(r){var n=e.call(this)||this;n._chartType=t.chart.ChartType.Line;n._type=i.Simple;n._period=2;n.initialize(r);return n}Object.defineProperty(MovingAverage.prototype,"type",{get:function(){return this._type},set:function(e){if((e=t.asEnum(e,i,!1))!=this._type){this._type=e;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(MovingAverage.prototype,"period",{get:function(){return this._period},set:function(e){if((e=t.asNumber(e,!1,!0))!=this._period){this._period=t.asNumber(e,!1,!0);this._invalidate()}},enumerable:!0,configurable:!0});MovingAverage.prototype._checkPeriod=function(){var e=this.period,i=this._originXValues;e<=1&&t.assert(!1,"period must be greater than 1.");i&&i.length&&e>=i.length&&t.assert(!1,"period must be less than itemSource's length.")};MovingAverage.prototype._calculateValues=function(){this._type;var t="_calculate"+i[this._type],e=[],r=[];this._checkPeriod();this[t]&&this[t].call(this,e,r);this._yValues=r;this._xValues=e};MovingAverage.prototype._calculateSimple=function(t,e,i){void 0===i&&(i=!1);for(var r=this._originXValues,n=this._originYValues,a=r.length,s=this._period,o=0,l=0;l<a;l++){o+=n[l]||0;l>=s&&(o-=n[l-s]||0);if(l>=s-1){t.push(r[l]);e.push(o/s)}else if(i){t.push(r[l]);e.push(o/(l+1))}}};MovingAverage.prototype._calculateWeighted=function(t,e){for(var i=this._originXValues,r=this._originYValues,n=i.length,a=this._period,s=a*(a+1)/2,o=0,l=0,u=0;u<n;u++){u>0&&(o+=r[u-1]||0);u>a&&(o-=r[u-a-1]||0);if(u<a-1)l+=(r[u]||0)*(u+1);else{l+=(r[u]||0)*a;u>a-1&&(l-=o);t.push(i[u]);e.push(l/s)}}};MovingAverage.prototype._calculateExponential=function(t,e){for(var i=this._originXValues,r=this._originYValues,n=i.length,a=this._period,s=0,o=0;o<n;o++)if(o<=a-2){s+=r[o]||0;o===a-2&&(s/=a-1)}else{s+=2/(a+1)*((r[o]||0)-s);t.push(i[o]);e.push(s)}};MovingAverage.prototype._calculateTriangular=function(t,e){var i=this._period,r=[],n=[],a=0;this._calculateSimple(r,n,!0);for(var s=0,o=r.length;s<o;s++){a+=n[s]||0;s>=i&&(a-=n[s-i]||0);if(s>=i-1){t.push(r[s]);e.push(a/i)}}};return MovingAverage}(e.TrendLineBase);e.MovingAverage=r}(e.analytics||(e.analytics={}))}(t.chart||(t.chart={}))}(wijmo||(wijmo={}));!function(t){!function(e){!function(e){"use strict";var i,r=function(){function MathHelper(){}MathHelper.round=function(t,e){if(!t)return 0;var i=Math.pow(10,e||2);return Math.round(t*i)/i};MathHelper.avg=function(t){return MathHelper.sum(t)/t.length};MathHelper.sum=function(e){return(e=t.asArray(e,!1)).reduce((function(t,e){return t+e}),0)};MathHelper.sumOfPow=function(e,i){e=t.asArray(e,!1);i=t.asNumber(i,!1);return e.reduce((function(t,e){return t+Math.pow(e,i)}),0)};MathHelper.sumProduct=function(){for(var e=[],i=0;i<arguments.length;i++)e[i]=arguments[i];e.length;var r,n,a=0,s=[];(e=t.asArray(e,!1)).forEach((function(e,i){e=t.asArray(e,!1);0===i?a=e.length:t.assert(e.length===a,"The length of the arrays must be equal")}));for(r=0;r<a;r++){n=1;e.some((function(e,i){var a=e[r];if(!a||!t.isNumber(a)){n=0;return!0}n*=a}));s.push(n)}return MathHelper.sum(s)};MathHelper.variance=function(e){e=t.asArray(e,!1);var i,r=MathHelper.avg(e);i=e.map((function(t){return t-r}));return MathHelper.sumOfSquares(i)/(e.length-1)};MathHelper.covariance=function(e,i){e=t.asArray(e,!1);i=t.asArray(i,!1);t.assert(e.length===i.length,"Length of arrays must be equal");var r,n=MathHelper.avg(e),a=MathHelper.avg(i),s=e.length,o=0;for(r=0;r<s;r++)o+=(e[r]-n)*(i[r]-a)/s;return o};MathHelper.min=function(e){return Math.min.apply(Math,t.asArray(e,!1))};MathHelper.max=function(e){return Math.max.apply(Math,t.asArray(e,!1))};MathHelper.square=function(e){return Math.pow(t.asNumber(e,!1),2)};MathHelper.sumOfSquares=function(t){return MathHelper.sumOfPow(t,2)};MathHelper.stdDev=function(t){return Math.sqrt(MathHelper.variance(t))};return MathHelper}();!function(t){t[t.Linear=0]="Linear";t[t.Exponential=1]="Exponential";t[t.Logarithmic=2]="Logarithmic";t[t.Power=3]="Power";t[t.Fourier=4]="Fourier";t[t.Polynomial=5]="Polynomial";t[t.MinX=6]="MinX";t[t.MinY=7]="MinY";t[t.MaxX=8]="MaxX";t[t.MaxY=9]="MaxY";t[t.AverageX=10]="AverageX";t[t.AverageY=11]="AverageY"}(i=e.TrendLineFitType||(e.TrendLineFitType={}));var n=function(e){__extends(TrendLine,e);function TrendLine(t){var r=e.call(this)||this;r._fitType=i.Linear;r._order=2;r.initialize(t);return r}Object.defineProperty(TrendLine.prototype,"fitType",{get:function(){return this._fitType},set:function(e){if((e=t.asEnum(e,i,!1))!=this._fitType){this._fitType=e;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(TrendLine.prototype,"order",{get:function(){return this._order},set:function(e){if(e!=this._order){this._order=t.asNumber(e,!1,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(TrendLine.prototype,"coefficients",{get:function(){return this._helper?this._helper.coefficients:null},enumerable:!0,configurable:!0});TrendLine.prototype.approximate=function(t){return this._helper?this._helper.approximate(t):NaN};TrendLine.prototype.getEquation=function(t){return(this._helper?this._helper.getEquation(t):"").replace(/\S(\+|\-)\d/g,(function(t){return t[0]+" "+t[1]+" "+t[2]}))};TrendLine.prototype._calculateValues=function(){var t=i[this._fitType];if(d[t]){var e=!1,r=this._originXValues;if(0==this._chart._xvals.length&&this._chart._xlabels.length>0){r=this._originXValues.map((function(t){return t+1}));e=!0}var n=new d[t](this._originYValues,r,this.sampleCount,this.order);n._isXString=e;var a=n.calculateValues();this._yValues=a[0];this._xValues=a[1];this._helper=n}};return TrendLine}(e.TrendLineBase);e.TrendLine=n;var a=function(){function Calculator(t,e){this._x=t;this._y=e}Object.defineProperty(Calculator.prototype,"x",{get:function(){return this._x},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"y",{get:function(){return this._y},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"minX",{get:function(){null==this._minX&&(this._minX=r.min(this._x));return this._minX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"minY",{get:function(){null==this._minY&&(this._minY=r.min(this._y));return this._minY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"maxX",{get:function(){null==this._maxX&&(this._maxX=r.max(this._x));return this._maxX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"maxY",{get:function(){null==this._maxY&&(this._maxY=r.max(this._y));return this._maxY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"averageX",{get:function(){null==this._averageX&&(this._averageX=r.avg(this._x));return this._averageX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"averageY",{get:function(){null==this._averageY&&(this._averageY=r.avg(this._y));return this._averageY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumX",{get:function(){null==this._sumX&&(this._sumX=r.sum(this._x));return this._sumX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumY",{get:function(){null==this._sumY&&(this._sumY=r.sum(this._y));return this._sumY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"LogX",{get:function(){null==this._logX&&(this._logX=this._x.map((function(t){return Math.log(t)})));return this._logX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"LogY",{get:function(){null==this._logY&&(this._logY=this._y.map((function(t){return Math.log(t)})));return this._logY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumLogX",{get:function(){null==this._sumLogX&&(this._sumLogX=r.sum(this.LogX));return this._sumLogX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumLogY",{get:function(){null==this._sumLogY&&(this._sumLogY=r.sum(this.LogY));return this._sumLogY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumOfSquareX",{get:function(){null==this._sumOfSquareX&&(this._sumOfSquareX=r.sumOfSquares(this._x));return this._sumOfSquareX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumOfSquareY",{get:function(){null==this._sumOfSquareY&&(this._sumOfSquareY=r.sumOfSquares(this._y));return this._sumOfSquareY},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumOfSquareLogX",{get:function(){null==this._sumOfSquareLogX&&(this._sumOfSquareLogX=r.sumOfSquares(this.LogX));return this._sumOfSquareLogX},enumerable:!0,configurable:!0});Object.defineProperty(Calculator.prototype,"sumOfSquareLogY",{get:function(){null==this._sumOfSquareLogY&&(this._sumOfSquareLogY=r.sumOfSquares(this.LogY));return this._sumOfSquareLogY},enumerable:!0,configurable:!0});Calculator.prototype.sumProduct=function(t,e){null==this._sumProduct&&(this._sumProduct=r.sumProduct(t,e));return this._sumProduct};return Calculator}(),s=function(){function TrendHelperBase(e,i,r){this._coefficients=[];this.y=t.asArray(e);this.x=t.asArray(i);t.assert(e.length===i.length,"Length of X and Y arrays are not equal");this.count=r||e.length;this._calculator=new a(i,e);this.xMin=this._calculator.minX;this.xMax=this._calculator.maxX}Object.defineProperty(TrendHelperBase.prototype,"calculator",{get:function(){return this._calculator},enumerable:!0,configurable:!0});Object.defineProperty(TrendHelperBase.prototype,"y",{get:function(){return this._y},set:function(e){e!==this.y&&(this._y=t.asArray(e,!1))},enumerable:!0,configurable:!0});Object.defineProperty(TrendHelperBase.prototype,"x",{get:function(){return this._x},set:function(e){e!==this.x&&(this._x=t.asArray(e,!1))},enumerable:!0,configurable:!0});Object.defineProperty(TrendHelperBase.prototype,"count",{get:function(){return this._count},set:function(e){e!==this.count&&(this._count=t.asInt(e,!1,!0))},enumerable:!0,configurable:!0});Object.defineProperty(TrendHelperBase.prototype,"xMin",{get:function(){return this._xMin},set:function(e){e!==this.xMin&&(this._xMin=t.asNumber(e,!1))},enumerable:!0,configurable:!0});Object.defineProperty(TrendHelperBase.prototype,"xMax",{get:function(){return this._xMax},set:function(e){e!==this.xMax&&(this._xMax=t.asNumber(e,!1))},enumerable:!0,configurable:!0});Object.defineProperty(TrendHelperBase.prototype,"coefficients",{get:function(){return this._coefficients},enumerable:!0,configurable:!0});TrendHelperBase.prototype._calculateCoefficients=function(){var t=this.calcB(),e=this.calcA(t);this._coefficients.push(e,t)};TrendHelperBase.prototype.calculateValues=function(){for(var t=(this.xMax-this.xMin)/(this.count-1),e=[[],[]],i=0;i<this.count;i++){var r=this.xMin+t*i,n=this.calcY(r);e[0].push(n);this._isXString?e[1].push(r-1):e[1].push(r)}return e};TrendHelperBase.prototype.calcA=function(t){var e=this.y.length,i=this.calculator.sumX;return(this.calculator.sumY-(t=t||this.calcB())*i)/e};TrendHelperBase.prototype.calcB=function(){var t=this.y.length,e=this.calculator,i=e.sumProduct(e.x,e.y),n=e.sumX;return(t*i-n*e.sumY)/(t*e.sumOfSquareX-r.square(n))};TrendHelperBase.prototype.calcY=function(t){var e=this.coefficients;return e[0]+e[1]*t};TrendHelperBase.prototype.approximate=function(t){return this.calcY(t)};TrendHelperBase.prototype.getEquation=function(t){t=t||this._defaultEquationFmt;return this._getEquation(t)};TrendHelperBase.prototype._getEquation=function(t){var e=this.coefficients,i=[];e.forEach((function(e){i.push(t(e))}));return this._concatEquation(i)};TrendHelperBase.prototype._concatEquation=function(t){return""};TrendHelperBase.prototype._defaultEquationFmt=function(t){var e,i=Math.abs(t),r=String(i),n=0;if(i>=1e5){e=String(Math.round(i)).length-1;return Math.round(t/Number("1e"+e))+"e"+e}if(i<1e-4){e=r.indexOf("e")>-1?Math.abs(+r.substring(r.indexOf("e")+1)):r.match(/\.0+/)[0].length;return Math.round(t*Number("1e"+e))+"e-"+e}n=t>0?6:7;i>=1e4&&n--;return String(+String(t).substring(0,n))};return TrendHelperBase}(),o=function(e){__extends(LinearHelper,e);function LinearHelper(t,i,r,n){var a=e.call(this,t,i,r)||this;a._calculateCoefficients();a.yOffset=n;return a}Object.defineProperty(LinearHelper.prototype,"yOffset",{get:function(){return this._yOffset},set:function(e){e!==this.yOffset&&(this._yOffset=t.asNumber(e,!0))},enumerable:!0,configurable:!0});LinearHelper.prototype.calcA=function(t){return null!=this.yOffset?this.yOffset:e.prototype.calcA.call(this,t)};LinearHelper.prototype.calcB=function(){return null!=this.yOffset?this._calculateBSimple():e.prototype.calcB.call(this)};LinearHelper.prototype._calculateBSimple=function(){var t=this.calculator,e=t.sumProduct(t.x,t.y),i=t.sumX,r=t.sumOfSquareX;return(e-this.yOffset*i)/r};LinearHelper.prototype._calculateCoefficients=function(){var t=this.calcB(),e=this.calcA(t);this.coefficients.push(t,e)};LinearHelper.prototype.calcY=function(t){var e=this.coefficients;return e[0]*t+e[1]};LinearHelper.prototype._concatEquation=function(t){return"y = "+t[0]+"x"+(this.coefficients[1]>=0?"+":"")+t[1]};return LinearHelper}(s),l=function(t){__extends(LogHelper,t);function LogHelper(e,i,r){var n=t.call(this,e,i,r)||this;n._calculateCoefficients();return n}LogHelper.prototype.calcA=function(t){var e=this.y.length,i=this.calculator,r=i.sumY,n=i.sumLogX;return(r-(t=t||this.calcB())*n)/e};LogHelper.prototype.calcB=function(){var t=this.y.length,e=this.calculator,i=e.sumProduct(e.y,e.LogX),n=e.sumY,a=e.sumLogX;return(t*i-n*a)/(t*e.sumOfSquareLogX-r.square(a))};LogHelper.prototype._calculateCoefficients=function(){var t=this.calcB(),e=this.calcA(t);this.coefficients.push(t,e)};LogHelper.prototype.calcY=function(t){var e=this.coefficients;return Math.log(t)*e[0]+e[1]};LogHelper.prototype._concatEquation=function(t){return"y = "+t[0]+"ln(x)"+(this.coefficients[1]>=0?"+":"")+t[1]};return LogHelper}(s),u=function(t){__extends(ExpHelper,t);function ExpHelper(e,i,r){var n=t.call(this,e,i,r)||this;n._calculateCoefficients();return n}ExpHelper.prototype.calcA=function(){var t=this.y.length,e=this.calculator,i=e.sumLogY,n=e.sumOfSquareX,a=e.sumX,s=e.sumProduct(e.x,e.LogY);return Math.exp((i*n-a*s)/(t*n-r.square(a)))};ExpHelper.prototype.calcB=function(){var t=this.y.length,e=this.calculator,i=e.sumLogY,n=e.sumOfSquareX,a=e.sumX;return(t*e.sumProduct(e.x,e.LogY)-a*i)/(t*n-r.square(a))};ExpHelper.prototype.calcY=function(t){var e=this.coefficients;return e[0]*Math.exp(e[1]*t)};ExpHelper.prototype._concatEquation=function(t){return"y = "+t[0]+"e<sup>"+t[1]+"x</sup>"};return ExpHelper}(s),h=function(t){__extends(PowerHelper,t);function PowerHelper(e,i,r){var n=t.call(this,e,i,r)||this;n._calculateCoefficients();return n}PowerHelper.prototype.calcA=function(t){var e=this.calculator,i=this.y.length,r=e.sumLogX,n=e.sumLogY;t=t||this.calcB();return Math.exp((n-t*r)/i)};PowerHelper.prototype.calcB=function(){var t=this.y.length,e=this.calculator,i=e.sumProduct(e.LogX,e.LogY),n=e.sumLogX;return(t*i-n*e.sumLogY)/(t*e.sumOfSquareLogX-r.square(n))};PowerHelper.prototype.calcY=function(t){var e=this.coefficients;return e[0]*Math.pow(t,e[1])};PowerHelper.prototype._concatEquation=function(t){return"y = "+t[0]+"x<sup>"+t[1]+"</sup>"};return PowerHelper}(s),c=function(e){__extends(LeastSquaresHelper,e);function LeastSquaresHelper(t,i,r,n){var a=e.call(this,t,i,r)||this;a._order=null==n?2:n;a._basis=[];a._calculateCoefficients();return a}Object.defineProperty(LeastSquaresHelper.prototype,"basis",{get:function(){return this._basis},enumerable:!0,configurable:!0});Object.defineProperty(LeastSquaresHelper.prototype,"order",{get:function(){return this._order},set:function(e){this._order=t.asNumber(e,!0)},enumerable:!0,configurable:!0});LeastSquaresHelper.prototype._calculateCoefficients=function(){this._coefficients.length=this.order;this._createBasis();this._normalizeAndSolveGauss()};LeastSquaresHelper.prototype._createBasis=function(){var t=this.x.length,e=this.order;if(t<2)throw"Incompatible data: Less than 2 data points.";if(e<1)throw"Incompatible data: Less than 1 coefficient in the fit";if(e>t)throw"Incompatible data: Number of data points less than number of terms"};LeastSquaresHelper.prototype._normalizeAndSolveGauss=function(){var t=[];this._computeNormalEquations(t);this._genDefValForArray(t,0);if(!this._solveGauss(t))throw"Incompatible data: No solution."};LeastSquaresHelper.prototype._genDefValForArray=function(t,e){var i=t.length+1;t.forEach((function(t){for(var r=0;r<i;r++)null==t[r]&&(t[r]=e)}))};LeastSquaresHelper.prototype._computeNormalEquations=function(t){var e,i,r,n,a=this.y,s=this.basis,o=this.order,l=a.length;for(e=0;e<o;e++){r=0;null==t[e]&&(t[e]=[]);a.forEach((function(t,i){r+=t*s[i][e]}));t[e][o]=r;for(i=e;i<o;i++){r=0;for(n=0;n<l;n++)r+=s[n][i]*s[n][e];null==t[i]&&(t[i]=[]);t[i][e]=r;t[e][i]=r}}};LeastSquaresHelper.prototype._solveGauss=function(t){var e,i,r=t.length,n=this._coefficients,a=!0;if(n.length<r||t[0].length<r+1)throw"Dimension of matrix is not correct.";t.some((function(e,n){var s,o,l=n,u=Math.abs(e[n]);for(i=n+1;i<r;i++)if(u<(s=Math.abs(t[i][n]))){u=s;l=i}if(!(u>0)){a=!1;return!0}for(i=n;i<=r;i++){o=t[n][i];t[n][i]=t[l][i];t[l][i]=o}for(l=n+1;l<r;l++){o=t[l][n]/e[n];t[l][n]=0;for(i=n+1;i<=r;i++)t[l][i]-=o*e[i]}}));if(a)for(e=r-1;e>=0;e--){n[e]=t[e][r];for(i=e+1;i<r;i++)n[e]-=t[e][i]*n[i];n[e]=n[e]/t[e][e]}return a};return LeastSquaresHelper}(s),f=function(t){__extends(PolyHelper,t);function PolyHelper(e,i,r,n){return t.call(this,e,i,r,n)||this}Object.defineProperty(PolyHelper.prototype,"coefficients",{get:function(){return this._coefficients.slice(0).reverse()},enumerable:!0,configurable:!0});PolyHelper.prototype.calcY=function(t){var e=this._coefficients,i=0,r=1;e.forEach((function(e,n){n>0&&(r*=t);i+=e*r}));return i};PolyHelper.prototype._calculateCoefficients=function(){this._coefficients;this.order++;0;t.prototype._calculateCoefficients.call(this);0;this.order--};PolyHelper.prototype._createBasis=function(){t.prototype._createBasis.call(this);var e=this.x,i=this.basis,r=this.order;e.forEach((function(t,e){i[e]=[1];for(var n=1;n<=r;n++)i[e][n]=t*i[e][n-1]}))};PolyHelper.prototype._concatEquation=function(t){var e="y = ",i=t.length,r=this.coefficients;t.forEach((function(t,n){var a,s=i-1-n;if(0===s)e+=t;else if(1===s){a=r[n+1]>=0?"+":"";e+=t+"x"+a}else{a=r[n+1]>=0?"+":"";e+=t+"x<sup>"+s+"</sup>"+a}}));return e};return PolyHelper}(c),p=function(t){__extends(FourierHelper,t);function FourierHelper(e,i,r,n){n=null==n?i.length:n;return t.call(this,e,i,r,n)||this}FourierHelper.prototype._createBasis=function(){t.prototype._createBasis.call(this);var e=this.x,i=this.basis,r=this.order;e.forEach((function(t,e){var n,a;i[e]=[1];for(n=1;n<r;n++){a=Math.floor((n+1)/2);n%2==1?i[e].push(Math.cos(a*t)):i[e].push(Math.sin(a*t))}}))};FourierHelper.prototype.calcY=function(t){var e;this._coefficients.forEach((function(i,r){var n,a=Math.floor((r+1)/2);if(0===r)e=i;else{n=a*t;e+=r%2==1?i*Math.cos(n):i*Math.sin(n)}}));return e};FourierHelper.prototype._concatEquation=function(t){var e="y = ",i=t.length,r=this.coefficients;t.forEach((function(t,n){var a=n===i-1?"":r[n+1]>=0?"+":"",s="",o=Math.ceil(n/2);if(0===n)e+=t+a;else{s=n%2==1?"cos":"sin";s+="("+(1===o?"":String(o))+"x)";e+=t+s+a}}));return e};return FourierHelper}(c),_=function(t){__extends(SimpleTrendHelper,t);function SimpleTrendHelper(e,i,r){var n=t.call(this,e,i,r)||this;n._calculateCoefficients();return n}SimpleTrendHelper.prototype._setVal=function(t){this._val=t};SimpleTrendHelper.prototype.calcY=function(t){return this._val};return SimpleTrendHelper}(s),d={TrendHelperBase:s,Linear:o,Exponential:u,Logarithmic:l,Power:h,Polynomial:f,Fourier:p,MinX:function(t){__extends(MinXHelper,t);function MinXHelper(e,i,r){return t.call(this,e,i,r)||this}MinXHelper.prototype.calculateValues=function(){var t,e,i=this.xMin,n=r.min(this.y),a=r.max(this.y);this._isXString&&(i-=1);t=[i,i];e=[n,a];this._setVal(i);return[e,t]};MinXHelper.prototype.getEquation=function(t){var e=this.xMin;this._isXString&&(e-=1);t&&(e=t(e));return"x = "+e};return MinXHelper}(_),MinY:function(t){__extends(MinYHelper,t);function MinYHelper(e,i,r){return t.call(this,e,i,r)||this}MinYHelper.prototype.calculateValues=function(){var t,e,i=this.xMin,n=this.xMax,a=r.min(this.y);if(this._isXString){i-=1;n-=1}t=[i,n];e=[a,a];this._setVal(a);return[e,t]};MinYHelper.prototype.getEquation=function(t){var e=r.min(this.y);t&&(e=t(e));return"y = "+e};return MinYHelper}(_),MaxX:function(t){__extends(MaxXHelper,t);function MaxXHelper(e,i,r){return t.call(this,e,i,r)||this}MaxXHelper.prototype.calculateValues=function(){var t,e,i=this.xMax,n=r.min(this.y),a=r.max(this.y);this._isXString&&(i-=1);t=[i,i];e=[n,a];this._setVal(i);return[e,t]};MaxXHelper.prototype.getEquation=function(t){var e=this.xMax;this._isXString&&(e-=1);t&&(e=t(e));return"x = "+e};return MaxXHelper}(_),MaxY:function(t){__extends(MaxYHelper,t);function MaxYHelper(e,i,r){return t.call(this,e,i,r)||this}MaxYHelper.prototype.calculateValues=function(){var t,e,i=this.xMin,n=this.xMax,a=r.max(this.y);if(this._isXString){i-=1;n-=1}t=[i,n];e=[a,a];this._setVal(a);return[e,t]};MaxYHelper.prototype.getEquation=function(t){var e=r.max(this.y);t&&(e=t(e));return"y = "+e};return MaxYHelper}(_),AverageX:function(t){__extends(AverageXHelper,t);function AverageXHelper(e,i,r){return t.call(this,e,i,r)||this}AverageXHelper.prototype.calculateValues=function(){var t,e,i=r.avg(this.x),n=r.min(this.y),a=r.max(this.y);this._isXString&&(i-=1);t=[i,i];e=[n,a];this._setVal(i);return[e,t]};AverageXHelper.prototype._getEquation=function(t){var e=r.avg(this.x);this._isXString&&(e-=1);t&&(e=t(e));return" x ="+e};AverageXHelper.prototype._defaultEquationFmt=function(e){return Math.abs(e)<1e5?t.prototype._defaultEquationFmt.call(this,e):""+r.round(e,2)};return AverageXHelper}(_),AverageY:function(t){__extends(AverageYHelper,t);function AverageYHelper(e,i,r){return t.call(this,e,i,r)||this}AverageYHelper.prototype.calculateValues=function(){var t,e,i=r.avg(this.y),n=this.xMin,a=this.xMax;if(this._isXString){n-=1;a-=1}t=[n,a];e=[i,i];this._setVal(i);return[e,t]};AverageYHelper.prototype._getEquation=function(t){return"y = "+t(r.avg(this.y))};AverageYHelper.prototype._defaultEquationFmt=function(e){return Math.abs(e)<1e5?t.prototype._defaultEquationFmt.call(this,e):""+r.round(e,2)};return AverageYHelper}(_)}}(e.analytics||(e.analytics={}))}(t.chart||(t.chart={}))}(wijmo||(wijmo={}));!function(t){!function(e){!function(e){"use strict";var i=function(e){__extends(FunctionSeries,e);function FunctionSeries(i){var r=e.call(this)||this;r._min=0;r._max=1;r.initialize(i);null==r.itemsSource&&(r.itemsSource=[new t.Point(0,0)]);return r}Object.defineProperty(FunctionSeries.prototype,"min",{get:function(){return this._min},set:function(e){if(this._min!==e){this._min=t.asNumber(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(FunctionSeries.prototype,"max",{get:function(){return this._max},set:function(e){if(this._max!==e){this._max=t.asNumber(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});FunctionSeries.prototype.getValues=function(t){null!=this._xValues&&null!=this._yValues||this._calculateValues();return 0===t?this._yValues||null:1===t?this._xValues||null:void 0};FunctionSeries.prototype._calculateValues=function(){for(var t,e=this.sampleCount,i=[],r=[],n=(this.max-this.min)/(e-1),a=0;a<e;a++){t=a===e-1?this.max:this.min+n*a;i[a]=this._calculateX(t);r[a]=this._calculateY(t)}this._yValues=r;this._xValues=i};FunctionSeries.prototype._validateValue=function(t){return isFinite(t)?t:Number.NaN};FunctionSeries.prototype._calculateValue=function(t,e){var i;try{i=t(e)}catch(t){i=Number.NaN}return this._validateValue(i)};FunctionSeries.prototype._calculateX=function(t){return 0};FunctionSeries.prototype._calculateY=function(t){return 0};return FunctionSeries}(e.TrendLineBase);e.FunctionSeries=i;var r=function(e){__extends(YFunctionSeries,e);function YFunctionSeries(t){return e.call(this,t)||this}Object.defineProperty(YFunctionSeries.prototype,"func",{get:function(){return this._func},set:function(e){if(e&&this._func!==e){this._func=t.asFunction(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});YFunctionSeries.prototype._calculateX=function(t){return t};YFunctionSeries.prototype._calculateY=function(t){return this._calculateValue(this.func,t)};YFunctionSeries.prototype.approximate=function(t){return this._calculateValue(this.func,t)};return YFunctionSeries}(i);e.YFunctionSeries=r;var n=function(e){__extends(ParametricFunctionSeries,e);function ParametricFunctionSeries(t){return e.call(this,t)||this}Object.defineProperty(ParametricFunctionSeries.prototype,"xFunc",{get:function(){return this._xFunc},set:function(e){if(e&&this._xFunc!==e){this._xFunc=t.asFunction(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(ParametricFunctionSeries.prototype,"yFunc",{get:function(){return this._yFunc},set:function(e){if(e&&this._yFunc!==e){this._yFunc=t.asFunction(e,!1);this._invalidate()}},enumerable:!0,configurable:!0});ParametricFunctionSeries.prototype._calculateX=function(t){return this._calculateValue(this.xFunc,t)};ParametricFunctionSeries.prototype._calculateY=function(t){return this._calculateValue(this.yFunc,t)};ParametricFunctionSeries.prototype.approximate=function(e){var i=this._calculateValue(this.xFunc,e),r=this._calculateValue(this.yFunc,e);return new t.Point(i,r)};return ParametricFunctionSeries}(i);e.ParametricFunctionSeries=n}(e.analytics||(e.analytics={}))}(t.chart||(t.chart={}))}(wijmo||(wijmo={}));!function(t){var e;(function(e){"use strict";var i,r,n;!function(t){t[t.FixedValue=0]="FixedValue";t[t.Percentage=1]="Percentage";t[t.StandardDeviation=2]="StandardDeviation";t[t.StandardError=3]="StandardError";t[t.Custom=4]="Custom"}(i=e.ErrorAmount||(e.ErrorAmount={}));!function(t){t[t.Cap=0]="Cap";t[t.NoCap=1]="NoCap"}(r=e.ErrorBarEndStyle||(e.ErrorBarEndStyle={}));!function(t){t[t.Both=0]="Both";t[t.Minus=1]="Minus";t[t.Plus=2]="Plus"}(n=e.ErrorBarDirection||(e.ErrorBarDirection={}));var a=function(e){__extends(ErrorBar,e);function ErrorBar(t){var a=e.call(this)||this;a._errorAmount=i.FixedValue;a._endStyle=r.Cap;a._direction=n.Both;a.rendering.addHandler(a._rendering,a);a.initialize(t);return a}Object.defineProperty(ErrorBar.prototype,"value",{get:function(){return this._value},set:function(t){if(t!=this._value){this._value=t;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"errorAmount",{get:function(){return this._errorAmount},set:function(e){if((e=t.asEnum(e,i,!0))!=this._errorAmount){this._errorAmount=e;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"errorBarStyle",{get:function(){return this._errorBarStyle},set:function(t){if(t!=this._errorBarStyle){this._errorBarStyle=t;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"endStyle",{get:function(){return this._endStyle},set:function(e){if((e=t.asEnum(e,r,!0))!=this._endStyle){this._endStyle=e;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"direction",{get:function(){return this._direction},set:function(e){if((e=t.asEnum(e,n,!0))!=this._direction){this._direction=e;this._invalidate()}},enumerable:!0,configurable:!0});ErrorBar.prototype.getDataRect=function(e,r){if(!e)return null;this._chart;var n,a=this.errorAmount,s=0,o=0;this._paddings=[];this._calculateErrorValue();var l,u,h=this.getValues(0),c=e.top,f=e.bottom;if(!h)return e;for(l=0,n=h.length;l<n;l++){var p={plus:0,val:0,minus:0},_=this._value||0;u=h[l];switch(a){case i.Custom:(p=this._getCustomValue(l)).val=u;this._paddings.push(p);break;case i.FixedValue:this._paddings.push({plus:_,minus:_,val:u});break;case i.Percentage:this._paddings.push({plus:u*_,minus:u*_,val:u});break;case i.StandardDeviation:this._paddings.push({plus:this._errorValue*_,minus:this._errorValue*_,val:u});break;case i.StandardError:this._paddings.push({plus:this._errorValue,minus:this._errorValue,val:u})}(isNaN(c)||c>u-p.minus)&&(c=u-p.minus);(isNaN(f)||f<u+p.plus)&&(f=u+p.plus)}switch(a){case i.FixedValue:s=_;o=_;break;case i.Percentage:s=c*_;o=f*_;break;case i.StandardDeviation:s=this._errorValue*_;o=this._errorValue*_;break;case i.StandardError:s=this._errorValue;o=this._errorValue}this._showPlus&&(f+=o);this._showMinus&&(c-=s);return new t.Rect(e.left,c,e.width,f-c)};ErrorBar.prototype._getCustomValue=function(e){var i,r=this.value,n={minus:0,val:0,plus:0};if(null!=this._minusBindingValues||null!=this._plusBindingValues){n.minus=this._minusBindingValues&&this._minusBindingValues[e]||0;n.plus=this._plusBindingValues&&this._plusBindingValues[e]||0;return n}if(null==r)return n;if(t.isArray(r)){(i=r[e])&&i.minus&&(n.minus=i.minus);i&&i.plus&&(n.plus=i.plus)}else if(t.isNumber(r)){n.minus=r;n.plus=r}else{r.minus&&(n.minus=r.minus);r.plus&&(n.plus=r.plus)}return n};ErrorBar.prototype._calculateErrorValue=function(){var t=0,e=0,r=0;if(this._errorAmount===i.StandardDeviation||this._errorAmount===i.StandardError){var n=this.getValues(0);if(null!=n){n.forEach((function(i){t+=i;e++}));r=t/e;this._mean=r;t=0;n.forEach((function(e){t+=Math.pow(e-r,2)}));this._errorValue=Math.sqrt(t/(e-1))}this._errorAmount==i.StandardError&&(this._errorValue=this._errorValue/Math.sqrt(e))}};ErrorBar.prototype._clearValues=function(){this.__errorValue=null;this._mean=null;this._plusBindingValues=null;this._minusBindingValues=null;e.prototype._clearValues.call(this)};ErrorBar.prototype.getValues=function(t){if(0==t&&this.errorAmount===i.Custom){var r=this._getBinding(1),n=this._getBinding(2);if((null==this._plusBindingValues||null==this._minusBindingValues)&&r&&n)if(null!=this._cv){if(r){var a=this._bindValues(this._cv.items,r);this._plusBindingValues=a.values}if(n){var s=this._bindValues(this._cv.items,n);this._minusBindingValues=s.values}}else if(null!=this.binding&&null!=this._chart&&null!=this._chart.collectionView){if(r){a=this._bindValues(this._chart.collectionView.items,r);this._plusBindingValues=a.values}if(n){s=this._bindValues(this._chart.collectionView.items,n);this._minusBindingValues=s.values}}}return e.prototype.getValues.call(this,t)};Object.defineProperty(ErrorBar.prototype,"_chart",{get:function(){return this.__chart},set:function(t){t!==this.__chart&&(this.__chart=t)},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"_errorValue",{get:function(){return this.__errorValue},set:function(t){t!=this.__errorValue&&(this.__errorValue=t)},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"_showPlus",{get:function(){return this.direction===n.Both||this.direction===n.Plus},enumerable:!0,configurable:!0});Object.defineProperty(ErrorBar.prototype,"_showMinus",{get:function(){return this.direction===n.Both||this.direction===n.Minus},enumerable:!0,configurable:!0});ErrorBar.prototype._rendering=function(e,n){var a=this;this._errorBarEles=[];n.cancel=!0;var s=this.chart,o=s._plotRect,l=this._getAxisY(),u=this._getAxisX(),h=(l.origin,n.engine),c=s.series.indexOf(this),f=this._plotter;f.plotSeries(h,u,l,this,s,n.index,n.count,(function(e){var n,p,_,d=a._paddings,y=a._showPlus,m=a._showMinus,g=s._isRotated(),v=a.errorBarStyle&&a.errorBarStyle["stroke-width"]||2;_=(p=g?u:l).actualMax;n=p.convert(_);var b=h.stroke,x=h.strokeWidth;h.stroke="black";h.strokeWidth=1;var P=a.chart._plotrectId;h.startGroup(null,P);e&&e.length&&e.forEach((function(e,s){if(null!=e&&null!=e.x&&null!=e.y){var l=d[s],u=l&&l.minus||0,b=l&&l.plus||0,x=Math.abs(p.convert(_-u)-n),P=Math.abs(p.convert(_+b)-n),S=new t.Point(e.x,e.y),M=new t.Point(e.x,e.y);if(g){if(a.errorAmount===i.StandardDeviation){e=new t.Point(p.convert(a._mean),e.y);S.x=e.x;M.x=e.x}m&&(S.x=S.x-x);y&&(M.x=M.x+P)}else{if(a.errorAmount===i.StandardDeviation){e=new t.Point(e.x,p.convert(a._mean));S.y=e.y;M.y=e.y}m&&(S.y=S.y+x);y&&(M.y=M.y-P)}var w=void 0;w=g?new t.Rect(S.x,S.y-v,Math.abs(M.x-S.x),2*v):new t.Rect(M.x-v,M.y,2*v,Math.abs(M.y-S.y));var L=new t.chart._RectArea(w);L.ignoreLabel=!0;var B=new t.chart._DataPoint(c,s,s,l.val);L.tag=B;f.hitTester.add(L,c);var V=[h.drawLine(S.x,S.y,M.x,M.y,"error-bar",a.errorBarStyle)];a._errorBarEles[s]=V;if(a.endStyle===r.Cap){if(y){var O=void 0;if(g){if(M.x<=o.right){O=h.drawLine(M.x,M.y-v,M.x,M.y+v,"error-bar",a.errorBarStyle);V.push(O)}}else if(M.y>=o.top){O=h.drawLine(M.x-v,M.y,M.x+v,M.y,"error-bar",a.errorBarStyle);V.push(O)}}if(m){var E=void 0;if(g){if(S.x>=o.left){E=h.drawLine(S.x,S.y-v,S.x,S.y+v,"error-bar",a.errorBarStyle);V.push(E)}}else if(S.y<=o.bottom){E=h.drawLine(S.x-v,S.y,S.x+v,S.y,"error-bar",a.errorBarStyle);V.push(E)}}}}}));h.endGroup();h.stroke=b;h.strokeWidth=x}))};ErrorBar.prototype.getPlotElement=function(t){if(this.hostElement&&t<this._pointIndexes.length){var e=null==this._errorBarEles[t]?[]:this._errorBarEles[t].slice(),i=this._pointIndexes[t];i<this.hostElement.childNodes.length&&e.push(this.hostElement.childNodes[i]);return e}return null};return ErrorBar}(t.chart.Series);e.ErrorBar=a})((e=t.chart||(t.chart={})).analytics||(e.analytics={}))}(wijmo||(wijmo={}));!function(t){!function(e){!function(e){"use strict";t._addCultureInfo("FlexChartAnalytics",{BreakEven:{profitArea:"Profit Area",lossArea:"Loss Area",safetyMargin:"Safety Margin",salesRevenue:"Sales Revenue",totalCost:"Total Cost",fixedCost:"Fixed Cost",variableCost:"Variable Cost",marginalProfit:"Marginal Profit",breakEven:"Break Even"}});var i=function(e){__extends(BreakEven,e);function BreakEven(i){var r=e.call(this)||this;r.rendering.addHandler(r._rendering,r);r.style={fill:"rgba(0,255,0,0.5)",strokeWidth:0};r.altStyle={fill:"rgba(255,0,0,0.5)",strokeWidth:0};r.tooltipContent="{y}";r.initialize(i);r._chartType=t.chart.ChartType.Line;var n=t.culture.FlexChartAnalytics.BreakEven;r.name=n.profitArea+","+n.lossArea+","+n.safetyMargin+","+n.salesRevenue+","+n.totalCost+","+n.fixedCost+","+n.variableCost+","+n.marginalProfit+","+n.breakEven;return r}Object.defineProperty(BreakEven.prototype,"fixedCost",{get:function(){return this._fixedCost},set:function(e){if(e!=this._fixedCost){this._fixedCost=t.asNumber(e,!0,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BreakEven.prototype,"variableCost",{get:function(){return this._variableCost},set:function(e){if(e!=this._variableCost){this._variableCost=t.asNumber(e,!0,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BreakEven.prototype,"salesPrice",{get:function(){return this._salesPrice},set:function(e){if(e!=this._salesPrice){this._salesPrice=t.asNumber(e,!0,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BreakEven.prototype,"styles",{get:function(){return this._styles},set:function(t){if(t!==this._styles){this._styles=t;this._invalidate()}},enumerable:!0,configurable:!0});BreakEven.prototype.getValues=function(t){var e=this.salesPrice-this.variableCost;if(0==e)return null;for(var i=1.3*(this.fixedCost/e),r=[],n=0;n<10;n++)0==t?r.push(n*i/10*this.salesPrice):1==t&&r.push(n*i/10);return r};BreakEven.prototype._rendering=function(t,e){this.chart._plotRect;var i=e.engine,r=this.chart.axisX,n=this.chart.axisY,a=this.getValues(1),s=this.getValues(0),o=this.salesPrice-this.variableCost,l=this.fixedCost/o,u=this.fixedCost+s[s.length-1]-o*a[a.length-1],h=this.chart._plotrectId;i.startGroup(null,h);if(this.style&&this.style.fill){i.fill=this.style.fill;i.drawPolygon([r.convert(a[a.length-1]),r.convert(l),r.convert(a[a.length-1])],[n.convert(s[s.length-1]),n.convert(l*this.salesPrice),n.convert(u)]);i.fill=null}if(this.altStyle&&this.altStyle.fill){i.fill=this.altStyle.fill;i.drawPolygon([r.convert(a[0]),r.convert(l),r.convert(a[0])],[n.convert(0),n.convert(l*this.salesPrice),n.convert(this.fixedCost)]);i.fill=null}var c=this.styles?this.styles.safetyMargin:void 0,f=this.styles?this.styles.salesRevenue:void 0,p=this.styles?this.styles.totalCost:void 0,_=this.styles?this.styles.fixedCost:void 0,d=this.styles?this.styles.variableCost:void 0,y=this.styles?this.styles.marginalProfit:void 0,m=this.styles?this.styles.breakEven:void 0;if(c&&c.fill){i.fill=c.fill;i.drawPolygon([r.convert(a[a.length-1]),r.convert(l),r.convert(a[a.length-1])],[n.convert(a[a.length-1]*(this.salesPrice-this.variableCost)),n.convert(this.fixedCost),n.convert(this.fixedCost)]);i.fill=null}if(f){this._setStyle(i,f);i.drawLine(r.convert(0),n.convert(0),r.convert(a[a.length-1]),n.convert(s[s.length-1]))}if(p){this._setStyle(i,p);i.drawLine(r.convert(a[0]),n.convert(this.fixedCost),r.convert(a[a.length-1]),n.convert(u))}if(_){this._setStyle(i,_);i.drawLine(r.convert(a[0]),n.convert(this.fixedCost),r.convert(a[a.length-1]),n.convert(this.fixedCost))}if(d){this._setStyle(i,d);i.drawLine(r.convert(a[0]),n.convert(0),r.convert(a[a.length-1]),n.convert(a[a.length-1]*this.variableCost))}if(y){this._setStyle(i,y);i.drawLine(r.convert(a[0]),n.convert(0),r.convert(a[a.length-1]),n.convert(a[a.length-1]*(this.salesPrice-this.variableCost)))}if(m){this._setStyle(i,m);i.drawLine(r.convert(l),n.convert(0),r.convert(l),n.convert(l*this.salesPrice));i.drawLine(r.convert(0),n.convert(l*this.salesPrice),r.convert(l),n.convert(l*this.salesPrice))}i.endGroup()};BreakEven.prototype._setStyle=function(t,e){t.stroke=e.stroke;t.strokeWidth=e.strokeWidth?e.strokeWidth:3};BreakEven.prototype._getName=function(t){var e=void 0;if(this.name)if(this.name.indexOf(",")){var i=this.name.split(",");i&&i.length-1>=t&&(e=i[t].trim())}else e=this.name;return e};BreakEven.prototype.legendItemLength=function(){return 9};BreakEven.prototype._getStyle=function(t){var e=null;switch(t){case 0:e=this.style;break;case 1:e=this.altStyle;break;case 2:e=this.styles?this.styles.safetyMargin:null;break;case 3:e=this.styles?this.styles.salesRevenue:null;break;case 4:e=this.styles?this.styles.totalCost:null;break;case 5:e=this.styles?this.styles.fixedCost:null;break;case 6:e=this.styles?this.styles.variableCost:null;break;case 7:e=this.styles?this.styles.marginalProfit:null;break;case 8:e=this.styles?this.styles.breakEven:null}return e};BreakEven.prototype.measureLegendItem=function(e,i){var r=this._getName(i),n=new t.Size(0,0),a=this._getStyle(i);r&&a&&(n=this._measureLegendItem(e,this._getName(i)));return n};BreakEven.prototype.drawLegendItem=function(t,e,i){var r=this._getStyle(i),n=this._getName(i);n&&r&&this._drawLegendItem(t,e,i<3?5:3,n,r,this.symbolStyle)};return BreakEven}(t.chart.SeriesBase);e.BreakEven=i}(e.analytics||(e.analytics={}))}(t.chart||(t.chart={}))}(wijmo||(wijmo={}));!function(t){var e;(function(e){"use strict";var i;!function(t){t[t.InclusiveMedian=0]="InclusiveMedian";t[t.ExclusiveMedian=1]="ExclusiveMedian"}(i=e.QuartileCalculation||(e.QuartileCalculation={}));var r=function(e){__extends(BoxWhisker,e);function BoxWhisker(r){var n=e.call(this)||this;n._groupWidth=.8;n._gapWidth=.1;n._showInnerPoints=!1;n._showOutliers=!1;n._quartileCalculation=i.InclusiveMedian;n._chartType=t.chart.ChartType.Bar;n.rendering.addHandler(n._rendering,n);n.initialize(r);return n}BoxWhisker.prototype._initProperties=function(e){t.copy(this,e)};BoxWhisker.prototype._clearValues=function(){e.prototype._clearValues.call(this)};Object.defineProperty(BoxWhisker.prototype,"quartileCalculation",{get:function(){return this._quartileCalculation},set:function(e){if((e=t.asEnum(e,i,!0))!=this._quartileCalculation){this._quartileCalculation=e;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"groupWidth",{get:function(){return this._groupWidth},set:function(e){if(e!=this._groupWidth&&e>=0&&e<=1){this._groupWidth=t.asNumber(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"gapWidth",{get:function(){return this._gapWidth},set:function(e){if(e!=this._gapWidth&&e>=0&&e<=1){this._gapWidth=t.asNumber(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"showMeanLine",{get:function(){return this._showMeanLine},set:function(e){if(e!=this._showMeanLine){this._showMeanLine=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"meanLineStyle",{get:function(){return this._meanLineStyle},set:function(t){if(t!=this._meanLineStyle){this._meanLineStyle=t;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"showMeanMarker",{get:function(){return this._showMeanMarker},set:function(e){if(e!=this._showMeanMarker){this._showMeanMarker=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"meanMarkerStyle",{get:function(){return this._meanMarkerStyle},set:function(t){if(t!=this._meanMarkerStyle){this._meanMarkerStyle=t;this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"showInnerPoints",{get:function(){return this._showInnerPoints},set:function(e){if(e!=this._showInnerPoints){this._showInnerPoints=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});Object.defineProperty(BoxWhisker.prototype,"showOutliers",{get:function(){return this._showOutliers},set:function(e){if(e!=this._showOutliers){this._showOutliers=t.asBoolean(e,!0);this._invalidate()}},enumerable:!0,configurable:!0});BoxWhisker.prototype._rendering=function(e,i){var r=this;i.cancel=!0;var a,s,o=this,l=o.chart,u=(o.chart,o._getAxisX()),h=o._getAxisY(),c=i.index,f=i.count,p=i.engine,_=this._plotter,d=l.series.indexOf(o),y=t.asType(o,t.chart.SeriesBase),m=this.quartileCalculation,g=this.showOutliers,v=this.groupWidth,b=(null==this.gapWidth?.2:this.gapWidth)/2;c=c||0;var x=v/(f=f||1),P=o.getValues(0),S=o.getValues(1);if(P){S||(S=_.dataInfo.getXVals());if(S){var M=_.dataInfo.getDeltaX();if(M>0){v*=M;x*=M}}var w=y._getSymbolFill(d),L=y._getAltSymbolFill(d)||w,B=y._getSymbolStroke(d),V=y._getAltSymbolStroke(d)||B,O=P.length;null!=S&&(O=Math.min(O,S.length));var E,T,H=0,C=0,X=_.getItemFormatter(o);if(_.rotated){(H=u.origin||H)<u.actualMin?H=u.actualMin:H>u.actualMax&&(H=u.actualMax);u.convert(H);var k=h.actualMin,Y=h.actualMax;for(W=0;W<O;W++){N=S?S[W]:W;if(null==(F=P[W])||0===F.length)return;_._getSymbolOrigin&&h.convert(_._getSymbolOrigin(H,W));if(_._getSymbolStyles){w=(I=_._getSymbolStyles(W))&&I.fill?I.fill:w;L=I&&I.fill?I.fill:L;B=I&&I.stroke?I.fill:B;V=I&&I.stroke?I.fill:V}E=F[0]>0?w:L;T=F[0]>0?B:V;p.fill=E;p.stroke=T;if(t.chart._DataInfo.isValid(N)&&t.isArray(F)&&F.length>0&&t.chart._DataInfo.isValid(F[0])){var j=N-.5*v+c*x,A=N-.5*v+(c+1)*x;A-=Q=(A-j)*b;if((j+=Q)<k&&A<k||j>Y&&A>Y)continue;j=h.convert(j);A=h.convert(A);z=new n(F,m,g),K={min:u.convert(z.min),max:u.convert(z.max),firstQuartile:u.convert(z.firstQuartile),median:u.convert(z.median),thirdQuartile:u.convert(z.thirdQuartile),mean:u.convert(z.mean),outlierPoints:this._convertPoints(z.outlierPoints,u),innerPoints:this._convertPoints(z.innerPoints,u)},U=new t.Rect(Math.min(K.min,K.max),Math.min(j,A),Math.abs(K.max-K.min),Math.abs(A-j)),J=new t.chart._RectArea(U);var q={min:Math.min(j,A),median:(j+A)/2,max:Math.max(A,j)};if(X){p.startGroup();($=new t.chart.HitTestInfo(l,new t.Point((K.min+K.max)/2,q.median),t.chart.ChartElement.SeriesSymbol))._setData(o,W);X(p,$,(function(){r._drawBoxWhisker(p,K,q,a,s,o);a=K;s=q}));p.endGroup()}else{this._drawBoxWhisker(p,K,q,a,s,o);a=K;s=q}o._setPointIndex(W,C);C++;(G=new t.chart._DataPoint(d,W,F,N)).item=z;J.tag=G;_.hitTester.add(J,d);z.outlierPoints&&z.outlierPoints.length&&z.outlierPoints.forEach((function(e,i){var r=K.outlierPoints[i],n=new t.chart._CircleArea(new t.Point(r,U.top+U.height/2),2);n.tag=G;_.hitTester.add(n,d)}))}}}else{(H=h.origin||H)<h.actualMin?H=h.actualMin:H>h.actualMax&&(H=h.actualMax);h.convert(H),u.actualMin,u.actualMax;for(var W=0;W<O;W++){var F,N=S?S[W]:W;if(null==(F=P[W])||0===F.length)return;_._getSymbolOrigin&&h.convert(_._getSymbolOrigin(H,W,O));if(_._getSymbolStyles){var I;w=(I=_._getSymbolStyles(W,O))&&I.fill?I.fill:w;L=I&&I.fill?I.fill:L;B=I&&I.stroke?I.stroke:B;V=I&&I.stroke?I.stroke:V}E=F[0]>0?w:L;T=F[0]>0?B:V;p.fill=E;p.stroke=T;if(t.chart._DataInfo.isValid(N)&&t.isArray(F)&&F.length>0&&t.chart._DataInfo.isValid(F[0])){var Q,D=N-.5*v+c*x,R=N-.5*v+(c+1)*x;D+=Q=(R-D)*b;R-=Q;D=u.convert(D);R=u.convert(R);if(!t.chart._DataInfo.isValid(D)||!t.chart._DataInfo.isValid(R))continue;var G,z=new n(F,m,g),K={min:h.convert(z.min),max:h.convert(z.max),firstQuartile:h.convert(z.firstQuartile),median:h.convert(z.median),thirdQuartile:h.convert(z.thirdQuartile),mean:h.convert(z.mean),outlierPoints:this._convertPoints(z.outlierPoints,h),innerPoints:this._convertPoints(z.innerPoints,h)},U=new t.Rect(Math.min(D,R),Math.min(K.min,K.max),Math.abs(R-D),Math.abs(K.max-K.min)),J=new t.chart._RectArea(U),Z={min:Math.min(D,R),median:(D+R)/2,max:Math.max(D,R)};if(X){p.startGroup();var $;($=new t.chart.HitTestInfo(l,new t.Point(Z.median,(K.min+K.max)/2),t.chart.ChartElement.SeriesSymbol))._setData(o,W);X(p,$,(function(){r._drawBoxWhisker(p,Z,K,a,s,o);a=Z;s=K}));p.endGroup()}else{this._drawBoxWhisker(p,Z,K,a,s,o);a=Z;s=K}o._setPointIndex(W,C);C++;(G=new t.chart._DataPoint(d,W,N,F)).item=z;J.tag=G;_.hitTester.add(J,d);z.outlierPoints&&z.outlierPoints.length&&z.outlierPoints.forEach((function(e,i){var r=K.outlierPoints[i],n=new t.chart._CircleArea(new t.Point(U.left+U.width/2,r),2);n.tag=G;_.hitTester.add(n,d)}))}}}}};BoxWhisker.prototype._convertPoints=function(t,e){return t.map((function(t){return e.convert(t)}))};BoxWhisker.prototype._drawBoxWhisker=function(t,e,i,r,n,a){var s=a.symbolStyle,o=this.showInnerPoints,l=this.showOutliers,u=this.showMeanLine,h=this.meanLineStyle,c=this.showMeanMarker,f=this.meanMarkerStyle,p=this._plotter;t.startGroup("box-plot");t.strokeWidth=1;if(p.rotated){t.drawLine(e.min,(i.min+i.median)/2,e.min,(i.max+i.median)/2,null,s);t.drawLine(e.min,i.median,e.firstQuartile,i.median,null,s);t.drawRect(Math.min(e.firstQuartile,e.thirdQuartile),Math.min(i.min,i.max),Math.abs(e.thirdQuartile-e.firstQuartile),Math.abs(i.max-i.min),null,s);t.drawLine(e.median,i.min,e.median,i.max,null,s);t.drawLine(e.max,i.median,e.thirdQuartile,i.median,null,s);t.drawLine(e.max,(i.min+i.median)/2,e.max,(i.max+i.median)/2,null,s);u&&r&&n&&t.drawLine(e.mean,i.median,r.mean,n.median,"box-whisker-mean-line",h||s);if(c){var _=Math.abs(i.median-i.min)/2;t.drawLine(e.mean-_,i.median-_,e.mean+_,i.median+_,null,f||s);t.drawLine(e.mean+_,i.median-_,e.mean-_,i.median+_,null,f||s)}l&&e.outlierPoints.forEach((function(e){t.drawPieSegment(e,i.median,2,0,2*Math.PI,null,s)}));o&&e.innerPoints.forEach((function(e){t.drawPieSegment(e,i.median,2,0,2*Math.PI,null,s)}))}else{t.drawLine((e.min+e.median)/2,i.min,(e.max+e.median)/2,i.min,null,s);t.drawLine(e.median,i.min,e.median,i.firstQuartile,null,s);t.drawRect(Math.min(e.min,e.max),Math.min(i.firstQuartile,i.thirdQuartile),Math.abs(e.max-e.min),Math.abs(i.thirdQuartile-i.firstQuartile),null,s);t.drawLine(e.min,i.median,e.max,i.median,null,s);t.drawLine(e.median,i.max,e.median,i.thirdQuartile,null,s);t.drawLine((e.min+e.median)/2,i.max,(e.max+e.median)/2,i.max,null,s);u&&r&&n&&t.drawLine(e.median,i.mean,r.median,n.mean,"box-whisker-mean-line",h||s);if(c){_=Math.abs(e.median-e.min)/2;t.drawLine(e.median-_,i.mean-_,e.median+_,i.mean+_,null,f||s);t.drawLine(e.median-_,i.mean+_,e.median+_,i.mean-_,null,f||s)}l&&i.outlierPoints.forEach((function(i){t.drawPieSegment(e.median,i,2,0,2*Math.PI,null,s)}));o&&i.innerPoints.forEach((function(i){t.drawPieSegment(e.median,i,2,0,2*Math.PI,null,s)}))}t.endGroup()};BoxWhisker.prototype._renderLabels=function(e,i,r,n){var a=this,s=this,o=this._plotter,l=i.length,u=r.dataLabel,h=u.border,c=u.offset,f=u.connectingLine,p="dataY";o.rotated&&(p="dataX");void 0===c&&(c=f?16:0);h&&(c-=2);for(var _=[],d=0;d<l;d++){var y=i[d],m=y.tag,g=t.asType(m,t.chart._DataPoint,!0);if(g&&-1==_.indexOf(g)){_.push(g);var v=m.item,b=m.y;m[p]=v.min;m.yfmt=v.min;m.y=v.min;this._plotter._renderLabel(e,y,g,r,u,s,c,n);m[p]=v.firstQuartile;m.yfmt=v.firstQuartile;m.y=v.firstQuartile;this._plotter._renderLabel(e,y,g,r,u,s,c,n);m[p]=v.median;m.yfmt=v.median;m.y=v.median;this._plotter._renderLabel(e,y,g,r,u,s,c,n);m[p]=v.thirdQuartile;m.yfmt=v.thirdQuartile;m.y=v.thirdQuartile;this._plotter._renderLabel(e,y,g,r,u,s,c,n);m[p]=v.max;m.yfmt=v.max;m.y=v.max;this._plotter._renderLabel(e,y,g,r,u,s,c,n);if(this.showMeanMarker){var x=Number(v.mean.toFixed(2));m[p]=x;m.yfmt=x;m.y=x;this._plotter._renderLabel(e,y,g,r,u,s,c,n)}v.showOutliers&&v.outlierPoints&&v.outlierPoints.forEach((function(t){m[p]=t;m.yfmt=t;m.y=t;a._plotter._renderLabel(e,y,g,r,u,s,c,n)}));m.y=b}}};return BoxWhisker}(t.chart.SeriesBase);e.BoxWhisker=r;var n=function(){function _BoxPlot(t,e,i){this._outlierPoints=[];this._innerPoints=[];this._data=t;this._quartileCalculation=e;this._showOutliers=i;this._parse()}Object.defineProperty(_BoxPlot.prototype,"showOutliers",{get:function(){return this._showOutliers},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"min",{get:function(){return this._min},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"max",{get:function(){return this._max},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"mean",{get:function(){return this._mean},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"firstQuartile",{get:function(){return this._firstQuartile},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"thirdQuartile",{get:function(){return this._thirdQuartile},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"median",{get:function(){return this._median},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"outlierPoints",{get:function(){return this._outlierPoints},enumerable:!0,configurable:!0});Object.defineProperty(_BoxPlot.prototype,"innerPoints",{get:function(){return this._innerPoints},enumerable:!0,configurable:!0});_BoxPlot.prototype._parse=function(){var t=this,e=this._data.length,r=this._data,n=0;this._outlierPoints=[];this._innerPoints=[];r.sort((function(t,e){return t-e}));r.some((function(e){if(null==e)return!1;t._min=e;return!0}));this._max=null==r[e-1]?0:r[e-1];if(this._quartileCalculation===i.InclusiveMedian){this._firstQuartile=this._quartileInc(r,.25);this._median=this._quartileInc(r,.5);this._thirdQuartile=this._quartileInc(r,.75)}else{this._firstQuartile=this._quartileExc(r,.25);this._median=this._quartileExc(r,.5);this._thirdQuartile=this._quartileExc(r,.75)}this._iqr=1.5*Math.abs(this._thirdQuartile-this._firstQuartile);var a=this._firstQuartile-this._iqr,s=this._thirdQuartile+this._iqr;if(this._showOutliers){var o=this._max;this._max=this._min;this._min=o;this._data.forEach((function(e){n+=e;if(e<a||e>s)t._outlierPoints.push(e);else{e<t._min&&(t._min=e);e>t._max&&(t._max=e)}}))}else n=this._data.reduce((function(t,e){return t+e}),0);this._innerPoints=this._data.filter((function(e){if(e>t._min&&e<t._max)return!0}));this._mean=n/e};_BoxPlot.prototype._quartileInc=function(t,e){var i,r,n,a,s=t.length;if(1===s)return t[0];a=(i=(s-1)*e+1)-(r=Math.floor(i));return(n=t[r-1])+(t[r]-n)*a};_BoxPlot.prototype._quartileExc=function(t,e){var i,r,n,a,s=t.length;if(1===s)return t[0];if(2===s)return t[Math.round(e)];a=(i=(s+1)*e)-(r=Math.floor(i));return(n=t[r-1])+(t[r]-n)*a};return _BoxPlot}();e._BoxPlot=n})((e=t.chart||(t.chart={})).analytics||(e.analytics={}))}(wijmo||(wijmo={}));!function(t){!function(e){e.analytics||(e.analytics={}),t._registerModule("wijmo.chart.analytics",t.chart.analytics)}(t.chart||(t.chart={}))}(wijmo||(wijmo={}));