/* Highstock JS v8.0.0 (2019-12-10) Indicator series type for Highstock (c) 2010-2019 Rafal Sebestjanski License: www.highcharts.com/license */ (function(a){"object"===typeof module&&module.exports?(a["default"]=a,module.exports=a):"function"===typeof define&&define.amd?define("highcharts/indicators/tema",["highcharts","highcharts/modules/stock"],function(b){a(b);a.Highcharts=b;return a}):a("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(a){function b(a,f,l,g){a.hasOwnProperty(f)||(a[f]=g.apply(null,l))}a=a?a._modules:{};b(a,"mixins/indicator-required.js",[a["parts/Globals.js"]],function(a){var f=a.error;return{isParentLoaded:function(a, g,b,k,r){if(a)return k?k(a):!0;f(r||this.generateMessage(b,g));return!1},generateMessage:function(a,b){return'Error: "'+a+'" indicator type requires "'+b+'" indicator loaded before. Please read docs: https://api.highcharts.com/highstock/plotOptions.'+a}}});b(a,"indicators/tema.src.js",[a["parts/Globals.js"],a["parts/Utilities.js"],a["mixins/indicator-required.js"]],function(a,b,l){var g=b.correctFloat,f=b.isArray,k=a.seriesTypes.ema;a.seriesType("tema","ema",{},{init:function(){var a=arguments,h= this;l.isParentLoaded(k,"ema",h.type,function(d){d.prototype.init.apply(h,a)})},getEMA:function(a,h,d,b,f,g){return k.prototype.calculateEma(g||[],a,"undefined"===typeof f?1:f,this.chart.series[0].EMApercent,h,"undefined"===typeof b?-1:b,d)},getTemaPoint:function(a,b,d,f){return[a[f-3],g(3*d.level1-3*d.level2+d.level3)]},getValues:function(a,b){var d=b.period,g=2*d,h=3*d,l=a.xData,m=a.yData,n=m?m.length:0,t=-1,v=[],w=[],x=[],p=[],u=[],e,q,c={};a.EMApercent=2/(d+1);if(!(n<3*d-2)){f(m[0])&&(t=b.index? b.index:0);a=k.prototype.accumulatePeriodPoints(d,t,m);b=a/d;a=0;for(e=d;e