e){returne.values.length}).length){varO=N.selectAll(".nv-noData").data([E]);returnO.enter().append("text").attr("class","nvd3 nv-noData").attr("dy","-.7em").style("text-anchor","middle"),O.attr("x",o.left+k/2).attr("y",o.top+L/2).text(function(e){returne}),T}N.selectAll(".nv-noData").remove(),g=t.xScale(),y=t.yScale();varM=N.selectAll("g.nv-wrap.nv-lineChart").data([m]),_=M.enter().append("g").attr("class","nvd3 nv-wrap nv-lineChart").append("g"),D=M.select("g");_.append("rect").attr("width",k).attr("height",L).style("opacity",0),_.append("g").attr("class","nv-x nv-axis"),_.append("g").attr("class","nv-y nv-axis"),_.append("g").attr("class","nv-linesWrap"),_.append("g").attr("class","nv-legendWrap"),_.append("g").attr("class","nv-interactive"),l&&(i.width(k),D.select(".nv-legendWrap").datum(m).call(i),o.top!=i.height()&&(o.top=i.height(),L=(f||parseInt(N.style("height"))||400)-o.top-o.bottom),M.select(".nv-legendWrap").attr("transform","translate(0,"+-o.top+")")),M.attr("transform","translate("+o.left+","+o.top+")"),p&&D.select(".nv-y.nv-axis").attr("transform","translate("+k+",0)"),d&&(s.width(k).height(L).margin({left:o.left,top:o.top}).svgContainer(N).xScale(g),M.select(".nv-interactive").call(s)),t.width(k).height(L).color(m.map(function(e,t){returne.color||u(e,t)}).filter(function(e,t){return!m[t].disabled}));varP=D.select(".nv-linesWrap").datum(m.filter(function(e){return!e.disabled}));d3.transition(P).call(t),c&&(n.scale(g).ticks(k/100).tickSize(-L,0),D.select(".nv-x.nv-axis").attr("transform","translate(0,"+y.range()[0]+")"),d3.transition(D.select(".nv-x.nv-axis")).call(n)),h&&(r.scale(y).ticks(L/36).tickSize(-k,0),d3.transition(D.select(".nv-y.nv-axis")).call(r)),i.dispatch.on("legendClick",function(e,t){e.disabled=!e.disabled,m.filter(function(e){return!e.disabled}).length||m.map(function(e){returne.disabled=!1,M.selectAll(".nv-series").classed("disabled",!1),e}),b.disabled=m.map(function(e){return!!e.disabled}),S.stateChange(b),T.update()}),i.dispatch.on("legendDblclick",function(e){m.forEach(function(e){e.disabled=!0}),e.disabled=!1,b.disabled=m.map(function(e){return!!e.disabled}),S.stateChange(b),T.update()}),s.dispatch.on("elementMousemove",function(i){t.clearHighlights();vara,f,l,c=[];m.filter(function(e,t){returne.seriesIndex=t,!e.disabled}).forEach(function(n,r){f=e.interactiveBisect(n.values,i.pointXValue,T.x()),t.highlightPoint(r,f,!0);vars=n.values[f];if(typeofs=="undefined")return;typeofa=="undefined"&&(a=s),typeofl=="undefined"&&(l=T.xScale()(T.x()(s,f))),c.push({key:n.key,value:T.y()(s,f),color:u(n,n.seriesIndex)})});varh=n.tickFormat()(T.x()(a,f));s.tooltip.position({left:l+o.left,top:i.mouseY+o.top}).chartContainer(C.parentNode).enabled(v).valueFormatter(function(e,t){returnr.tickFormat()(e)}).data({value:h,series:c})(),s.renderGuideLine(l)}),s.dispatch.on("elementMouseout",function(e){S.tooltipHide(),t.clearHighlights()}),S.on("tooltipShow",function(e){v&&x(e,C.parentNode)}),S.on("changeState",function(e){typeofe.disabled!="undefined"&&(m.forEach(function(t,n){t.disabled=e.disabled[n]}),b.disabled=e.disabled),T.update()})}),T}vart=e.models.line(),n=e.models.axis(),r=e.models.axis(),i=e.models.legend(),s=e.interactiveGuideline(),o={top:30,right:20,bottom:50,left:60},u=e.utils.defaultColor(),a=null,f=null,l=!0,c=!0,h=!0,p=!1,d=!1,v=!0,m=function(e,t,n,r,i){return"<h3>"+e+"</h3>"+"<p>"+n+" at "+t+"</p>"},g,y,b={},w=null,E="No Data Available.",S=d3.dispatch("tooltipShow","tooltipHide","stateChange","changeState");n.orient("bottom").tickPadding(7),r.orient(p?"right":"left");varx=function(i,s){varo=i.pos[0]+(s.offsetLeft||0),u=i.pos[1]+(s.offsetTop||0),a=n.tickFormat()(t.x()(i.point,i.pointIndex)),f=r.tickFormat()(t.y()(i.point,i.pointIndex)),l=m(i.series.key,a,f,i,T);e.tooltip.show([o,u],l,null,null,s)};returnt.dispatch.on("elementMouseover.tooltip",function(e){e.pos=[e.pos[0]+o.left,e.pos[1]+o.top],S.tooltipShow(e)}),t.dispatch.on("elementMouseout.tooltip",function(e){S.tooltipHide(e)}),S.on("tooltipHide",function(){v&&e.tooltip.cleanup()}),T.dispatch=S,T.lines=t,T.legend=i,T
.length?(f=e,S):f},S.stacked=function(e){returnarguments.length?(c=e,S):c},S.clipEdge=function(e){returnarguments.length?(l=e,S):l},S.color=function(t){returnarguments.length?(h=e.utils.getColor(t),S):h},S.barColor=function(t){returnarguments.length?(d=e.utils.getColor(t),S):d},S.disabled=function(e){returnarguments.length?(v=e,S):v},S.id=function(e){returnarguments.length?(o=e,S):o},S.hideable=function(e){returnarguments.length?(p=e,S):p},S.delay=function(e){returnarguments.length?(m=e,S):m},S},e.models.multiBarChart=function(){functionL(e){returne.each(function(e){varb=d3.select(this),A=this,O=(u||parseInt(b.style("width"))||960)-o.left-o.right,M=(a||parseInt(b.style("height"))||400)-o.top-o.bottom;L.update=function(){b.transition().call(L)},L.container=this,S.disabled=e.map(function(e){return!!e.disabled});if(!x){var_;x={};for(_inS)S[_]instanceofArray?x[_]=S[_].slice(0):x[_]=S[_]}if(!e||!e.length||!e.filter(function(e){returne.values.length}).length){varD=b.selectAll(".nv-noData").data([T]);returnD.enter().append("text").attr("class","nvd3 nv-noData").attr("dy","-.7em").style("text-anchor","middle"),D.attr("x",o.left+O/2).attr("y",o.top+M/2).text(function(e){returne}),L}b.selectAll(".nv-noData").remove(),w=t.xScale(),E=t.yScale();varP=b.selectAll("g.nv-wrap.nv-multiBarWithLegend").data([e]),H=P.enter().append("g").attr("class","nvd3 nv-wrap nv-multiBarWithLegend").append("g"),B=P.select("g");H.append("g").attr("class","nv-x nv-axis"),H.append("g").attr("class","nv-y nv-axis"),H.append("g").attr("class","nv-barsWrap"),H.append("g").attr("class","nv-legendWrap"),H.append("g").attr("class","nv-controlsWrap"),c&&(i.width(O-C()),t.barColor()&&e.forEach(function(e,t){e.color=d3.rgb("#ccc").darker(t*1.5).toString()}),B.select(".nv-legendWrap").datum(e).call(i),o.top!=i.height()&&(o.top=i.height(),M=(a||parseInt(b.style("height"))||400)-o.top-o.bottom),B.select(".nv-legendWrap").attr("transform","translate("+C()+","+-o.top+")"));if(l){varj=[{key:"Grouped",disabled:t.stacked()},{key:"Stacked",disabled:!t.stacked()}];s.width(C()).color(["#444","#444","#444"]),B.select(".nv-controlsWrap").datum(j).attr("transform","translate(0,"+-o.top+")").call(s)}P.attr("transform","translate("+o.left+","+o.top+")"),d&&B.select(".nv-y.nv-axis").attr("transform","translate("+O+",0)"),t.disabled(e.map(function(e){returne.disabled})).width(O).height(M).color(e.map(function(e,t){returne.color||f(e,t)}).filter(function(t,n){return!e[n].disabled}));varF=B.select(".nv-barsWrap").datum(e.filter(function(e){return!e.disabled}));d3.transition(F).call(t);if(h){n.scale(w).ticks(O/100).tickSize(-M,0),B.select(".nv-x.nv-axis").attr("transform","translate(0,"+E.range()[0]+")"),d3.transition(B.select(".nv-x.nv-axis")).call(n);varI=B.select(".nv-x.nv-axis > g").selectAll("g");I.selectAll("line, text").style("opacity",1);if(m){varq=function(e,t){return"translate("+e+","+t+")"},R=5,U=17;I.selectAll("text").attr("transform",function(e,t,n){returnq(0,n%2==0?R:U)});varz=d3.selectAll(".nv-x.nv-axis .nv-wrap g g text")[0].length;B.selectAll(".nv-x.nv-axis .nv-axisMaxMin text").attr("transform",function(e,t){returnq(0,t===0||z%2!==0?U:R)})}v&&I.filter(function(t,n){returnn%Math.ceil(e[0].values.length/(O/100))!==0}).selectAll("text, line").style("opacity",0),g&&I.selectAll("text").attr("transform","rotate("+g+" 0,0)").attr("text-anchor",g>0?"start":"end"),B.select(".nv-x.nv-axis").selectAll("g.nv-axisMaxMin text").style("opacity",1)}p&&(r.scale(E).ticks(M/36).tickSize(-O,0),d3.transition(B.select(".nv-y.nv-axis")).call(r)),i.dispatch.on("legendClick",function(t,n){t.disabled=!t.disabled,e.filter(function(e){return!e.disabled}).length||e.map(function(e){returne.disabled=!1,P.selectAll(".nv-series").classed("disabled",!1),e}),S.disabled=e.map(function(e){return!!e.disabled}),N.stateChange(S),L.update()}),i.dispatch.on("legendDblclick",function(t){e.forEach(function(e){e.disabled=!0}),t.disabled=!1,S.disabled=e.map(function(e){return!!e.disabled}),N.stateChange(S),L.update()}),s.dispatch.on("legendClick",function(e,n){if(!e.disabled)retu
,!1),w.elementMouseout({label:i(e.data),value:s(e.data),point:e.data,index:t,id:u})}).on("click",function(e,t){w.elementClick({label:i(e.data),value:s(e.data),point:e.data,index:t,pos:d3.event,id:u}),d3.event.stopPropagation()}).on("dblclick",function(e,t){w.elementDblClick({label:i(e.data),value:s(e.data),point:e.data,index:t,pos:d3.event,id:u}),d3.event.stopPropagation()});O.attr("fill",function(e,t){returna(e,t)}).attr("stroke",function(e,t){returna(e,t)});var_=M.append("path").each(function(e){this._current=e});d3.transition(O.select("path")).attr("d",L).attrTween("d",H);if(l){varD=d3.svg.arc().innerRadius(0);c&&(D=L),h&&(D=d3.svg.arc().outerRadius(L.outerRadius())),M.append("g").classed("nv-label",!0).each(function(e,t){varn=d3.select(this);n.attr("transform",function(e){if(m){e.outerRadius=S+10,e.innerRadius=S+15;vart=(e.startAngle+e.endAngle)/2*(180/Math.PI);return(e.startAngle+e.endAngle)/2<Math.PI?t-=90:t+=90,"translate("+D.centroid(e)+") rotate("+t+")"}returne.outerRadius=E+10,e.innerRadius=E+15,"translate("+D.centroid(e)+")"}),n.append("rect").style("stroke","#fff").style("fill","#fff").attr("rx",3).attr("ry",3),n.append("text").style("text-anchor",m?(e.startAngle+e.endAngle)/2<Math.PI?"start":"end":"middle").style("fill","#000")}),O.select(".nv-label").transition().attr("transform",function(e){if(m){e.outerRadius=S+10,e.innerRadius=S+15;vart=(e.startAngle+e.endAngle)/2*(180/Math.PI);return(e.startAngle+e.endAngle)/2<Math.PI?t-=90:t+=90,"translate("+D.centroid(e)+") rotate("+t+")"}returne.outerRadius=E+10,e.innerRadius=E+15,"translate("+D.centroid(e)+")"}),O.each(function(e,t){varn=d3.select(this);n.select(".nv-label text").style("text-anchor",m?(e.startAngle+e.endAngle)/2<Math.PI?"start":"end":"middle").text(function(e,t){varn=(e.endAngle-e.startAngle)/(2*Math.PI),r={key:i(e.data),value:s(e.data),percent:d3.format("%")(n)};returne.value&&n>d?r[p]:""});varr=n.select("text").node().getBBox();n.select(".nv-label rect").attr("width",r.width+10).attr("height",r.height+10).attr("transform",function(){return"translate("+[r.x-5,r.y-5]+")"})})}}),E}vart={top:0,right:0,bottom:0,left:0},n=500,r=500,i=function(e){returne.x},s=function(e){returne.y},o=function(e){returne.description},u=Math.floor(Math.random()*1e4),a=e.utils.defaultColor(),f=d3.format(",.2f"),l=!0,c=!0,h=!1,p="key",d=.02,v=!1,m=!1,g=!1,y=!1,b=.5,w=d3.dispatch("chartClick","elementClick","elementDblClick","elementMouseover","elementMouseout");returnE.dispatch=w,E.margin=function(e){returnarguments.length?(t.top=typeofe.top!="undefined"?e.top:t.top,t.right=typeofe.right!="undefined"?e.right:t.right,t.bottom=typeofe.bottom!="undefined"?e.bottom:t.bottom,t.left=typeofe.left!="undefined"?e.left:t.left,E):t},E.width=function(e){returnarguments.length?(n=e,E):n},E.height=function(e){returnarguments.length?(r=e,E):r},E.values=function(t){returne.log("pie.values() is no longer supported."),E},E.x=function(e){returnarguments.length?(i=e,E):i},E.y=function(e){returnarguments.length?(s=d3.functor(e),E):s},E.description=function(e){returnarguments.length?(o=e,E):o},E.showLabels=function(e){returnarguments.length?(l=e,E):l},E.labelSunbeamLayout=function(e){returnarguments.length?(m=e,E):m},E.donutLabelsOutside=function(e){returnarguments.length?(h=e,E):h},E.pieLabelsOutside=function(e){returnarguments.length?(c=e,E):c},E.labelType=function(e){returnarguments.length?(p=e,p=p||"key",E):p},E.donut=function(e){returnarguments.length?(v=e,E):v},E.donutRatio=function(e){returnarguments.length?(b=e,E):b},E.startAngle=function(e){returnarguments.length?(g=e,E):g},E.endAngle=function(e){returnarguments.length?(y=e,E):y},E.id=function(e){returnarguments.length?(u=e,E):u},E.color=function(t){returnarguments.length?(a=e.utils.getColor(t),E):a},E.valueFormat=function(e){returnarguments.length?(f=e,E):f},E.labelThreshold=function(e){returnarguments.length?(d=e,E):d},E},e.models.pieChart=function(){functionv(e){returne.each(function(e){varu=d3.select(this),a=this,f=(i||parseInt(u.style("width"))||960)-r.left-r.right,d=(s||parseInt(u.style