functionmb(a){varb=Na[a.id];a.name=p(b)?b:a.id;returna}functionqc(a){varb=a[0],c={},f=[],m,d;for(m=1;m<a.length;m++){c={};for(d=0;d<a[m].length;d++)c[b[d]]=a[m][d];f.push(c)}returnf}functionrc(a){varb=[],c,f,m;for(c=0;c<a.length;c++)for(m=a[c][0],f=1;f<a[c].length;f++)v(b[f-1])&&(b[f-1]={}),b[f-1][m]=a[c][f];returnb}functionOa(a){varb=d.keys(a[0]).filter(Dd),c=d.keys(a[0]).filter(pc);if(A&&0===c.length)returnL.alert('data.x or data.xs must be specified when axis.x.type == "timeseries"'),
c.length)returnN.alert('data.x or data.xs must be specified when axis.x.type == "timeseries"'),[];Cb&&b.forEach(function(b){varl=qa?qa:da?da[b]:null;0<=c.indexOf(l)&&(g.data.x[b]=a.map(function(a){returna[l]}))});b=b.map(function(b){varc=Gd(b);return{id:c,id_org:b,values:a.map(function(a,d){vare;e=qa?qa:da?da[b]:null;e=A?pa(a[e]):Cb?a[e]?a[e]:bing.data.x&&g.data.x[b]&&g.data.x[b][d]?g.data.x[b][d]:d:d;a.x=e;return{x:e,value:null===a[b]||isNaN(a[b])?null:+a[b],id:c}})}});b.forEach(function(a){varb;
C[a]||"area"===C[a]||"area-spline"===C[a]}functionJc(a){a="string"===typeofa?a:a.id;return"spline"===C[a]||"area-spline"===C[a]}functionJa(a){return"bar"===C["string"===typeofa?a:a.id]}functionKc(a){return"pie"===C["string"===typeofa?a:a.id]}functionLc(a){returnJa(a)?a.values:[]}functionLd(a){varb;(b=Eb(a))||(b="scatter"===C["string"===typeofa?a:a.id]);returnb?a.values:[]}functionoa(a){varb;if(!a)throwError(a+" can not be parsed as d3.time with format "+Fb+". Maybe 'x' of this data is not defined. See data.x or data.xs option.");
b=d.time.format(Fb).parse(a);if(!b)throwError("Failed to parse '"+a+"' with format "+Fb);returnb}functionMc(a,b){varc=d.mouse(a),f=d.select(a),m=1*f.attr("cx"),f=1*f.attr("cy");returnMath.sqrt(Math.pow(m-c[0],2)+Math.pow(f-c[1],2))<b}functionNc(a){varb=d.mouse(a),c=d.select(a);a=1*c.attr("x");varf=1*c.attr("y"),c=1*c.attr("width");returna-10<b[0]&&b[0]<a+c+10&&f-10<b[1]}functionMd(a,b){varc;for(c=0;c<b.length;c++)if(b[c].start<a&&a<=b[c].end)return!0;return!1}functionCd(a,b){varc=!1;
D["string"===typeofa?a:a.id]}functionNc(a){returnHa(a)?a.values:[]}functionOd(a){varb;(b=Eb(a))||(b="scatter"===D["string"===typeofa?a:a.id]);returnb?a.values:[]}functionpa(a){varb;if(!a)throwError(a+" can not be parsed as d3.time with format "+Fb+". Maybe 'x' of this data is not defined. See data.x or data.xs option.");b=d.time.format(Fb).parse(a);if(!b)throwError("Failed to parse '"+a+"' with format "+Fb);returnb}functionOc(a,b){varc=d.mouse(a),f=d.select(a),l=1*f.attr("cx"),f=1*f.attr("cy");
" "+c(l(f+e))}:function(a,d,f,e){return"M"+b(k(f))+" "+c(l(f))+" "+b(k(f+e))+" "+c(l(f+e))};for(d=0;d<a.length;d++)if(v(r)||!Md(a[d].x,r))h+=" "+Tc(a[d])+" "+q(a[d]);else{k=M(a[d-1].x,a[d].x);l=J(a[d-1].value,a[d].value);e=b(a[d].x)-b(a[d-1].x);n=c(a[d].value)-c(a[d-1].value);e=Math.sqrt(Math.pow(e,2)+Math.pow(n,2));n=2/e;vart=2*n;for(e=n;1>=e;e+=t)h+=f(a[d-1],a[d],e,n)}returnh}functionLb(a){varb,c;ob=d.select(va);if(ob.empty())L.alert('No bind element found. Check the selector specified by "bindto" and existance of that element. Default "bindto" is "#chart".');
S(a[d-1].value,a[d].value);e=b(a[d].x)-b(a[d-1].x);m=c(a[d].value)-c(a[d-1].value);e=Math.sqrt(Math.pow(e,2)+Math.pow(m,2));m=2/e;vars=2*m;for(e=m;1>=e;e+=s)g+=f(a[d-1],a[d],e,m)}returng}functionLb(a){varb;nb=d.select(va);if(nb.empty())N.alert('No bind element found. Check the selector specified by "bindto" and existance of that element. Default "bindto" is "#chart".');else{nb.html("");g.data.x={};g.data.targets=Ma(a);ta();Q();n.domain(d.extent(jb(g.data.targets)));y.domain(hb("y"));X.domain(hb("y2"));
"enabled"],!1),ed=e(["zoom","extent"],null),be=e(["zoom","privileged"],!1),Vd=e(["onenter"],function(){}),Wd=e(["onleave"],function(){});if(!("data"inca))throwError("data is required in config");varpa=e(["data","x"],null),aa=e(["data","xs"],null),Fb=e(["data","x_format"],"%Y-%m-%d"),Ed=e(["data","id_converter"],function(a){returna}),Na=e(["data","names"],{}),s=e(["data","groups"],[]),mc=e(["data","axes"],{}),bd=e(["data","type"],null),C=e(["data","types"],{}),fd=e(["data","regions"],{}),me=e(["data",
"enabled"],!1),gd=e(["zoom","extent"],null),ce=e(["zoom","privileged"],!1),Yd=e(["onenter"],function(){}),Zd=e(["onleave"],function(){});if(!("data"in$))throwError("data is required in config");varqa=e(["data","x"],null),da=e(["data","xs"],null),Fb=e(["data","x_format"],"%Y-%m-%d"),Gd=e(["data","id_converter"],function(a){returna}),La=e(["data","names"],{}),v=e(["data","groups"],[]),nc=e(["data","axes"],{}),dd=e(["data","type"],null),D=e(["data","types"],{}),hd=e(["data","regions"],{}),pe=e(["data",
a.done);elsethrowError("url or rows or columns is required.");};h.unload=function(a){h.data.targets=h.data.targets.filter(function(b){returnb.id!==a});q.selectAll(".target-"+a).transition().style("opacity",0).remove();Aa&&(q.selectAll(".legend-item-"+a).remove(),rb(h.data.targets));0<h.data.targets.length&&E({withUpdateOrgXDomain:!0,withUpdateXDomain:!0})};h.selected=function(a){a=p(a)?"-"+a:"";returnd.merge(k.selectAll(".-shapes"+a).selectAll(".-shape").filter(function(){returnd.select(this).classed(ja)}).map(function(a){returna.map(function(a){returna.__data__})}))};
a.done);elsethrowError("url or rows or columns is required.");};g.unload=function(a){g.data.targets=g.data.targets.filter(function(b){returnb.id!==a});p.selectAll(".target-"+a).transition().style("opacity",0).remove();Aa&&(p.selectAll(".legend-item-"+a).remove(),qb(g.data.targets));0<g.data.targets.length&&F({withUpdateOrgXDomain:!0,withUpdateXDomain:!0})};g.selected=function(a){a=q(a)?"-"+a:"";returnd.merge(k.selectAll(".-shapes"+a).selectAll(".-shape").filter(function(){returnd.select(this).classed(ia)}).map(function(a){returna.map(function(a){returna.__data__})}))};