text: !function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).Dygraph=t()}}(function(){return function r(o,s,l){function h(e,t){if(!s[e]){if(!o[e]){var a="function"==typeof require&&require;if(!t&&a)return a(e,!0);if(u)return u(e,!0);var i=new Error("Cannot find module '"+e+"'");throw i.code="MODULE_NOT_FOUND",i}var n=s[e]={exports:{}};o[e][0].call(n.exports,function(t){return h(o[e][1][t]||t)},n,n.exports,r,o,s,l)}return s[e].exports}for(var u="function"==typeof require&&require,t=0;t<l.length;t++)h(l[t]);return h}({1:[function(t,e,a){function i(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function r(e){if(u===setTimeout)return setTimeout(e,0);if((u===i||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function o(){f&&p&&(f=!1,p.length?g=p.concat(g):_=-1,g.length&&s())}function s(){if(!f){var t=r(o);f=!0;for(var e=g.length;e;){for(p=g,g=[];++_<e;)p&&p[_].run();_=-1,e=g.length}p=null,f=!1,function(e){if(d===clearTimeout)return clearTimeout(e);if((d===n||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(e);try{d(e)}catch(t){try{return d.call(null,e)}catch(t){return d.call(this,e)}}}(t)}}function l(t,e){this.fun=t,this.array=e}function h(){}var u,d,c=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:i}catch(t){u=i}try{d="function"==typeof clearTimeout?clearTimeout:n}catch(t){d=n}}();var p,g=[],f=!1,_=-1;c.nextTick=function(t){var e=new Array(arguments.length-1);if(1<arguments.length)for(var a=1;a<arguments.length;a++)e[a-1]=arguments[a];g.push(new l(t,e)),1!==g.length||f||r(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},c.title="browser",c.browser=!0,c.env={},c.argv=[],c.version="",c.versions={},c.on=h,c.addListener=h,c.once=h,c.off=h,c.removeListener=h,c.removeAllListeners=h,c.emit=h,c.prependListener=h,c.prependOnceListener=h,c.listeners=function(t){return[]},c.binding=function(t){throw new Error("process.binding is not supported")},c.cwd=function(){return"/"},c.chdir=function(t){throw new Error("process.chdir is not supported")},c.umask=function(){return 0}},{}],2:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){}var n,r=t("./bars"),o=(n=r)&&n.__esModule?n:{default:n};(i.prototype=new o.default).extractSeries=function(t,e,a){for(var i,n,r,o=[],s=a.get("logscale"),l=0;l<t.length;l++)i=t[l][0],r=t[l][e],s&&null!==r&&(r[0]<=0||r[1]<=0||r[2]<=0)&&(r=null),null!==r?null===(n=r[1])||isNaN(n)?o.push([i,n,[n,n]]):o.push([i,n,[r[0],r[2]]]):o.push([i,null,[null,null]]);return o},i.prototype.rollingAverage=function(t,e,a){e=Math.min(e,t.length);var i,n,r,o,s,l,h,u=[];for(l=s=r=o=n=0;l<t.length;l++){if(i=t[l][1],h=t[l][2],u[l]=t[l],null===i||isNaN(i)||(n+=h[0],o+=i,r+=h[1],s+=1),0<=l-e){var d=t[l-e];null===d[1]||isNaN(d[1])||(n-=d[2][0],o-=d[1],r-=d[2][1],s-=1)}u[l]=s?[t[l][0],1*o/s,[1*n/s,1*r/s]]:[t[l][0],null,[null,null]]}return u},a.default=i,e.exports=a.default},{"./bars":5}],3:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){}var n,r=t("./bars"),o=(n=r)&&n.__esModule?n:{default:n};(i.prototype=new o.default).extractSeries=function(t,e,a){for(var i,n,r,o,s=[],l=a.get("sigma"),h=a.get("logscale"),u=0;u<t.length;u++)i=t[u][0],o=t[u][e],h&&null!==o&&(o[0]<=0||o[0]-l*o[1]<=0)&&(o=null),null!==o?null===(n=o[0])||isNaN(n)?s.push([i,n,[n,n,n]]):(r=l*o[1],s.push([i,n,[n-r,n+r,o[1]]])):s.push([i,null,[null,null,null]]);return s},i.prototype.rollingAverage=function(t,e,a){e=Math.min(e,t.length);var i,n,r,o,s,l,h,u,d,c=[],p=a.get("sigma");for(i=0;i<t.length;i++){for(l=u=s=0,n=Math.max(0,i-e+1);n<i+1;n++)null===(r=t[n][1])||isNaN(r)||(l++,s+=r,u+=Math.pow(t[n][2][2],2));l?(h=Math.sqrt(u)/l,d=s/l,c[i]=[t[i][0],d,[d-p*h,d+p*h]]):(o=1==e?t[i][1]:null,c[i]=[t[i][0],o,[o,o]])}return c},a.default=i,e.exports=a.default},{"./bars":5}],4:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){}var n,r=t("./bars"),o=(n=r)&&n.__esModule?n:{default:n};(i.prototype=new o.default).extractSeries=function(t,e,a){for(var i,n,r,o,s,l,h,u=[],d=a.get("sigma"),c=a.get("logscale"),p=0;p<t.length;p++)i=t[p][0],r=t[p][e],c&&null!==r&&(r[0]<=0||r[1]<=0)&&(r=null),null!==r?(o=r[0],s=r[1],null===o||isNaN(o)?u.push([i,o,[o,o,o,s]]):(l=s?o/s:0,h=100*(s?d*Math.sqrt(l*(1-l)/s):1),n=100*l,u.push([i,n,[n-h,n+h,o,s]]))):u.push([i,null,[null,null,null,null]]);return u},i.prototype.rollingAverage=function(t,e,a){e=Math.min(e,t.length);var i,n,r,o,s=[],l=a.get("sigma"),h=a.get("wilsonInterval"),u=0,d=0;for(r=0;r<t.length;r++){u+=t[r][2][2],d+=t[r][2][3],0<=r-e&&(u-=t[r-e][2][2],d-=t[r-e][2][3]);var c=t[r][0],p=d?u/d:0;if(h)if(d){var g=p<0?0:p,f=d,_=l*Math.sqrt(g*(1-g)/f+l*l/(4*f*f)),v=1+l*l/d;i=(g+l*l/(2*d)-_)/v,n=(g+l*l/(2*d)+_)/v,s[r]=[c,100*g,[100*i,100*n]]}else s[r]=[c,0,[0,0]];else o=d?l*Math.sqrt(p*(1-p)/d):1,s[r]=[c,100*p,[100*(p-o),100*(p+o)]]}return s},a.default=i,e.exports=a.default},{"./bars":5}],5:[function(t,e,a){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(a,"__esModule",{value:!0});function n(){r.default.call(this)}var r=i(t("./datahandler")),o=i(t("../dygraph-layout"));(n.prototype=new r.default).extractSeries=function(t,e,a){},n.prototype.rollingAverage=function(t,e,a){},n.prototype.onPointsCreated_=function(t,e){for(var a=0;a<t.length;++a){var i=t[a],n=e[a];n.y_top=NaN,n.y_bottom=NaN,n.yval_minus=r.default.parseFloat(i[2][0]),n.yval_plus=r.default.parseFloat(i[2][1])}},n.prototype.getExtremeYValues=function(t,e,a){for(var i,n=null,r=null,o=t.length-1,s=0;s<=o;s++)if(null!==(i=t[s][1])&&!isNaN(i)){var l=t[s][2][0],h=t[s][2][1];i<l&&(l=i),h<i&&(h=i),(null===r||r<h)&&(r=h),(null===n||l<n)&&(n=l)}return[n,r]},n.prototype.onLineEvaluated=function(t,e,a){for(var i,n=0;n<t.length;n++)(i=t[n]).y_top=o.default.calcYNormal_(e,i.yval_minus,a),i.y_bottom=o.default.calcYNormal_(e,i.yval_plus,a)},a.default=n,e.exports=a.default},{"../dygraph-layout":13,"./datahandler":6}],6:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){}var h=i;h.X=0,h.Y=1,h.EXTRAS=2,h.prototype.extractSeries=function(t,e,a){},h.prototype.seriesToPoints=function(t,e,a){for(var i=[],n=0;n<t.length;++n){var r=t[n],o=r[1],s=null===o?null:h.parseFloat(o),l={x:NaN,y:NaN,xval:h.parseFloat(r[0]),yval:s,name:e,idx:n+a};i.push(l)}return this.onPointsCreated_(t,i),i},h.prototype.onPointsCreated_=function(t,e){},h.prototype.rollingAverage=function(t,e,a){},h.prototype.getExtremeYValues=function(t,e,a){},h.prototype.onLineEvaluated=function(t,e,a){},h.parseFloat=function(t){return null===t?NaN:t},a.default=i,e.exports=a.default},{}],7:[function(t,e,a){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(a,"__esModule",{value:!0});function n(){}var r=i((i(t("./datahandler")),t("./default")));(n.prototype=new r.default).extractSeries=function(t,e,a){for(var i,n,r,o,s,l=[],h=a.get("logscale"),u=0;u<t.length;u++)i=t[u][0],r=t[u][e],h&&null!==r&&(r[0]<=0||r[1]<=0)&&(r=null),null!==r?(o=r[0],s=r[1],null===o||isNaN(o)?l.push([i,o,[o,s]]):(n=100*(s?o/s:0),l.push([i,n,[o,s]]))):l.push([i,null,[null,null]]);return l},n.prototype.rollingAverage=function(t,e,a){e=Math.min(e,t.length);var i,n=[],r=0,o=0;for(i=0;i<t.length;i++){r+=t[i][2][0],o+=t[i][2][1],0<=i-e&&(r-=t[i-e][2][0],o-=t[i-e][2][1]);var s=t[i][0],l=o?r/o:0;n[i]=[s,100*l]}return n},a.default=n,e.exports=a.default},{"./datahandler":6,"./default":8}],8:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){}var n,r=t("./datahandler"),o=(n=r)&&n.__esModule?n:{default:n};(i.prototype=new o.default).extractSeries=function(t,e,a){for(var i=[],n=a.get("logscale"),r=0;r<t.length;r++){var o=t[r][0],s=t[r][e];n&&s<=0&&(s=null),i.push([o,s])}return i},i.prototype.rollingAverage=function(t,e,a){var i,n,r,o,s,l=[];if(1==(e=Math.min(e,t.length)))return t;for(i=0;i<t.length;i++){for(s=o=0,n=Math.max(0,i-e+1);n<i+1;n++)null===(r=t[n][1])||isNaN(r)||(s++,o+=t[n][1]);l[i]=s?[t[i][0],o/s]:[t[i][0],null]}return l},i.prototype.getExtremeYValues=function(t,e,a){for(var i,n=null,r=null,o=t.length-1,s=0;s<=o;s++)null===(i=t[s][1])||isNaN(i)||((null===r||r<i)&&(r=i),(null===n||i<n)&&(n=i));return[n,r]},a.default=i,e.exports=a.default},{"./datahandler":6}],9:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function N(t,e,a,i){if(this.dygraph_=t,this.layout=i,this.element=e,this.elementContext=a,this.height=t.height_,this.width=t.width_,!k.isCanvasSupported(this.element))throw"Canvas is not supported.";this.area=i.getPlotArea();var n=this.dygraph_.canvas_ctx_;n.beginPath(),n.rect(this.area.x,this.area.y,this.area.w,this.area.h),n.clip(),(n=this.dygraph_.hidden_ctx_).beginPath(),n.rect(this.area.x,this.area.y,this.area.w,this.area.h),n.clip()}var i,k=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("./dygraph-utils")),n=t("./dygraph"),R=(i=n)&&i.__esModule?i:{default:i};N.prototype.clear=function(){this.elementContext.clearRect(0,0,this.width,this.height)},N.prototype.render=function(){this._updatePoints(),this._renderLineChart()},N._getIteratorPredicate=function(t){return t?N._predicateThatSkipsEmptyPoints:null},N._predicateThatSkipsEmptyPoints=function(t,e){return null!==t[e].yval},N._drawStyledLine=function(t,e,a,i,n,r,o){var s=t.dygraph,l=s.getBooleanOption("stepPlot",t.setName);k.isArrayLike(i)||(i=null);var h=s.getBooleanOption("drawGapEdgePoints",t.setName),u=t.points,d=t.setName,c=k.createIterator(u,0,u.length,N._getIteratorPredicate(s.getBooleanOption("connectSeparatedPoints",d))),p=i&&2<=i.length,g=t.drawingContext;g.save(),p&&g.setLineDash&&g.setLineDash(i);var f=N._drawSeries(t,c,a,o,n,h,l,e);N._drawPointsOnLine(t,f,r,e,o),p&&g.setLineDash&&g.setLineDash([]),g.restore()},N._drawSeries=function(t,e,a,i,n,r,o,s){var l,h,u=null,d=null,c=null,p=[],g=!0,f=t.drawingContext;f.beginPath(),f.strokeStyle=s,f.lineWidth=a;for(var _=e.array_,v=e.end_,y=e.predicate_,x=e.start_;x<v;x++){if(h=_[x],y){for(;x<v&&!y(_,x);)x++;if(x==v)break;h=_[x]}if(null===h.canvasy||h.canvasy!=h.canvasy)o&&null!==u&&(f.moveTo(u,d),f.lineTo(h.canvasx,d)),u=d=null;else{if(l=!1,r||null===u){e.nextIdx_=x,e.next();var m=null===(c=e.hasNext?e.peek.canvasy:null)||c!=c;l=null===u&&m,r&&(!g&&null===u||e.hasNext&&m)&&(l=!0)}null!==u?a&&(o&&(f.moveTo(u,d),f.lineTo(h.canvasx,d)),f.lineTo(h.canvasx,h.canvasy)):f.moveTo(h.canvasx,h.canvasy),(n||l)&&p.push([h.canvasx,h.canvasy,h.idx]),u=h.canvasx,d=h.canvasy}g=!1}return f.stroke(),p},N._drawPointsOnLine=function(t,e,a,i,n){for(var r=t.drawingContext,o=0;o<e.length;o++){var s=e[o];r.save(),a.call(t.dygraph,t.dygraph,t.setName,r,s[0],s[1],i,n,s[2]),r.restore()}},N.prototype._updatePoints=function(){for(var t=this.layout.points,e=t.length;e--;)for(var a=t[e],i=a.length;i--;){var n=a[i];n.canvasx=this.area.w*n.x+this.area.x,n.canvasy=this.area.h*n.y+this.area.y}},N.prototype._renderLineChart=function(t,e){var a,i,n=e||this.elementContext,r=this.layout.points,o=this.layout.setNames;this.colors=this.dygraph_.colorsMap_;var s=this.dygraph_.getOption("plotter"),l=s;k.isArrayLike(l)||(l=[l]);var h={};for(a=0;a<o.length;a++){i=o[a];var u=this.dygraph_.getOption("plotter",i);u!=s&&(h[i]=u)}for(a=0;a<l.length;a++)for(var d=l[a],c=a==l.length-1,p=0;p<r.length;p++)if(i=o[p],!t||i==t){var g=r[p],f=d;if(i in h){if(!c)continue;f=h[i]}var _=this.colors[i],v=this.dygraph_.getOption("strokeWidth",i);n.save(),n.strokeStyle=_,n.lineWidth=v,f({points:g,setName:i,drawingContext:n,color:_,strokeWidth:v,dygraph:this.dygraph_,axis:this.dygraph_.axisPropertiesForSeries(i),plotArea:this.area,seriesIndex:p,seriesCount:r.length,singleSeriesName:t,allSeriesPoints:r}),n.restore()}},N._Plotters={linePlotter:function(t){N._linePlotter(t)},fillPlotter:function(t){N._fillPlotter(t)},errorPlotter:function(t){N._errorPlotter(t)}},N._linePlotter=function(t){var e=t.dygraph,a=t.setName,i=t.strokeWidth,n=e.getNumericOption("strokeBorderWidth",a),r=e.getOption("drawPointCallback",a)||k.Circles.DEFAULT,o=e.getOption("strokePattern",a),s=e.getBooleanOption("drawPoints",a),l=e.getNumericOption("pointSize",a);n&&i&&N._drawStyledLine(t,e.getOption("strokeBorderColor",a),i+2*n,o,s,r,l),N._drawStyledLine(t,t.color,i,o,s,r,l)},N._errorPlotter=function(t){var e=t.dygraph,a=t.setName;if(e.getBooleanOption("errorBars")||e.getBooleanOption("customBars")){e.getBooleanOption("fillGraph",a)&&console.warn("Can't use fillGraph option with error bars");var i,n=t.drawingContext,r=t.color,o=e.getNumericOption("fillAlpha",a),s=e.getBooleanOption("stepPlot",a),l=t.points,h=k.createIterator(l,0,l.length,N._getIteratorPredicate(e.getBooleanOption("connectSeparatedPoints",a))),u=NaN,d=NaN,c=[-1,-1],p=k.toRGB_(r),g="rgba("+p.r+","+p.g+","+p.b+","+o+")";n.fillStyle=g,n.beginPath();for(var f=function(t){return null==t||isNaN(t)};h.hasNext;){var _=h.next();u=!s&&f(_.y)||s&&!isNaN(d)&&f(d)?NaN:(i=[_.y_bottom,_.y_top],s&&(d=_.y),isNaN(i[0])&&(i[0]=_.y),isNaN(i[1])&&(i[1]=_.y),i[0]=t.plotArea.h*i[0]+t.plotArea.y,i[1]=t.plotArea.h*i[1]+t.plotArea.y,isNaN(u)||(s?(n.moveTo(u,c[0]),n.lineTo(_.canvasx,c[0]),n.lineTo(_.canvasx,c[1])):(n.moveTo(u,c[0]),n.lineTo(_.canvasx,i[0]),n.lineTo(_.canvasx,i[1])),n.lineTo(u,c[1]),n.closePath()),c=i,_.canvasx)}n.fill()}},N._fastCanvasProxy=function(n){function r(t){!function(t){if(!(u.length<=1)){for(var e=u.length-1;0<e;e--)if(2==(o=u[e])[0]){var a=u[e-1];a[1]==o[1]&&a[2]==o[2]&&u.splice(e,1)}for(e=0;e<u.length-1;)2==(o=u[e])[0]&&2==u[e+1][0]?u.splice(e,1):e++;if(2<u.length&&!t){var i=0;2==u[0][0]&&i++;var n=null,r=null;for(e=i;e<u.length;e++){var o;if(1==(o=u[e])[0])if(null===n&&null===r)r=n=e;else{var s=o[2];s<u[n][2]?n=e:s>u[r][2]&&(r=e)}}var l=u[n],h=u[r];u.splice(i,u.length-i),n<r?(u.push(l),u.push(h)):(r<n&&u.push(h),u.push(l))}}}(t);for(var e=0,a=u.length;e<a;e++){var i=u[e];1==i[0]?n.lineTo(i[1],i[2]):2==i[0]&&n.moveTo(i[1],i[2])}u.length&&(s=u[u.length-1][1]),l+=u.length,u=[]}function a(t,e,a){var i=Math.round(e);null!==o&&i==o||(r(1<o-s||1<i-o),o=i),u.push([t,e,a])}var u=[],o=null,s=null,l=0;return{moveTo:function(t,e){a(2,t,e)},lineTo:function(t,e){a(1,t,e)},stroke:function(){r(!0),n.stroke()},fill:function(){r(!0),n.fill()},beginPath:function(){r(!0),n.beginPath()},closePath:function(){r(!0),n.closePath()},_count:function(){return l}}},N._fillPlotter=function(t){if(!t.singleSeriesName&&0===t.seriesIndex){for(var e=t.dygraph,a=e.getLabels().slice(1),i=a.length;0<=i;i--)e.visibility()[i]||a.splice(i,1);if(function(){for(var t=0;t<a.length;t++)if(e.getBooleanOption("fillGraph",a[t]))return!0;return!1}())for(var n,r,o=t.plotArea,s=t.allSeriesPoints,l=s.length,h=e.getBooleanOption("stackedGraph"),u=e.getColors(),d={},c=function(t,e,a,i){if(t.lineTo(e,a),h)for(var n=i.length-1;0<=n;n--){var r=i[n];t.lineTo(r[0],r[1])}},p=l-1;0<=p;p--){var g=t.drawingContext,f=a[p];if(e.getBooleanOption("fillGraph",f)){var _=e.getNumericOption("fillAlpha",f),v=e.getBooleanOption("stepPlot",f),y=u[p],x=e.axisPropertiesForSeries(f),m=1+x.minyval*x.yscale;m<0?m=0:1<m&&(m=1),m=o.h*m+o.y;var b,w=s[p],A=k.createIterator(w,0,w.length,N._getIteratorPredicate(e.getBooleanOption("connectSeparatedPoints",f))),O=NaN,P=[-1,-1],L=k.toRGB_(y),S="rgba("+L.r+","+L.g+","+L.b+","+_+")";g.fillStyle=S,g.beginPath();var T,C=!0;(w.length>2*e.width_||R.default.FORCE_FAST_PROXY)&&(g=N._fastCanvasProxy(g));for(var M,E=[];A.hasNext;)if(M=A.next(),k.isOK(M.y)||v){if(h){if(!C&&T==M.xval)continue;var D;C=!1,T=M.xval,D=void 0===(n=d[M.canvasx])?m:r?n[0]:n,b=[M.canvasy,D],v?-1===P[0]?d[M.canvasx]=[M.canvasy,m]:d[M.canvasx]=[M.canvasy,P[0]]:d[M.canvasx]=M.canvasy}else b=isNaN(M.canvasy)&&v?[o.y+o.h,m]:[M.canvasy,m];isNaN(O)?(g.moveTo(M.canvasx,b[1]),g.lineTo(M.canvasx,b[0])):(v&&g.lineTo(M.canvasx,P[0]),g.lineTo(M.canvasx,b[0]),h&&(E.push([O,P[1]]),r&&n?E.push([M.canvasx,n[1]]):E.push([M.canvasx,b[1]]))),P=b,O=M.canvasx}else c(g,O,P[1],E),E=[],O=NaN,null===M.y_stacked||isNaN(M.y_stacked)||(d[M.canvasx]=o.h*M.y_stacked+o.y);r=v,b&&M&&(c(g,M.canvasx,b[1],E),E=[]),g.fill()}}}},a.default=N,e.exports=a.default},{"./dygraph":18,"./dygraph-utils":17}],10:[function(t,e,a){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}Object.defineProperty(a,"__esModule",{value:!0});var r=n(t("./dygraph-tickers")),o=i(t("./dygraph-interaction-model")),s=i(t("./dygraph-canvas")),l=n(t("./dygraph-utils")),h={highlightCircleSize:3,highlightSeriesOpts:null,highlightSeriesBackgroundAlpha:.5,highlightSeriesBackgroundColor:"rgb(255, 255, 255)",labelsSeparateLines:!1,labelsShowZeroValues:!0,labelsKMB:!1,labelsKMG2:!1,showLabelsOnHighlight:!0,digitsAfterDecimal:2,maxNumberWidth:6,sigFigs:null,strokeWidth:1,strokeBorderWidth:0,strokeBorderColor:"white",axisTickSize:3,axisLabelFontSize:14,rightGap:5,showRoller:!1,xValueParser:void 0,delimiter:",",sigma:2,errorBars:!1,fractions:!1,wilsonInterval:!0,customBars:!1,fillGraph:!1,fillAlpha:.15,connectSeparatedPoints:!1,stackedGraph:!1,stackedGraphNaNFill:"all",hideOverlayOnMouseOut:!0,legend:"onmouseover",stepPlot:!1,xRangePad:0,yRangePad:null,drawAxesAtZero:!1,titleHeight:28,xLabelHeight:18,yLabelWidth:18,axisLineColor:"black",axisLineWidth:.3,gridLineWidth:.3,axisLabelWidth:50,gridLineColor:"rgb(128,128,128)",interactionModel:o.default.defaultModel,animatedZooms:!1,showRangeSelector:!1,rangeSelectorHeight:40,rangeSelectorPlotStrokeColor:"#808FAB",rangeSelectorPlotFillGradientColor:"white",rangeSelectorPlotFillColor:"#A7B1C4",rangeSelectorBackgroundStrokeColor:"gray",rangeSelectorBackgroundLineWidth:1,rangeSelectorPlotLineWidth:1.5,rangeSelectorForegroundStrokeColor:"black",rangeSelectorForegroundLineWidth:1,rangeSelectorAlpha:.6,showInRangeSelector:null,plotter:[s.default._fillPlotter,s.default._errorPlotter,s.default._linePlotter],plugins:[],axes:{x:{pixelsPerLabel:70,axisLabelWidth:60,axisLabelFormatter:l.dateAxisLabelFormatter,valueFormatter:l.dateValueFormatter,drawGrid:!0,drawAxis:!0,independentTicks:!0,ticker:r.dateTicker},y:{axisLabelWidth:50,pixelsPerLabel:30,valueFormatter:l.numberValueFormatter,axisLabelFormatter:l.numberAxisLabelFormatter,drawGrid:!0,drawAxis:!0,independentTicks:!0,ticker:r.numericTicks},y2:{axisLabelWidth:50,pixelsPerLabel:30,valueFormatter:l.numberValueFormatter,axisLabelFormatter:l.numberAxisLabelFormatter,drawAxis:!0,drawGrid:!1,independentTicks:!1,ticker:r.numericTicks}}};a.default=h,e.exports=a.default},{"./dygraph-canvas":9,"./dygraph-interaction-model":12,"./dygraph-tickers":16,"./dygraph-utils":17}],11:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(t){this.container=t}var n,r=t("./dygraph"),o=(n=r)&&n.__esModule?n:{default:n};i.prototype.draw=function(t,e){this.container.innerHTML="",void 0!==this.date_graph&&this.date_graph.destroy(),this.date_graph=new o.default(this.container,t,e)},i.prototype.setSelection=function(t){var e=!1;t.length&&(e=t[0].row),this.date_graph.setSelection(e)},i.prototype.getSelection=function(){var t=[],e=this.date_graph.getSelection();if(e<0)return t;for(var a=this.date_graph.layout_.points,i=0;i<a.length;++i)t.push({row:e,column:i+1});return t},a.default=i,e.exports=a.default},{"./dygraph":18}],12:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var b=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("./dygraph-utils")),l={maybeTreatMouseOpAsClick:function(t,e,a){a.dragEndX=b.dragGetX_(t,a),a.dragEndY=b.dragGetY_(t,a);var i=Math.abs(a.dragEndX-a.dragStartX),n=Math.abs(a.dragEndY-a.dragStartY);i<2&&n<2&&void 0!==e.lastx_&&-1!=e.lastx_&&l.treatMouseOpAsClick(e,t,a),a.regionWidth=i,a.regionHeight=n},startPan:function(t,e,a){var i,n;a.isPanning=!0;var r=e.xAxisRange();if(e.getOptionForAxis("logscale","x")?(a.initialLeftmostDate=b.log10(r[0]),a.dateRange=b.log10(r[1])-b.log10(r[0])):(a.initialLeftmostDate=r[0],a.dateRange=r[1]-r[0]),a.xUnitsPerPixel=a.dateRange/(e.plotter_.area.w-1),e.getNumericOption("panEdgeFraction")){var o=e.width_*e.getNumericOption("panEdgeFraction"),s=e.xAxisExtremes(),l=e.toDomXCoord(s[0])-o,h=e.toDomXCoord(s[1])+o,u=e.toDataXCoord(l),d=e.toDataXCoord(h);a.boundedDates=[u,d];var c=[],p=e.height_*e.getNumericOption("panEdgeFraction");for(i=0;i<e.axes_.length;i++){var g=(n=e.axes_[i]).extremeRange,f=e.toDomYCoord(g[0],i)+p,_=e.toDomYCoord(g[1],i)-p,v=e.toDataYCoord(f,i),y=e.toDataYCoord(_,i);c[i]=[v,y]}a.boundedValues=c}for(a.is2DPan=!1,a.axes=[],i=0;i<e.axes_.length;i++){n=e.axes_[i];var x={},m=e.yAxisRange(i);e.attributes_.getForAxis("logscale",i)?(x.initialTopValue=b.log10(m[1]),x.dragValueRange=b.log10(m[1])-b.log10(m[0])):(x.initialTopValue=m[1],x.dragValueRange=m[1]-m[0]),x.unitsPerPixel=x.dragValueRange/(e.plotter_.area.h-1),a.axes.push(x),n.valueRange&&(a.is2DPan=!0)}},movePan:function(t,e,a){a.dragEndX=b.dragGetX_(t,a),a.dragEndY=b.dragGetY_(t,a);var i=a.initialLeftmostDate-(a.dragEndX-a.dragStartX)*a.xUnitsPerPixel;a.boundedDates&&(i=Math.max(i,a.boundedDates[0]));var n=i+a.dateRange;if(a.boundedDates&&n>a.boundedDates[1]&&(n=(i-=n-a.boundedDates[1])+a.dateRange),e.getOptionForAxis("logscale","x")?e.dateWindow_=[Math.pow(b.LOG_SCALE,i),Math.pow(b.LOG_SCALE,n)]:e.dateWindow_=[i,n],a.is2DPan)for(var r=a.dragEndY-a.dragStartY,o=0;o<e.axes_.length;o++){var s=e.axes_[o],l=a.axes[o],h=r*l.unitsPerPixel,u=a.boundedValues?a.boundedValues[o]:null,d=l.initialTopValue+h;u&&(d=Math.min(d,u[1]));var c=d-l.dragValueRange;u&&c<u[0]&&(c=(d-=c-u[0])-l.dragValueRange),e.attributes_.getForAxis("logscale",o)?s.valueRange=[Math.pow(b.LOG_SCALE,c),Math.pow(b.LOG_SCALE,d)]:s.valueRange=[c,d]}e.drawGraph_(!1)}};l.endPan=l.maybeTreatMouseOpAsClick,l.startZoom=function(t,e,a){a.isZooming=!0,a.zoomMoved=!1},l.moveZoom=function(t,e,a){a.zoomMoved=!0,a.dragEndX=b.dragGetX_(t,a),a.dragEndY=b.dragGetY_(t,a);var i=Math.abs(a.dragStartX-a.dragEndX),n=Math.abs(a.dragStartY-a.dragEndY);a.dragDirection=i<n/2?b.VERTICAL:b.HORIZONTAL,e.drawZoomRect_(a.dragDirection,a.dragStartX,a.dragEndX,a.dragStartY,a.dragEndY,a.prevDragDirection,a.prevEndX,a.prevEndY),a.prevEndX=a.dragEndX,a.prevEndY=a.dragEndY,a.prevDragDirection=a.dragDirection},l.treatMouseOpAsClick=function(t,e,a){for(var i=t.getFunctionOption("clickCallback"),n=t.getFunctionOption("pointClickCallback"),r=null,o=-1,s=Number.MAX_VALUE,l=0;l<t.selPoints_.length;l++){var h=t.selPoints_[l],u=Math.pow(h.canvasx-a.dragEndX,2)+Math.pow(h.canvasy-a.dragEndY,2);!isNaN(u)&&(-1==o||u<s)&&(s=u,o=l)}var d=t.getNumericOption("highlightCircleSize")+2;if(s<=d*d&&(r=t.selPoints_[o]),r){var c={cancelable:!0,point:r,canvasx:a.dragEndX,canvasy:a.dragEndY};if(t.cascadeEvents_("pointClick",c))return;n&&n.call(t,e,r)}c={cancelable:!0,xval:t.lastx_,pts:t.selPoints_,canvasx:a.dragEndX,canvasy:a.dragEndY};t.cascadeEvents_("click",c)||i&&i.call(t,e,t.lastx_,t.selPoints_)},l.endZoom=function(t,e,a){e.clearZoomRect_(),a.isZooming=!1,l.maybeTreatMouseOpAsClick(t,e,a);var i=e.getArea();if(10<=a.regionWidth&&a.dragDirection==b.HORIZONTAL){var n=Math.min(a.dragStartX,a.dragEndX),r=Math.max(a.dragStartX,a.dragEndX);(n=Math.max(n,i.x))<(r=Math.min(r,i.x+i.w))&&e.doZoomX_(n,r),a.cancelNextDblclick=!0}else if(10<=a.regionHeight&&a.dragDirection==b.VERTICAL){var o=Math.min(a.dragStartY,a.dragEndY),s=Math.max(a.dragStartY,a.dragEndY);(o=Math.max(o,i.y))<(s=Math.min(s,i.y+i.h))&&e.doZoomY_(o,s),a.cancelNextDblclick=!0}a.dragStartX=null,a.dragStartY=null},l.startTouch=function(t,e,a){t.preventDefault(),1<t.touches.length&&(a.startTimeForDoubleTapMs=null);for(var i=[],n=0;n<t.touches.length;n++){var r=t.touches[n];i.push({pageX:r.pageX,pageY:r.pageY,dataX:e.toDataXCoord(r.pageX),dataY:e.toDataYCoord(r.pageY)})}if(1==(a.initialTouches=i).length)a.initialPinchCenter=i[0],a.touchDirections={x:!0,y:!0};else if(2<=i.length){a.initialPinchCenter={pageX:.5*(i[0].pageX+i[1].pageX),pageY:.5*(i[0].pageY+i[1].pageY),dataX:.5*(i[0].dataX+i[1].dataX),dataY:.5*(i[0].dataY+i[1].dataY)};var o=180/Math.PI*Math.atan2(a.initialPinchCenter.pageY-i[0].pageY,i[0].pageX-a.initialPinchCenter.pageX);90<(o=Math.abs(o))&&(o=90-o),a.touchDirections={x:o<67.5,y:22.5<o}}a.initialRange={x:e.xAxisRange(),y:e.yAxisRange()}},l.moveTouch=function(t,e,a){a.startTimeForDoubleTapMs=null;var i,n=[];for(i=0;i<t.touches.length;i++){var r=t.touches[i];n.push({pageX:r.pageX,pageY:r.pageY})}var o,s,l,h=a.initialTouches,u=a.initialPinchCenter,d={pageX:(o=1==n.length?n[0]:{pageX:.5*(n[0].pageX+n[1].pageX),pageY:.5*(n[0].pageY+n[1].pageY)}).pageX-u.pageX,pageY:o.pageY-u.pageY},c=a.initialRange.x[1]-a.initialRange.x[0],p=a.initialRange.y[0]-a.initialRange.y[1];if(d.dataX=d.pageX/e.plotter_.area.w*c,d.dataY=d.pageY/e.plotter_.area.h*p,1==n.length)l=s=1;else if(2<=n.length){var g=h[1].pageX-u.pageX;s=(n[1].pageX-o.pageX)/g;var f=h[1].pageY-u.pageY;l=(n[1].pageY-o.pageY)/f}s=Math.min(8,Math.max(.125,s)),l=Math.min(8,Math.max(.125,l));var _=!1;if(a.touchDirections.x&&(e.dateWindow_=[u.dataX-d.dataX+(a.initialRange.x[0]-u.dataX)/s,u.dataX-d.dataX+(a.initialRange.x[1]-u.dataX)/s],_=!0),a.touchDirections.y)for(i=0;i<1;i++){var v=e.axes_[i];e.attributes_.getForAxis("logscale",i)||(v.valueRange=[u.dataY-d.dataY+(a.initialRange.y[0]-u.dataY)/l,u.dataY-d.dataY+(a.initialRange.y[1]-u.dataY)/l],_=!0)}if(e.drawGraph_(!1),_&&1<n.length&&e.getFunctionOption("zoomCallback")){var y=e.xAxisRange();e.getFunctionOption("zoomCallback").call(e,y[0],y[1],e.yAxisRanges())}},l.endTouch=function(t,e,a){if(0!==t.touches.length)l.startTouch(t,e,a);else if(1==t.changedTouches.length){var i=(new Date).getTime(),n=t.changedTouches[0];a.startTimeForDoubleTapMs&&i-a.startTimeForDoubleTapMs<500&&a.doubleTapX&&Math.abs(a.doubleTapX-n.screenX)<50&&a.doubleTapY&&Math.abs(a.doubleTapY-n.screenY)<50?e.resetZoom():(a.startTimeForDoubleTapMs=i,a.doubleTapX=n.screenX,a.doubleTapY=n.screenY)}};function s(t,e,a){return t<e?e-t:a<t?t-a:0}l.defaultModel={mousedown:function(t,a,i){if(!t.button||2!=t.button){i.initializeMouseDown(t,a,i),t.altKey||t.shiftKey?l.startPan(t,a,i):l.startZoom(t,a,i);var n=function(t){i.isZooming?function(t,e){var a=b.findPos(e.canvas_),i={left:a.x,right:a.x+e.canvas_.offsetWidth,top:a.y,bottom:a.y+e.canvas_.offsetHeight},n={x:b.pageX(t),y:b.pageY(t)},r=s(n.x,i.left,i.right),o=s(n.y,i.top,i.bottom);return Math.max(r,o)}(t,a)<100?l.moveZoom(t,a,i):null!==i.dragEndX&&(i.dragEndX=null,i.dragEndY=null,a.clearZoomRect_()):i.isPanning&&l.movePan(t,a,i)};a.addAndTrackEvent(document,"mousemove",n),a.addAndTrackEvent(document,"mouseup",function t(e){i.isZooming?null!==i.dragEndX?l.endZoom(e,a,i):l.maybeTreatMouseOpAsClick(e,a,i):i.isPanning&&l.endPan(e,a,i),b.removeEvent(document,"mousemove",n),b.removeEvent(document,"mouseup",t),i.destroy()})}},willDestroyContextMyself:!0,touchstart:function(t,e,a){l.startTouch(t,e,a)},touchmove:function(t,e,a){l.moveTouch(t,e,a)},touchend:function(t,e,a){l.endTouch(t,e,a)},dblclick:function(t,e,a){if(a.cancelNextDblclick)a.cancelNextDblclick=!1;else{var i={canvasx:a.dragEndX,canvasy:a.dragEndY,cancelable:!0};e.cascadeEvents_("dblclick",i)||t.altKey||t.shiftKey||e.resetZoom()}}},l.nonInteractiveModel_={mousedown:function(t,e,a){a.initializeMouseDown(t,e,a)},mouseup:l.maybeTreatMouseOpAsClick},l.dragIsPanInteractionModel={mousedown:function(t,e,a){a.initializeMouseDown(t,e,a),l.startPan(t,e,a)},mousemove:function(t,e,a){a.isPanning&&l.movePan(t,e,a)},mouseup:function(t,e,a){a.isPanning&&l.endPan(t,e,a)}},a.default=l,e.exports=a.default},{"./dygraph-utils":17}],13:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function d(t){this.dygraph_=t,this.points=[],this.setNames=[],this.annotations=[],this.yAxes_=null,this.xTicks_=null,this.yTicks_=null}var n=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("./dygraph-utils"));d.prototype.addDataset=function(t,e){this.points.push(e),this.setNames.push(t)},d.prototype.getPlotArea=function(){return this.area_},d.prototype.computePlotArea=function(){var a={x:0,y:0};a.w=this.dygraph_.width_-a.x-this.dygraph_.getOption("rightGap"),a.h=this.dygraph_.height_;var t={chart_div:this.dygraph_.graphDiv,reserveSpaceLeft:function(t){var e={x:a.x,y:a.y,w:t,h:a.h};return a.x+=t,a.w-=t,e},reserveSpaceRight:function(t){var e={x:a.x+a.w-t,y:a.y,w:t,h:a.h};return a.w-=t,e},reserveSpaceTop:function(t){var e={x:a.x,y:a.y,w:a.w,h:t};return a.y+=t,a.h-=t,e},reserveSpaceBottom:function(t){var e={x:a.x,y:a.y+a.h-t,w:a.w,h:t};return a.h-=t,e},chartRect:function(){return{x:a.x,y:a.y,w:a.w,h:a.h}}};this.dygraph_.cascadeEvents_("layout",t),this.area_=a},d.prototype.setAnnotations=function(t){this.annotations=[];for(var e=this.dygraph_.getOption("xValueParser")||function(t){return t},a=0;a<t.length;a++){var i={};if(!t[a].xval&&void 0===t[a].x)return void console.error("Annotations must have an 'x' property");if(t[a].icon&&(!t[a].hasOwnProperty("width")||!t[a].hasOwnProperty("height")))return void console.error("Must set width and height when setting annotation.icon property");n.update(i,t[a]),i.xval||(i.xval=e(i.x)),this.annotations.push(i)}},d.prototype.setXTicks=function(t){this.xTicks_=t},d.prototype.setYAxes=function(t){this.yAxes_=t},d.prototype.evaluate=function(){this._xAxis={},this._evaluateLimits(),this._evaluateLineCharts(),this._evaluateLineTicks(),this._evaluateAnnotations()},d.prototype._evaluateLimits=function(){var t=this.dygraph_.xAxisRange();this._xAxis.minval=t[0],this._xAxis.maxval=t[1];var e=t[1]-t[0];this._xAxis.scale=0!=e?1/e:1,this.dygraph_.getOptionForAxis("logscale","x")&&(this._xAxis.xlogrange=n.log10(this._xAxis.maxval)-n.log10(this._xAxis.minval),this._xAxis.xlogscale=0!==this._xAxis.xlogrange?1/this._xAxis.xlogrange:1);for(var a=0;a<this.yAxes_.length;a++){var i=this.yAxes_[a];i.minyval=i.computedValueRange[0],i.maxyval=i.computedValueRange[1],i.yrange=i.maxyval-i.minyval,i.yscale=0!==i.yrange?1/i.yrange:1,this.dygraph_.getOption("logscale")&&(i.ylogrange=n.log10(i.maxyval)-n.log10(i.minyval),i.ylogscale=0!==i.ylogrange?1/i.ylogrange:1,isFinite(i.ylogrange)&&!isNaN(i.ylogrange)||console.error("axis "+a+" of graph at "+i.g+" can't be displayed in log scale for range ["+i.minyval+" - "+i.maxyval+"]"))}},d.calcXNormal_=function(t,e,a){return a?(n.log10(t)-n.log10(e.minval))*e.xlogscale:(t-e.minval)*e.scale},d.calcYNormal_=function(t,e,a){if(a){var i=1-(n.log10(e)-n.log10(t.minyval))*t.ylogscale;return isFinite(i)?i:NaN}return 1-(e-t.minyval)*t.yscale},d.prototype._evaluateLineCharts=function(){for(var t=this.dygraph_.getOption("stackedGraph"),e=this.dygraph_.getOptionForAxis("logscale","x"),a=0;a<this.points.length;a++){for(var i=this.points[a],n=this.setNames[a],r=this.dygraph_.getOption("connectSeparatedPoints",n),o=this.dygraph_.axisPropertiesForSeries(n),s=this.dygraph_.attributes_.getForSeries("logscale",n),l=0;l<i.length;l++){var h=i[l];h.x=d.calcXNormal_(h.xval,this._xAxis,e);var u=h.yval;t&&(h.y_stacked=d.calcYNormal_(o,h.yval_stacked,s),null===u||isNaN(u)||(u=h.yval_stacked)),null===u&&(u=NaN,r||(h.yval=NaN)),h.y=d.calcYNormal_(o,u,s)}this.dygraph_.dataHandler_.onLineEvaluated(i,o,s)}},d.prototype._evaluateLineTicks=function(){var t,e,a,i,n,r;for(this.xticks=[],t=0;t<this.xTicks_.length;t++)a=(e=this.xTicks_[t]).label,n=(r=!("label_v"in e))?e.v:e.label_v,0<=(i=this.dygraph_.toPercentXCoord(n))&&i<1&&this.xticks.push({pos:i,label:a,has_tick:r});for(this.yticks=[],t=0;t<this.yAxes_.length;t++)for(var o=this.yAxes_[t],s=0;s<o.ticks.length;s++)a=(e=o.ticks[s]).label,n=(r=!("label_v"in e))?e.v:e.label_v,0<(i=this.dygraph_.toPercentYCoord(n,t))&&i<=1&&this.yticks.push({axis:t,pos:i,label:a,has_tick:r})},d.prototype._evaluateAnnotations=function(){var t,e={};for(t=0;t<this.annotations.length;t++){var a=this.annotations[t];e[a.xval+","+a.series]=a}if(this.annotated_points=[],this.annotations&&this.annotations.length)for(var i=0;i<this.points.length;i++){var n=this.points[i];for(t=0;t<n.length;t++){var r=n[t],o=r.xval+","+r.name;o in e&&(r.annotation=e[o],this.annotated_points.push(r))}}},d.prototype.removeAllDatasets=function(){delete this.points,delete this.setNames,delete this.setPointsLengths,delete this.setPointsOffsets,this.points=[],this.setNames=[],this.setPointsLengths=[],this.setPointsOffsets=[]},a.default=d,e.exports=a.default},{"./dygraph-utils":17}],14:[function(t,e,a){(function(t){"use strict";Object.defineProperty(a,"__esModule",{value:!0});a.default=null,e.exports=a.default}).call(this,t("_process"))},{_process:1}],15:[function(a,i,n){(function(t){"use strict";function e(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(n,"__esModule",{value:!0});var s=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(a("./dygraph-utils")),l=e(a("./dygraph-default-attrs")),h=(e(a("./dygraph-options-reference")),function(t){this.dygraph_=t,this.yAxes_=[],this.xAxis_={},this.series_={},this.global_=this.dygraph_.attrs_,this.user_=this.dygraph_.user_attrs_||{},this.labels_=[],this.highlightSeries_=this.get("highlightSeriesOpts")||{},this.reparseSeries()});h.AXIS_STRING_MAPPINGS_={y:0,Y:0,y1:0,Y1:0,y2:1,Y2:1},h.axisToIndex_=function(t){if("string"==typeof t){if(h.AXIS_STRING_MAPPINGS_.hasOwnProperty(t))return h.AXIS_STRING_MAPPINGS_[t];throw"Unknown axis : "+t}if("number"==typeof t){if(0===t||1===t)return t;throw"Dygraphs only supports two y-axes, indexed from 0-1."}if(t)throw"Unknown axis : "+t;return 0},h.prototype.reparseSeries=function(){var t=this.get("labels");if(t){this.labels_=t.slice(1),this.yAxes_=[{series:[],options:{}}],this.xAxis_={options:{}},this.series_={};for(var e=this.user_.series||{},a=0;a<this.labels_.length;a++){var i=this.labels_[a],n=e[i]||{},r=h.axisToIndex_(n.axis);this.series_[i]={idx:a,yAxis:r,options:n},this.yAxes_[r]?this.yAxes_[r].series.push(i):this.yAxes_[r]={series:[i],options:{}}}var o=this.user_.axes||{};s.update(this.yAxes_[0].options,o.y||{}),1<this.yAxes_.length&&s.update(this.yAxes_[1].options,o.y2||{}),s.update(this.xAxis_.options,o.x||{})}},h.prototype.get=function(t){var e=this.getGlobalUser_(t);return null!==e?e:this.getGlobalDefault_(t)},h.prototype.getGlobalUser_=function(t){return this.user_.hasOwnProperty(t)?this.user_[t]:null},h.prototype.getGlobalDefault_=function(t){return this.global_.hasOwnProperty(t)?this.global_[t]:l.default.hasOwnProperty(t)?l.default[t]:null},h.prototype.getForAxis=function(t,e){var a,i;if("number"==typeof e)i=0===(a=e)?"y":"y2";else{if("y1"==e&&(e="y"),"y"==e)a=0;else if("y2"==e)a=1;else{if("x"!=e)throw"Unknown axis "+e;a=-1}i=e}var n=-1==a?this.xAxis_:this.yAxes_[a];if(n){var r=n.options;if(r.hasOwnProperty(t))return r[t]}if("x"!==e||"logscale"!==t){var o=this.getGlobalUser_(t);if(null!==o)return o}var s=l.default.axes[i];return s.hasOwnProperty(t)?s[t]:this.getGlobalDefault_(t)},h.prototype.getForSeries=function(t,e){if(e===this.dygraph_.getHighlightSeries()&&this.highlightSeries_.hasOwnProperty(t))return this.highlightSeries_[t];if(!this.series_.hasOwnProperty(e))throw"Unknown series: "+e;var a=this.series_[e],i=a.options;return i.hasOwnProperty(t)?i[t]:this.getForAxis(t,a.yAxis)},h.prototype.numAxes=function(){return this.yAxes_.length},h.prototype.axisForSeries=function(t){return this.series_[t].yAxis},h.prototype.axisOptions=function(t){return this.yAxes_[t].options},h.prototype.seriesForAxis=function(t){return this.yAxes_[t].series},h.prototype.seriesNames=function(){return this.labels_},n.default=h,i.exports=n.default}).call(this,a("_process"))},{"./dygraph-default-attrs":10,"./dygraph-options-reference":14,"./dygraph-utils":17,_process:1}],16:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var C=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("./dygraph-utils"));a.numericLinearTicks=function(t,e,a,i,n,r){return o(t,e,a,function(t){return"logscale"!==t&&i(t)},n,r)};var o=function(t,e,a,i,n,r){var o,s,l,h,u=i("pixelsPerLabel"),d=[];if(r)for(o=0;o<r.length;o++)d.push({v:r[o]});else{if(i("logscale")){h=Math.floor(a/u);var c=C.binarySearch(t,M,1),p=C.binarySearch(e,M,-1);-1==c&&(c=0),-1==p&&(p=M.length-1);var g=null;if(h/4<=p-c){for(var f=p;c<=f;f--){var _=M[f],v=Math.log(_/t)/Math.log(e/t)*a,y={v:_};null===g?g={tickValue:_,pixel_coord:v}:Math.abs(v-g.pixel_coord)>=u?g={tickValue:_,pixel_coord:v}:y.label="",d.push(y)}d.reverse()}}if(0===d.length){var x,m;m=i("labelsKMG2")?(x=[1,2,4,8,16,32,64,128,256],16):(x=[1,2,5,10,20,50,100],10);var b,w,A,O=Math.ceil(a/u),P=Math.abs(e-t)/O,L=Math.floor(Math.log(P)/Math.log(m)),S=Math.pow(m,L);for(s=0;s<x.length&&(b=S*x[s],w=Math.floor(t/b)*b,A=Math.ceil(e/b)*b,!(u<a/(h=Math.abs(A-w)/b)));s++);for(A<w&&(b*=-1),o=0;o<=h;o++)l=w+o*b,d.push({v:l})}}var T=i("axisLabelFormatter");for(o=0;o<d.length;o++)void 0===d[o].label&&(d[o].label=T.call(n,d[o].v,0,i,n));return d};a.numericTicks=o;a.dateTicker=function(t,e,a,i,n,r){var o=s(t,e,a,i);return 0<=o?h(t,e,o,i,n):[]};var v={MILLISECONDLY:0,TWO_MILLISECONDLY:1,FIVE_MILLISECONDLY:2,TEN_MILLISECONDLY:3,FIFTY_MILLISECONDLY:4,HUNDRED_MILLISECONDLY:5,FIVE_HUNDRED_MILLISECONDLY:6,SECONDLY:7,TWO_SECONDLY:8,FIVE_SECONDLY:9,TEN_SECONDLY:10,THIRTY_SECONDLY:11,MINUTELY:12,TWO_MINUTELY:13,FIVE_MINUTELY:14,TEN_MINUTELY:15,THIRTY_MINUTELY:16,HOURLY:17,TWO_HOURLY:18,SIX_HOURLY:19,DAILY:20,TWO_DAILY:21,WEEKLY:22,MONTHLY:23,QUARTERLY:24,BIANNUAL:25,ANNUAL:26,DECADAL:27,CENTENNIAL:28,NUM_GRANULARITIES:29};a.Granularity=v;var y=0,x=1,m=2,b=3,w=4,A=5,O=6,P=7,L=[];L[v.MILLISECONDLY]={datefield:O,step:1,spacing:1},L[v.TWO_MILLISECONDLY]={datefield:O,step:2,spacing:2},L[v.FIVE_MILLISECONDLY]={datefield:O,step:5,spacing:5},L[v.TEN_MILLISECONDLY]={datefield:O,step:10,spacing:10},L[v.FIFTY_MILLISECONDLY]={datefield:O,step:50,spacing:50},L[v.HUNDRED_MILLISECONDLY]={datefield:O,step:100,spacing:100},L[v.FIVE_HUNDRED_MILLISECONDLY]={datefield:O,step:500,spacing:500},L[v.SECONDLY]={datefield:A,step:1,spacing:1e3},L[v.TWO_SECONDLY]={datefield:A,step:2,spacing:2e3},L[v.FIVE_SECONDLY]={datefield:A,step:5,spacing:5e3},L[v.TEN_SECONDLY]={datefield:A,step:10,spacing:1e4},L[v.THIRTY_SECONDLY]={datefield:A,step:30,spacing:3e4},L[v.MINUTELY]={datefield:w,step:1,spacing:6e4},L[v.TWO_MINUTELY]={datefield:w,step:2,spacing:12e4},L[v.FIVE_MINUTELY]={datefield:w,step:5,spacing:3e5},L[v.TEN_MINUTELY]={datefield:w,step:10,spacing:6e5},L[v.THIRTY_MINUTELY]={datefield:w,step:30,spacing:18e5},L[v.HOURLY]={datefield:b,step:1,spacing:36e5},L[v.TWO_HOURLY]={datefield:b,step:2,spacing:72e5},L[v.SIX_HOURLY]={datefield:b,step:6,spacing:216e5},L[v.DAILY]={datefield:m,step:1,spacing:864e5},L[v.TWO_DAILY]={datefield:m,step:2,spacing:1728e5},L[v.WEEKLY]={datefield:m,step:7,spacing:6048e5},L[v.MONTHLY]={datefield:x,step:1,spacing:2629817280},L[v.QUARTERLY]={datefield:x,step:3,spacing:216e5*365.2524},L[v.BIANNUAL]={datefield:x,step:6,spacing:432e5*365.2524},L[v.ANNUAL]={datefield:y,step:1,spacing:864e5*365.2524},L[v.DECADAL]={datefield:y,step:10,spacing:315578073600},L[v.CENTENNIAL]={datefield:y,step:100,spacing:3155780736e3};var M=function(){for(var t=[],e=-39;e<=39;e++)for(var a=Math.pow(10,e),i=1;i<=9;i++){var n=a*i;t.push(n)}return t}(),s=function(t,e,a,i){for(var n=i("pixelsPerLabel"),r=0;r<v.NUM_GRANULARITIES;r++)if(a/l(t,e,r)>=n)return r;return-1},l=function(t,e,a){var i=L[a].spacing;return Math.round(1*(e-t)/i)},h=function(t,e,a,i,n){var r=i("axisLabelFormatter"),o=i("labelsUTC")?C.DateAccessorsUTC:C.DateAccessorsLocal,s=L[a].datefield,l=L[a].step,h=L[a].spacing,u=new Date(t),d=[];d[y]=o.getFullYear(u),d[x]=o.getMonth(u),d[m]=o.getDate(u),d[b]=o.getHours(u),d[w]=o.getMinutes(u),d[A]=o.getSeconds(u),d[O]=o.getMilliseconds(u);var c=d[s]%l;a==v.WEEKLY&&(c=o.getDay(u)),d[s]-=c;for(var p=s+1;p<P;p++)d[p]=p===m?1:0;var g=[],f=o.makeDate.apply(null,d),_=f.getTime();if(a<=v.HOURLY)for(_<t&&(_+=h,f=new Date(_));_<=e;)g.push({v:_,label:r.call(n,f,a,i,n)}),_+=h,f=new Date(_);else for(_<t&&(d[s]+=l,_=(f=o.makeDate.apply(null,d)).getTime());_<=e;)(v.DAILY<=a||o.getHours(f)%l==0)&&g.push({v:_,label:r.call(n,f,a,i,n)}),d[s]+=l,_=(f=o.makeDate.apply(null,d)).getTime();return g};a.getDateAxis=h},{"./dygraph-utils":17}],17:[function(t,e,a){"use strict";function i(t){return!t.pageX||t.pageX<0?0:t.pageX}function n(t){return!t.pageY||t.pageY<0?0:t.pageY}function f(t,e){var a=Math.min(Math.max(1,e||2),21);return Math.abs(t)<.001&&0!==t?t.toExponential(a-1):t.toPrecision(a)}function c(t){return t<10?"0"+t:""+t}function p(t,e,a,i){var n=c(t)+":"+c(e);if(a&&(n+=":"+c(a),i)){var r=""+i;n+="."+("000"+r).substring(r.length)}return n}function r(t,e){var a=e?m:x,i=new Date(t),n=a.getFullYear(i),r=a.getMonth(i),o=a.getDate(i),s=a.getHours(i),l=a.getMinutes(i),h=a.getSeconds(i),u=a.getMilliseconds(i),d=""+n+"/"+c(r+1)+"/"+c(o);return 3600*s+60*l+h+.001*u&&(d+=" "+p(s,l,h,u)),d}function _(t,e){var a=Math.pow(10,e);return Math.round(t*a)/a}function o(t){return new Date(t).getTime()}function s(t){var e=typeof t;return("object"==e||"function"==e&&"function"==typeof t.item)&&null!==t&&"number"==typeof t.length&&3!==t.nodeType}function l(t,e,a,i){e=e||0,a=a||t.length,this.hasNext=!0,this.peek=null,this.start_=e,this.array_=t,this.predicate_=i,this.end_=Math.min(t.length,e+a),this.nextIdx_=e-1,this.next()}function v(t,e){return e<0?1/Math.pow(t,-e):Math.pow(t,e)}function h(t){var e=O.exec(t);if(!e)return null;var a=parseInt(e[1],10),i=parseInt(e[2],10),n=parseInt(e[3],10);return e[4]?{r:a,g:i,b:n,a:parseFloat(e[4])}:{r:a,g:i,b:n}}function u(t,e){var a=e("sigFigs");if(null!==a)return f(t,a);var i,n=e("digitsAfterDecimal"),r=e("maxNumberWidth"),o=e("labelsKMB"),s=e("labelsKMG2");if(i=0!==t&&(Math.abs(t)>=Math.pow(10,r)||Math.abs(t)<Math.pow(10,-n))?t.toExponential(n):""+_(t,n),o||s){var l,h=[],u=[];o&&(l=1e3,h=P),s&&(o&&console.warn("Setting both labelsKMB and labelsKMG2. Pick one!"),l=1024,h=L,u=S);for(var d=Math.abs(t),c=v(l,h.length),p=h.length-1;0<=p;p--,c/=l)if(c<=d){i=_(t/c,n)+h[p];break}if(s){var g=String(t.toExponential()).split("e-");2===g.length&&3<=g[1]&&g[1]<=24&&(i=0<g[1]%3?_(g[0]/v(10,g[1]%3),n):Number(g[0]).toFixed(2),i+=u[Math.floor(g[1]/3)-1])}}return i}Object.defineProperty(a,"__esModule",{value:!0}),a.removeEvent=function(t,e,a){t.removeEventListener(e,a,!1)},a.cancelEvent=function(t){return(t=t||window.event).stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),t.cancelBubble=!0,t.cancel=!0,t.returnValue=!1},a.hsvToRGB=function(t,e,a){var i,n,r;if(0===e)r=n=i=a;else{var o=Math.floor(6*t),s=6*t-o,l=a*(1-e),h=a*(1-e*s),u=a*(1-e*(1-s));switch(o){case 1:i=h,n=a,r=l;break;case 2:i=l,n=a,r=u;break;case 3:i=l,n=h,r=a;break;case 4:i=u,n=l,r=a;break;case 5:i=a,n=l,r=h;break;case 6:case 0:i=a,n=u,r=l}}return"rgb("+(i=Math.floor(255*i+.5))+","+(n=Math.floor(255*n+.5))+","+(r=Math.floor(255*r+.5))+")"},a.findPos=function(t){var e=t.getBoundingClientRect(),a=window,i=document.documentElement;return{x:e.left+(a.pageXOffset||i.scrollLeft),y:e.top+(a.pageYOffset||i.scrollTop)}},a.pageX=i,a.pageY=n,a.dragGetX_=function(t,e){return i(t)-e.px},a.dragGetY_=function(t,e){return n(t)-e.py},a.isOK=function(t){return!!t&&!isNaN(t)},a.isValidPoint=function(t,e){return!!t&&null!==t.yval&&null!==t.x&&void 0!==t.x&&null!==t.y&&void 0!==t.y&&!(isNaN(t.x)||!e&&isNaN(t.y))},a.floatFormat=f,a.zeropad=c,a.hmsString_=p,a.dateString_=r,a.round_=_,a.binarySearch=function(t,e,a,i,n){for(var r=!0;r;){var o=t,s=e,l=a,h=i,u=n;if(r=!1,null!=h&&null!=u||(h=0,u=s.length-1),u<h)return-1;null!=l||(l=0);var d,c=function(t){return 0<=t&&t<s.length},p=parseInt((h+u)/2,10),g=s[p];if(g==o)return p;if(o<g){if(0<l&&c(d=p-1)&&s[d]<o)return p;t=o,e=s,a=l,i=h,n=p-1,r=!0,c=p=g=d=void 0}else{if(!(g<o))return-1;if(l<0&&c(d=p+1)&&s[d]>o)return p;t=o,e=s,a=l,i=p+1,n=u,r=!0,c=p=g=d=void 0}}},a.dateParser=function(t){var e,a;if((-1==t.search("-")||-1!=t.search("T")||-1!=t.search("Z"))&&(a=o(t))&&!isNaN(a))return a;if(-1!=t.search("-")){for(e=t.replace("-","/","g");-1!=e.search("-");)e=e.replace("-","/");a=o(e)}else a=8==t.length?o(e=t.substr(0,4)+"/"+t.substr(4,2)+"/"+t.substr(6,2)):o(t);return a&&!isNaN(a)||console.error("Couldn't parse "+t+" as a date"),a},a.dateStrToMillis=o,a.update=function(t,e){if(null!=e)for(var a in e)e.hasOwnProperty(a)&&(t[a]=e[a]);return t},a.updateDeep=function t(e,a){if(null!=a)for(var i in a)a.hasOwnProperty(i)&&(null===a[i]?e[i]=null:s(a[i])?e[i]=a[i].slice():(n=a[i],("object"==typeof Node?n instanceof Node:"object"==typeof n&&"number"==typeof n.nodeType&&"string"==typeof n.nodeName)||"object"!=typeof a[i]?e[i]=a[i]:("object"==typeof e[i]&&null!==e[i]||(e[i]={}),t(e[i],a[i]))));var n;return e},a.isArrayLike=s,a.isDateLike=function(t){return"object"==typeof t&&null!==t&&"function"==typeof t.getTime},a.clone=function t(e){for(var a=[],i=0;i<e.length;i++)s(e[i])?a.push(t(e[i])):a.push(e[i]);return a},a.createCanvas=function(){return document.createElement("canvas")},a.getContextPixelRatio=function(t){try{var e=window.devicePixelRatio,a=t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1;return void 0!==e?e/a:1}catch(t){return 1}},a.Iterator=l,a.createIterator=function(t,e,a,i){return new l(t,e,a,i)},a.repeatAndCleanup=function(i,t,n,r){var o,s=0,l=(new Date).getTime();if(i(s),1!=t){var h=t-1;!function a(){t<=s||b.call(window,function(){var t=(new Date).getTime()-l;o=s;var e=(s=Math.floor(t/n))-o;h<s+e||h<=s?(i(h),r()):(0!=e&&i(s),a())})}()}else r()},a.isPixelChangingOptionList=function(t,e){var a={};if(t)for(var i=1;i<t.length;i++)a[t[i]]=!0;function n(t){for(var e in t)if(t.hasOwnProperty(e)&&!w[e])return!0;return!1}for(var r in e)if(e.hasOwnProperty(r))if("highlightSeriesOpts"==r||a[r]&&!e.series){if(n(e[r]))return!0}else if("series"==r||"axes"==r){var o=e[r];for(var s in o)if(o.hasOwnProperty(s)&&n(o[s]))return!0}else if(!w[r])return!0;return!1},a.detectLineDelimiter=function(t){for(var e=0;e<t.length;e++){var a=t.charAt(e);if("\r"===a)return e+1<t.length&&"\n"===t.charAt(e+1)?"\r\n":a;if("\n"===a)return e+1<t.length&&"\r"===t.charAt(e+1)?"\n\r":a}return null},a.isNodeContainedBy=function(t,e){if(null===e||null===t)return!1;for(var a=t;a&&a!==e;)a=a.parentNode;return a===e},a.pow=v,a.toRGB_=function(t){var e=h(t);if(e)return e;var a=document.createElement("div");a.style.backgroundColor=t,a.style.visibility="hidden",document.body.appendChild(a);var i=window.getComputedStyle(a,null).backgroundColor;return document.body.removeChild(a),h(i)},a.isCanvasSupported=function(t){try{(t||document.createElement("canvas")).getContext("2d")}catch(t){return!1}return!0},a.parseFloat_=function(t,e,a){var i=parseFloat(t);if(!isNaN(i))return i;if(/^ *$/.test(t))return null;if(/^ *nan *$/i.test(t))return NaN;var n="Unable to parse '"+t+"' as a number";return void 0!==a&&void 0!==e&&(n+=" on line "+(1+(e||0))+" ('"+a+"') of CSV."),console.error(n),null},a.numberValueFormatter=u,a.numberAxisLabelFormatter=function(t,e,a){return u.call(this,t,a)},a.dateAxisLabelFormatter=function(t,e,a){var i=a("labelsUTC")?m:x,n=i.getFullYear(t),r=i.getMonth(t),o=i.getDate(t),s=i.getHours(t),l=i.getMinutes(t),h=i.getSeconds(t),u=i.getMilliseconds(t);if(e>=g.Granularity.DECADAL)return""+n;if(e>=g.Granularity.MONTHLY)return T[r]+"&#160;"+n;if(0===3600*s+60*l+h+.001*u||e>=g.Granularity.DAILY)return c(o)+"&#160;"+T[r];if(e<g.Granularity.SECONDLY){var d=""+u;return c(h)+"."+("000"+d).substring(d.length)}return e>g.Granularity.MINUTELY?p(s,l,h,0):p(s,l,h,u)},a.dateValueFormatter=function(t,e){return r(t,e("labelsUTC"))};var g=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("./dygraph-tickers"));a.LOG_SCALE=10;var d=Math.log(10);a.LN_TEN=d;function y(t){return Math.log(t)/d}a.log10=y;a.logRangeFraction=function(t,e,a){var i=y(t),n=i+a*(y(e)-i);return Math.pow(10,n)};a.DOTTED_LINE=[2,2];a.DASHED_LINE=[7,3];a.DOT_DASH_LINE=[7,2,2,2],a.HORIZONTAL=1,a.VERTICAL=2;a.getContext=function(t){return t.getContext("2d")};a.addEvent=function(t,e,a){t.addEventListener(e,a,!1)};var x={getFullYear:function(t){return t.getFullYear()},getMonth:function(t){return t.getMonth()},getDate:function(t){return t.getDate()},getHours:function(t){return t.getHours()},getMinutes:function(t){return t.getMinutes()},getSeconds:function(t){return t.getSeconds()},getMilliseconds:function(t){return t.getMilliseconds()},getDay:function(t){return t.getDay()},makeDate:function(t,e,a,i,n,r,o){return new Date(t,e,a,i,n,r,o)}};a.DateAccessorsLocal=x;var m={getFullYear:function(t){return t.getUTCFullYear()},getMonth:function(t){return t.getUTCMonth()},getDate:function(t){return t.getUTCDate()},getHours:function(t){return t.getUTCHours()},getMinutes:function(t){return t.getUTCMinutes()},getSeconds:function(t){return t.getUTCSeconds()},getMilliseconds:function(t){return t.getUTCMilliseconds()},getDay:function(t){return t.getUTCDay()},makeDate:function(t,e,a,i,n,r,o){return new Date(Date.UTC(t,e,a,i,n,r,o))}};a.DateAccessorsUTC=m,l.prototype.next=function(){if(!this.hasNext)return null;for(var t=this.peek,e=this.nextIdx_+1,a=!1;e<this.end_;){if(!this.predicate_||this.predicate_(this.array_,e)){this.peek=this.array_[e],a=!0;break}e++}return this.nextIdx_=e,a||(this.hasNext=!1,this.peek=null),t};var b=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)};a.requestAnimFrame=b;var w={annotationClickHandler:!0,annotationDblClickHandler:!0,annotationMouseOutHandler:!0,annotationMouseOverHandler:!0,axisLineColor:!0,axisLineWidth:!0,clickCallback:!0,drawCallback:!0,drawHighlightPointCallback:!0,drawPoints:!0,drawPointCallback:!0,drawGrid:!0,fillAlpha:!0,gridLineColor:!0,gridLineWidth:!0,hideOverlayOnMouseOut:!0,highlightCallback:!0,highlightCircleSize:!0,interactionModel:!0,labelsDiv:!0,labelsKMB:!0,labelsKMG2:!0,labelsSeparateLines:!0,labelsShowZeroValues:!0,legend:!0,panEdgeFraction:!0,pixelsPerYLabel:!0,pointClickCallback:!0,pointSize:!0,rangeSelectorPlotFillColor:!0,rangeSelectorPlotFillGradientColor:!0,rangeSelectorPlotStrokeColor:!0,rangeSelectorBackgroundStrokeColor:!0,rangeSelectorBackgroundLineWidth:!0,rangeSelectorPlotLineWidth:!0,rangeSelectorForegroundStrokeColor:!0,rangeSelectorForegroundLineWidth:!0,rangeSelectorAlpha:!0,showLabelsOnHighlight:!0,showRoller:!0,strokeWidth:!0,underlayCallback:!0,unhighlightCallback:!0,zoomCallback:!0},A={DEFAULT:function(t,e,a,i,n,r,o){a.beginPath(),a.fillStyle=r,a.arc(i,n,o,0,2*Math.PI,!1),a.fill()}};a.Circles=A;var O=/^rgba?\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})(?:,\s*([01](?:\.\d+)?))?\)$/,P=["K","M","B","T","Q"],L=["k","M","G","T","P","E","Z","Y"],S=["m","u","n","p","f","a","z","y"],T=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]},{"./dygraph-tickers":16}],18:[function(P,L,S){(function(t){"use strict";function e(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}function a(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(S,"__esModule",{value:!0});function m(t,e,a){this.__init__(t,e,a)}var g=function(t,e){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return function(t,e){var a=[],i=!0,n=!1,r=void 0;try{for(var o,s=t[Symbol.iterator]();!(i=(o=s.next()).done)&&(a.push(o.value),!e||a.length!==e);i=!0);}catch(t){n=!0,r=t}finally{try{!i&&s.return&&s.return()}finally{if(n)throw r}}return a}(t,e);throw new TypeError("Invalid attempt to destructure non-iterable instance")},n=a(P("./dygraph-layout")),r=a(P("./dygraph-canvas")),p=a(P("./dygraph-options")),i=a(P("./dygraph-interaction-model")),x=e(P("./dygraph-tickers")),k=e(P("./dygraph-utils")),f=a(P("./dygraph-default-attrs")),o=a((a(P("./dygraph-options-reference")),P("./iframe-tarp"))),s=a(P("./datahandler/default")),l=a(P("./datahandler/bars-error")),h=a(P("./datahandler/bars-custom")),u=a(P("./datahandler/default-fractions")),d=a(P("./datahandler/bars-fractions")),c=a(P("./datahandler/bars")),_=a(P("./plugins/annotations")),v=a(P("./plugins/axes")),y=a(P("./plugins/chart-labels")),b=a(P("./plugins/grid")),w=a(P("./plugins/legend")),A=a(P("./plugins/range-selector")),O=a(P("./dygraph-gviz"));m.NAME="Dygraph",m.VERSION="2.0.0",m.DEFAULT_ROLL_PERIOD=1,m.DEFAULT_WIDTH=480,m.DEFAULT_HEIGHT=320,m.ANIMATION_STEPS=12,m.ANIMATION_DURATION=200,m.Plotters=r.default._Plotters,m.addedAnnotationCSS=!1,m.prototype.__init__=function(t,e,a){if(this.is_initial_draw_=!0,this.readyFns_=[],null!=a||(a={}),a=m.copyUserAttrs_(a),"string"==typeof t&&(t=document.getElementById(t)),!t)throw new Error("Constructing dygraph with a non-existent div!");this.maindiv_=t,this.file_=e,this.rollPeriod_=a.rollPeriod||m.DEFAULT_ROLL_PERIOD,this.previousVerticalX_=-1,this.fractions_=a.fractions||!1,this.dateWindow_=a.dateWindow||null,this.annotations_=[],(t.innerHTML="")===t.style.width&&a.width&&(t.style.width=a.width+"px"),""===t.style.height&&a.height&&(t.style.height=a.height+"px"),""===t.style.height&&0===t.clientHeight&&(t.style.height=m.DEFAULT_HEIGHT+"px",""===t.style.width&&(t.style.width=m.DEFAULT_WIDTH+"px")),this.width_=t.clientWidth||a.width||0,this.height_=t.clientHeight||a.height||0,a.stackedGraph&&(a.fillGraph=!0),this.user_attrs_={},k.update(this.user_attrs_,a),this.attrs_={},k.updateDeep(this.attrs_,f.default),this.boundaryIds_=[],this.setIndexByName_={},this.datasetIndex_=[],this.registeredEvents_=[],this.eventListeners_={},this.attributes_=new p.default(this),this.createInterface_(),this.plugins_=[];for(var i=m.PLUGINS.concat(this.getOption("plugins")),n=0;n<i.length;n++){var r,o=i[n],s={plugin:r=void 0!==o.activate?o:new o,events:{},options:{},pluginOptions:{}},l=r.activate(this);for(var h in l)l.hasOwnProperty(h)&&(s.events[h]=l[h]);this.plugins_.push(s)}for(n=0;n<this.plugins_.length;n++){var u=this.plugins_[n];for(var h in u.events)if(u.events.hasOwnProperty(h)){var d=u.events[h],c=[u.plugin,d];h in this.eventListeners_?this.eventListeners_[h].push(c):this.eventListeners_[h]=[c]}}this.createDragInterface_(),this.start_()},m.prototype.cascadeEvents_=function(t,e){if(!(t in this.eventListeners_))return!1;var a={dygraph:this,cancelable:!1,defaultPrevented:!1,preventDefault:function(){if(!a.cancelable)throw"Cannot call preventDefault on non-cancelable event.";a.defaultPrevented=!0},propagationStopped:!1,stopPropagation:function(){a.propagationStopped=!0}};k.update(a,e);var i=this.eventListeners_[t];if(i)for(var n=i.length-1;0<=n;n--){var r=i[n][0];if(i[n][1].call(r,a),a.propagationStopped)break}return a.defaultPrevented},m.prototype.getPluginInstance_=function(t){for(var e=0;e<this.plugins_.length;e++){var a=this.plugins_[e];if(a.plugin instanceof t)return a.plugin}return null},m.prototype.isZoomed=function(t){var e=!!this.dateWindow_;if("x"===t)return e;var a=0<=this.axes_.map(function(t){return!!t.valueRange}).indexOf(!0);if(null==t)return e||a;if("y"===t)return a;throw new Error("axis parameter is ["+t+"] must be null, 'x' or 'y'.")},m.prototype.toString=function(){var t=this.maindiv_;return"[Dygraph "+(t&&t.id?t.id:t)+"]"},m.prototype.attr_=function(t,e){return e?this.attributes_.getForSeries(t,e):this.attributes_.get(t)},m.prototype.getOption=function(t,e){return this.attr_(t,e)},m.prototype.getNumericOption=function(t,e){return this.getOption(t,e)},m.prototype.getStringOption=function(t,e){return this.getOption(t,e)},m.prototype.getBooleanOption=function(t,e){return this.getOption(t,e)},m.prototype.getFunctionOption=function(t,e){return this.getOption(t,e)},m.prototype.getOptionForAxis=function(t,e){return this.attributes_.getForAxis(t,e)},m.prototype.optionsViewForAxis_=function(a){var i=this;return function(t){var e=i.user_attrs_.axes;return e&&e[a]&&e[a].hasOwnProperty(t)?e[a][t]:("x"!==a||"logscale"!==t)&&(void 0!==i.user_attrs_[t]?i.user_attrs_[t]:(e=i.attrs_.axes)&&e[a]&&e[a].hasOwnProperty(t)?e[a][t]:"y"==a&&i.axes_[0].hasOwnProperty(t)?i.axes_[0][t]:"y2"==a&&i.axes_[1].hasOwnProperty(t)?i.axes_[1][t]:i.attr_(t))}},m.prototype.rollPeriod=function(){return this.rollPeriod_},m.prototype.xAxisRange=function(){return this.dateWindow_?this.dateWindow_:this.xAxisExtremes()},m.prototype.xAxisExtremes=function(){var t=this.getNumericOption("xRangePad")/this.plotter_.area.w;if(0===this.numRows())return[0-t,1+t];var e=this.rawData_[0][0],a=this.rawData_[this.rawData_.length-1][0];if(t){var i=a-e;e-=i*t,a+=i*t}return[e,a]},m.prototype.yAxisExtremes=function(){var t=this.gatherDatasets_(this.rolledSeries_,null).extremes,e=this.axes_;this.computeYAxisRanges_(t);var a=this.axes_;return this.axes_=e,a.map(function(t){return t.extremeRange})},m.prototype.yAxisRange=function(t){if(void 0===t&&(t=0),t<0||t>=this.axes_.length)return null;var e=this.axes_[t];return[e.computedValueRange[0],e.computedValueRange[1]]},m.prototype.yAxisRanges=function(){for(var t=[],e=0;e<this.axes_.length;e++)t.push(this.yAxisRange(e));return t},m.prototype.toDomCoords=function(t,e,a){return[this.toDomXCoord(t),this.toDomYCoord(e,a)]},m.prototype.toDomXCoord=function(t){if(null===t)return null;var e=this.plotter_.area,a=this.xAxisRange();return e.x+(t-a[0])/(a[1]-a[0])*e.w},m.prototype.toDomYCoord=function(t,e){var a=this.toPercentYCoord(t,e);if(null===a)return null;var i=this.plotter_.area;return i.y+a*i.h},m.prototype.toDataCoords=function(t,e,a){return[this.toDataXCoord(t),this.toDataYCoord(e,a)]},m.prototype.toDataXCoord=function(t){if(null===t)return null;var e=this.plotter_.area,a=this.xAxisRange();if(this.attributes_.getForAxis("logscale","x")){var i=(t-e.x)/e.w;return k.logRangeFraction(a[0],a[1],i)}return a[0]+(t-e.x)/e.w*(a[1]-a[0])},m.prototype.toDataYCoord=function(t,e){if(null===t)return null;var a=this.plotter_.area,i=this.yAxisRange(e);if(void 0===e&&(e=0),this.attributes_.getForAxis("logscale",e)){var n=(t-a.y)/a.h;return k.logRangeFraction(i[1],i[0],n)}return i[0]+(a.y+a.h-t)/a.h*(i[1]-i[0])},m.prototype.toPercentYCoord=function(t,e){if(null===t)return null;void 0===e&&(e=0);var a,i=this.yAxisRange(e);if(this.attributes_.getForAxis("logscale",e)){var n=k.log10(i[0]),r=k.log10(i[1]);a=(r-k.log10(t))/(r-n)}else a=(i[1]-t)/(i[1]-i[0]);return a},m.prototype.toPercentXCoord=function(t){if(null===t)return null;var e,a=this.xAxisRange();if(!0===this.attributes_.getForAxis("logscale","x")){var i=k.log10(a[0]),n=k.log10(a[1]);e=(k.log10(t)-i)/(n-i)}else e=(t-a[0])/(a[1]-a[0]);return e},m.prototype.numColumns=function(){return this.rawData_?this.rawData_[0]?this.rawData_[0].length:this.attr_("labels").length:0},m.prototype.numRows=function(){return this.rawData_?this.rawData_.length:0},m.prototype.getValue=function(t,e){return t<0||t>this.rawData_.length?null:e<0||e>this.rawData_[t].length?null:this.rawData_[t][e]},m.prototype.createInterface_=function(){var t=this.maindiv_;this.graphDiv=document.createElement("div"),this.graphDiv.style.textAlign="left",this.graphDiv.style.position="relative",t.appendChild(this.graphDiv),this.canvas_=k.createCanvas(),this.canvas_.style.position="absolute",this.hidden_=this.createPlotKitCanvas_(this.canvas_),this.canvas_ctx_=k.getContext(this.canvas_),this.hidden_ctx_=k.getContext(this.hidden_),this.resizeElements_(),this.graphDiv.appendChild(this.hidden_),this.graphDiv.appendChild(this.canvas_),this.mouseEventElement_=this.createMouseEventElement_(),this.layout_=new n.default(this);var i=this;this.mouseMoveHandler_=function(t){i.mouseMove_(t)},this.mouseOutHandler_=function(t){var e=t.target||t.fromElement,a=t.relatedTarget||t.toElement;k.isNodeContainedBy(e,i.graphDiv)&&!k.isNodeContainedBy(a,i.graphDiv)&&i.mouseOut_(t)},this.addAndTrackEvent(window,"mouseout",this.mouseOutHandler_),this.addAndTrackEvent(this.mouseEventElement_,"mousemove",this.mouseMoveHandler_),this.resizeHandler_||(this.resizeHandler_=function(t){i.resize()},this.addAndTrackEvent(window,"resize",this.resizeHandler_))},m.prototype.resizeElements_=function(){this.graphDiv.style.width=this.width_+"px",this.graphDiv.style.height=this.height_+"px";var t=this.getNumericOption("pixelRatio"),e=t||k.getContextPixelRatio(this.canvas_ctx_);this.canvas_.width=this.width_*e,this.canvas_.height=this.height_*e,this.canvas_.style.width=this.width_+"px",this.canvas_.style.height=this.height_+"px",1!==e&&this.canvas_ctx_.scale(e,e);var a=t||k.getContextPixelRatio(this.hidden_ctx_);this.hidden_.width=this.width_*a,this.hidden_.height=this.height_*a,this.hidden_.style.width=this.width_+"px",this.hidden_.style.height=this.height_+"px",1!==a&&this.hidden_ctx_.scale(a,a)},m.prototype.destroy=function(){this.canvas_ctx_.restore(),this.hidden_ctx_.restore();for(var t=this.plugins_.length-1;0<=t;t--){var e=this.plugins_.pop();e.plugin.destroy&&e.plugin.destroy()}this.removeTrackedEvents_(),k.removeEvent(window,"mouseout",this.mouseOutHandler_),k.removeEvent(this.mouseEventElement_,"mousemove",this.mouseMoveHandler_),k.removeEvent(window,"resize",this.resizeHandler_),this.resizeHandler_=null,function t(e){for(;e.hasChildNodes();)t(e.firstChild),e.removeChild(e.firstChild)}(this.maindiv_);function a(t){for(var e in t)"object"==typeof t[e]&&(t[e]=null)}a(this.layout_),a(this.plotter_),a(this)},m.prototype.createPlotKitCanvas_=function(t){var e=k.createCanvas();return e.style.position="absolute",e.style.top=t.style.top,e.style.left=t.style.left,e.width=this.width_,e.height=this.height_,e.style.width=this.width_+"px",e.style.height=this.height_+"px",e},m.prototype.createMouseEventElement_=function(){return this.canvas_},m.prototype.setColors_=function(){var t=this.getLabels(),e=t.length-1;this.colors_=[],this.colorsMap_={};for(var a=this.getNumericOption("colorSaturation")||1,i=this.getNumericOption("colorValue")||.5,n=Math.ceil(e/2),r=this.getOption("colors"),o=this.visibility(),s=0;s<e;s++)if(o[s]){var l=t[s+1],h=this.attributes_.getForSeries("color",l);if(!h)if(r)h=r[s%r.length];else{var u=1*(s%2?n+(s+1)/2:Math.ceil((s+1)/2))/(1+e);h=k.hsvToRGB(u,a,i)}this.colors_.push(h),this.colorsMap_[l]=h}},m.prototype.getColors=function(){return this.colors_},m.prototype.getPropertiesForSeries=function(t){for(var e=-1,a=this.getLabels(),i=1;i<a.length;i++)if(a[i]==t){e=i;break}return-1==e?null:{name:t,column:e,visible:this.visibility()[e-1],color:this.colorsMap_[t],axis:1+this.attributes_.axisForSeries(t)}},m.prototype.createRollInterface_=function(){var t=this,e=this.roller_;e||(this.roller_=e=document.createElement("input"),e.type="text",e.style.display="none",e.className="dygraph-roller",this.graphDiv.appendChild(e));var a=this.getBooleanOption("showRoller")?"block":"none",i=this.getArea(),n={top:i.y+i.h-25+"px",left:i.x+1+"px",display:a};e.size="2",e.value=this.rollPeriod_,k.update(e.style,n),e.onchange=function(){return t.adjustRoll(e.value)}},m.prototype.createDragInterface_=function(){var a={isZooming:!1,isPanning:!1,is2DPan:!1,dragStartX:null,dragStartY:null,dragEndX:null,dragEndY:null,dragDirection:null,prevEndX:null,prevEndY:null,prevDragDirection:null,cancelNextDblclick:!1,initialLeftmostDate:null,xUnitsPerPixel:null,dateRange:null,px:0,py:0,boundedDates:null,boundedValues:null,tarp:new o.default,initializeMouseDown:function(t,e,a){t.preventDefault?t.preventDefault():(t.returnValue=!1,t.cancelBubble=!0);var i=k.findPos(e.canvas_);a.px=i.x,a.py=i.y,a.dragStartX=k.dragGetX_(t,a),a.dragStartY=k.dragGetY_(t,a),a.cancelNextDblclick=!1,a.tarp.cover()},destroy:function(){var t=this;if((t.isZooming||t.isPanning)&&(t.isZooming=!1,t.dragStartX=null,t.dragStartY=null),t.isPanning){t.isPanning=!1,t.draggingDate=null,t.dateRange=null;for(var e=0;e<i.axes_.length;e++)delete i.axes_[e].draggingValue,delete i.axes_[e].dragValueRange}t.tarp.uncover()}},t=this.getOption("interactionModel"),i=this;for(var e in t)t.hasOwnProperty(e)&&this.addAndTrackEvent(this.mouseEventElement_,e,function(e){return function(t){e(t,i,a)}}(t[e]));if(!t.willDestroyContextMyself){this.addAndTrackEvent(document,"mouseup",function(t){a.destroy()})}},m.prototype.drawZoomRect_=function(t,e,a,i,n,r,o,s){var l=this.canvas_ctx_;r==k.HORIZONTAL?l.clearRect(Math.min(e,o),this.layout_.getPlotArea().y,Math.abs(e-o),this.layout_.getPlotArea().h):r==k.VERTICAL&&l.clearRect(this.layout_.getPlotArea().x,Math.min(i,s),this.layout_.getPlotArea().w,Math.abs(i-s)),t==k.HORIZONTAL?a&&e&&(l.fillStyle="rgba(128,128,128,0.33)",l.fillRect(Math.min(e,a),this.layout_.getPlotArea().y,Math.abs(a-e),this.layout_.getPlotArea().h)):t==k.VERTICAL&&n&&i&&(l.fillStyle="rgba(128,128,128,0.33)",l.fillRect(this.layout_.getPlotArea().x,Math.min(i,n),this.layout_.getPlotArea().w,Math.abs(n-i)))},m.prototype.clearZoomRect_=function(){this.currentZoomRectArgs_=null,this.canvas_ctx_.clearRect(0,0,this.width_,this.height_)},m.prototype.doZoomX_=function(t,e){this.currentZoomRectArgs_=null;var a=this.toDataXCoord(t),i=this.toDataXCoord(e);this.doZoomXDates_(a,i)},m.prototype.doZoomXDates_=function(t,e){var a=this,i=this.xAxisRange(),n=[t,e],r=this.getFunctionOption("zoomCallback");this.doAnimatedZoom(i,n,null,null,function(){r&&r.call(a,t,e,a.yAxisRanges())})},m.prototype.doZoomY_=function(t,e){var n=this;this.currentZoomRectArgs_=null;for(var a=this.yAxisRanges(),i=[],r=0;r<this.axes_.length;r++){var o=this.toDataYCoord(t,r),s=this.toDataYCoord(e,r);i.push([s,o])}var l=this.getFunctionOption("zoomCallback");this.doAnimatedZoom(null,null,a,i,function(){if(l){var t=n.xAxisRange(),e=g(t,2),a=e[0],i=e[1];l.call(n,a,i,n.yAxisRanges())}})},m.zoomAnimationFunction=function(t,e){return(1-Math.pow(1.5,-t))/(1-Math.pow(1.5,-e))},m.prototype.resetZoom=function(){var t=this,e=this.isZoomed("x"),a=this.isZoomed("y"),i=e||a;if(this.clearSelection(),i){var n=this.xAxisExtremes(),r=g(n,2),o=r[0],s=r[1],l=this.getBooleanOption("animatedZooms"),h=this.getFunctionOption("zoomCallback");if(!l)return this.dateWindow_=null,this.axes_.forEach(function(t){t.valueRange&&delete t.valueRange}),this.drawGraph_(),void(h&&h.call(this,o,s,this.yAxisRanges()));var u=null,d=null,c=null,p=null;e&&(u=this.xAxisRange(),d=[o,s]),a&&(c=this.yAxisRanges(),p=this.yAxisExtremes()),this.doAnimatedZoom(u,d,c,p,function(){t.dateWindow_=null,t.axes_.forEach(function(t){t.valueRange&&delete t.valueRange}),h&&h.call(t,o,s,t.yAxisRanges())})}},m.prototype.doAnimatedZoom=function(t,e,a,i,n){var r,o,s=this,l=this.getBooleanOption("animatedZooms")?m.ANIMATION_STEPS:1,h=[],u=[];if(null!==t&&null!==e)for(r=1;r<=l;r++)o=m.zoomAnimationFunction(r,l),h[r-1]=[t[0]*(1-o)+o*e[0],t[1]*(1-o)+o*e[1]];if(null!==a&&null!==i)for(r=1;r<=l;r++){o=m.zoomAnimationFunction(r,l);for(var d=[],c=0;c<this.axes_.length;c++)d.push([a[c][0]*(1-o)+o*i[c][0],a[c][1]*(1-o)+o*i[c][1]]);u[r-1]=d}k.repeatAndCleanup(function(t){if(u.length)for(var e=0;e<s.axes_.length;e++){var a=u[t][e];s.axes_[e].valueRange=[a[0],a[1]]}h.length&&(s.dateWindow_=h[t]),s.drawGraph_()},l,m.ANIMATION_DURATION/l,n)},m.prototype.getArea=function(){return this.plotter_.area},m.prototype.eventToDomCoords=function(t){if(t.offsetX&&t.offsetY)return[t.offsetX,t.offsetY];var e=k.findPos(this.mouseEventElement_);return[k.pageX(t)-e.x,k.pageY(t)-e.y]},m.prototype.findClosestRow=function(t){for(var e=1/0,a=-1,i=this.layout_.points,n=0;n<i.length;n++)for(var r=i[n],o=r.length,s=0;s<o;s++){var l=r[s];if(k.isValidPoint(l,!0)){var h=Math.abs(l.canvasx-t);h<e&&(e=h,a=l.idx)}}return a},m.prototype.findClosestPoint=function(t,e){for(var a,i,n,r,o,s,l,h=1/0,u=this.layout_.points.length-1;0<=u;--u)for(var d=this.layout_.points[u],c=0;c<d.length;++c)r=d[c],k.isValidPoint(r)&&((a=(i=r.canvasx-t)*i+(n=r.canvasy-e)*n)<h&&(h=a,s=u,l=(o=r).idx));return{row:l,seriesName:this.layout_.setNames[s],point:o}},m.prototype.findStackedPoint=function(t,e){for(var a,i,n=this.findClosestRow(t),r=0;r<this.layout_.points.length;++r){var o=n-this.getLeftBoundary_(r),s=this.layout_.points[r];if(!(o>=s.length)){var l=s[o];if(k.isValidPoint(l)){var h=l.canvasy;if(t>l.canvasx&&1+o<s.length){var u=s[1+o];if(k.isValidPoint(u))if(0<(d=u.canvasx-l.canvasx))h+=(t-l.canvasx)/d*(u.canvasy-l.canvasy)}else if(t<l.canvasx&&0<o){var d,c=s[o-1];if(k.isValidPoint(c))if(0<(d=l.canvasx-c.canvasx))h+=(l.canvasx-t)/d*(c.canvasy-l.canvasy)}(0===r||h<e)&&(a=l,i=r)}}}return{row:n,seriesName:this.layout_.setNames[i],point:a}},m.prototype.mouseMove_=function(t){var e=this.layout_.points;if(null!=e){var a=this.eventToDomCoords(t),i=a[0],n=a[1],r=!1;if(this.getOption("highlightSeriesOpts")&&!this.isSeriesLocked()){var o;o=this.getBooleanOption("stackedGraph")?this.findStackedPoint(i,n):this.findClosestPoint(i,n),r=this.setSelection(o.row,o.seriesName)}else{var s=this.findClosestRow(i);r=this.setSelection(s)}var l=this.getFunctionOption("highlightCallback");l&&r&&l.call(this,t,this.lastx_,this.selPoints_,this.lastRow_,this.highlightSet_)}},m.prototype.getLeftBoundary_=function(t){if(this.boundaryIds_[t])return this.boundaryIds_[t][0];for(var e=0;e<this.boundaryIds_.length;e++)if(void 0!==this.boundaryIds_[e])return this.boundaryIds_[e][0];return 0},m.prototype.animateSelection_=function(e){void 0===this.fadeLevel&&(this.fadeLevel=0),void 0===this.animateId&&(this.animateId=0);var t=this.fadeLevel,a=e<0?t:10-t;if(a<=0)this.fadeLevel&&this.updateSelection_(1);else{var i=++this.animateId,n=this;k.repeatAndCleanup(function(t){n.animateId==i&&(n.fadeLevel+=e,0===n.fadeLevel?n.clearSelection():n.updateSelection_(n.fadeLevel/10))},a,30,function(){0!==n.fadeLevel&&e<0&&(n.fadeLevel=0,n.clearSelection())})}},m.prototype.updateSelection_=function(t){this.cascadeEvents_("select",{selectedRow:-1===this.lastRow_?void 0:this.lastRow_,selectedX:-1===this.lastx_?void 0:this.lastx_,selectedPoints:this.selPoints_});var e,a=this.canvas_ctx_;if(this.getOption("highlightSeriesOpts")){a.clearRect(0,0,this.width_,this.height_);var i=1-this.getNumericOption("highlightSeriesBackgroundAlpha"),n=k.toRGB_(this.getOption("highlightSeriesBackgroundColor"));if(i){if(void 0===t)return void this.animateSelection_(1);i*=t,a.fillStyle="rgba("+n.r+","+n.g+","+n.b+","+i+")",a.fillRect(0,0,this.width_,this.height_)}this.plotter_._renderLineChart(this.highlightSet_,a)}else if(0<=this.previousVerticalX_){var r=0,o=this.attr_("labels");for(e=1;e<o.length;e++){var s=this.getNumericOption("highlightCircleSize",o[e]);r<s&&(r=s)}var l=this.previousVerticalX_;a.clearRect(l-r-1,0,2*r+2,this.height_)}if(0<this.selPoints_.length){var h=this.selPoints_[0].canvasx;for(a.save(),e=0;e<this.selPoints_.length;e++){var u=this.selPoints_[e];if(!isNaN(u.canvasy)){var d=this.getNumericOption("highlightCircleSize",u.name),c=this.getFunctionOption("drawHighlightPointCallback",u.name),p=this.plotter_.colors[u.name];c||(c=k.Circles.DEFAULT),a.lineWidth=this.getNumericOption("strokeWidth",u.name),a.strokeStyle=p,a.fillStyle=p,c.call(this,this,u.name,a,h,u.canvasy,p,d,u.idx)}}a.restore(),this.previousVerticalX_=h}},m.prototype.setSelection=function(t,e,a){var i=!(this.selPoints_=[]);if(!1!==t&&0<=t){t!=this.lastRow_&&(i=!0),this.lastRow_=t;for(var n=0;n<this.layout_.points.length;++n){var r=this.layout_.points[n],o=t-this.getLeftBoundary_(n);if(0<=o&&o<r.length&&r[o].idx==t)null!==(l=r[o]).yval&&this.selPoints_.push(l);else for(var s=0;s<r.length;++s){var l;if((l=r[s]).idx==t){null!==l.yval&&this.selPoints_.push(l);break}}}}else 0<=this.lastRow_&&(i=!0),this.lastRow_=-1;return this.selPoints_.length?this.lastx_=this.selPoints_[0].xval:this.lastx_=-1,void 0!==e&&(this.highlightSet_!==e&&(i=!0),this.highlightSet_=e),void 0!==a&&(this.lockedSet_=a),i&&this.updateSelection_(void 0),i},m.prototype.mouseOut_=function(t){this.getFunctionOption("unhighlightCallback")&&this.getFunctionOption("unhighlightCallback").call(this,t),this.getBooleanOption("hideOverlayOnMouseOut")&&!this.lockedSet_&&this.clearSelection()},m.prototype.clearSelection=function(){this.cascadeEvents_("deselect",{}),this.lockedSet_=!1,this.fadeLevel?this.animateSelection_(-1):(this.canvas_ctx_.clearRect(0,0,this.width_,this.height_),this.fadeLevel=0,this.selPoints_=[],this.lastx_=-1,this.lastRow_=-1,this.highlightSet_=null)},m.prototype.getSelection=function(){if(!this.selPoints_||this.selPoints_.length<1)return-1;for(var t=0;t<this.layout_.points.length;t++)for(var e=this.layout_.points[t],a=0;a<e.length;a++)if(e[a].x==this.selPoints_[0].x)return e[a].idx;return-1},m.prototype.getHighlightSeries=function(){return this.highlightSet_},m.prototype.isSeriesLocked=function(){return this.lockedSet_},m.prototype.loadedEvent_=function(t){this.rawData_=this.parseCSV_(t),this.cascadeDataDidUpdateEvent_(),this.predraw_()},m.prototype.addXTicks_=function(){var t;t=this.dateWindow_?[this.dateWindow_[0],this.dateWindow_[1]]:this.xAxisExtremes();var e=this.optionsViewForAxis_("x"),a=e("ticker")(t[0],t[1],this.plotter_.area.w,e,this);this.layout_.setXTicks(a)},m.prototype.getHandlerClass_=function(){return this.attr_("dataHandler")?this.attr_("dataHandler"):this.fractions_?this.getBooleanOption("errorBars")?d.default:u.default:this.getBooleanOption("customBars")?h.default:this.getBooleanOption("errorBars")?l.default:s.default},m.prototype.predraw_=function(){var t=new Date;this.dataHandler_=new(this.getHandlerClass_()),this.layout_.computePlotArea(),this.computeYAxes_(),this.is_initial_draw_||(this.canvas_ctx_.restore(),this.hidden_ctx_.restore()),this.canvas_ctx_.save(),this.hidden_ctx_.save(),this.plotter_=new r.default(this,this.hidden_,this.hidden_ctx_,this.layout_),this.createRollInterface_(),this.cascadeEvents_("predraw"),this.rolledSeries_=[null];for(var e=1;e<this.numColumns();e++){var a=this.dataHandler_.extractSeries(this.rawData_,e,this.attributes_);1<this.rollPeriod_&&(a=this.dataHandler_.rollingAverage(a,this.rollPeriod_,this.attributes_)),this.rolledSeries_.push(a)}this.drawGraph_();var i=new Date;this.drawingTimeMs_=i-t},m.PointType=void 0,m.stackPoints_=function(a,t,e,i){for(var n=null,r=null,o=null,s=-1,l=0;l<a.length;++l){var h=a[l],u=h.xval;void 0===t[u]&&(t[u]=0);var d=h.yval;isNaN(d)||null===d?d="none"==i?0:(function(t){if(!(l<=s))for(var e=l;e<a.length;++e)if(o=null,!isNaN(a[e].yval)&&null!==a[e].yval){o=a[s=e];break}}(),r&&o&&"none"!=i?r.yval+(o.yval-r.yval)*((u-r.xval)/(o.xval-r.xval)):r&&"all"==i?r.yval:o&&"all"==i?o.yval:0):r=h;var c=t[u];n!=u&&(c+=d,t[u]=c),n=u,(h.yval_stacked=c)>e[1]&&(e[1]=c),c<e[0]&&(e[0]=c)}},m.prototype.gatherDatasets_=function(t,e){var a,i,n,r,o,s,l=[],h=[],u=[],d={};for(a=t.length-1;1<=a;a--)if(this.visibility()[a-1]){if(e){s=t[a];var c=e[0],p=e[1];for(r=n=null,i=0;i<s.length;i++)s[i][0]>=c&&null===n&&(n=i),s[i][0]<=p&&(r=i);null===n&&(n=0);for(var g=n,f=!0;f&&0<g;)f=null===s[--g][1];null===r&&(r=s.length-1);var _=r;for(f=!0;f&&_<s.length-1;)f=null===s[++_][1];g!==n&&(n=g),_!==r&&(r=_),l[a-1]=[n,r],s=s.slice(n,r+1)}else s=t[a],l[a-1]=[0,s.length-1];var v=this.attr_("labels")[a],y=this.dataHandler_.getExtremeYValues(s,e,this.getBooleanOption("stepPlot",v)),x=this.dataHandler_.seriesToPoints(s,v,l[a-1][0]);this.getBooleanOption("stackedGraph")&&(void 0===u[o=this.attributes_.axisForSeries(v)]&&(u[o]=[]),m.stackPoints_(x,u[o],y,this.getBooleanOption("stackedGraphNaNFill"))),d[v]=y,h[a]=x}return{points:h,extremes:d,boundaryIds:l}},m.prototype.drawGraph_=function(){var t=new Date,e=this.is_initial_draw_;this.is_initial_draw_=!1,this.layout_.removeAllDatasets(),this.setColors_(),this.attrs_.pointSize=.5*this.getNumericOption("highlightCircleSize");var a=this.gatherDatasets_(this.rolledSeries_,this.dateWindow_),i=a.points,n=a.extremes;this.boundaryIds_=a.boundaryIds,this.setIndexByName_={};for(var r=this.attr_("labels"),o=0,s=1;s<i.length;s++)this.visibility()[s-1]&&(this.layout_.addDataset(r[s],i[s]),this.datasetIndex_[s]=o++);for(s=0;s<r.length;s++)this.setIndexByName_[r[s]]=s;if(this.computeYAxisRanges_(n),this.layout_.setYAxes(this.axes_),this.addXTicks_(),this.layout_.evaluate(),this.renderGraph_(e),this.getStringOption("timingName")){var l=new Date;console.log(this.getStringOption("timingName")+" - drawGraph: "+(l-t)+"ms")}},m.prototype.renderGraph_=function(t){this.cascadeEvents_("clearChart"),this.plotter_.clear();var e=this.getFunctionOption("underlayCallback");e&&e.call(this,this.hidden_ctx_,this.layout_.getPlotArea(),this,this);var a={canvas:this.hidden_,drawingContext:this.hidden_ctx_};this.cascadeEvents_("willDrawChart",a),this.plotter_.render(),this.cascadeEvents_("didDrawChart",a),this.lastRow_=-1,this.canvas_.getContext("2d").clearRect(0,0,this.width_,this.height_);var i=this.getFunctionOption("drawCallback");if(null!==i&&i.call(this,this,t),t)for(this.readyFired_=!0;0<this.readyFns_.length;){this.readyFns_.pop()(this)}},m.prototype.computeYAxes_=function(){var t,e,a;for(this.axes_=[],t=0;t<this.attributes_.numAxes();t++)e={g:this},k.update(e,this.attributes_.axisOptions(t)),this.axes_[t]=e;for(t=0;t<this.axes_.length;t++)if(0===t)(a=(e=this.optionsViewForAxis_("y"+(t?"2":"")))("valueRange"))&&(this.axes_[t].valueRange=a);else{var i=this.user_attrs_.axes;i&&i.y2&&(a=i.y2.valueRange)&&(this.axes_[t].valueRange=a)}},m.prototype.numAxes=function(){return this.attributes_.numAxes()},m.prototype.axisPropertiesForSeries=function(t){return this.axes_[this.attributes_.axisForSeries(t)]},m.prototype.computeYAxisRanges_=function(t){for(var e,a,i,n,r,o=function(t){return isNaN(parseFloat(t))},s=this.attributes_.numAxes(),l=0;l<s;l++){var h=this.axes_[l],u=this.attributes_.getForAxis("logscale",l),d=this.attributes_.getForAxis("includeZero",l),c=this.attributes_.getForAxis("independentTicks",l);i=this.attributes_.seriesForAxis(l),e=!0,n=.1;var p=this.getNumericOption("yRangePad");if(null!==p&&(e=!1,n=p/this.plotter_.area.h),0===i.length)h.extremeRange=[0,1];else{for(var g,f,_=1/0,v=-1/0,y=0;y<i.length;y++)t.hasOwnProperty(i[y])&&(null!==(g=t[i[y]][0])&&(_=Math.min(g,_)),null!==(f=t[i[y]][1])&&(v=Math.max(f,v)));d&&!u&&(0<_&&(_=0),v<0&&(v=0)),_==1/0&&(_=0),v==-1/0&&(v=1),0===(a=v-_)&&(a=0!==v?Math.abs(v):v=1);var x=v,m=_;e&&(u?(x=v+n*a,m=_):((m=_-n*a)<0&&0<=_&&(m=0),0<(x=v+n*a)&&v<=0&&(x=0))),h.extremeRange=[m,x]}if(h.valueRange){var b=o(h.valueRange[0])?h.extremeRange[0]:h.valueRange[0],w=o(h.valueRange[1])?h.extremeRange[1]:h.valueRange[1];h.computedValueRange=[b,w]}else h.computedValueRange=h.extremeRange;if(!e)if(u){b=h.computedValueRange[0],w=h.computedValueRange[1];var A=n/(2*n-1),O=(n-1)/(2*n-1);h.computedValueRange[0]=k.logRangeFraction(b,w,A),h.computedValueRange[1]=k.logRangeFraction(b,w,O)}else b=h.computedValueRange[0],a=(w=h.computedValueRange[1])-b,h.computedValueRange[0]=b-a*n,h.computedValueRange[1]=w+a*n;if(c){h.independentTicks=c;var P=(L=this.optionsViewForAxis_("y"+(l?"2":"")))("ticker");h.ticks=P(h.computedValueRange[0],h.computedValueRange[1],this.plotter_.area.h,L,this),r||(r=h)}}if(void 0===r)throw'Configuration Error: At least one axis has to have the "independentTicks" option activated.';for(l=0;l<s;l++){if(!(h=this.axes_[l]).independentTicks){P=(L=this.optionsViewForAxis_("y"+(l?"2":"")))("ticker");for(var L,S=r.ticks,T=r.computedValueRange[1]-r.computedValueRange[0],C=h.computedValueRange[1]-h.computedValueRange[0],M=[],E=0;E<S.length;E++){var D=(S[E].v-r.computedValueRange[0])/T,N=h.computedValueRange[0]+D*C;M.push(N)}h.ticks=P(h.computedValueRange[0],h.computedValueRange[1],this.plotter_.area.h,L,this,M)}}},m.prototype.detectTypeFromString_=function(t){var e=!1,a=t.indexOf("-");0<a&&"e"!=t[a-1]&&"E"!=t[a-1]||0<=t.indexOf("/")||isNaN(parseFloat(t))?e=!0:8==t.length&&"19700101"<t&&t<"20371231"&&(e=!0),this.setXAxisOptions_(e)},m.prototype.setXAxisOptions_=function(t){t?(this.attrs_.xValueParser=k.dateParser,this.attrs_.axes.x.valueFormatter=k.dateValueFormatter,this.attrs_.axes.x.ticker=x.dateTicker,this.attrs_.axes.x.axisLabelFormatter=k.dateAxisLabelFormatter):(this.attrs_.xValueParser=function(t){return parseFloat(t)},this.attrs_.axes.x.valueFormatter=function(t){return t},this.attrs_.axes.x.ticker=x.numericTicks,this.attrs_.axes.x.axisLabelFormatter=this.attrs_.axes.x.valueFormatter)},m.prototype.parseCSV_=function(t){var e,a,i=[],n=k.detectLineDelimiter(t),r=t.split(n||"\n"),o=this.getStringOption("delimiter");-1==r[0].indexOf(o)&&0<=r[0].indexOf("\t")&&(o="\t");var s=0;"labels"in this.user_attrs_||(s=1,this.attrs_.labels=r[0].split(o),this.attributes_.reparseSeries());for(var l,h=!1,u=this.attr_("labels").length,d=!1,c=s;c<r.length;c++){var p=r[c];if(0!==p.length&&"#"!=p[0]){var g=p.split(o);if(!(g.length<2)){var f=[];if(h||(this.detectTypeFromString_(g[0]),l=this.getFunctionOption("xValueParser"),h=!0),f[0]=l(g[0],this),this.fractions_)for(a=1;a<g.length;a++)2!=(e=g[a].split("/")).length?(console.error('Expected fractional "num/den" values in CSV data but found a value \''+g[a]+"' on line "+(1+c)+" ('"+p+"') which is not of this form."),f[a]=[0,0]):f[a]=[k.parseFloat_(e[0],c,p),k.parseFloat_(e[1],c,p)];else if(this.getBooleanOption("errorBars"))for(g.length%2!=1&&console.error("Expected alternating (value, stdev.) pairs in CSV data but line "+(1+c)+" has an odd number of values ("+(g.length-1)+"): '"+p+"'"),a=1;a<g.length;a+=2)f[(a+1)/2]=[k.parseFloat_(g[a],c,p),k.parseFloat_(g[a+1],c,p)];else if(this.getBooleanOption("customBars"))for(a=1;a<g.length;a++){var _=g[a];/^ *$/.test(_)?f[a]=[null,null,null]:3==(e=_.split(";")).length?f[a]=[k.parseFloat_(e[0],c,p),k.parseFloat_(e[1],c,p),k.parseFloat_(e[2],c,p)]:console.warn('When using customBars, values must be either blank or "low;center;high" tuples (got "'+_+'" on line '+(1+c))}else for(a=1;a<g.length;a++)f[a]=k.parseFloat_(g[a],c,p);if(0<i.length&&f[0]<i[i.length-1][0]&&(d=!0),f.length!=u&&console.error("Number of columns in line "+c+" ("+f.length+") does not agree with number of labels ("+u+") "+p),0===c&&this.attr_("labels")){var v=!0;for(a=0;v&&a<f.length;a++)f[a]&&(v=!1);if(v){console.warn("The dygraphs 'labels' option is set, but the first row of CSV data ('"+p+"') appears to also contain labels. Will drop the CSV labels and use the option labels.");continue}}i.push(f)}}}return d&&(console.warn("CSV is out of order; order it correctly to speed loading."),i.sort(function(t,e){return t[0]-e[0]})),i},m.prototype.parseArray_=function(t){if(0===t.length)return console.error("Can't plot empty data set"),null;if(0===t[0].length)return console.error("Data set cannot contain an empty row"),null;var e;if(function(t){var e=t[0],a=e[0];if("number"!=typeof a&&!k.isDateLike(a))throw new Error("Expected number or date but got "+typeof a+": "+a+".");for(var i=1;i<e.length;i++){var n=e[i];if(null!=n&&"number"!=typeof n&&!k.isArrayLike(n))throw new Error("Expected number or array but got "+typeof n+": "+n+".")}}(t),null===this.attr_("labels")){for(console.warn("Using default labels. Set labels explicitly via 'labels' in the options parameter"),this.attrs_.labels=["X"],e=1;e<t[0].length;e++)this.attrs_.labels.push("Y"+e);this.attributes_.reparseSeries()}else{var a=this.attr_("labels");if(a.length!=t[0].length)return console.error("Mismatch between number of labels ("+a+") and number of columns in array ("+t[0].length+")"),null}if(k.isDateLike(t[0][0])){this.attrs_.axes.x.valueFormatter=k.dateValueFormatter,this.attrs_.axes.x.ticker=x.dateTicker,this.attrs_.axes.x.axisLabelFormatter=k.dateAxisLabelFormatter;var i=k.clone(t);for(e=0;e<t.length;e++){if(0===i[e].length)return console.error("Row "+(1+e)+" of data is empty"),null;if(null===i[e][0]||"function"!=typeof i[e][0].getTime||isNaN(i[e][0].getTime()))return console.error("x value in row "+(1+e)+" is not a Date"),null;i[e][0]=i[e][0].getTime()}return i}return this.attrs_.axes.x.valueFormatter=function(t){return t},this.attrs_.axes.x.ticker=x.numericTicks,this.attrs_.axes.x.axisLabelFormatter=k.numberAxisLabelFormatter,t},m.prototype.parseDataTable_=function(t){var e=t.getNumberOfColumns(),a=t.getNumberOfRows(),i=t.getColumnType(0);if("date"==i||"datetime"==i)this.attrs_.xValueParser=k.dateParser,this.attrs_.axes.x.valueFormatter=k.dateValueFormatter,this.attrs_.axes.x.ticker=x.dateTicker,this.attrs_.axes.x.axisLabelFormatter=k.dateAxisLabelFormatter;else{if("number"!=i)throw new Error("only 'date', 'datetime' and 'number' types are supported for column 1 of DataTable input (Got '"+i+"')");this.attrs_.xValueParser=function(t){return parseFloat(t)},this.attrs_.axes.x.valueFormatter=function(t){return t},this.attrs_.axes.x.ticker=x.numericTicks,this.attrs_.axes.x.axisLabelFormatter=this.attrs_.axes.x.valueFormatter}var n,r,o=[],s={},l=!1;for(n=1;n<e;n++){var h=t.getColumnType(n);if("number"==h)o.push(n);else{if("string"!=h||!this.getBooleanOption("displayAnnotations"))throw new Error("Only 'number' is supported as a dependent type with Gviz. 'string' is only supported if displayAnnotations is true");var u=o[o.length-1];s.hasOwnProperty(u)?s[u].push(n):s[u]=[n],l=!0}}var d=[t.getColumnLabel(0)];for(n=0;n<o.length;n++)d.push(t.getColumnLabel(o[n])),this.getBooleanOption("errorBars")&&(n+=1);e=(this.attrs_.labels=d).length;var c=[],p=!1,g=[];for(n=0;n<a;n++){var f=[];if(void 0!==t.getValue(n,0)&&null!==t.getValue(n,0)){if("date"==i||"datetime"==i?f.push(t.getValue(n,0).getTime()):f.push(t.getValue(n,0)),this.getBooleanOption("errorBars"))for(r=0;r<e-1;r++)f.push([t.getValue(n,1+2*r),t.getValue(n,2+2*r)]);else{for(r=0;r<o.length;r++){var _=o[r];if(f.push(t.getValue(n,_)),l&&s.hasOwnProperty(_)&&null!==t.getValue(n,s[_][0])){var v={};v.series=t.getColumnLabel(_),v.xval=f[0],v.shortText=function(t){var e=String.fromCharCode(65+t%26);for(t=Math.floor(t/26);0<t;)e=String.fromCharCode(65+(t-1)%26)+e.toLowerCase(),t=Math.floor((t-1)/26);return e}(g.length),v.text="";for(var y=0;y<s[_].length;y++)y&&(v.text+="\n"),v.text+=t.getValue(n,s[_][y]);g.push(v)}}for(r=0;r<f.length;r++)isFinite(f[r])||(f[r]=null)}0<c.length&&f[0]<c[c.length-1][0]&&(p=!0),c.push(f)}else console.warn("Ignoring row "+n+" of DataTable because of undefined or null first column.")}p&&(console.warn("DataTable is out of order; order it correctly to speed loading."),c.sort(function(t,e){return t[0]-e[0]})),this.rawData_=c,0<g.length&&this.setAnnotations(g,!0),this.attributes_.reparseSeries()},m.prototype.cascadeDataDidUpdateEvent_=function(){this.cascadeEvents_("dataDidUpdate",{})},m.prototype.start_=function(){var t=this.file_;if("function"==typeof t&&(t=t()),k.isArrayLike(t))this.rawData_=this.parseArray_(t),this.cascadeDataDidUpdateEvent_(),this.predraw_();else if("object"==typeof t&&"function"==typeof t.getColumnRange)this.parseDataTable_(t),this.cascadeDataDidUpdateEvent_(),this.predraw_();else if("string"==typeof t){if(k.detectLineDelimiter(t))this.loadedEvent_(t);else{var e;e=window.XMLHttpRequest?new XMLHttpRequest:new ActiveXObject("Microsoft.XMLHTTP");var a=this;e.onreadystatechange=function(){4==e.readyState&&(200!==e.status&&0!==e.status||a.loadedEvent_(e.responseText))},e.open("GET",t,!0),e.send(null)}}else console.error("Unknown data format: "+typeof t)},m.prototype.updateOptions=function(t,e){void 0===e&&(e=!1);var a=t.file,i=m.copyUserAttrs_(t);"rollPeriod"in i&&(this.rollPeriod_=i.rollPeriod),"dateWindow"in i&&(this.dateWindow_=i.dateWindow);var n=k.isPixelChangingOptionList(this.attr_("labels"),i);k.updateDeep(this.user_attrs_,i),this.attributes_.reparseSeries(),a?(this.cascadeEvents_("dataWillUpdate",{}),this.file_=a,e||this.start_()):e||(n?this.predraw_():this.renderGraph_(!1))},m.copyUserAttrs_=function(t){var e={};for(var a in t)t.hasOwnProperty(a)&&"file"!=a&&t.hasOwnProperty(a)&&(e[a]=t[a]);return e},m.prototype.resize=function(t,e){if(!this.resize_lock){this.resize_lock=!0,null===t!=(null===e)&&(console.warn("Dygraph.resize() should be called with zero parameters or two non-NULL parameters. Pretending it was zero."),t=e=null);var a=this.width_,i=this.height_;t?(this.maindiv_.style.width=t+"px",this.maindiv_.style.height=e+"px",this.width_=t,this.height_=e):(this.width_=this.maindiv_.clientWidth,this.height_=this.maindiv_.clientHeight),a==this.width_&&i==this.height_||(this.resizeElements_(),this.predraw_()),this.resize_lock=!1}},m.prototype.adjustRoll=function(t){this.rollPeriod_=t,this.predraw_()},m.prototype.visibility=function(){for(this.getOption("visibility")||(this.attrs_.visibility=[]);this.getOption("visibility").length<this.numColumns()-1;)this.attrs_.visibility.push(!0);return this.getOption("visibility")},m.prototype.setVisibility=function(t,e){var a=this.visibility(),i=!1;if(Array.isArray(t)||(null!==t&&"object"==typeof t?i=!0:t=[t]),i)for(var n in t)t.hasOwnProperty(n)&&(n<0||n>=a.length?console.warn("Invalid series number in setVisibility: "+n):a[n]=t[n]);else for(n=0;n<t.length;n++)"boolean"==typeof t[n]?n>=a.length?console.warn("Invalid series number in setVisibility: "+n):a[n]=t[n]:t[n]<0||t[n]>=a.length?console.warn("Invalid series number in setVisibility: "+t[n]):a[t[n]]=e;this.predraw_()},m.prototype.size=function(){return{width:this.width_,height:this.height_}},m.prototype.setAnnotations=function(t,e){this.annotations_=t,this.layout_?(this.layout_.setAnnotations(this.annotations_),e||this.predraw_()):console.warn("Tried to setAnnotations before dygraph was ready. Try setting them in a ready() block. See dygraphs.com/tests/annotation.html")},m.prototype.annotations=function(){return this.annotations_},m.prototype.getLabels=function(){var t=this.attr_("labels");return t?t.slice():null},m.prototype.indexFromSetName=function(t){return this.setIndexByName_[t]},m.prototype.getRowForX=function(t){for(var e=0,a=this.numRows()-1;e<=a;){var i=a+e>>1,n=this.getValue(i,0);if(n<t)e=1+i;else if(t<n)a=i-1;else{if(e==i)return i;a=i}}return null},m.prototype.ready=function(t){this.is_initial_draw_?this.readyFns_.push(t):t.call(this,this)},m.prototype.addAndTrackEvent=function(t,e,a){k.addEvent(t,e,a),this.registeredEvents_.push({elem:t,type:e,fn:a})},m.prototype.removeTrackedEvents_=function(){if(this.registeredEvents_)for(var t=0;t<this.registeredEvents_.length;t++){var e=this.registeredEvents_[t];k.removeEvent(e.elem,e.type,e.fn)}this.registeredEvents_=[]},m.PLUGINS=[w.default,v.default,A.default,y.default,_.default,b.default],m.GVizChart=O.default,m.DASHED_LINE=k.DASHED_LINE,m.DOT_DASH_LINE=k.DOT_DASH_LINE,m.dateAxisLabelFormatter=k.dateAxisLabelFormatter,m.toRGB_=k.toRGB_,m.findPos=k.findPos,m.pageX=k.pageX,m.pageY=k.pageY,m.dateString_=k.dateString_,m.defaultInteractionModel=i.default.defaultModel,m.nonInteractiveModel=m.nonInteractiveModel_=i.default.nonInteractiveModel_,m.Circles=k.Circles,m.Plugins={Legend:w.default,Axes:v.default,Annotations:_.default,ChartLabels:y.default,Grid:b.default,RangeSelector:A.default},m.DataHandlers={DefaultHandler:s.default,BarsHandler:c.default,CustomBarsHandler:h.default,DefaultFractionHandler:u.default,ErrorBarsHandler:l.default,FractionsBarsHandler:d.default},m.startPan=i.default.startPan,m.startZoom=i.default.startZoom,m.movePan=i.default.movePan,m.moveZoom=i.default.moveZoom,m.endPan=i.default.endPan,m.endZoom=i.default.endZoom,m.numericLinearTicks=x.numericLinearTicks,m.numericTicks=x.numericTicks,m.dateTicker=x.dateTicker,m.Granularity=x.Granularity,m.getDateAxis=x.getDateAxis,m.floatFormat=k.floatFormat,S.default=m,L.exports=S.default}).call(this,P("_process"))},{"./datahandler/bars":5,"./datahandler/bars-custom":2,"./datahandler/bars-error":3,"./datahandler/bars-fractions":4,"./datahandler/default":8,"./datahandler/default-fractions":7,"./dygraph-canvas":9,"./dygraph-default-attrs":10,"./dygraph-gviz":11,"./dygraph-interaction-model":12,"./dygraph-layout":13,"./dygraph-options":15,"./dygraph-options-reference":14,"./dygraph-tickers":16,"./dygraph-utils":17,"./iframe-tarp":19,"./plugins/annotations":20,"./plugins/axes":21,"./plugins/chart-labels":22,"./plugins/grid":23,"./plugins/legend":24,"./plugins/range-selector":25,_process:1}],19:[function(t,e,a){"use strict";function i(){this.tarps=[]}Object.defineProperty(a,"__esModule",{value:!0});var h=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("./dygraph-utils"));i.prototype.cover=function(){for(var t=document.getElementsByTagName("iframe"),e=0;e<t.length;e++){var a=t[e],i=h.findPos(a),n=i.x,r=i.y,o=a.offsetWidth,s=a.offsetHeight,l=document.createElement("div");l.style.position="absolute",l.style.left=n+"px",l.style.top=r+"px",l.style.width=o+"px",l.style.height=s+"px",l.style.zIndex=999,document.body.appendChild(l),this.tarps.push(l)}},i.prototype.uncover=function(){for(var t=0;t<this.tarps.length;t++)this.tarps[t].parentNode.removeChild(this.tarps[t]);this.tarps=[]},a.default=i,e.exports=a.default},{"./dygraph-utils":17}],20:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){this.annotations_=[]}i.prototype.toString=function(){return"Annotations Plugin"},i.prototype.activate=function(t){return{clearChart:this.clearChart,didDrawChart:this.didDrawChart}},i.prototype.detachLabels=function(){for(var t=0;t<this.annotations_.length;t++){var e=this.annotations_[t];e.parentNode&&e.parentNode.removeChild(e),this.annotations_[t]=null}this.annotations_=[]},i.prototype.clearChart=function(t){this.detachLabels()},i.prototype.didDrawChart=function(t){var r=t.dygraph,e=r.layout_.annotated_points;if(e&&0!==e.length)for(var a=t.canvas.parentNode,i=function(a,i,n){return function(t){var e=n.annotation;e.hasOwnProperty(a)?e[a](e,n,r,t):r.getOption(i)&&r.getOption(i)(e,n,r,t)}},n=t.dygraph.getArea(),o={},s=0;s<e.length;s++){var l=e[s];if(!(l.canvasx<n.x||l.canvasx>n.x+n.w||l.canvasy<n.y||l.canvasy>n.y+n.h)){var h=l.annotation,u=6;h.hasOwnProperty("tickHeight")&&(u=h.tickHeight);var d=document.createElement("div");d.style.fontSize=r.getOption("axisLabelFontSize")+"px";var c="dygraph-annotation";h.hasOwnProperty("icon")||(c+=" dygraphDefaultAnnotation dygraph-default-annotation"),h.hasOwnProperty("cssClass")&&(c+=" "+h.cssClass),d.className=c;var p=h.hasOwnProperty("width")?h.width:16,g=h.hasOwnProperty("height")?h.height:16;if(h.hasOwnProperty("icon")){var f=document.createElement("img");f.src=h.icon,f.width=p,f.height=g,d.appendChild(f)}else l.annotation.hasOwnProperty("shortText")&&d.appendChild(document.createTextNode(l.annotation.shortText));var _=l.canvasx-p/2;d.style.left=_+"px";var v=0;if(h.attachAtBottom){var y=n.y+n.h-g-u;o[_]?y-=o[_]:o[_]=0,o[_]+=u+g,v=y}else v=l.canvasy-g-u;d.style.top=v+"px",d.style.width=p+"px",d.style.height=g+"px",d.title=l.annotation.text,d.style.color=r.colorsMap_[l.name],d.style.borderColor=r.colorsMap_[l.name],h.div=d,r.addAndTrackEvent(d,"click",i("clickHandler","annotationClickHandler",l)),r.addAndTrackEvent(d,"mouseover",i("mouseOverHandler","annotationMouseOverHandler",l)),r.addAndTrackEvent(d,"mouseout",i("mouseOutHandler","annotationMouseOutHandler",l)),r.addAndTrackEvent(d,"dblclick",i("dblClickHandler","annotationDblClickHandler",l)),a.appendChild(d),this.annotations_.push(d);var x=t.drawingContext;if(x.save(),x.strokeStyle=h.hasOwnProperty("tickColor")?h.tickColor:r.colorsMap_[l.name],x.lineWidth=h.hasOwnProperty("tickWidth")?h.tickWidth:r.getOption("strokeWidth"),x.beginPath(),h.attachAtBottom){y=v+g;x.moveTo(l.canvasx,y),x.lineTo(l.canvasx,y+u)}else x.moveTo(l.canvasx,l.canvasy),x.lineTo(l.canvasx,l.canvasy-2-u);x.closePath(),x.stroke(),x.restore()}}},i.prototype.destroy=function(){this.detachLabels()},a.default=i,e.exports=a.default},{}],21:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){this.xlabels_=[],this.ylabels_=[]}var L=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("../dygraph-utils"));i.prototype.toString=function(){return"Axes Plugin"},i.prototype.activate=function(t){return{layout:this.layout,clearChart:this.clearChart,willDrawChart:this.willDrawChart}},i.prototype.layout=function(t){var e,a=t.dygraph;if(a.getOptionForAxis("drawAxis","y")){var i=a.getOptionForAxis("axisLabelWidth","y")+2*a.getOptionForAxis("axisTickSize","y");t.reserveSpaceLeft(i)}a.getOptionForAxis("drawAxis","x")&&(e=a.getOption("xAxisHeight")?a.getOption("xAxisHeight"):a.getOptionForAxis("axisLabelFontSize","x")+2*a.getOptionForAxis("axisTickSize","x"),t.reserveSpaceBottom(e));if(2==a.numAxes()){if(a.getOptionForAxis("drawAxis","y2")){i=a.getOptionForAxis("axisLabelWidth","y2")+2*a.getOptionForAxis("axisTickSize","y2");t.reserveSpaceRight(i)}}else 2<a.numAxes()&&a.error("Only two y-axes are supported at this time. (Trying to use "+a.numAxes()+")")},i.prototype.detachLabels=function(){function t(t){for(var e=0;e<t.length;e++){var a=t[e];a.parentNode&&a.parentNode.removeChild(a)}}t(this.xlabels_),t(this.ylabels_),this.xlabels_=[],this.ylabels_=[]},i.prototype.clearChart=function(t){this.detachLabels()},i.prototype.willDrawChart=function(t){function e(t){return Math.round(t)+.5}function a(t){return Math.round(t)-.5}var r=this,i=t.dygraph;if(i.getOptionForAxis("drawAxis","x")||i.getOptionForAxis("drawAxis","y")||i.getOptionForAxis("drawAxis","y2")){var o,s,l,n=t.drawingContext,h=t.canvas.parentNode,u=i.width_,d=i.height_,c=function(t){return{position:"absolute",fontSize:i.getOptionForAxis("axisLabelFontSize",t)+"px",width:i.getOptionForAxis("axisLabelWidth",t)+"px"}},p={x:c("x"),y:c("y"),y2:c("y2")},g=function(t,e,a){var i=document.createElement("div"),n=p["y2"==a?"y2":e];L.update(i.style,n);var r=document.createElement("div");return r.className="dygraph-axis-label dygraph-axis-label-"+e+(a?" dygraph-axis-label-"+a:""),r.innerHTML=t,i.appendChild(r),i};n.save();var f=i.layout_,_=t.dygraph.plotter_.area,v=function(e){return function(t){return i.getOptionForAxis(t,e)}};if(i.getOptionForAxis("drawAxis","y")){if(f.yticks&&0<f.yticks.length){var y=i.numAxes(),x=[v("y"),v("y2")];f.yticks.forEach(function(t){if(void 0!==t.label){s=_.x;var e="y1",a=x[0];1==t.axis&&(s=_.x+_.w,e="y2",a=x[1]);var i=a("axisLabelFontSize");l=_.y+t.pos*_.h,o=g(t.label,"y",2==y?e:null);var n=l-i/2;n<0&&(n=0),d<n+i+3?o.style.bottom="0":o.style.top=n+"px",0===t.axis?(o.style.left=_.x-a("axisLabelWidth")-a("axisTickSize")+"px",o.style.textAlign="right"):1==t.axis&&(o.style.left=_.x+_.w+a("axisTickSize")+"px",o.style.textAlign="left"),o.style.width=a("axisLabelWidth")+"px",h.appendChild(o),r.ylabels_.push(o)}});var m=this.ylabels_[0],b=i.getOptionForAxis("axisLabelFontSize","y");parseInt(m.style.top,10)+b>d-b&&(m.style.top=parseInt(m.style.top,10)-b/2+"px")}var w;if(i.getOption("drawAxesAtZero"))(1<(P=i.toPercentXCoord(0))||P<0||isNaN(P))&&(P=0),w=e(_.x+P*_.w);else w=e(_.x);n.strokeStyle=i.getOptionForAxis("axisLineColor","y"),n.lineWidth=i.getOptionForAxis("axisLineWidth","y"),n.beginPath(),n.moveTo(w,a(_.y)),n.lineTo(w,a(_.y+_.h)),n.closePath(),n.stroke(),2==i.numAxes()&&(n.strokeStyle=i.getOptionForAxis("axisLineColor","y2"),n.lineWidth=i.getOptionForAxis("axisLineWidth","y2"),n.beginPath(),n.moveTo(a(_.x+_.w),a(_.y)),n.lineTo(a(_.x+_.w),a(_.y+_.h)),n.closePath(),n.stroke())}if(i.getOptionForAxis("drawAxis","x")){if(f.xticks){var A=v("x");f.xticks.forEach(function(t){if(void 0!==t.label){s=_.x+t.pos*_.w,l=_.y+_.h,(o=g(t.label,"x")).style.textAlign="center",o.style.top=l+A("axisTickSize")+"px";var e=s-A("axisLabelWidth")/2;e+A("axisLabelWidth")>u&&(e=u-A("axisLabelWidth"),o.style.textAlign="right"),e<0&&(e=0,o.style.textAlign="left"),o.style.left=e+"px",o.style.width=A("axisLabelWidth")+"px",h.appendChild(o),r.xlabels_.push(o)}})}var O,P;if(n.strokeStyle=i.getOptionForAxis("axisLineColor","x"),n.lineWidth=i.getOptionForAxis("axisLineWidth","x"),n.beginPath(),i.getOption("drawAxesAtZero"))(1<(P=i.toPercentYCoord(0,0))||P<0)&&(P=1),O=a(_.y+P*_.h);else O=a(_.y+_.h);n.moveTo(e(_.x),O),n.lineTo(e(_.x+_.w),O),n.closePath(),n.stroke()}n.restore()}},a.default=i,e.exports=a.default},{"../dygraph-utils":17}],22:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){this.title_div_=null,this.xlabel_div_=null,this.ylabel_div_=null,this.y2label_div_=null}i.prototype.toString=function(){return"ChartLabels Plugin"},i.prototype.activate=function(t){return{layout:this.layout,didDrawChart:this.didDrawChart}};function l(t){var e=document.createElement("div");return e.style.position="absolute",e.style.left=t.x+"px",e.style.top=t.y+"px",e.style.width=t.w+"px",e.style.height=t.h+"px",e}i.prototype.detachLabels_=function(){for(var t=[this.title_div_,this.xlabel_div_,this.ylabel_div_,this.y2label_div_],e=0;e<t.length;e++){var a=t[e];a&&a.parentNode&&a.parentNode.removeChild(a)}this.title_div_=null,this.xlabel_div_=null,this.ylabel_div_=null,this.y2label_div_=null};function h(t,e,a,i,n){var r=document.createElement("div");r.style.position="absolute",r.style.left=1==a?"0px":e.x+"px",r.style.top=e.y+"px",r.style.width=e.w+"px",r.style.height=e.h+"px",r.style.fontSize=t.getOption("yLabelWidth")-2+"px";var o=document.createElement("div");o.style.position="absolute",o.style.width=e.h+"px",o.style.height=e.w+"px",o.style.top=e.h/2-e.w/2+"px",o.style.left=e.w/2-e.h/2+"px",o.className="dygraph-label-rotate-"+(1==a?"right":"left");var s=document.createElement("div");return s.className=i,s.innerHTML=n,o.appendChild(s),r.appendChild(o),r}i.prototype.layout=function(t){this.detachLabels_();var e=t.dygraph,a=t.chart_div;if(e.getOption("title")){var i=t.reserveSpaceTop(e.getOption("titleHeight"));this.title_div_=l(i),this.title_div_.style.fontSize=e.getOption("titleHeight")-8+"px",(n=document.createElement("div")).className="dygraph-label dygraph-title",n.innerHTML=e.getOption("title"),this.title_div_.appendChild(n),a.appendChild(this.title_div_)}if(e.getOption("xlabel")){var n,r=t.reserveSpaceBottom(e.getOption("xLabelHeight"));this.xlabel_div_=l(r),this.xlabel_div_.style.fontSize=e.getOption("xLabelHeight")-2+"px",(n=document.createElement("div")).className="dygraph-label dygraph-xlabel",n.innerHTML=e.getOption("xlabel"),this.xlabel_div_.appendChild(n),a.appendChild(this.xlabel_div_)}if(e.getOption("ylabel")){var o=t.reserveSpaceLeft(0);this.ylabel_div_=h(e,o,1,"dygraph-label dygraph-ylabel",e.getOption("ylabel")),a.appendChild(this.ylabel_div_)}if(e.getOption("y2label")&&2==e.numAxes()){var s=t.reserveSpaceRight(0);this.y2label_div_=h(e,s,2,"dygraph-label dygraph-y2label",e.getOption("y2label")),a.appendChild(this.y2label_div_)}},i.prototype.didDrawChart=function(t){var e=t.dygraph;this.title_div_&&(this.title_div_.children[0].innerHTML=e.getOption("title")),this.xlabel_div_&&(this.xlabel_div_.children[0].innerHTML=e.getOption("xlabel")),this.ylabel_div_&&(this.ylabel_div_.children[0].children[0].innerHTML=e.getOption("ylabel")),this.y2label_div_&&(this.y2label_div_.children[0].children[0].innerHTML=e.getOption("y2label"))},i.prototype.clearChart=function(){},i.prototype.destroy=function(){this.detachLabels_()},a.default=i,e.exports=a.default},{}],23:[function(t,e,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});function i(){}i.prototype.toString=function(){return"Gridline Plugin"},i.prototype.activate=function(t){return{willDrawChart:this.willDrawChart}},i.prototype.willDrawChart=function(t){function a(t){return Math.round(t)+.5}function i(t){return Math.round(t)-.5}var n,r,e,o=t.dygraph,s=t.drawingContext,l=o.layout_,h=t.dygraph.plotter_.area;if(o.getOptionForAxis("drawGrid","y")){for(var u=["y","y2"],d=[],c=[],p=[],g=[],f=[],_=0;_<u.length;_++)p[_]=o.getOptionForAxis("drawGrid",u[_]),p[_]&&(d[_]=o.getOptionForAxis("gridLineColor",u[_]),c[_]=o.getOptionForAxis("gridLineWidth",u[_]),f[_]=o.getOptionForAxis("gridLinePattern",u[_]),g[_]=f[_]&&2<=f[_].length);e=l.yticks,s.save(),e.forEach(function(t){if(t.has_tick){var e=t.axis;p[e]&&(s.save(),g[e]&&s.setLineDash&&s.setLineDash(f[e]),s.strokeStyle=d[e],s.lineWidth=c[e],n=a(h.x),r=i(h.y+t.pos*h.h),s.beginPath(),s.moveTo(n,r),s.lineTo(n+h.w,r),s.stroke(),s.restore())}}),s.restore()}if(o.getOptionForAxis("drawGrid","x")){e=l.xticks,s.save();f=o.getOptionForAxis("gridLinePattern","x");(g=f&&2<=f.length)&&s.setLineDash&&s.setLineDash(f),s.strokeStyle=o.getOptionForAxis("gridLineColor","x"),s.lineWidth=o.getOptionForAxis("gridLineWidth","x"),e.forEach(function(t){t.has_tick&&(n=a(h.x+t.pos*h.w),r=i(h.y+h.h),s.beginPath(),s.moveTo(n,r),s.lineTo(n,h.y),s.closePath(),s.stroke())}),g&&s.setLineDash&&s.setLineDash([]),s.restore()}},i.prototype.destroy=function(){},a.default=i,e.exports=a.default},{}],24:[function(t,e,a){"use strict";function b(t,e,a){if(!t||t.length<=1)return'<div class="dygraph-legend-line" style="border-bottom-color: '+e+';"></div>';var i,n,r,o,s=0,l=0,h=[];for(i=0;i<=t.length;i++)s+=t[i%t.length];if(1<(o=Math.floor(a/(s-t[0])))){for(i=0;i<t.length;i++)h[i]=t[i]/a;l=h.length}else{for(o=1,i=0;i<t.length;i++)h[i]=t[i]/s;l=h.length+1}var u="";for(n=0;n<o;n++)for(i=0;i<l;i+=2)r=h[i%h.length],u+='<div class="dygraph-legend-dash" style="margin-right: '+(i<t.length?h[(i+1)%h.length]:0)+"em; padding-left: "+r+'em;"></div>';return u}Object.defineProperty(a,"__esModule",{value:!0});function w(){this.legend_div_=null,this.is_generated_div_=!1}var A=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("../dygraph-utils"));w.prototype.toString=function(){return"Legend Plugin"},w.prototype.activate=function(t){var e,a=t.getOption("labelsDiv");return a&&null!==a?e="string"==typeof a||a instanceof String?document.getElementById(a):a:((e=document.createElement("div")).className="dygraph-legend",t.graphDiv.appendChild(e),this.is_generated_div_=!0),this.legend_div_=e,this.one_em_width_=10,{select:this.select,deselect:this.deselect,predraw:this.predraw,didDrawChart:this.didDrawChart}};w.prototype.select=function(t){var e=t.selectedX,a=t.selectedPoints,i=t.selectedRow,n=t.dygraph.getOption("legend");if("never"!==n){if("follow"===n){var r=t.dygraph.plotter_.area,o=this.legend_div_.offsetWidth,s=t.dygraph.getOptionForAxis("axisLabelWidth","y"),l=a[0].x*r.w+50,h=a[0].y*r.h-50;l+o+1>r.w&&(l=l-100-o-(s-r.x)),t.dygraph.graphDiv.appendChild(this.legend_div_),this.legend_div_.style.left=s+l+"px",this.legend_div_.style.top=h+"px"}var u=w.generateLegendHTML(t.dygraph,e,a,this.one_em_width_,i);this.legend_div_.innerHTML=u,this.legend_div_.style.display=""}else this.legend_div_.style.display="none"},w.prototype.deselect=function(t){"always"!==t.dygraph.getOption("legend")&&(this.legend_div_.style.display="none");var e=function(t){var e=document.createElement("span");e.setAttribute("style","margin: 0; padding: 0 0 0 1em; border: 0;"),t.appendChild(e);var a=e.offsetWidth;return t.removeChild(e),a}(this.legend_div_);this.one_em_width_=e;var a=w.generateLegendHTML(t.dygraph,void 0,void 0,e,null);this.legend_div_.innerHTML=a},w.prototype.didDrawChart=function(t){this.deselect(t)},w.prototype.predraw=function(t){if(this.is_generated_div_){t.dygraph.graphDiv.appendChild(this.legend_div_);var e=t.dygraph.getArea(),a=this.legend_div_.offsetWidth;this.legend_div_.style.left=e.x+e.w-a-1+"px",this.legend_div_.style.top=e.y+"px"}},w.prototype.destroy=function(){this.legend_div_=null},w.generateLegendHTML=function(t,e,a,i,n){var r,o={dygraph:t,x:e,series:[]},s={},l=t.getLabels();if(l)for(var h=1;h<l.length;h++){var u=t.getPropertiesForSeries(l[h]),d={dashHTML:b(t.getOption("strokePattern",l[h]),u.color,i),label:l[h],labelHTML:(r=l[h],r.replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/</g,"&lt;").replace(/>/g,"&gt;")),isVisible:u.visible,color:u.color};o.series.push(d),s[l[h]]=d}if(void 0!==e){var c=t.optionsViewForAxis_("x"),p=c("valueFormatter");o.xHTML=p.call(t,e,c,l[0],t,n,0);var g=[],f=t.numAxes();for(h=0;h<f;h++)g[h]=t.optionsViewForAxis_("y"+(h?1+h:""));var _=t.getOption("labelsShowZeroValues"),v=t.getHighlightSeries();for(h=0;h<a.length;h++){var y=a[h];if((d=s[y.name]).y=y.yval,0===y.yval&&!_||isNaN(y.canvasy))d.isVisible=!1;else{var x=g[(u=t.getPropertiesForSeries(y.name)).axis-1],m=x("valueFormatter").call(t,y.yval,x,y.name,t,n,l.indexOf(y.name));A.update(d,{yHTML:m}),y.name==v&&(d.isHighlighted=!0)}}}return(t.getOption("legendFormatter")||w.defaultFormatter).call(t,o)},w.defaultFormatter=function(t){var e=t.dygraph;if(!0!==e.getOption("showLabelsOnHighlight"))return"";var a,i=e.getOption("labelsSeparateLines");if(void 0===t.x){if("always"!=e.getOption("legend"))return"";a="";for(var n=0;n<t.series.length;n++){(r=t.series[n]).isVisible&&(""!==a&&(a+=i?"<br/>":" "),a+="<span style='font-weight: bold; color: "+r.color+";'>"+r.dashHTML+" "+r.labelHTML+"</span>")}return a}a=t.xHTML+":";for(n=0;n<t.series.length;n++){var r;(r=t.series[n]).isVisible&&(i&&(a+="<br>"),a+="<span"+(r.isHighlighted?' class="highlight"':"")+"> <b><span style='color: "+r.color+";'>"+r.labelHTML+"</span></b>:&#160;"+r.yHTML+"</span>")}return a},a.default=w,e.exports=a.default},{"../dygraph-utils":17}],25:[function(t,e,a){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(a,"__esModule",{value:!0});function n(){this.hasTouchInterface_="undefined"!=typeof TouchEvent,this.isMobileDevice_=/mobile|android/gi.test(navigator.appVersion),this.interfaceCreated_=!1}var O=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e.default=t,e}(t("../dygraph-utils")),A=i(t("../dygraph-interaction-model")),P=i(t("../iframe-tarp"));n.prototype.toString=function(){return"RangeSelector Plugin"},n.prototype.activate=function(t){return this.dygraph_=t,this.getOption_("showRangeSelector")&&this.createInterface_(),{layout:this.reserveSpace_,predraw:this.renderStaticLayer_,didDrawChart:this.renderInteractiveLayer_}},n.prototype.destroy=function(){this.bgcanvas_=null,this.fgcanvas_=null,this.leftZoomHandle_=null,this.rightZoomHandle_=null},n.prototype.getOption_=function(t,e){return this.dygraph_.getOption(t,e)},n.prototype.setDefaultOption_=function(t,e){this.dygraph_.attrs_[t]=e},n.prototype.createInterface_=function(){this.createCanvases_(),this.createZoomHandles_(),this.initInteraction_(),this.getOption_("animatedZooms")&&(console.warn("Animated zooms and range selector are not compatible; disabling animatedZooms."),this.dygraph_.updateOptions({animatedZooms:!1},!0)),this.interfaceCreated_=!0,this.addToGraph_()},n.prototype.addToGraph_=function(){var t=this.graphDiv_=this.dygraph_.graphDiv;t.appendChild(this.bgcanvas_),t.appendChild(this.fgcanvas_),t.appendChild(this.leftZoomHandle_),t.appendChild(this.rightZoomHandle_)},n.prototype.removeFromGraph_=function(){var t=this.graphDiv_;t.removeChild(this.bgcanvas_),t.removeChild(this.fgcanvas_),t.removeChild(this.leftZoomHandle_),t.removeChild(this.rightZoomHandle_),this.graphDiv_=null},n.prototype.reserveSpace_=function(t){this.getOption_("showRangeSelector")&&t.reserveSpaceBottom(this.getOption_("rangeSelectorHeight")+4)},n.prototype.renderStaticLayer_=function(){this.updateVisibility_()&&(this.resize_(),this.drawStaticLayer_())},n.prototype.renderInteractiveLayer_=function(){this.updateVisibility_()&&!this.isChangingRange_&&(this.placeZoomHandles_(),this.drawInteractiveLayer_())},n.prototype.updateVisibility_=function(){var t=this.getOption_("showRangeSelector");if(t)this.interfaceCreated_?this.graphDiv_&&this.graphDiv_.parentNode||this.addToGraph_():this.createInterface_();else if(this.graphDiv_){this.removeFromGraph_();var e=this.dygraph_;setTimeout(function(){e.width_=0,e.resize()},1)}return t},n.prototype.resize_=function(){function t(t,e,a,i){var n=i||O.getContextPixelRatio(e);t.style.top=a.y+"px",t.style.left=a.x+"px",t.width=a.w*n,t.height=a.h*n,t.style.width=a.w+"px",t.style.height=a.h+"px",1!=n&&e.scale(n,n)}var e=this.dygraph_.layout_.getPlotArea(),a=0;this.dygraph_.getOptionForAxis("drawAxis","x")&&(a=this.getOption_("xAxisHeight")||this.getOption_("axisLabelFontSize")+2*this.getOption_("axisTickSize")),this.canvasRect_={x:e.x,y:e.y+e.h+a+4,w:e.w,h:this.getOption_("rangeSelectorHeight")};var i=this.dygraph_.getNumericOption("pixelRatio");t(this.bgcanvas_,this.bgcanvas_ctx_,this.canvasRect_,i),t(this.fgcanvas_,this.fgcanvas_ctx_,this.canvasRect_,i)},n.prototype.createCanvases_=function(){this.bgcanvas_=O.createCanvas(),this.bgcanvas_.className="dygraph-rangesel-bgcanvas",this.bgcanvas_.style.position="absolute",this.bgcanvas_.style.zIndex=9,this.bgcanvas_ctx_=O.getContext(this.bgcanvas_),this.fgcanvas_=O.createCanvas(),this.fgcanvas_.className="dygraph-rangesel-fgcanvas",this.fgcanvas_.style.position="absolute",this.fgcanvas_.style.zIndex=9,this.fgcanvas_.style.cursor="default",this.fgcanvas_ctx_=O.getContext(this.fgcanvas_)},n.prototype.createZoomHandles_=function(){var t=new Image;t.className="dygraph-rangesel-zoomhandle",t.style.position="absolute",t.style.zIndex=10,t.style.visibility="hidden",t.style.cursor="col-resize",t.width=9,t.height=16,t.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAQCAYAAADESFVDAAAAAXNSR0IArs4c6QAAAAZiS0dEANAAzwDP4Z7KegAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAAd0SU1FB9sHGw0cMqdt1UwAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAaElEQVQoz+3SsRFAQBCF4Z9WJM8KCDVwownl6YXsTmCUsyKGkZzcl7zkz3YLkypgAnreFmDEpHkIwVOMfpdi9CEEN2nGpFdwD03yEqDtOgCaun7sqSTDH32I1pQA2Pb9sZecAxc5r3IAb21d6878xsAAAAAASUVORK5CYII=",this.isMobileDevice_&&(t.width*=2,t.height*=2),this.leftZoomHandle_=t,this.rightZoomHandle_=t.cloneNode(!1)},n.prototype.initInteraction_=function(){var a,e,i,n,r,o,s,l,h,u,t,d,c,p,g=this,f=document,_=0,v=null,y=!1,x=!1,m=!this.isMobileDevice_,b=new P.default;a=function(t){var e=g.dygraph_.xAxisExtremes(),a=(e[1]-e[0])/g.canvasRect_.w;return[e[0]+(t.leftHandlePos-g.canvasRect_.x)*a,e[0]+(t.rightHandlePos-g.canvasRect_.x)*a]},e=function(t){return O.cancelEvent(t),y=!0,_=t.clientX,v=t.target?t.target:t.srcElement,"mousedown"!==t.type&&"dragstart"!==t.type||(O.addEvent(f,"mousemove",i),O.addEvent(f,"mouseup",n)),g.fgcanvas_.style.cursor="col-resize",b.cover(),!0},i=function(t){if(!y)return!1;O.cancelEvent(t);var e=t.clientX-_;if(Math.abs(e)<4)return!0;_=t.clientX;var a,i=g.getZoomHandleStatus_();a=v==g.leftZoomHandle_?(a=i.leftHandlePos+e,a=Math.min(a,i.rightHandlePos-v.width-3),Math.max(a,g.canvasRect_.x)):(a=i.rightHandlePos+e,a=Math.min(a,g.canvasRect_.x+g.canvasRect_.w),Math.max(a,i.leftHandlePos+v.width+3));var n=v.width/2;return v.style.left=a-n+"px",g.drawInteractiveLayer_(),m&&r(),!0},n=function(t){return!!y&&(y=!1,b.uncover(),O.removeEvent(f,"mousemove",i),O.removeEvent(f,"mouseup",n),g.fgcanvas_.style.cursor="default",m||r(),!0)},r=function(){try{var t=g.getZoomHandleStatus_();if(g.isChangingRange_=!0,t.isZoomed){var e=a(t);g.dygraph_.doZoomXDates_(e[0],e[1])}else g.dygraph_.resetZoom()}finally{g.isChangingRange_=!1}},o=function(t){var e=g.leftZoomHandle_.getBoundingClientRect(),a=e.left+e.width/2,i=(e=g.rightZoomHandle_.getBoundingClientRect()).left+e.width/2;return t.clientX>a&&t.clientX<i},s=function(t){return!(x||!o(t)||!g.getZoomHandleStatus_().isZoomed||(O.cancelEvent(t),x=!0,_=t.clientX,"mousedown"===t.type&&(O.addEvent(f,"mousemove",l),O.addEvent(f,"mouseup",h)),0))},l=function(t){if(!x)return!1;O.cancelEvent(t);var e=t.clientX-_;if(Math.abs(e)<4)return!0;_=t.clientX;var a=g.getZoomHandleStatus_(),i=a.leftHandlePos,n=a.rightHandlePos,r=n-i;i+e<=g.canvasRect_.x?n=(i=g.canvasRect_.x)+r:n+e>=g.canvasRect_.x+g.canvasRect_.w?i=(n=g.canvasRect_.x+g.canvasRect_.w)-r:(i+=e,n+=e);var o=g.leftZoomHandle_.width/2;return g.leftZoomHandle_.style.left=i-o+"px",g.rightZoomHandle_.style.left=n-o+"px",g.drawInteractiveLayer_(),m&&u(),!0},h=function(t){return!!x&&(x=!1,O.removeEvent(f,"mousemove",l),O.removeEvent(f,"mouseup",h),m||u(),!0)},u=function(){try{g.isChangingRange_=!0,g.dygraph_.dateWindow_=a(g.getZoomHandleStatus_()),g.dygraph_.drawGraph_(!1)}finally{g.isChangingRange_=!1}},t=function(t){if(!y&&!x){var e=o(t)?"move":"default";e!=g.fgcanvas_.style.cursor&&(g.fgcanvas_.style.cursor=e)}},d=function(t){"touchstart"==t.type&&1==t.targetTouches.length?e(t.targetTouches[0])&&O.cancelEvent(t):"touchmove"==t.type&&1==t.targetTouches.length?i(t.targetTouches[0])&&O.cancelEvent(t):n(t)},c=function(t){"touchstart"==t.type&&1==t.targetTouches.length?s(t.targetTouches[0])&&O.cancelEvent(t):"touchmove"==t.type&&1==t.targetTouches.length?l(t.targetTouches[0])&&O.cancelEvent(t):h(t)},p=function(t,e){for(var a=["touchstart","touchend","touchmove","touchcancel"],i=0;i<a.length;i++)g.dygraph_.addAndTrackEvent(t,a[i],e)},this.setDefaultOption_("interactionModel",A.default.dragIsPanInteractionModel),this.setDefaultOption_("panEdgeFraction",1e-4);var w=window.opera?"mousedown":"dragstart";this.dygraph_.addAndTrackEvent(this.leftZoomHandle_,w,e),this.dygraph_.addAndTrackEvent(this.rightZoomHandle_,w,e),this.dygraph_.addAndTrackEvent(this.fgcanvas_,"mousedown",s),this.dygraph_.addAndTrackEvent(this.fgcanvas_,"mousemove",t),this.hasTouchInterface_&&(p(this.leftZoomHandle_,d),p(this.rightZoomHandle_,d),p(this.fgcanvas_,c))},n.prototype.drawStaticLayer_=function(){var t=this.bgcanvas_ctx_;t.clearRect(0,0,this.canvasRect_.w,this.canvasRect_.h);try{this.drawMiniPlot_()}catch(t){console.warn(t)}this.bgcanvas_ctx_.lineWidth=this.getOption_("rangeSelectorBackgroundLineWidth"),t.strokeStyle=this.getOption_("rangeSelectorBackgroundStrokeColor"),t.beginPath(),t.moveTo(.5,.5),t.lineTo(.5,this.canvasRect_.h-.5),t.lineTo(this.canvasRect_.w-.5,this.canvasRect_.h-.5),t.lineTo(this.canvasRect_.w-.5,.5),t.stroke()},n.prototype.drawMiniPlot_=function(){var t=this.getOption_("rangeSelectorPlotFillColor"),e=this.getOption_("rangeSelectorPlotFillGradientColor"),a=this.getOption_("rangeSelectorPlotStrokeColor");if(t||a){var i=this.getOption_("stepPlot"),n=this.computeCombinedSeriesAndLimits_(),r=n.yMax-n.yMin,o=this.bgcanvas_ctx_,s=this.dygraph_.xAxisExtremes(),l=Math.max(s[1]-s[0],1e-30),h=(this.canvasRect_.w-.5)/l,u=(this.canvasRect_.h-.5)/r,d=this.canvasRect_.w-.5,c=this.canvasRect_.h-.5,p=null,g=null;o.beginPath(),o.moveTo(.5,c);for(var f=0;f<n.data.length;f++){var _=n.data[f],v=null!==_[0]?(_[0]-s[0])*h:NaN,y=null!==_[1]?c-(_[1]-n.yMin)*u:NaN;!i&&null!==p&&Math.round(v)==Math.round(p)||(isFinite(v)&&isFinite(y)?(null===p?o.lineTo(v,c):i&&o.lineTo(v,g),o.lineTo(v,y),p=v,g=y):(null!==p&&(i?(o.lineTo(v,g),o.lineTo(v,c)):o.lineTo(p,c)),p=g=null))}if(o.lineTo(d,c),o.closePath(),t){var x=this.bgcanvas_ctx_.createLinearGradient(0,0,0,c);e&&x.addColorStop(0,e),x.addColorStop(1,t),this.bgcanvas_ctx_.fillStyle=x,o.fill()}a&&(this.bgcanvas_ctx_.strokeStyle=a,this.bgcanvas_ctx_.lineWidth=this.getOption_("rangeSelectorPlotLineWidth"),o.stroke())}},n.prototype.computeCombinedSeriesAndLimits_=function(){var t,e=this.dygraph_,a=this.getOption_("logscale"),i=e.numColumns(),n=e.getLabels(),r=new Array(i),o=!1,s=e.visibility(),l=[];for(t=1;t<i;t++){var h=this.getOption_("showInRangeSelector",n[t]);l.push(h),null!==h&&(o=!0)}if(o)for(t=1;t<i;t++)r[t]=l[t-1];else for(t=1;t<i;t++)r[t]=s[t-1];var u=[],d=e.dataHandler_,c=e.attributes_;for(t=1;t<e.numColumns();t++)if(r[t]){var p=d.extractSeries(e.rawData_,t,c);1<e.rollPeriod()&&(p=d.rollingAverage(p,e.rollPeriod(),c)),u.push(p)}var g=[];for(t=0;t<u[0].length;t++){for(var f=0,_=0,v=0;v<u.length;v++){var y=u[v][t][1];null===y||isNaN(y)||(_++,f+=y)}g.push([u[0][t][0],f/_])}var x=Number.MAX_VALUE,m=-Number.MAX_VALUE;for(t=0;t<g.length;t++){var b=g[t][1];null!==b&&isFinite(b)&&(!a||0<b)&&(x=Math.min(x,b),m=Math.max(m,b))}if(a)for(m=O.log10(m),m+=.25*m,x=O.log10(x),t=0;t<g.length;t++)g[t][1]=O.log10(g[t][1]);else{var w,A=m-x;m+=w=A<=Number.MIN_VALUE?.25*m:.25*A,x-=w}return{data:g,yMin:x,yMax:m}},n.prototype.placeZoomHandles_=function(){var t=this.dygraph_.xAxisExtremes(),e=this.dygraph_.xAxisRange(),a=t[1]-t[0],i=Math.max(0,(e[0]-t[0])/a),n=Math.max(0,(t[1]-e[1])/a),r=this.canvasRect_.x+this.canvasRect_.w*i,o=this.canvasRect_.x+this.canvasRect_.w*(1-n),s=Math.max(this.canvasRect_.y,this.canvasRect_.y+(this.canvasRect_.h-this.leftZoomHandle_.height)/2),l=this.leftZoomHandle_.width/2;this.leftZoomHandle_.style.left=r-l+"px",this.leftZoomHandle_.style.top=s+"px",this.rightZoomHandle_.style.left=o-l+"px",this.rightZoomHandle_.style.top=this.leftZoomHandle_.style.top,this.leftZoomHandle_.style.visibility="visible",this.rightZoomHandle_.style.visibility="visible"},n.prototype.drawInteractiveLayer_=function(){var t=this.fgcanvas_ctx_;t.clearRect(0,0,this.canvasRect_.w,this.canvasRect_.h);var e=this.canvasRect_.w-1,a=this.canvasRect_.h-1,i=this.getZoomHandleStatus_();if(t.strokeStyle=this.getOption_("rangeSelectorForegroundStrokeColor"),t.lineWidth=this.getOption_("rangeSelectorForegroundLineWidth"),i.isZoomed){var n=Math.max(1,i.leftHandlePos-this.canvasRect_.x),r=Math.min(e,i.rightHandlePos-this.canvasRect_.x);t.fillStyle="rgba(240, 240, 240, "+this.getOption_("rangeSelectorAlpha").toString()+")",t.fillRect(0,0,n,this.canvasRect_.h),t.fillRect(r,0,this.canvasRect_.w-r,this.canvasRect_.h),t.beginPath(),t.moveTo(1,1),t.lineTo(n,1),t.lineTo(n,a),t.lineTo(r,a),t.lineTo(r,1),t.lineTo(e,1),t.stroke()}else t.beginPath(),t.moveTo(1,1),t.lineTo(1,a),t.lineTo(e,a),t.lineTo(e,1),t.stroke()},n.prototype.getZoomHandleStatus_=function(){var t=this.leftZoomHandle_.width/2,e=parseFloat(this.leftZoomHandle_.style.left)+t,a=parseFloat(this.rightZoomHandle_.style.left)+t;return{leftHandlePos:e,rightHandlePos:a,isZoomed:e-1>this.canvasRect_.x||a+1<this.canvasRect_.x+this.canvasRect_.w}},a.default=n,e.exports=a.default},{"../dygraph-interaction-model":12,"../dygraph-utils":17,"../iframe-tarp":19}]},{},[18])(18)});