Файл: templates/backend/default/assets/plugins/jquery-ricksaw-chart/js/d3.v2.min.js
Строк: 7143
<?php
!function(){function e(e,l){try{for(var t in l)Object.defineProperty(e.prototype,t,{value:l[t],enumerable:!1})}catch(n){e.prototype=l}}function l(e){for(var l=-1,t=e.length,n=[];++l<t;)n.push(e[l]);return n}function t(e){return Array.prototype.slice.call(e)}function n(){}function i(e){return e}function a(){return this}function o(){return!0}function r(e){return"function"==typeof e?e:function(){return e}}function s(e,l,t){return function(){var n=t.apply(l,arguments);return arguments.length?e:n}}function c(e){return null!=e&&!isNaN(e)}function u(e){return e.length}function d(e){return null==e}function h(e){return e.trim().replace(/s+/g," ")}function f(e){for(var l=1;e*l%1;)l*=10;return l}function p(){}function m(e){function l(){for(var l,n=t,i=-1,a=n.length;++i<a;)(l=n[i].on)&&l.apply(this,arguments);return e}var t=[],i=new n;return l.on=function(l,n){var a,o=i.get(l);return arguments.length<2?o&&o.on:(o&&(o.on=null,t=t.slice(0,a=t.indexOf(o)).concat(t.slice(a+1)),i.remove(l)),n&&t.push(i.set(l,{on:n})),e)},l}function g(e,l){return l-(e?1+Math.floor(Math.log(e+Math.pow(10,1+Math.floor(Math.log(e)/Math.LN10)-l))/Math.LN10):1)}function v(e){return e+""}function y(e){for(var l=e.lastIndexOf("."),t=l>=0?e.substring(l):(l=e.length,""),n=[];l>0;)n.push(e.substring(l-=3,l+3));return n.reverse().join(",")+t}function b(e,l){var t=Math.pow(10,3*Math.abs(8-l));return{scale:l>8?function(e){return e/t}:function(e){return e*t},symbol:e}}function T(e){return function(l){return 0>=l?0:l>=1?1:e(l)}}function C(e){return function(l){return 1-e(1-l)}}function E(e){return function(l){return.5*(.5>l?e(2*l):2-e(2-2*l))}}function D(e){return e}function w(e){return function(l){return Math.pow(l,e)}}function _(e){return 1-Math.cos(e*Math.PI/2)}function I(e){return Math.pow(2,10*(e-1))}function S(e){return 1-Math.sqrt(1-e*e)}function k(e,l){var t;return arguments.length<2&&(l=.45),arguments.length<1?(e=1,t=l/4):t=l/(2*Math.PI)*Math.asin(1/e),function(n){return 1+e*Math.pow(2,10*-n)*Math.sin(2*(n-t)*Math.PI/l)}}function x(e){return e||(e=1.70158),function(l){return l*l*((e+1)*l-e)}}function O(e){return 1/2.75>e?7.5625*e*e:2/2.75>e?7.5625*(e-=1.5/2.75)*e+.75:2.5/2.75>e?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375}function R(){d3.event.stopPropagation(),d3.event.preventDefault()}function M(){for(var e,l=d3.event;e=l.sourceEvent;)l=e;return l}function N(e){for(var l=new p,t=0,n=arguments.length;++t<n;)l[arguments[t]]=m(l);return l.of=function(t,n){return function(i){try{var a=i.sourceEvent=d3.event;i.target=e,d3.event=i,l[i.type].apply(t,n)}finally{d3.event=a}}},l}function A(e){var l=[e.a,e.b],t=[e.c,e.d],n=L(l),i=K(l,t),a=L(P(t,l,-i))||0;l[0]*t[1]<t[0]*l[1]&&(l[0]*=-1,l[1]*=-1,n*=-1,i*=-1),this.rotate=(n?Math.atan2(l[1],l[0]):Math.atan2(-t[0],t[1]))*ra,this.translate=[e.e,e.f],this.scale=[n,a],this.skew=a?Math.atan2(i,a)*ra:0}function K(e,l){return e[0]*l[0]+e[1]*l[1]}function L(e){var l=Math.sqrt(K(e,e));return l&&(e[0]/=l,e[1]/=l),l}function P(e,l,t){return e[0]+=t*l[0],e[1]+=t*l[1],e}function F(e){return"transform"==e?d3.interpolateTransform:d3.interpolate}function B(e,l){return l=l-(e=+e)?1/(l-e):0,function(t){return(t-e)*l}}function $(e,l){return l=l-(e=+e)?1/(l-e):0,function(t){return Math.max(0,Math.min(1,(t-e)*l))}}function H(){}function Z(e,l,t){return new U(e,l,t)}function U(e,l,t){this.r=e,this.g=l,this.b=t}function z(e){return 16>e?"0"+Math.max(0,e).toString(16):Math.min(255,e).toString(16)}function j(e,l,t){var n,i,a,o=0,r=0,s=0;if(n=/([a-z]+)((.*))/i.exec(e))switch(i=n[2].split(","),n[1]){case"hsl":return t(parseFloat(i[0]),parseFloat(i[1])/100,parseFloat(i[2])/100);case"rgb":return l(q(i[0]),q(i[1]),q(i[2]))}return(a=da.get(e))?l(a.r,a.g,a.b):(null!=e&&"#"===e.charAt(0)&&(4===e.length?(o=e.charAt(1),o+=o,r=e.charAt(2),r+=r,s=e.charAt(3),s+=s):7===e.length&&(o=e.substring(1,3),r=e.substring(3,5),s=e.substring(5,7)),o=parseInt(o,16),r=parseInt(r,16),s=parseInt(s,16)),l(o,r,s))}function W(e,l,t){var n,i,a=Math.min(e/=255,l/=255,t/=255),o=Math.max(e,l,t),r=o-a,s=(o+a)/2;return r?(i=.5>s?r/(o+a):r/(2-o-a),n=e==o?(l-t)/r+(t>l?6:0):l==o?(t-e)/r+2:(e-l)/r+4,n*=60):i=n=0,Y(n,i,s)}function G(e,l,t){e=V(e),l=V(l),t=V(t);var n=rl((.4124564*e+.3575761*l+.1804375*t)/ma),i=rl((.2126729*e+.7151522*l+.072175*t)/ga),a=rl((.0193339*e+.119192*l+.9503041*t)/va);return tl(116*i-16,500*(n-i),200*(i-a))}function V(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function q(e){var l=parseFloat(e);return"%"===e.charAt(e.length-1)?Math.round(2.55*l):l}function Y(e,l,t){return new J(e,l,t)}function J(e,l,t){this.h=e,this.s=l,this.l=t}function X(e,l,t){function n(e){return e>360?e-=360:0>e&&(e+=360),60>e?a+(o-a)*e/60:180>e?o:240>e?a+(o-a)*(240-e)/60:a}function i(e){return Math.round(255*n(e))}var a,o;return e%=360,0>e&&(e+=360),l=0>l?0:l>1?1:l,t=0>t?0:t>1?1:t,o=.5>=t?t*(1+l):t+l-t*l,a=2*t-o,Z(i(e+120),i(e),i(e-120))}function Q(e,l,t){return new el(e,l,t)}function el(e,l,t){this.h=e,this.c=l,this.l=t}function ll(e,l,t){return tl(t,Math.cos(e*=Math.PI/180)*l,Math.sin(e)*l)}function tl(e,l,t){return new nl(e,l,t)}function nl(e,l,t){this.l=e,this.a=l,this.b=t}function il(e,l,t){var n=(e+16)/116,i=n+l/500,a=n-t/200;return i=ol(i)*ma,n=ol(n)*ga,a=ol(a)*va,Z(sl(3.2404542*i-1.5371385*n-.4985314*a),sl(-.969266*i+1.8760108*n+.041556*a),sl(.0556434*i-.2040259*n+1.0572252*a))}function al(e,l,t){return Q(180*(Math.atan2(t,l)/Math.PI),Math.sqrt(l*l+t*t),e)}function ol(e){return e>.206893034?e*e*e:(e-4/29)/7.787037}function rl(e){return e>.008856?Math.pow(e,1/3):7.787037*e+4/29}function sl(e){return Math.round(255*(.00304>=e?12.92*e:1.055*Math.pow(e,1/2.4)-.055))}function cl(e){return Gi(e,wa),e}function ul(e){return function(){return ba(e,this)}}function dl(e){return function(){return Ta(e,this)}}function hl(e,l){function t(){this.removeAttribute(e)}function n(){this.removeAttributeNS(e.space,e.local)}function i(){this.setAttribute(e,l)}function a(){this.setAttributeNS(e.space,e.local,l)}function o(){var t=l.apply(this,arguments);null==t?this.removeAttribute(e):this.setAttribute(e,t)}function r(){var t=l.apply(this,arguments);null==t?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,t)}return e=d3.ns.qualify(e),null==l?e.local?n:t:"function"==typeof l?e.local?r:o:e.local?a:i}function fl(e){return new RegExp("(?:^|\s+)"+d3.requote(e)+"(?:\s+|$)","g")}function pl(e,l){function t(){for(var t=-1;++t<i;)e[t](this,l)}function n(){for(var t=-1,n=l.apply(this,arguments);++t<i;)e[t](this,n)}e=e.trim().split(/s+/).map(ml);var i=e.length;return"function"==typeof l?n:t}function ml(e){var l=fl(e);return function(t,n){if(i=t.classList)return n?i.add(e):i.remove(e);var i=t.className,a=null!=i.baseVal,o=a?i.baseVal:i;n?(l.lastIndex=0,l.test(o)||(o=h(o+" "+e),a?i.baseVal=o:t.className=o)):o&&(o=h(o.replace(l," ")),a?i.baseVal=o:t.className=o)}}function gl(e,l,t){function n(){this.style.removeProperty(e)}function i(){this.style.setProperty(e,l,t)}function a(){var n=l.apply(this,arguments);null==n?this.style.removeProperty(e):this.style.setProperty(e,n,t)}return null==l?n:"function"==typeof l?a:i}function vl(e,l){function t(){delete this[e]}function n(){this[e]=l}function i(){var t=l.apply(this,arguments);null==t?delete this[e]:this[e]=t}return null==l?t:"function"==typeof l?i:n}function yl(e){return{__data__:e}}function bl(e){return function(){return Da(this,e)}}function Tl(e){return arguments.length||(e=d3.ascending),function(l,t){return e(l&&l.__data__,t&&t.__data__)}}function Cl(e,l,t){function n(){var l=this[a];l&&(this.removeEventListener(e,l,l.$),delete this[a])}function i(){function i(e){var t=d3.event;d3.event=e,r[0]=o.__data__;try{l.apply(o,r)}finally{d3.event=t}}var o=this,r=arguments;n.call(this),this.addEventListener(e,this[a]=i,i.$=t),i._=l}var a="__on"+e,o=e.indexOf(".");return o>0&&(e=e.substring(0,o)),l?i:n}function El(e,l){for(var t=0,n=e.length;n>t;t++)for(var i,a=e[t],o=0,r=a.length;r>o;o++)(i=a[o])&&l(i,o,t);return e}function Dl(e){return Gi(e,Ia),e}function wl(e,l,t){Gi(e,Sa);var i=new n,a=d3.dispatch("start","end"),o=Ka;return e.id=l,e.time=t,e.tween=function(l,t){return arguments.length<2?i.get(l):(null==t?i.remove(l):i.set(l,t),e)},e.ease=function(l){return arguments.length?(o="function"==typeof l?l:d3.ease.apply(d3,arguments),e):o},e.each=function(l,t){return arguments.length<2?_l.call(e,l):(a.on(l,t),e)},d3.timer(function(n){return El(e,function(e,r){function s(n){return p.active>l?u():(p.active=l,i.forEach(function(l,t){(t=t.call(e,m,r))&&d.push(t)}),a.start.call(e,m,r),c(n)||d3.timer(c,0,t),1)}function c(t){if(p.active!==l)return u();for(var n=(t-h)/f,i=o(n),s=d.length;s>0;)d[--s].call(e,i);return n>=1?(u(),xa=l,a.end.call(e,m,r),xa=0,1):void 0}function u(){return--p.count||delete e.__transition__,1}var d=[],h=e.delay,f=e.duration,p=(e=e.node).__transition__||(e.__transition__={active:0,count:0}),m=e.__data__;++p.count,n>=h?s(n):d3.timer(s,h,t)})},0,t),e}function _l(e){var l=xa,t=Ka,n=Na,i=Aa;return xa=this.id,Ka=this.ease(),El(this,function(l,t,n){Na=l.delay,Aa=l.duration,e.call(l=l.node,l.__data__,t,n)}),xa=l,Ka=t,Na=n,Aa=i,this}function Il(e,l,t){return""!=t&&Fa}function Sl(e,l){return d3.tween(e,F(l))}function kl(){for(var e,l=Date.now(),t=Ha;t;)e=l-t.then,e>=t.delay&&(t.flush=t.callback(e)),t=t.next;var n=xl()-l;n>24?(isFinite(n)&&(clearTimeout(Pa),Pa=setTimeout(kl,n)),La=0):(La=1,Za(kl))}function xl(){for(var e=null,l=Ha,t=1/0;l;)l.flush?(delete $a[l.callback.id],l=e?e.next=l.next:Ha=l.next):(t=Math.min(t,l.then+l.delay),l=(e=l).next);return t}function Ol(e,l){var t=e.ownerSVGElement||e;if(t.createSVGPoint){var n=t.createSVGPoint();if(0>Ua&&(window.scrollX||window.scrollY)){t=d3.select(document.body).append("svg").style("position","absolute").style("top",0).style("left",0);var i=t[0][0].getScreenCTM();Ua=!(i.f||i.e),t.remove()}return Ua?(n.x=l.pageX,n.y=l.pageY):(n.x=l.clientX,n.y=l.clientY),n=n.matrixTransform(e.getScreenCTM().inverse()),[n.x,n.y]}var a=e.getBoundingClientRect();return[l.clientX-a.left-e.clientLeft,l.clientY-a.top-e.clientTop]}function Rl(e){var l=e[0],t=e[e.length-1];return t>l?[l,t]:[t,l]}function Ml(e){return e.rangeExtent?e.rangeExtent():Rl(e.range())}function Nl(e,l){var t,n=0,i=e.length-1,a=e[n],o=e[i];return a>o&&(t=n,n=i,i=t,t=a,a=o,o=t),(l=l(o-a))&&(e[n]=l.floor(a),e[i]=l.ceil(o)),e}function Al(){return Math}function Kl(e,l,t,n){function i(){var i=Math.min(e.length,l.length)>2?Zl:Hl,s=n?$:B;return o=i(e,l,s,t),r=i(l,e,s,d3.interpolate),a}function a(e){return o(e)}var o,r;return a.invert=function(e){return r(e)},a.domain=function(l){return arguments.length?(e=l.map(Number),i()):e},a.range=function(e){return arguments.length?(l=e,i()):l},a.rangeRound=function(e){return a.range(e).interpolate(d3.interpolateRound)},a.clamp=function(e){return arguments.length?(n=e,i()):n},a.interpolate=function(e){return arguments.length?(t=e,i()):t},a.ticks=function(l){return Bl(e,l)},a.tickFormat=function(l){return $l(e,l)},a.nice=function(){return Nl(e,Pl),i()},a.copy=function(){return Kl(e,l,t,n)},i()}function Ll(e,l){return d3.rebind(e,l,"range","rangeRound","interpolate","clamp")}function Pl(e){return e=Math.pow(10,Math.round(Math.log(e)/Math.LN10)-1),e&&{floor:function(l){return Math.floor(l/e)*e},ceil:function(l){return Math.ceil(l/e)*e}}}function Fl(e,l){var t=Rl(e),n=t[1]-t[0],i=Math.pow(10,Math.floor(Math.log(n/l)/Math.LN10)),a=l/n*i;return.15>=a?i*=10:.35>=a?i*=5:.75>=a&&(i*=2),t[0]=Math.ceil(t[0]/i)*i,t[1]=Math.floor(t[1]/i)*i+.5*i,t[2]=i,t}function Bl(e,l){return d3.range.apply(d3,Fl(e,l))}function $l(e,l){return d3.format(",."+Math.max(0,-Math.floor(Math.log(Fl(e,l)[2])/Math.LN10+.01))+"f")}function Hl(e,l,t,n){var i=t(e[0],e[1]),a=n(l[0],l[1]);return function(e){return a(i(e))}}function Zl(e,l,t,n){var i=[],a=[],o=0,r=Math.min(e.length,l.length)-1;for(e[r]<e[0]&&(e=e.slice().reverse(),l=l.slice().reverse());++o<=r;)i.push(t(e[o-1],e[o])),a.push(n(l[o-1],l[o]));return function(l){var t=d3.bisect(e,l,1,r)-1;return a[t](i[t](l))}}function Ul(e,l){function t(t){return e(l(t))}var n=l.pow;return t.invert=function(l){return n(e.invert(l))},t.domain=function(i){return arguments.length?(l=i[0]<0?jl:zl,n=l.pow,e.domain(i.map(l)),t):e.domain().map(n)},t.nice=function(){return e.domain(Nl(e.domain(),Al)),t},t.ticks=function(){var t=Rl(e.domain()),i=[];if(t.every(isFinite)){var a=Math.floor(t[0]),o=Math.ceil(t[1]),r=n(t[0]),s=n(t[1]);if(l===jl)for(i.push(n(a));a++<o;)for(var c=9;c>0;c--)i.push(n(a)*c);else{for(;o>a;a++)for(var c=1;10>c;c++)i.push(n(a)*c);i.push(n(a))}for(a=0;i[a]<r;a++);for(o=i.length;i[o-1]>s;o--);i=i.slice(a,o)}return i},t.tickFormat=function(e,i){if(arguments.length<2&&(i=za),arguments.length<1)return i;var a,o=Math.max(.1,e/t.ticks().length),r=l===jl?(a=-1e-12,Math.floor):(a=1e-12,Math.ceil);return function(e){return e/n(r(l(e)+a))<=o?i(e):""}},t.copy=function(){return Ul(e.copy(),l)},Ll(t,e)}function zl(e){return Math.log(0>e?0:e)/Math.LN10}function jl(e){return-Math.log(e>0?0:-e)/Math.LN10}function Wl(e,l){function t(l){return e(n(l))}var n=Gl(l),i=Gl(1/l);return t.invert=function(l){return i(e.invert(l))},t.domain=function(l){return arguments.length?(e.domain(l.map(n)),t):e.domain().map(i)},t.ticks=function(e){return Bl(t.domain(),e)},t.tickFormat=function(e){return $l(t.domain(),e)},t.nice=function(){return t.domain(Nl(t.domain(),Pl))},t.exponent=function(e){if(!arguments.length)return l;var a=t.domain();return n=Gl(l=e),i=Gl(1/l),t.domain(a)},t.copy=function(){return Wl(e.copy(),l)},Ll(t,e)}function Gl(e){return function(l){return 0>l?-Math.pow(-l,e):Math.pow(l,e)}}function Vl(e,l){function t(l){return o[((a.get(l)||a.set(l,e.push(l)))-1)%o.length]}function i(l,t){return d3.range(e.length).map(function(e){return l+t*e})}var a,o,r;return t.domain=function(i){if(!arguments.length)return e;e=[],a=new n;for(var o,r=-1,s=i.length;++r<s;)a.has(o=i[r])||a.set(o,e.push(o));return t[l.t].apply(t,l.a)},t.range=function(e){return arguments.length?(o=e,r=0,l={t:"range",a:arguments},t):o},t.rangePoints=function(n,a){arguments.length<2&&(a=0);var s=n[0],c=n[1],u=(c-s)/(Math.max(1,e.length-1)+a);return o=i(e.length<2?(s+c)/2:s+u*a/2,u),r=0,l={t:"rangePoints",a:arguments},t},t.rangeBands=function(n,a,s){arguments.length<2&&(a=0),arguments.length<3&&(s=a);var c=n[1]<n[0],u=n[c-0],d=n[1-c],h=(d-u)/(e.length-a+2*s);return o=i(u+h*s,h),c&&o.reverse(),r=h*(1-a),l={t:"rangeBands",a:arguments},t},t.rangeRoundBands=function(n,a,s){arguments.length<2&&(a=0),arguments.length<3&&(s=a);var c=n[1]<n[0],u=n[c-0],d=n[1-c],h=Math.floor((d-u)/(e.length-a+2*s)),f=d-u-(e.length-a)*h;return o=i(u+Math.round(f/2),h),c&&o.reverse(),r=Math.round(h*(1-a)),l={t:"rangeRoundBands",a:arguments},t},t.rangeBand=function(){return r},t.rangeExtent=function(){return Rl(l.a[0])},t.copy=function(){return Vl(e,l)},t.domain(e)}function ql(e,l){function t(){var t=0,a=(e.length,l.length);for(i=[];++t<a;)i[t-1]=d3.quantile(e,t/a);return n}function n(e){return isNaN(e=+e)?0/0:l[d3.bisect(i,e)]}var i;return n.domain=function(l){return arguments.length?(e=l.filter(function(e){return!isNaN(e)}).sort(d3.ascending),t()):e},n.range=function(e){return arguments.length?(l=e,t()):l},n.quantiles=function(){return i},n.copy=function(){return ql(e,l)},t()}function Yl(e,l,t){function n(l){return t[Math.max(0,Math.min(o,Math.floor(a*(l-e))))]}function i(){return a=t.length/(l-e),o=t.length-1,n}var a,o;return n.domain=function(t){return arguments.length?(e=+t[0],l=+t[t.length-1],i()):[e,l]},n.range=function(e){return arguments.length?(t=e,i()):t},n.copy=function(){return Yl(e,l,t)},i()}function Jl(e,l){function t(t){return l[d3.bisect(e,t)]}return t.domain=function(l){return arguments.length?(e=l,t):e},t.range=function(e){return arguments.length?(l=e,t):l},t.copy=function(){return Jl(e,l)},t}function Xl(e){function l(e){return+e}return l.invert=l,l.domain=l.range=function(t){return arguments.length?(e=t.map(l),l):e},l.ticks=function(l){return Bl(e,l)},l.tickFormat=function(l){return $l(e,l)},l.copy=function(){return Xl(e)},l}function Ql(e){return e.innerRadius}function et(e){return e.outerRadius}function lt(e){return e.startAngle}function tt(e){return e.endAngle}function nt(e){function l(l){function o(){u.push("M",a(e(d),c))}for(var s,u=[],d=[],h=-1,f=l.length,p=r(t),m=r(n);++h<f;)i.call(this,s=l[h],h)?d.push([+p.call(this,s,h),+m.call(this,s,h)]):d.length&&(o(),d=[]);return d.length&&o(),u.length?u.join(""):null}var t=it,n=at,i=o,a=ot,s=a.key,c=.7;return l.x=function(e){return arguments.length?(t=e,l):t},l.y=function(e){return arguments.length?(n=e,l):n},l.defined=function(e){return arguments.length?(i=e,l):i},l.interpolate=function(e){return arguments.length?(s="function"==typeof e?a=e:(a=Ja.get(e)||ot).key,l):s},l.tension=function(e){return arguments.length?(c=e,l):c},l}function it(e){return e[0]}function at(e){return e[1]}function ot(e){return e.join("L")}function rt(e){return ot(e)+"Z"}function st(e){for(var l=0,t=e.length,n=e[0],i=[n[0],",",n[1]];++l<t;)i.push("V",(n=e[l])[1],"H",n[0]);return i.join("")}function ct(e){for(var l=0,t=e.length,n=e[0],i=[n[0],",",n[1]];++l<t;)i.push("H",(n=e[l])[0],"V",n[1]);return i.join("")}function ut(e,l){return e.length<4?ot(e):e[1]+ft(e.slice(1,e.length-1),pt(e,l))}function dt(e,l){return e.length<3?ot(e):e[0]+ft((e.push(e[0]),e),pt([e[e.length-2]].concat(e,[e[1]]),l))}function ht(e,l){return e.length<3?ot(e):e[0]+ft(e,pt(e,l))}function ft(e,l){if(l.length<1||e.length!=l.length&&e.length!=l.length+2)return ot(e);var t=e.length!=l.length,n="",i=e[0],a=e[1],o=l[0],r=o,s=1;if(t&&(n+="Q"+(a[0]-2*o[0]/3)+","+(a[1]-2*o[1]/3)+","+a[0]+","+a[1],i=e[1],s=2),l.length>1){r=l[1],a=e[s],s++,n+="C"+(i[0]+o[0])+","+(i[1]+o[1])+","+(a[0]-r[0])+","+(a[1]-r[1])+","+a[0]+","+a[1];for(var c=2;c<l.length;c++,s++)a=e[s],r=l[c],n+="S"+(a[0]-r[0])+","+(a[1]-r[1])+","+a[0]+","+a[1]}if(t){var u=e[s];n+="Q"+(a[0]+2*r[0]/3)+","+(a[1]+2*r[1]/3)+","+u[0]+","+u[1]}return n}function pt(e,l){for(var t,n=[],i=(1-l)/2,a=e[0],o=e[1],r=1,s=e.length;++r<s;)t=a,a=o,o=e[r],n.push([i*(o[0]-t[0]),i*(o[1]-t[1])]);return n}function mt(e){if(e.length<3)return ot(e);var l=1,t=e.length,n=e[0],i=n[0],a=n[1],o=[i,i,i,(n=e[1])[0]],r=[a,a,a,n[1]],s=[i,",",a];for(Tt(s,o,r);++l<t;)n=e[l],o.shift(),o.push(n[0]),r.shift(),r.push(n[1]),Tt(s,o,r);for(l=-1;++l<2;)o.shift(),o.push(n[0]),r.shift(),r.push(n[1]),Tt(s,o,r);return s.join("")}function gt(e){if(e.length<4)return ot(e);for(var l,t=[],n=-1,i=e.length,a=[0],o=[0];++n<3;)l=e[n],a.push(l[0]),o.push(l[1]);for(t.push(bt(eo,a)+","+bt(eo,o)),--n;++n<i;)l=e[n],a.shift(),a.push(l[0]),o.shift(),o.push(l[1]),Tt(t,a,o);return t.join("")}function vt(e){for(var l,t,n=-1,i=e.length,a=i+4,o=[],r=[];++n<4;)t=e[n%i],o.push(t[0]),r.push(t[1]);for(l=[bt(eo,o),",",bt(eo,r)],--n;++n<a;)t=e[n%i],o.shift(),o.push(t[0]),r.shift(),r.push(t[1]),Tt(l,o,r);return l.join("")}function yt(e,l){var t=e.length-1;if(t)for(var n,i,a=e[0][0],o=e[0][1],r=e[t][0]-a,s=e[t][1]-o,c=-1;++c<=t;)n=e[c],i=c/t,n[0]=l*n[0]+(1-l)*(a+i*r),n[1]=l*n[1]+(1-l)*(o+i*s);return mt(e)}function bt(e,l){return e[0]*l[0]+e[1]*l[1]+e[2]*l[2]+e[3]*l[3]}function Tt(e,l,t){e.push("C",bt(Xa,l),",",bt(Xa,t),",",bt(Qa,l),",",bt(Qa,t),",",bt(eo,l),",",bt(eo,t))}function Ct(e,l){return(l[1]-e[1])/(l[0]-e[0])}function Et(e){for(var l=0,t=e.length-1,n=[],i=e[0],a=e[1],o=n[0]=Ct(i,a);++l<t;)n[l]=(o+(o=Ct(i=a,a=e[l+1])))/2;return n[l]=o,n}function Dt(e){for(var l,t,n,i,a=[],o=Et(e),r=-1,s=e.length-1;++r<s;)l=Ct(e[r],e[r+1]),Math.abs(l)<1e-6?o[r]=o[r+1]=0:(t=o[r]/l,n=o[r+1]/l,i=t*t+n*n,i>9&&(i=3*l/Math.sqrt(i),o[r]=i*t,o[r+1]=i*n));for(r=-1;++r<=s;)i=(e[Math.min(s,r+1)][0]-e[Math.max(0,r-1)][0])/(6*(1+o[r]*o[r])),a.push([i||0,o[r]*i||0]);return a}function wt(e){return e.length<3?ot(e):e[0]+ft(e,Dt(e))}function _t(e){for(var l,t,n,i=-1,a=e.length;++i<a;)l=e[i],t=l[0],n=l[1]+qa,l[0]=t*Math.cos(n),l[1]=t*Math.sin(n);return e}function It(e){function l(l){function o(){g.push("M",c(e(y),f),h,d(e(v.reverse()),f),"Z")}for(var u,p,m,g=[],v=[],y=[],b=-1,T=l.length,C=r(t),E=r(i),D=t===n?function(){return p}:r(n),w=i===a?function(){return m}:r(a);++b<T;)s.call(this,u=l[b],b)?(v.push([p=+C.call(this,u,b),m=+E.call(this,u,b)]),y.push([+D.call(this,u,b),+w.call(this,u,b)])):v.length&&(o(),v=[],y=[]);return v.length&&o(),g.length?g.join(""):null}var t=it,n=it,i=0,a=at,s=o,c=ot,u=c.key,d=c,h="L",f=.7;return l.x=function(e){return arguments.length?(t=n=e,l):n},l.x0=function(e){return arguments.length?(t=e,l):t},l.x1=function(e){return arguments.length?(n=e,l):n},l.y=function(e){return arguments.length?(i=a=e,l):a},l.y0=function(e){return arguments.length?(i=e,l):i},l.y1=function(e){return arguments.length?(a=e,l):a},l.defined=function(e){return arguments.length?(s=e,l):s},l.interpolate=function(e){return arguments.length?(u="function"==typeof e?c=e:(c=Ja.get(e)||ot).key,d=c.reverse||c,h=c.closed?"M":"L",l):u},l.tension=function(e){return arguments.length?(f=e,l):f},l}function St(e){return e.source}function kt(e){return e.target}function xt(e){return e.radius}function Ot(e){return[e.x,e.y]}function Rt(e){return function(){var l=e.apply(this,arguments),t=l[0],n=l[1]+qa;return[t*Math.cos(n),t*Math.sin(n)]}}function Mt(){return 64}function Nt(){return"circle"}function At(e){var l=Math.sqrt(e/Math.PI);return"M0,"+l+"A"+l+","+l+" 0 1,1 0,"+-l+"A"+l+","+l+" 0 1,1 0,"+l+"Z"}function Kt(e,l){e.attr("transform",function(e){return"translate("+l(e)+",0)"})}function Lt(e,l){e.attr("transform",function(e){return"translate(0,"+l(e)+")"})}function Pt(e,l,t){if(n=[],t&&l.length>1){for(var n,i,a,o=Rl(e.domain()),r=-1,s=l.length,c=(l[1]-l[0])/++t;++r<s;)for(i=t;--i>0;)(a=+l[r]-i*c)>=o[0]&&n.push(a);for(--r,i=0;++i<t&&(a=+l[r]+i*c)<o[1];)n.push(a)}return n}function Ft(){oo||(oo=d3.select("body").append("div").style("visibility","hidden").style("top",0).style("height",0).style("width",0).style("overflow-y","scroll").append("div").style("height","2000px").node().parentNode);var e,l=d3.event;try{oo.scrollTop=1e3,oo.dispatchEvent(l),e=1e3-oo.scrollTop}catch(t){e=l.wheelDelta||5*-l.detail}return e}function Bt(e){for(var l=e.source,t=e.target,n=Ht(l,t),i=[l];l!==n;)l=l.parent,i.push(l);for(var a=i.length;t!==n;)i.splice(a,0,t),t=t.parent;return i}function $t(e){for(var l=[],t=e.parent;null!=t;)l.push(e),e=t,t=t.parent;return l.push(e),l}function Ht(e,l){if(e===l)return e;for(var t=$t(e),n=$t(l),i=t.pop(),a=n.pop(),o=null;i===a;)o=i,i=t.pop(),a=n.pop();return o}function Zt(e){e.fixed|=2}function Ut(e){e.fixed&=1}function zt(e){e.fixed|=4}function jt(e){e.fixed&=3}function Wt(e,l,t){var n=0,i=0;if(e.charge=0,!e.leaf)for(var a,o=e.nodes,r=o.length,s=-1;++s<r;)a=o[s],null!=a&&(Wt(a,l,t),e.charge+=a.charge,n+=a.charge*a.cx,i+=a.charge*a.cy);if(e.point){e.leaf||(e.point.x+=Math.random()-.5,e.point.y+=Math.random()-.5);var c=l*t[e.point.index];e.charge+=e.pointCharge=c,n+=c*e.point.x,i+=c*e.point.y}e.cx=n/e.charge,e.cy=i/e.charge}function Gt(){return 20}function Vt(){return 1}function qt(e){return e.x}function Yt(e){return e.y}function Jt(e,l,t){e.y0=l,e.y=t}function Xt(e){return d3.range(e.length)}function Qt(e){for(var l=-1,t=e[0].length,n=[];++l<t;)n[l]=0;return n}function en(e){for(var l,t=1,n=0,i=e[0][1],a=e.length;a>t;++t)(l=e[t][1])>i&&(n=t,i=l);return n}function ln(e){return e.reduce(tn,0)}function tn(e,l){return e+l[1]}function nn(e,l){return an(e,Math.ceil(Math.log(l.length)/Math.LN2+1))}function an(e,l){for(var t=-1,n=+e[0],i=(e[1]-n)/l,a=[];++t<=l;)a[t]=i*t+n;return a}function on(e){return[d3.min(e),d3.max(e)]}function rn(e,l){return d3.rebind(e,l,"sort","children","value"),e.links=dn,e.nodes=function(l){return ho=!0,(e.nodes=e)(l)},e}function sn(e){return e.children}function cn(e){return e.value}function un(e,l){return l.value-e.value}function dn(e){return d3.merge(e.map(function(e){return(e.children||[]).map(function(l){return{source:e,target:l}})}))}function hn(e,l){return e.value-l.value}function fn(e,l){var t=e._pack_next;e._pack_next=l,l._pack_prev=e,l._pack_next=t,t._pack_prev=l}function pn(e,l){e._pack_next=l,l._pack_prev=e}function mn(e,l){var t=l.x-e.x,n=l.y-e.y,i=e.r+l.r;return i*i-t*t-n*n>.001}function gn(e){function l(e){u=Math.min(e.x-e.r,u),d=Math.max(e.x+e.r,d),h=Math.min(e.y-e.r,h),f=Math.max(e.y+e.r,f)}if((t=e.children)&&(c=t.length)){var t,n,i,a,o,r,s,c,u=1/0,d=-1/0,h=1/0,f=-1/0;if(t.forEach(vn),n=t[0],n.x=-n.r,n.y=0,l(n),c>1&&(i=t[1],i.x=i.r,i.y=0,l(i),c>2))for(a=t[2],Tn(n,i,a),l(a),fn(n,a),n._pack_prev=a,fn(a,i),i=n._pack_next,o=3;c>o;o++){Tn(n,i,a=t[o]);var p=0,m=1,g=1;for(r=i._pack_next;r!==i;r=r._pack_next,m++)if(mn(r,a)){p=1;break}if(1==p)for(s=n._pack_prev;s!==r._pack_prev&&!mn(s,a);s=s._pack_prev,g++);p?(g>m||m==g&&i.r<n.r?pn(n,i=r):pn(n=s,i),o--):(fn(n,a),i=a,l(a))}var v=(u+d)/2,y=(h+f)/2,b=0;for(o=0;c>o;o++)a=t[o],a.x-=v,a.y-=y,b=Math.max(b,a.r+Math.sqrt(a.x*a.x+a.y*a.y));e.r=b,t.forEach(yn)}}function vn(e){e._pack_next=e._pack_prev=e}function yn(e){delete e._pack_next,delete e._pack_prev}function bn(e,l,t,n){var i=e.children;if(e.x=l+=n*e.x,e.y=t+=n*e.y,e.r*=n,i)for(var a=-1,o=i.length;++a<o;)bn(i[a],l,t,n)}function Tn(e,l,t){var n=e.r+t.r,i=l.x-e.x,a=l.y-e.y;if(n&&(i||a)){var o=l.r+t.r,r=i*i+a*a;o*=o,n*=n;var s=.5+(n-o)/(2*r),c=Math.sqrt(Math.max(0,2*o*(n+r)-(n-=r)*n-o*o))/(2*r);t.x=e.x+s*i+c*a,t.y=e.y+s*a-c*i}else t.x=e.x+n,t.y=e.y}function Cn(e){return 1+d3.max(e,function(e){return e.y})}function En(e){return e.reduce(function(e,l){return e+l.x},0)/e.length}function Dn(e){var l=e.children;return l&&l.length?Dn(l[0]):e}function wn(e){var l,t=e.children;return t&&(l=t.length)?wn(t[l-1]):e}function _n(e,l){return e.parent==l.parent?1:2}function In(e){var l=e.children;return l&&l.length?l[0]:e._tree.thread}function Sn(e){var l,t=e.children;return t&&(l=t.length)?t[l-1]:e._tree.thread}function kn(e,l){var t=e.children;if(t&&(i=t.length))for(var n,i,a=-1;++a<i;)l(n=kn(t[a],l),e)>0&&(e=n);return e}function xn(e,l){return e.x-l.x}function On(e,l){return l.x-e.x}function Rn(e,l){return e.depth-l.depth}function Mn(e,l){function t(e,n){var i=e.children;if(i&&(o=i.length))for(var a,o,r=null,s=-1;++s<o;)a=i[s],t(a,r),r=a;l(e,n)}t(e,null)}function Nn(e){for(var l,t=0,n=0,i=e.children,a=i.length;--a>=0;)l=i[a]._tree,l.prelim+=t,l.mod+=t,t+=l.shift+(n+=l.change)}function An(e,l,t){e=e._tree,l=l._tree;var n=t/(l.number-e.number);e.change+=n,l.change-=n,l.shift+=t,l.prelim+=t,l.mod+=t}function Kn(e,l,t){return e._tree.ancestor.parent==l.parent?e._tree.ancestor:t}function Ln(e){return{x:e.x,y:e.y,dx:e.dx,dy:e.dy}}function Pn(e,l){var t=e.x+l[3],n=e.y+l[0],i=e.dx-l[1]-l[3],a=e.dy-l[0]-l[2];return 0>i&&(t+=i/2,i=0),0>a&&(n+=a/2,a=0),{x:t,y:n,dx:i,dy:a}}function Fn(e,l){function t(e,n){d3.text(e,l,function(e){n(e&&t.parse(e))})}function n(l){return l.map(i).join(e)}function i(e){return o.test(e)?'"'+e.replace(/"/g,'""')+'"':e}var a=new RegExp("rn|["+e+"rn]","g"),o=new RegExp('["'+e+"n]"),r=e.charCodeAt(0);return t.parse=function(e){var l;return t.parseRows(e,function(e,t){if(t){for(var n={},i=-1,a=l.length;++i<a;)n[l[i]]=e[i];return n}return l=e,null})},t.parseRows=function(e,l){function t(){if(a.lastIndex>=e.length)return s;if(i)return i=!1,o;var l=a.lastIndex;if(34===e.charCodeAt(l)){for(var t=l;t++<e.length;)if(34===e.charCodeAt(t)){if(34!==e.charCodeAt(t+1))break;t++}a.lastIndex=t+2;var n=e.charCodeAt(t+1);return 13===n?(i=!0,10===e.charCodeAt(t+2)&&a.lastIndex++):10===n&&(i=!0),e.substring(l+1,t).replace(/""/g,'"')}var c=a.exec(e);return c?(i=c[0].charCodeAt(0)!==r,e.substring(l,c.index)):(a.lastIndex=e.length,e.substring(l))}var n,i,o={},s={},c=[],u=0;for(a.lastIndex=0;(n=t())!==s;){for(var d=[];n!==o&&n!==s;)d.push(n),n=t();(!l||(d=l(d,u++)))&&c.push(d)}return c},t.format=function(e){return e.map(n).join("n")},t}function Bn(e,l){return function(t){return t&&e.hasOwnProperty(t.type)?e[t.type](t):l}}function $n(e){return"m0,"+e+"a"+e+","+e+" 0 1,1 0,"+-2*e+"a"+e+","+e+" 0 1,1 0,"+2*e+"z"}function Hn(e,l){po.hasOwnProperty(e.type)&&po[e.type](e,l)}function Zn(e,l){Hn(e.geometry,l)}function Un(e,l){for(var t=e.features,n=0,i=t.length;i>n;n++)Hn(t[n].geometry,l)}function zn(e,l){for(var t=e.geometries,n=0,i=t.length;i>n;n++)Hn(t[n],l)}function jn(e,l){for(var t=e.coordinates,n=0,i=t.length;i>n;n++)l.apply(null,t[n])}function Wn(e,l){for(var t=e.coordinates,n=0,i=t.length;i>n;n++)for(var a=t[n],o=0,r=a.length;r>o;o++)l.apply(null,a[o])}function Gn(e,l){for(var t=e.coordinates,n=0,i=t.length;i>n;n++)for(var a=t[n][0],o=0,r=a.length;r>o;o++)l.apply(null,a[o])}function Vn(e,l){l.apply(null,e.coordinates)}function qn(e,l){for(var t=e.coordinates[0],n=0,i=t.length;i>n;n++)l.apply(null,t[n])}function Yn(e){return e.source}function Jn(e){return e.target}function Xn(){function e(e){var l=Math.sin(e*=f)*p,t=Math.sin(f-e)*p,n=t*a+l*d,r=t*o+l*h,s=t*i+l*u;return[Math.atan2(r,n)/fo,Math.atan2(s,Math.sqrt(n*n+r*r))/fo]}var l,t,n,i,a,o,r,s,c,u,d,h,f,p;return e.distance=function(){return null==f&&(p=1/Math.sin(f=Math.acos(Math.max(-1,Math.min(1,i*u+n*c*Math.cos(r-l)))))),f},e.source=function(r){var s=Math.cos(l=r[0]*fo),c=Math.sin(l);return n=Math.cos(t=r[1]*fo),i=Math.sin(t),a=n*s,o=n*c,f=null,e},e.target=function(l){var t=Math.cos(r=l[0]*fo),n=Math.sin(r);return c=Math.cos(s=l[1]*fo),u=Math.sin(s),d=c*t,h=c*n,f=null,e},e}function Qn(e,l){var t=Xn().source(e).target(l);return t.distance(),t}function ei(e){for(var l=0,t=0;;){if(e(l,t))return[l,t];0===l?(l=t+1,t=0):(l-=1,t+=1)}}function li(e,l,t,n){var i,a,o,r,s,c,u;return i=n[e],a=i[0],o=i[1],i=n[l],r=i[0],s=i[1],i=n[t],c=i[0],u=i[1],(u-o)*(r-a)-(s-o)*(c-a)>0}function ti(e,l,t){return(t[0]-l[0])*(e[1]-l[1])<(t[1]-l[1])*(e[0]-l[0])}function ni(e,l,t,n){var i=e[0],a=l[0],o=t[0],r=n[0],s=e[1],c=l[1],u=t[1],d=n[1],h=i-o,f=a-i,p=r-o,m=s-u,g=c-s,v=d-u,y=(p*m-v*h)/(v*f-p*g);return[i+y*f,s+y*g]}function ii(e,l){var t={list:e.map(function(e,l){return{index:l,x:e[0],y:e[1]}}).sort(function(e,l){return e.y<l.y?-1:e.y>l.y?1:e.x<l.x?-1:e.x>l.x?1:0}),bottomSite:null},n={list:[],leftEnd:null,rightEnd:null,init:function(){n.leftEnd=n.createHalfEdge(null,"l"),n.rightEnd=n.createHalfEdge(null,"l"),n.leftEnd.r=n.rightEnd,n.rightEnd.l=n.leftEnd,n.list.unshift(n.leftEnd,n.rightEnd)},createHalfEdge:function(e,l){return{edge:e,side:l,vertex:null,l:null,r:null}},insert:function(e,l){l.l=e,l.r=e.r,e.r.l=l,e.r=l},leftBound:function(e){var l=n.leftEnd;do l=l.r;while(l!=n.rightEnd&&i.rightOf(l,e));return l=l.l},del:function(e){e.l.r=e.r,e.r.l=e.l,e.edge=null},right:function(e){return e.r},left:function(e){return e.l},leftRegion:function(e){return null==e.edge?t.bottomSite:e.edge.region[e.side]},rightRegion:function(e){return null==e.edge?t.bottomSite:e.edge.region[vo[e.side]]}},i={bisect:function(e,l){var t={region:{l:e,r:l},ep:{l:null,r:null}},n=l.x-e.x,i=l.y-e.y,a=n>0?n:-n,o=i>0?i:-i;return t.c=e.x*n+e.y*i+.5*(n*n+i*i),a>o?(t.a=1,t.b=i/n,t.c/=n):(t.b=1,t.a=n/i,t.c/=i),t},intersect:function(e,l){var t=e.edge,n=l.edge;if(!t||!n||t.region.r==n.region.r)return null;var i=t.a*n.b-t.b*n.a;if(Math.abs(i)<1e-10)return null;var a,o,r=(t.c*n.b-n.c*t.b)/i,s=(n.c*t.a-t.c*n.a)/i,c=t.region.r,u=n.region.r;c.y<u.y||c.y==u.y&&c.x<u.x?(a=e,o=t):(a=l,o=n);var d=r>=o.region.r.x;return d&&"l"===a.side||!d&&"r"===a.side?null:{x:r,y:s}},rightOf:function(e,l){var t=e.edge,n=t.region.r,i=l.x>n.x;if(i&&"l"===e.side)return 1;if(!i&&"r"===e.side)return 0;if(1===t.a){var a=l.y-n.y,o=l.x-n.x,r=0,s=0;if(!i&&t.b<0||i&&t.b>=0?s=r=a>=t.b*o:(s=l.x+l.y*t.b>t.c,t.b<0&&(s=!s),s||(r=1)),!r){var c=n.x-t.region.l.x;s=t.b*(o*o-a*a)<c*a*(1+2*o/c+t.b*t.b),t.b<0&&(s=!s)}}else{var u=t.c-t.a*l.x,d=l.y-u,h=l.x-n.x,f=u-n.y;s=d*d>h*h+f*f}return"l"===e.side?s:!s},endPoint:function(e,t,n){e.ep[t]=n,e.ep[vo[t]]&&l(e)},distance:function(e,l){var t=e.x-l.x,n=e.y-l.y;return Math.sqrt(t*t+n*n)}},a={list:[],insert:function(e,l,t){e.vertex=l,e.ystar=l.y+t;for(var n=0,i=a.list,o=i.length;o>n;n++){var r=i[n];if(!(e.ystar>r.ystar||e.ystar==r.ystar&&l.x>r.vertex.x))break}i.splice(n,0,e)},del:function(e){for(var l=0,t=a.list,n=t.length;n>l&&t[l]!=e;++l);t.splice(l,1)},empty:function(){return 0===a.list.length
},nextEvent:function(e){for(var l=0,t=a.list,n=t.length;n>l;++l)if(t[l]==e)return t[l+1];return null},min:function(){var e=a.list[0];return{x:e.vertex.x,y:e.ystar}},extractMin:function(){return a.list.shift()}};n.init(),t.bottomSite=t.list.shift();for(var o,r,s,c,u,d,h,f,p,m,g,v,y,b=t.list.shift();;)if(a.empty()||(o=a.min()),b&&(a.empty()||b.y<o.y||b.y==o.y&&b.x<o.x))r=n.leftBound(b),s=n.right(r),h=n.rightRegion(r),v=i.bisect(h,b),d=n.createHalfEdge(v,"l"),n.insert(r,d),m=i.intersect(r,d),m&&(a.del(r),a.insert(r,m,i.distance(m,b))),r=d,d=n.createHalfEdge(v,"r"),n.insert(r,d),m=i.intersect(d,s),m&&a.insert(d,m,i.distance(m,b)),b=t.list.shift();else{if(a.empty())break;r=a.extractMin(),c=n.left(r),s=n.right(r),u=n.right(s),h=n.leftRegion(r),f=n.rightRegion(s),g=r.vertex,i.endPoint(r.edge,r.side,g),i.endPoint(s.edge,s.side,g),n.del(r),a.del(s),n.del(s),y="l",h.y>f.y&&(p=h,h=f,f=p,y="r"),v=i.bisect(h,f),d=n.createHalfEdge(v,y),n.insert(c,d),i.endPoint(v,vo[y],g),m=i.intersect(c,d),m&&(a.del(c),a.insert(c,m,i.distance(m,h))),m=i.intersect(d,u),m&&a.insert(d,m,i.distance(m,h))}for(r=n.right(n.leftEnd);r!=n.rightEnd;r=n.right(r))l(r.edge)}function ai(){return{leaf:!0,nodes:[],point:null}}function oi(e,l,t,n,i,a){if(!e(l,t,n,i,a)){var o=.5*(t+i),r=.5*(n+a),s=l.nodes;s[0]&&oi(e,s[0],t,n,o,r),s[1]&&oi(e,s[1],o,n,i,r),s[2]&&oi(e,s[2],t,r,o,a),s[3]&&oi(e,s[3],o,r,i,a)}}function ri(e){return{x:e[0],y:e[1]}}function si(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function ci(e){return e.substring(0,3)}function ui(e,l,t,n){for(var i,a,o=0,r=l.length,s=t.length;r>o;){if(n>=s)return-1;if(i=l.charCodeAt(o++),37==i){if(a=Bo[l.charAt(o++)],!a||(n=a(e,t,n))<0)return-1}else if(i!=t.charCodeAt(n++))return-1}return n}function di(e){return new RegExp("^(?:"+e.map(d3.requote).join("|")+")","i")}function hi(e){for(var l=new n,t=-1,i=e.length;++t<i;)l.set(e[t].toLowerCase(),t);return l}function fi(e,l,t){No.lastIndex=0;var n=No.exec(l.substring(t));return n?t+=n[0].length:-1}function pi(e,l,t){Mo.lastIndex=0;var n=Mo.exec(l.substring(t));return n?t+=n[0].length:-1}function mi(e,l,t){Lo.lastIndex=0;var n=Lo.exec(l.substring(t));return n?(e.m=Po.get(n[0].toLowerCase()),t+=n[0].length):-1}function gi(e,l,t){Ao.lastIndex=0;var n=Ao.exec(l.substring(t));return n?(e.m=Ko.get(n[0].toLowerCase()),t+=n[0].length):-1}function vi(e,l,t){return ui(e,Fo.c.toString(),l,t)}function yi(e,l,t){return ui(e,Fo.x.toString(),l,t)}function bi(e,l,t){return ui(e,Fo.X.toString(),l,t)}function Ti(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+4));return n?(e.y=+n[0],t+=n[0].length):-1}function Ci(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+2));return n?(e.y=Ei(+n[0]),t+=n[0].length):-1}function Ei(e){return e+(e>68?1900:2e3)}function Di(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+2));return n?(e.m=n[0]-1,t+=n[0].length):-1}function wi(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+2));return n?(e.d=+n[0],t+=n[0].length):-1}function _i(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+2));return n?(e.H=+n[0],t+=n[0].length):-1}function Ii(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+2));return n?(e.M=+n[0],t+=n[0].length):-1}function Si(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+2));return n?(e.S=+n[0],t+=n[0].length):-1}function ki(e,l,t){$o.lastIndex=0;var n=$o.exec(l.substring(t,t+3));return n?(e.L=+n[0],t+=n[0].length):-1}function xi(e,l,t){var n=Ho.get(l.substring(t,t+=2).toLowerCase());return null==n?-1:(e.p=n,t)}function Oi(e){var l=e.getTimezoneOffset(),t=l>0?"-":"+",n=~~(Math.abs(l)/60),i=Math.abs(l)%60;return t+ko(n)+ko(i)}function Ri(e){return e.toISOString()}function Mi(e,l,t){function n(l){var t=e(l),n=a(t,1);return n-l>l-t?t:n}function i(t){return l(t=e(new yo(t-1)),1),t}function a(e,t){return l(e=new yo(+e),t),e}function o(e,n,a){var o=i(e),r=[];if(a>1)for(;n>o;)t(o)%a||r.push(new Date(+o)),l(o,1);else for(;n>o;)r.push(new Date(+o)),l(o,1);return r}function r(e,l,t){try{yo=si;var n=new si;return n._=e,o(n,l,t)}finally{yo=Date}}e.floor=e,e.round=n,e.ceil=i,e.offset=a,e.range=o;var s=e.utc=Ni(e);return s.floor=s,s.round=Ni(n),s.ceil=Ni(i),s.offset=Ni(a),s.range=r,e}function Ni(e){return function(l,t){try{yo=si;var n=new si;return n._=l,e(n,t)._}finally{yo=Date}}}function Ai(e,l,t){function n(l){return e(l)}return n.invert=function(l){return Li(e.invert(l))},n.domain=function(l){return arguments.length?(e.domain(l),n):e.domain().map(Li)},n.nice=function(e){return n.domain(Nl(n.domain(),function(){return e}))},n.ticks=function(t,i){var a=Ki(n.domain());if("function"!=typeof t){var o=a[1]-a[0],r=o/t,s=d3.bisect(Uo,r);if(s==Uo.length)return l.year(a,t);if(!s)return e.ticks(t).map(Li);Math.log(r/Uo[s-1])<Math.log(Uo[s]/r)&&--s,t=l[s],i=t[1],t=t[0].range}return t(a[0],new Date(+a[1]+1),i)},n.tickFormat=function(){return t},n.copy=function(){return Ai(e.copy(),l,t)},d3.rebind(n,e,"range","rangeRound","interpolate","clamp")}function Ki(e){var l=e[0],t=e[e.length-1];return t>l?[l,t]:[t,l]}function Li(e){return new Date(e)}function Pi(e){return function(l){for(var t=e.length-1,n=e[t];!n[1](l);)n=e[--t];return n[0](l)}}function Fi(e){var l=new Date(e,0,1);return l.setFullYear(e),l}function Bi(e){var l=e.getFullYear(),t=Fi(l),n=Fi(l+1);return l+(e-t)/(n-t)}function $i(e){var l=new Date(Date.UTC(e,0,1));return l.setUTCFullYear(e),l}function Hi(e){var l=e.getUTCFullYear(),t=$i(l),n=$i(l+1);return l+(e-t)/(n-t)}Date.now||(Date.now=function(){return+new Date});try{document.createElement("div").style.setProperty("opacity",0,"")}catch(Zi){var Ui=CSSStyleDeclaration.prototype,zi=Ui.setProperty;Ui.setProperty=function(e,l,t){zi.call(this,e,l+"",t)}}d3={version:"2.10.3"};var ji=t;try{ji(document.documentElement.childNodes)[0].nodeType}catch(Wi){ji=l}var Gi=[].__proto__?function(e,l){e.__proto__=l}:function(e,l){for(var t in l)e[t]=l[t]};d3.map=function(e){var l=new n;for(var t in e)l.set(t,e[t]);return l},e(n,{has:function(e){return Vi+e in this},get:function(e){return this[Vi+e]},set:function(e,l){return this[Vi+e]=l},remove:function(e){return e=Vi+e,e in this&&delete this[e]},keys:function(){var e=[];return this.forEach(function(l){e.push(l)}),e},values:function(){var e=[];return this.forEach(function(l,t){e.push(t)}),e},entries:function(){var e=[];return this.forEach(function(l,t){e.push({key:l,value:t})}),e},forEach:function(e){for(var l in this)l.charCodeAt(0)===qi&&e.call(this,l.substring(1),this[l])}});var Vi=" ",qi=Vi.charCodeAt(0);d3.functor=r,d3.rebind=function(e,l){for(var t,n=1,i=arguments.length;++n<i;)e[t=arguments[n]]=s(e,l,l[t]);return e},d3.ascending=function(e,l){return l>e?-1:e>l?1:e>=l?0:0/0},d3.descending=function(e,l){return e>l?-1:l>e?1:l>=e?0:0/0},d3.mean=function(e,l){var t,n=e.length,i=0,a=-1,o=0;if(1===arguments.length)for(;++a<n;)c(t=e[a])&&(i+=(t-i)/++o);else for(;++a<n;)c(t=l.call(e,e[a],a))&&(i+=(t-i)/++o);return o?i:void 0},d3.median=function(e,l){return arguments.length>1&&(e=e.map(l)),e=e.filter(c),e.length?d3.quantile(e.sort(d3.ascending),.5):void 0},d3.min=function(e,l){var t,n,i=-1,a=e.length;if(1===arguments.length){for(;++i<a&&(null==(t=e[i])||t!=t);)t=void 0;for(;++i<a;)null!=(n=e[i])&&t>n&&(t=n)}else{for(;++i<a&&(null==(t=l.call(e,e[i],i))||t!=t);)t=void 0;for(;++i<a;)null!=(n=l.call(e,e[i],i))&&t>n&&(t=n)}return t},d3.max=function(e,l){var t,n,i=-1,a=e.length;if(1===arguments.length){for(;++i<a&&(null==(t=e[i])||t!=t);)t=void 0;for(;++i<a;)null!=(n=e[i])&&n>t&&(t=n)}else{for(;++i<a&&(null==(t=l.call(e,e[i],i))||t!=t);)t=void 0;for(;++i<a;)null!=(n=l.call(e,e[i],i))&&n>t&&(t=n)}return t},d3.extent=function(e,l){var t,n,i,a=-1,o=e.length;if(1===arguments.length){for(;++a<o&&(null==(t=i=e[a])||t!=t);)t=i=void 0;for(;++a<o;)null!=(n=e[a])&&(t>n&&(t=n),n>i&&(i=n))}else{for(;++a<o&&(null==(t=i=l.call(e,e[a],a))||t!=t);)t=void 0;for(;++a<o;)null!=(n=l.call(e,e[a],a))&&(t>n&&(t=n),n>i&&(i=n))}return[t,i]},d3.random={normal:function(e,l){var t=arguments.length;return 2>t&&(l=1),1>t&&(e=0),function(){var t,n,i;do t=2*Math.random()-1,n=2*Math.random()-1,i=t*t+n*n;while(!i||i>1);return e+l*t*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(e,l){var t=arguments.length;2>t&&(l=1),1>t&&(e=0);var n=d3.random.normal();return function(){return Math.exp(e+l*n())}},irwinHall:function(e){return function(){for(var l=0,t=0;e>t;t++)l+=Math.random();return l/e}}},d3.sum=function(e,l){var t,n=0,i=e.length,a=-1;if(1===arguments.length)for(;++a<i;)isNaN(t=+e[a])||(n+=t);else for(;++a<i;)isNaN(t=+l.call(e,e[a],a))||(n+=t);return n},d3.quantile=function(e,l){var t=(e.length-1)*l+1,n=Math.floor(t),i=e[n-1],a=t-n;return a?i+a*(e[n]-i):i},d3.transpose=function(e){return d3.zip.apply(d3,e)},d3.zip=function(){if(!(n=arguments.length))return[];for(var e=-1,l=d3.min(arguments,u),t=new Array(l);++e<l;)for(var n,i=-1,a=t[e]=new Array(n);++i<n;)a[i]=arguments[i][e];return t},d3.bisector=function(e){return{left:function(l,t,n,i){for(arguments.length<3&&(n=0),arguments.length<4&&(i=l.length);i>n;){var a=n+i>>>1;e.call(l,l[a],a)<t?n=a+1:i=a}return n},right:function(l,t,n,i){for(arguments.length<3&&(n=0),arguments.length<4&&(i=l.length);i>n;){var a=n+i>>>1;t<e.call(l,l[a],a)?i=a:n=a+1}return n}}};var Yi=d3.bisector(function(e){return e});d3.bisectLeft=Yi.left,d3.bisect=d3.bisectRight=Yi.right,d3.first=function(e,l){var t,n=0,i=e.length,a=e[0];for(1===arguments.length&&(l=d3.ascending);++n<i;)l.call(e,a,t=e[n])>0&&(a=t);return a},d3.last=function(e,l){var t,n=0,i=e.length,a=e[0];for(1===arguments.length&&(l=d3.ascending);++n<i;)l.call(e,a,t=e[n])<=0&&(a=t);return a},d3.nest=function(){function e(l,r){if(r>=o.length)return i?i.call(a,l):t?l.sort(t):l;for(var s,c,u,d=-1,h=l.length,f=o[r++],p=new n,m={};++d<h;)(u=p.get(s=f(c=l[d])))?u.push(c):p.set(s,[c]);return p.forEach(function(l,t){m[l]=e(t,r)}),m}function l(e,t){if(t>=o.length)return e;var n,i=[],a=r[t++];for(n in e)i.push({key:n,values:l(e[n],t)});return a&&i.sort(function(e,l){return a(e.key,l.key)}),i}var t,i,a={},o=[],r=[];return a.map=function(l){return e(l,0)},a.entries=function(t){return l(e(t,0),0)},a.key=function(e){return o.push(e),a},a.sortKeys=function(e){return r[o.length-1]=e,a},a.sortValues=function(e){return t=e,a},a.rollup=function(e){return i=e,a},a},d3.keys=function(e){var l=[];for(var t in e)l.push(t);return l},d3.values=function(e){var l=[];for(var t in e)l.push(e[t]);return l},d3.entries=function(e){var l=[];for(var t in e)l.push({key:t,value:e[t]});return l},d3.permute=function(e,l){for(var t=[],n=-1,i=l.length;++n<i;)t[n]=e[l[n]];return t},d3.merge=function(e){return Array.prototype.concat.apply([],e)},d3.split=function(e,l){var t,n=[],i=[],a=-1,o=e.length;for(arguments.length<2&&(l=d);++a<o;)l.call(i,t=e[a],a)?i=[]:(i.length||n.push(i),i.push(t));return n},d3.range=function(e,l,t){if(arguments.length<3&&(t=1,arguments.length<2&&(l=e,e=0)),1/0===(l-e)/t)throw new Error("infinite range");var n,i=[],a=f(Math.abs(t)),o=-1;if(e*=a,l*=a,t*=a,0>t)for(;(n=e+t*++o)>l;)i.push(n/a);else for(;(n=e+t*++o)<l;)i.push(n/a);return i},d3.requote=function(e){return e.replace(Ji,"\$&")};var Ji=/[\^$*+?|[]().{}]/g;d3.round=function(e,l){return l?Math.round(e*(l=Math.pow(10,l)))/l:Math.round(e)},d3.xhr=function(e,l,t){var n=new XMLHttpRequest;arguments.length<3?(t=l,l=null):l&&n.overrideMimeType&&n.overrideMimeType(l),n.open("GET",e,!0),l&&n.setRequestHeader("Accept",l),n.onreadystatechange=function(){if(4===n.readyState){var e=n.status;t(!e&&n.response||e>=200&&300>e||304===e?n:null)}},n.send(null)},d3.text=function(e,l,t){function n(e){t(e&&e.responseText)}arguments.length<3&&(t=l,l=null),d3.xhr(e,l,n)},d3.json=function(e,l){d3.text(e,"application/json",function(e){l(e?JSON.parse(e):null)})},d3.html=function(e,l){d3.text(e,"text/html",function(e){if(null!=e){var t=document.createRange();t.selectNode(document.body),e=t.createContextualFragment(e)}l(e)})},d3.xml=function(e,l,t){function n(e){t(e&&e.responseXML)}arguments.length<3&&(t=l,l=null),d3.xhr(e,l,n)};var Xi={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};d3.ns={prefix:Xi,qualify:function(e){var l=e.indexOf(":"),t=e;return l>=0&&(t=e.substring(0,l),e=e.substring(l+1)),Xi.hasOwnProperty(t)?{space:Xi[t],local:e}:e}},d3.dispatch=function(){for(var e=new p,l=-1,t=arguments.length;++l<t;)e[arguments[l]]=m(e);return e},p.prototype.on=function(e,l){var t=e.indexOf("."),n="";return t>0&&(n=e.substring(t+1),e=e.substring(0,t)),arguments.length<2?this[e].on(n):this[e].on(n,l)},d3.format=function(e){var l=Qi.exec(e),t=l[1]||" ",n=l[3]||"",i=l[5],a=+l[6],o=l[7],r=l[8],s=l[9],c=1,u="",d=!1;switch(r&&(r=+r.substring(1)),i&&(t="0",o&&(a-=Math.floor((a-1)/4))),s){case"n":o=!0,s="g";break;case"%":c=100,u="%",s="f";break;case"p":c=100,u="%",s="r";break;case"d":d=!0,r=0;break;case"s":c=-1,s="r"}return"r"!=s||r||(s="g"),s=ea.get(s)||v,function(e){if(d&&e%1)return"";var l=0>e&&(e=-e)?"-":n;if(0>c){var h=d3.formatPrefix(e,r);e=h.scale(e),u=h.symbol}else e*=c;if(e=s(e,r),i){var f=e.length+l.length;a>f&&(e=new Array(a-f+1).join(t)+e),o&&(e=y(e)),e=l+e}else{o&&(e=y(e)),e=l+e;var f=e.length;a>f&&(e=new Array(a-f+1).join(t)+e)}return e+u}};var Qi=/(?:([^{])?([<>=^]))?([+- ])?(#)?(0)?([0-9]+)?(,)?(.[0-9]+)?([a-zA-Z%])?/,ea=d3.map({g:function(e,l){return e.toPrecision(l)},e:function(e,l){return e.toExponential(l)},f:function(e,l){return e.toFixed(l)},r:function(e,l){return d3.round(e,l=g(e,l)).toFixed(Math.max(0,Math.min(20,l)))}}),la=["y","z","a","f","p","n","μ","m","","k","M","G","T","P","E","Z","Y"].map(b);d3.formatPrefix=function(e,l){var t=0;return e&&(0>e&&(e*=-1),l&&(e=d3.round(e,g(e,l))),t=1+Math.floor(1e-12+Math.log(e)/Math.LN10),t=Math.max(-24,Math.min(24,3*Math.floor((0>=t?t+1:t-1)/3)))),la[8+t/3]};var ta=w(2),na=w(3),ia=function(){return D},aa=d3.map({linear:ia,poly:w,quad:function(){return ta},cubic:function(){return na},sin:function(){return _},exp:function(){return I},circle:function(){return S},elastic:k,back:x,bounce:function(){return O}}),oa=d3.map({"in":D,out:C,"in-out":E,"out-in":function(e){return E(C(e))}});d3.ease=function(e){var l=e.indexOf("-"),t=l>=0?e.substring(0,l):e,n=l>=0?e.substring(l+1):"in";return t=aa.get(t)||ia,n=oa.get(n)||D,T(n(t.apply(null,Array.prototype.slice.call(arguments,1))))},d3.event=null,d3.transform=function(e){var l=document.createElementNS(d3.ns.prefix.svg,"g");return(d3.transform=function(e){l.setAttribute("transform",e);var t=l.transform.baseVal.consolidate();return new A(t?t.matrix:sa)})(e)},A.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var ra=180/Math.PI,sa={a:1,b:0,c:0,d:1,e:0,f:0};d3.interpolate=function(e,l){for(var t,n=d3.interpolators.length;--n>=0&&!(t=d3.interpolators[n](e,l)););return t},d3.interpolateNumber=function(e,l){return l-=e,function(t){return e+l*t}},d3.interpolateRound=function(e,l){return l-=e,function(t){return Math.round(e+l*t)}},d3.interpolateString=function(e,l){var t,n,i,a,o,r=0,s=0,c=[],u=[];for(ca.lastIndex=0,n=0;t=ca.exec(l);++n)t.index&&c.push(l.substring(r,s=t.index)),u.push({i:c.length,x:t[0]}),c.push(null),r=ca.lastIndex;for(r<l.length&&c.push(l.substring(r)),n=0,a=u.length;(t=ca.exec(e))&&a>n;++n)if(o=u[n],o.x==t[0]){if(o.i)if(null==c[o.i+1])for(c[o.i-1]+=o.x,c.splice(o.i,1),i=n+1;a>i;++i)u[i].i--;else for(c[o.i-1]+=o.x+c[o.i+1],c.splice(o.i,2),i=n+1;a>i;++i)u[i].i-=2;else if(null==c[o.i+1])c[o.i]=o.x;else for(c[o.i]=o.x+c[o.i+1],c.splice(o.i+1,1),i=n+1;a>i;++i)u[i].i--;u.splice(n,1),a--,n--}else o.x=d3.interpolateNumber(parseFloat(t[0]),parseFloat(o.x));for(;a>n;)o=u.pop(),null==c[o.i+1]?c[o.i]=o.x:(c[o.i]=o.x+c[o.i+1],c.splice(o.i+1,1)),a--;return 1===c.length?null==c[0]?u[0].x:function(){return l}:function(e){for(n=0;a>n;++n)c[(o=u[n]).i]=o.x(e);return c.join("")}},d3.interpolateTransform=function(e,l){var t,n=[],i=[],a=d3.transform(e),o=d3.transform(l),r=a.translate,s=o.translate,c=a.rotate,u=o.rotate,d=a.skew,h=o.skew,f=a.scale,p=o.scale;return r[0]!=s[0]||r[1]!=s[1]?(n.push("translate(",null,",",null,")"),i.push({i:1,x:d3.interpolateNumber(r[0],s[0])},{i:3,x:d3.interpolateNumber(r[1],s[1])})):s[0]||s[1]?n.push("translate("+s+")"):n.push(""),c!=u?(c-u>180?u+=360:u-c>180&&(c+=360),i.push({i:n.push(n.pop()+"rotate(",null,")")-2,x:d3.interpolateNumber(c,u)})):u&&n.push(n.pop()+"rotate("+u+")"),d!=h?i.push({i:n.push(n.pop()+"skewX(",null,")")-2,x:d3.interpolateNumber(d,h)}):h&&n.push(n.pop()+"skewX("+h+")"),f[0]!=p[0]||f[1]!=p[1]?(t=n.push(n.pop()+"scale(",null,",",null,")"),i.push({i:t-4,x:d3.interpolateNumber(f[0],p[0])},{i:t-2,x:d3.interpolateNumber(f[1],p[1])})):(1!=p[0]||1!=p[1])&&n.push(n.pop()+"scale("+p+")"),t=i.length,function(e){for(var l,a=-1;++a<t;)n[(l=i[a]).i]=l.x(e);return n.join("")}},d3.interpolateRgb=function(e,l){e=d3.rgb(e),l=d3.rgb(l);var t=e.r,n=e.g,i=e.b,a=l.r-t,o=l.g-n,r=l.b-i;return function(e){return"#"+z(Math.round(t+a*e))+z(Math.round(n+o*e))+z(Math.round(i+r*e))}},d3.interpolateHsl=function(e,l){e=d3.hsl(e),l=d3.hsl(l);var t=e.h,n=e.s,i=e.l,a=l.h-t,o=l.s-n,r=l.l-i;return a>180?a-=360:-180>a&&(a+=360),function(e){return X(t+a*e,n+o*e,i+r*e)+""}},d3.interpolateLab=function(e,l){e=d3.lab(e),l=d3.lab(l);var t=e.l,n=e.a,i=e.b,a=l.l-t,o=l.a-n,r=l.b-i;return function(e){return il(t+a*e,n+o*e,i+r*e)+""}},d3.interpolateHcl=function(e,l){e=d3.hcl(e),l=d3.hcl(l);var t=e.h,n=e.c,i=e.l,a=l.h-t,o=l.c-n,r=l.l-i;return a>180?a-=360:-180>a&&(a+=360),function(e){return ll(t+a*e,n+o*e,i+r*e)+""}},d3.interpolateArray=function(e,l){var t,n=[],i=[],a=e.length,o=l.length,r=Math.min(e.length,l.length);for(t=0;r>t;++t)n.push(d3.interpolate(e[t],l[t]));for(;a>t;++t)i[t]=e[t];for(;o>t;++t)i[t]=l[t];return function(e){for(t=0;r>t;++t)i[t]=n[t](e);return i}},d3.interpolateObject=function(e,l){var t,n={},i={};for(t in e)t in l?n[t]=F(t)(e[t],l[t]):i[t]=e[t];for(t in l)t in e||(i[t]=l[t]);return function(e){for(t in n)i[t]=n[t](e);return i}};var ca=/[-+]?(?:d+.?d*|.?d+)(?:[eE][-+]?d+)?/g;d3.interpolators=[d3.interpolateObject,function(e,l){return l instanceof Array&&d3.interpolateArray(e,l)},function(e,l){return("string"==typeof e||"string"==typeof l)&&d3.interpolateString(e+"",l+"")},function(e,l){return("string"==typeof l?da.has(l)||/^(#|rgb(|hsl()/.test(l):l instanceof H)&&d3.interpolateRgb(e,l)},function(e,l){return!isNaN(e=+e)&&!isNaN(l=+l)&&d3.interpolateNumber(e,l)}],H.prototype.toString=function(){return this.rgb()+""},d3.rgb=function(e,l,t){return 1===arguments.length?e instanceof U?Z(e.r,e.g,e.b):j(""+e,Z,X):Z(~~e,~~l,~~t)};var ua=U.prototype=new H;ua.brighter=function(e){e=Math.pow(.7,arguments.length?e:1);var l=this.r,t=this.g,n=this.b,i=30;return l||t||n?(l&&i>l&&(l=i),t&&i>t&&(t=i),n&&i>n&&(n=i),Z(Math.min(255,Math.floor(l/e)),Math.min(255,Math.floor(t/e)),Math.min(255,Math.floor(n/e)))):Z(i,i,i)},ua.darker=function(e){return e=Math.pow(.7,arguments.length?e:1),Z(Math.floor(e*this.r),Math.floor(e*this.g),Math.floor(e*this.b))},ua.hsl=function(){return W(this.r,this.g,this.b)},ua.toString=function(){return"#"+z(this.r)+z(this.g)+z(this.b)};var da=d3.map({aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"});da.forEach(function(e,l){da.set(e,j(l,Z,X))}),d3.hsl=function(e,l,t){return 1===arguments.length?e instanceof J?Y(e.h,e.s,e.l):j(""+e,W,Y):Y(+e,+l,+t)};var ha=J.prototype=new H;ha.brighter=function(e){return e=Math.pow(.7,arguments.length?e:1),Y(this.h,this.s,this.l/e)},ha.darker=function(e){return e=Math.pow(.7,arguments.length?e:1),Y(this.h,this.s,e*this.l)},ha.rgb=function(){return X(this.h,this.s,this.l)},d3.hcl=function(e,l,t){return 1===arguments.length?e instanceof el?Q(e.h,e.c,e.l):e instanceof nl?al(e.l,e.a,e.b):al((e=G((e=d3.rgb(e)).r,e.g,e.b)).l,e.a,e.b):Q(+e,+l,+t)};var fa=el.prototype=new H;fa.brighter=function(e){return Q(this.h,this.c,Math.min(100,this.l+pa*(arguments.length?e:1)))},fa.darker=function(e){return Q(this.h,this.c,Math.max(0,this.l-pa*(arguments.length?e:1)))},fa.rgb=function(){return ll(this.h,this.c,this.l).rgb()},d3.lab=function(e,l,t){return 1===arguments.length?e instanceof nl?tl(e.l,e.a,e.b):e instanceof el?ll(e.l,e.c,e.h):G((e=d3.rgb(e)).r,e.g,e.b):tl(+e,+l,+t)};var pa=18,ma=.95047,ga=1,va=1.08883,ya=nl.prototype=new H;ya.brighter=function(e){return tl(Math.min(100,this.l+pa*(arguments.length?e:1)),this.a,this.b)},ya.darker=function(e){return tl(Math.max(0,this.l-pa*(arguments.length?e:1)),this.a,this.b)},ya.rgb=function(){return il(this.l,this.a,this.b)};var ba=function(e,l){return l.querySelector(e)},Ta=function(e,l){return l.querySelectorAll(e)},Ca=document.documentElement,Ea=Ca.matchesSelector||Ca.webkitMatchesSelector||Ca.mozMatchesSelector||Ca.msMatchesSelector||Ca.oMatchesSelector,Da=function(e,l){return Ea.call(e,l)};"function"==typeof Sizzle&&(ba=function(e,l){return Sizzle(e,l)[0]||null},Ta=function(e,l){return Sizzle.uniqueSort(Sizzle(e,l))},Da=Sizzle.matchesSelector);var wa=[];d3.selection=function(){return _a},d3.selection.prototype=wa,wa.select=function(e){var l,t,n,i,a=[];"function"!=typeof e&&(e=ul(e));for(var o=-1,r=this.length;++o<r;){a.push(l=[]),l.parentNode=(n=this[o]).parentNode;for(var s=-1,c=n.length;++s<c;)(i=n[s])?(l.push(t=e.call(i,i.__data__,s)),t&&"__data__"in i&&(t.__data__=i.__data__)):l.push(null)}return cl(a)},wa.selectAll=function(e){var l,t,n=[];"function"!=typeof e&&(e=dl(e));for(var i=-1,a=this.length;++i<a;)for(var o=this[i],r=-1,s=o.length;++r<s;)(t=o[r])&&(n.push(l=ji(e.call(t,t.__data__,r))),l.parentNode=t);return cl(n)},wa.attr=function(e,l){if(arguments.length<2){if("string"==typeof e){var t=this.node();return e=d3.ns.qualify(e),e.local?t.getAttributeNS(e.space,e.local):t.getAttribute(e)}for(l in e)this.each(hl(l,e[l]));return this}return this.each(hl(e,l))},wa.classed=function(e,l){if(arguments.length<2){if("string"==typeof e){var t=this.node(),n=(e=e.trim().split(/^|s+/g)).length,i=-1;if(l=t.classList){for(;++i<n;)if(!l.contains(e[i]))return!1}else for(l=t.className,null!=l.baseVal&&(l=l.baseVal);++i<n;)if(!fl(e[i]).test(l))return!1;return!0}for(l in e)this.each(pl(l,e[l]));return this}return this.each(pl(e,l))},wa.style=function(e,l,t){var n=arguments.length;if(3>n){if("string"!=typeof e){2>n&&(l="");for(t in e)this.each(gl(t,e[t],l));return this}if(2>n)return window.getComputedStyle(this.node(),null).getPropertyValue(e);t=""}return this.each(gl(e,l,t))},wa.property=function(e,l){if(arguments.length<2){if("string"==typeof e)return this.node()[e];for(l in e)this.each(vl(l,e[l]));return this}return this.each(vl(e,l))},wa.text=function(e){return arguments.length<1?this.node().textContent:this.each("function"==typeof e?function(){var l=e.apply(this,arguments);this.textContent=null==l?"":l}:null==e?function(){this.textContent=""}:function(){this.textContent=e})},wa.html=function(e){return arguments.length<1?this.node().innerHTML:this.each("function"==typeof e?function(){var l=e.apply(this,arguments);this.innerHTML=null==l?"":l}:null==e?function(){this.innerHTML=""}:function(){this.innerHTML=e})},wa.append=function(e){function l(){return this.appendChild(document.createElementNS(this.namespaceURI,e))}function t(){return this.appendChild(document.createElementNS(e.space,e.local))}return e=d3.ns.qualify(e),this.select(e.local?t:l)},wa.insert=function(e,l){function t(){return this.insertBefore(document.createElementNS(this.namespaceURI,e),ba(l,this))}function n(){return this.insertBefore(document.createElementNS(e.space,e.local),ba(l,this))}return e=d3.ns.qualify(e),this.select(e.local?n:t)},wa.remove=function(){return this.each(function(){var e=this.parentNode;e&&e.removeChild(this)})},wa.data=function(e,l){function t(e,t){var i,a,o,r=e.length,d=t.length,h=Math.min(r,d),f=Math.max(r,d),p=[],m=[],g=[];if(l){var v,y=new n,b=[],T=t.length;for(i=-1;++i<r;)v=l.call(a=e[i],a.__data__,i),y.has(v)?g[T++]=a:y.set(v,a),b.push(v);for(i=-1;++i<d;)v=l.call(t,o=t[i],i),y.has(v)?(p[i]=a=y.get(v),a.__data__=o,m[i]=g[i]=null):(m[i]=yl(o),p[i]=g[i]=null),y.remove(v);for(i=-1;++i<r;)y.has(b[i])&&(g[i]=e[i])}else{for(i=-1;++i<h;)a=e[i],o=t[i],a?(a.__data__=o,p[i]=a,m[i]=g[i]=null):(m[i]=yl(o),p[i]=g[i]=null);for(;d>i;++i)m[i]=yl(t[i]),p[i]=g[i]=null;for(;f>i;++i)g[i]=e[i],m[i]=p[i]=null}m.update=p,m.parentNode=p.parentNode=g.parentNode=e.parentNode,s.push(m),c.push(p),u.push(g)}var i,a,o=-1,r=this.length;if(!arguments.length){for(e=new Array(r=(i=this[0]).length);++o<r;)(a=i[o])&&(e[o]=a.__data__);return e}var s=Dl([]),c=cl([]),u=cl([]);if("function"==typeof e)for(;++o<r;)t(i=this[o],e.call(i,i.parentNode.__data__,o));else for(;++o<r;)t(i=this[o],e);return c.enter=function(){return s},c.exit=function(){return u},c},wa.datum=wa.map=function(e){return arguments.length<1?this.property("__data__"):this.property("__data__",e)},wa.filter=function(e){var l,t,n,i=[];"function"!=typeof e&&(e=bl(e));for(var a=0,o=this.length;o>a;a++){i.push(l=[]),l.parentNode=(t=this[a]).parentNode;for(var r=0,s=t.length;s>r;r++)(n=t[r])&&e.call(n,n.__data__,r)&&l.push(n)}return cl(i)},wa.order=function(){for(var e=-1,l=this.length;++e<l;)for(var t,n=this[e],i=n.length-1,a=n[i];--i>=0;)(t=n[i])&&(a&&a!==t.nextSibling&&a.parentNode.insertBefore(t,a),a=t);return this},wa.sort=function(e){e=Tl.apply(this,arguments);for(var l=-1,t=this.length;++l<t;)this[l].sort(e);return this.order()},wa.on=function(e,l,t){var n=arguments.length;if(3>n){if("string"!=typeof e){2>n&&(l=!1);for(t in e)this.each(Cl(t,e[t],l));return this}if(2>n)return(n=this.node()["__on"+e])&&n._;t=!1}return this.each(Cl(e,l,t))},wa.each=function(e){return El(this,function(l,t,n){e.call(l,l.__data__,t,n)})},wa.call=function(e){return e.apply(this,(arguments[0]=this,arguments)),this},wa.empty=function(){return!this.node()},wa.node=function(){for(var e=0,l=this.length;l>e;e++)for(var t=this[e],n=0,i=t.length;i>n;n++){var a=t[n];if(a)return a}return null},wa.transition=function(){for(var e,l,t=[],n=-1,i=this.length;++n<i;){t.push(e=[]);for(var a=this[n],o=-1,r=a.length;++o<r;)e.push((l=a[o])?{node:l,delay:Na,duration:Aa}:null)}return wl(t,xa||++ka,Date.now())};var _a=cl([[document]]);_a[0].parentNode=Ca,d3.select=function(e){return"string"==typeof e?_a.select(e):cl([[e]])},d3.selectAll=function(e){return"string"==typeof e?_a.selectAll(e):cl([ji(e)])};var Ia=[];d3.selection.enter=Dl,d3.selection.enter.prototype=Ia,Ia.append=wa.append,Ia.insert=wa.insert,Ia.empty=wa.empty,Ia.node=wa.node,Ia.select=function(e){for(var l,t,n,i,a,o=[],r=-1,s=this.length;++r<s;){n=(i=this[r]).update,o.push(l=[]),l.parentNode=i.parentNode;for(var c=-1,u=i.length;++c<u;)(a=i[c])?(l.push(n[c]=t=e.call(i.parentNode,a.__data__,c)),t.__data__=a.__data__):l.push(null)}return cl(o)};var Sa=[],ka=0,xa=0,Oa=0,Ra=250,Ma=d3.ease("cubic-in-out"),Na=Oa,Aa=Ra,Ka=Ma;Sa.call=wa.call,d3.transition=function(e){return arguments.length?xa?e.transition():e:_a.transition()},d3.transition.prototype=Sa,Sa.select=function(e){var l,t,n,i=[];"function"!=typeof e&&(e=ul(e));for(var a=-1,o=this.length;++a<o;){i.push(l=[]);for(var r=this[a],s=-1,c=r.length;++s<c;)(n=r[s])&&(t=e.call(n.node,n.node.__data__,s))?("__data__"in n.node&&(t.__data__=n.node.__data__),l.push({node:t,delay:n.delay,duration:n.duration})):l.push(null)}return wl(i,this.id,this.time).ease(this.ease())},Sa.selectAll=function(e){var l,t,n,i=[];"function"!=typeof e&&(e=dl(e));for(var a=-1,o=this.length;++a<o;)for(var r=this[a],s=-1,c=r.length;++s<c;)if(n=r[s]){t=e.call(n.node,n.node.__data__,s),i.push(l=[]);for(var u=-1,d=t.length;++u<d;)l.push({node:t[u],delay:n.delay,duration:n.duration})}return wl(i,this.id,this.time).ease(this.ease())},Sa.filter=function(e){var l,t,n,i=[];"function"!=typeof e&&(e=bl(e));for(var a=0,o=this.length;o>a;a++){i.push(l=[]);for(var t=this[a],r=0,s=t.length;s>r;r++)(n=t[r])&&e.call(n.node,n.node.__data__,r)&&l.push(n)}return wl(i,this.id,this.time).ease(this.ease())},Sa.attr=function(e,l){if(arguments.length<2){for(l in e)this.attrTween(l,Sl(e[l],l));return this}return this.attrTween(e,Sl(l,e))},Sa.attrTween=function(e,l){function t(e,t){var n=l.call(this,e,t,this.getAttribute(i));return n===Fa?(this.removeAttribute(i),null):n&&function(e){this.setAttribute(i,n(e))}}function n(e,t){var n=l.call(this,e,t,this.getAttributeNS(i.space,i.local));return n===Fa?(this.removeAttributeNS(i.space,i.local),null):n&&function(e){this.setAttributeNS(i.space,i.local,n(e))}}var i=d3.ns.qualify(e);return this.tween("attr."+e,i.local?n:t)},Sa.style=function(e,l,t){var n=arguments.length;if(3>n){if("string"!=typeof e){2>n&&(l="");for(t in e)this.styleTween(t,Sl(e[t],t),l);return this}t=""}return this.styleTween(e,Sl(l,e),t)},Sa.styleTween=function(e,l,t){return arguments.length<3&&(t=""),this.tween("style."+e,function(n,i){var a=l.call(this,n,i,window.getComputedStyle(this,null).getPropertyValue(e));return a===Fa?(this.style.removeProperty(e),null):a&&function(l){this.style.setProperty(e,a(l),t)}})},Sa.text=function(e){return this.tween("text",function(l,t){this.textContent="function"==typeof e?e.call(this,l,t):e})},Sa.remove=function(){return this.each("end.transition",function(){var e;!this.__transition__&&(e=this.parentNode)&&e.removeChild(this)
})},Sa.delay=function(e){return El(this,"function"==typeof e?function(l,t,n){l.delay=0|e.call(l=l.node,l.__data__,t,n)}:(e=0|e,function(l){l.delay=e}))},Sa.duration=function(e){return El(this,"function"==typeof e?function(l,t,n){l.duration=Math.max(1,0|e.call(l=l.node,l.__data__,t,n))}:(e=Math.max(1,0|e),function(l){l.duration=e}))},Sa.transition=function(){return this.select(a)},d3.tween=function(e,l){function t(t,n,i){var a=e.call(this,t,n);return null==a?""!=i&&Fa:i!=a&&l(i,a+"")}function n(t,n,i){return i!=e&&l(i,e)}return"function"==typeof e?t:null==e?Il:(e+="",n)};var La,Pa,Fa={},Ba=0,$a={},Ha=null;d3.timer=function(e,l,t){if(arguments.length<3){if(arguments.length<2)l=0;else if(!isFinite(l))return;t=Date.now()}var n=$a[e.id];n&&n.callback===e?(n.then=t,n.delay=l):$a[e.id=++Ba]=Ha={callback:e,then:t,delay:l,next:Ha},La||(Pa=clearTimeout(Pa),La=1,Za(kl))},d3.timer.flush=function(){for(var e,l=Date.now(),t=Ha;t;)e=l-t.then,t.delay||(t.flush=t.callback(e)),t=t.next;xl()};var Za=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(e){setTimeout(e,17)};d3.mouse=function(e){return Ol(e,M())};var Ua=/WebKit/.test(navigator.userAgent)?-1:0;d3.touches=function(e,l){return arguments.length<2&&(l=M().touches),l?ji(l).map(function(l){var t=Ol(e,l);return t.identifier=l.identifier,t}):[]},d3.scale={},d3.scale.linear=function(){return Kl([0,1],[0,1],d3.interpolate,!1)},d3.scale.log=function(){return Ul(d3.scale.linear(),zl)};var za=d3.format(".0e");zl.pow=function(e){return Math.pow(10,e)},jl.pow=function(e){return-Math.pow(10,-e)},d3.scale.pow=function(){return Wl(d3.scale.linear(),1)},d3.scale.sqrt=function(){return d3.scale.pow().exponent(.5)},d3.scale.ordinal=function(){return Vl([],{t:"range",a:[[]]})},d3.scale.category10=function(){return d3.scale.ordinal().range(ja)},d3.scale.category20=function(){return d3.scale.ordinal().range(Wa)},d3.scale.category20b=function(){return d3.scale.ordinal().range(Ga)},d3.scale.category20c=function(){return d3.scale.ordinal().range(Va)};var ja=["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],Wa=["#1f77b4","#aec7e8","#ff7f0e","#ffbb78","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5","#8c564b","#c49c94","#e377c2","#f7b6d2","#7f7f7f","#c7c7c7","#bcbd22","#dbdb8d","#17becf","#9edae5"],Ga=["#393b79","#5254a3","#6b6ecf","#9c9ede","#637939","#8ca252","#b5cf6b","#cedb9c","#8c6d31","#bd9e39","#e7ba52","#e7cb94","#843c39","#ad494a","#d6616b","#e7969c","#7b4173","#a55194","#ce6dbd","#de9ed6"],Va=["#3182bd","#6baed6","#9ecae1","#c6dbef","#e6550d","#fd8d3c","#fdae6b","#fdd0a2","#31a354","#74c476","#a1d99b","#c7e9c0","#756bb1","#9e9ac8","#bcbddc","#dadaeb","#636363","#969696","#bdbdbd","#d9d9d9"];d3.scale.quantile=function(){return ql([],[])},d3.scale.quantize=function(){return Yl(0,1,[0,1])},d3.scale.threshold=function(){return Jl([.5],[0,1])},d3.scale.identity=function(){return Xl([0,1])},d3.svg={},d3.svg.arc=function(){function e(){var e=l.apply(this,arguments),a=t.apply(this,arguments),o=n.apply(this,arguments)+qa,r=i.apply(this,arguments)+qa,s=(o>r&&(s=o,o=r,r=s),r-o),c=s<Math.PI?"0":"1",u=Math.cos(o),d=Math.sin(o),h=Math.cos(r),f=Math.sin(r);return s>=Ya?e?"M0,"+a+"A"+a+","+a+" 0 1,1 0,"+-a+"A"+a+","+a+" 0 1,1 0,"+a+"M0,"+e+"A"+e+","+e+" 0 1,0 0,"+-e+"A"+e+","+e+" 0 1,0 0,"+e+"Z":"M0,"+a+"A"+a+","+a+" 0 1,1 0,"+-a+"A"+a+","+a+" 0 1,1 0,"+a+"Z":e?"M"+a*u+","+a*d+"A"+a+","+a+" 0 "+c+",1 "+a*h+","+a*f+"L"+e*h+","+e*f+"A"+e+","+e+" 0 "+c+",0 "+e*u+","+e*d+"Z":"M"+a*u+","+a*d+"A"+a+","+a+" 0 "+c+",1 "+a*h+","+a*f+"L0,0"+"Z"}var l=Ql,t=et,n=lt,i=tt;return e.innerRadius=function(t){return arguments.length?(l=r(t),e):l},e.outerRadius=function(l){return arguments.length?(t=r(l),e):t},e.startAngle=function(l){return arguments.length?(n=r(l),e):n},e.endAngle=function(l){return arguments.length?(i=r(l),e):i},e.centroid=function(){var e=(l.apply(this,arguments)+t.apply(this,arguments))/2,a=(n.apply(this,arguments)+i.apply(this,arguments))/2+qa;return[Math.cos(a)*e,Math.sin(a)*e]},e};var qa=-Math.PI/2,Ya=2*Math.PI-1e-6;d3.svg.line=function(){return nt(i)};var Ja=d3.map({linear:ot,"linear-closed":rt,"step-before":st,"step-after":ct,basis:mt,"basis-open":gt,"basis-closed":vt,bundle:yt,cardinal:ht,"cardinal-open":ut,"cardinal-closed":dt,monotone:wt});Ja.forEach(function(e,l){l.key=e,l.closed=/-closed$/.test(e)});var Xa=[0,2/3,1/3,0],Qa=[0,1/3,2/3,0],eo=[0,1/6,2/3,1/6];d3.svg.line.radial=function(){var e=nt(_t);return e.radius=e.x,delete e.x,e.angle=e.y,delete e.y,e},st.reverse=ct,ct.reverse=st,d3.svg.area=function(){return It(i)},d3.svg.area.radial=function(){var e=It(_t);return e.radius=e.x,delete e.x,e.innerRadius=e.x0,delete e.x0,e.outerRadius=e.x1,delete e.x1,e.angle=e.y,delete e.y,e.startAngle=e.y0,delete e.y0,e.endAngle=e.y1,delete e.y1,e},d3.svg.chord=function(){function e(e,r){var s=l(this,a,e,r),c=l(this,o,e,r);return"M"+s.p0+n(s.r,s.p1,s.a1-s.a0)+(t(s,c)?i(s.r,s.p1,s.r,s.p0):i(s.r,s.p1,c.r,c.p0)+n(c.r,c.p1,c.a1-c.a0)+i(c.r,c.p1,s.r,s.p0))+"Z"}function l(e,l,t,n){var i=l.call(e,t,n),a=s.call(e,i,n),o=c.call(e,i,n)+qa,r=u.call(e,i,n)+qa;return{r:a,a0:o,a1:r,p0:[a*Math.cos(o),a*Math.sin(o)],p1:[a*Math.cos(r),a*Math.sin(r)]}}function t(e,l){return e.a0==l.a0&&e.a1==l.a1}function n(e,l,t){return"A"+e+","+e+" 0 "+ +(t>Math.PI)+",1 "+l}function i(e,l,t,n){return"Q 0,0 "+n}var a=St,o=kt,s=xt,c=lt,u=tt;return e.radius=function(l){return arguments.length?(s=r(l),e):s},e.source=function(l){return arguments.length?(a=r(l),e):a},e.target=function(l){return arguments.length?(o=r(l),e):o},e.startAngle=function(l){return arguments.length?(c=r(l),e):c},e.endAngle=function(l){return arguments.length?(u=r(l),e):u},e},d3.svg.diagonal=function(){function e(e,i){var a=l.call(this,e,i),o=t.call(this,e,i),r=(a.y+o.y)/2,s=[a,{x:a.x,y:r},{x:o.x,y:r},o];return s=s.map(n),"M"+s[0]+"C"+s[1]+" "+s[2]+" "+s[3]}var l=St,t=kt,n=Ot;return e.source=function(t){return arguments.length?(l=r(t),e):l},e.target=function(l){return arguments.length?(t=r(l),e):t},e.projection=function(l){return arguments.length?(n=l,e):n},e},d3.svg.diagonal.radial=function(){var e=d3.svg.diagonal(),l=Ot,t=e.projection;return e.projection=function(e){return arguments.length?t(Rt(l=e)):l},e},d3.svg.mouse=d3.mouse,d3.svg.touches=d3.touches,d3.svg.symbol=function(){function e(e,n){return(lo.get(l.call(this,e,n))||At)(t.call(this,e,n))}var l=Nt,t=Mt;return e.type=function(t){return arguments.length?(l=r(t),e):l},e.size=function(l){return arguments.length?(t=r(l),e):t},e};var lo=d3.map({circle:At,cross:function(e){var l=Math.sqrt(e/5)/2;return"M"+-3*l+","+-l+"H"+-l+"V"+-3*l+"H"+l+"V"+-l+"H"+3*l+"V"+l+"H"+l+"V"+3*l+"H"+-l+"V"+l+"H"+-3*l+"Z"},diamond:function(e){var l=Math.sqrt(e/(2*no)),t=l*no;return"M0,"+-l+"L"+t+",0"+" 0,"+l+" "+-t+",0"+"Z"},square:function(e){var l=Math.sqrt(e)/2;return"M"+-l+","+-l+"L"+l+","+-l+" "+l+","+l+" "+-l+","+l+"Z"},"triangle-down":function(e){var l=Math.sqrt(e/to),t=l*to/2;return"M0,"+t+"L"+l+","+-t+" "+-l+","+-t+"Z"},"triangle-up":function(e){var l=Math.sqrt(e/to),t=l*to/2;return"M0,"+-t+"L"+l+","+t+" "+-l+","+t+"Z"}});d3.svg.symbolTypes=lo.keys();var to=Math.sqrt(3),no=Math.tan(30*Math.PI/180);d3.svg.axis=function(){function e(e){e.each(function(){var e,d=d3.select(this),h=null==c?t.ticks?t.ticks.apply(t,s):t.domain():c,f=null==l?t.tickFormat?t.tickFormat.apply(t,s):String:l,p=Pt(t,h,u),m=d.selectAll(".minor").data(p,String),g=m.enter().insert("line","g").attr("class","tick minor").style("opacity",1e-6),v=d3.transition(m.exit()).style("opacity",1e-6).remove(),y=d3.transition(m).style("opacity",1),b=d.selectAll("g").data(h,String),T=b.enter().insert("g","path").style("opacity",1e-6),C=d3.transition(b.exit()).style("opacity",1e-6).remove(),E=d3.transition(b).style("opacity",1),D=Ml(t),w=d.selectAll(".domain").data([0]),_=(w.enter().append("path").attr("class","domain"),d3.transition(w)),I=t.copy(),S=this.__chart__||I;this.__chart__=I,T.append("line").attr("class","tick"),T.append("text");var k=T.select("line"),x=E.select("line"),O=b.select("text").text(f),R=T.select("text"),M=E.select("text");switch(n){case"bottom":e=Kt,g.attr("y2",a),y.attr("x2",0).attr("y2",a),k.attr("y2",i),R.attr("y",Math.max(i,0)+r),x.attr("x2",0).attr("y2",i),M.attr("x",0).attr("y",Math.max(i,0)+r),O.attr("dy",".71em").attr("text-anchor","middle"),_.attr("d","M"+D[0]+","+o+"V0H"+D[1]+"V"+o);break;case"top":e=Kt,g.attr("y2",-a),y.attr("x2",0).attr("y2",-a),k.attr("y2",-i),R.attr("y",-(Math.max(i,0)+r)),x.attr("x2",0).attr("y2",-i),M.attr("x",0).attr("y",-(Math.max(i,0)+r)),O.attr("dy","0em").attr("text-anchor","middle"),_.attr("d","M"+D[0]+","+-o+"V0H"+D[1]+"V"+-o);break;case"left":e=Lt,g.attr("x2",-a),y.attr("x2",-a).attr("y2",0),k.attr("x2",-i),R.attr("x",-(Math.max(i,0)+r)),x.attr("x2",-i).attr("y2",0),M.attr("x",-(Math.max(i,0)+r)).attr("y",0),O.attr("dy",".32em").attr("text-anchor","end"),_.attr("d","M"+-o+","+D[0]+"H0V"+D[1]+"H"+-o);break;case"right":e=Lt,g.attr("x2",a),y.attr("x2",a).attr("y2",0),k.attr("x2",i),R.attr("x",Math.max(i,0)+r),x.attr("x2",i).attr("y2",0),M.attr("x",Math.max(i,0)+r).attr("y",0),O.attr("dy",".32em").attr("text-anchor","start"),_.attr("d","M"+o+","+D[0]+"H0V"+D[1]+"H"+o)}if(t.ticks)T.call(e,S),E.call(e,I),C.call(e,I),g.call(e,S),y.call(e,I),v.call(e,I);else{var N=I.rangeBand()/2,A=function(e){return I(e)+N};T.call(e,A),E.call(e,A)}})}var l,t=d3.scale.linear(),n="bottom",i=6,a=6,o=6,r=3,s=[10],c=null,u=0;return e.scale=function(l){return arguments.length?(t=l,e):t},e.orient=function(l){return arguments.length?(n=l,e):n},e.ticks=function(){return arguments.length?(s=arguments,e):s},e.tickValues=function(l){return arguments.length?(c=l,e):c},e.tickFormat=function(t){return arguments.length?(l=t,e):l},e.tickSize=function(l,t){if(!arguments.length)return i;var n=arguments.length-1;return i=+l,a=n>1?+t:i,o=n>0?+arguments[n]:i,e},e.tickPadding=function(l){return arguments.length?(r=+l,e):r},e.tickSubdivide=function(l){return arguments.length?(u=+l,e):u},e},d3.svg.brush=function(){function e(a){a.each(function(){var a,o=d3.select(this),u=o.selectAll(".background").data([0]),d=o.selectAll(".extent").data([0]),h=o.selectAll(".resize").data(c,String);o.style("pointer-events","all").on("mousedown.brush",i).on("touchstart.brush",i),u.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),d.enter().append("rect").attr("class","extent").style("cursor","move"),h.enter().append("g").attr("class",function(e){return"resize "+e}).style("cursor",function(e){return io[e]}).append("rect").attr("x",function(e){return/[ew]$/.test(e)?-3:null}).attr("y",function(e){return/^[ns]/.test(e)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),h.style("display",e.empty()?"none":null),h.exit().remove(),r&&(a=Ml(r),u.attr("x",a[0]).attr("width",a[1]-a[0]),t(o)),s&&(a=Ml(s),u.attr("y",a[0]).attr("height",a[1]-a[0]),n(o)),l(o)})}function l(e){e.selectAll(".resize").attr("transform",function(e){return"translate("+u[+/e$/.test(e)][0]+","+u[+/^s/.test(e)][1]+")"})}function t(e){e.select(".extent").attr("x",u[0][0]),e.selectAll(".extent,.n>rect,.s>rect").attr("width",u[1][0]-u[0][0])}function n(e){e.select(".extent").attr("y",u[0][1]),e.selectAll(".extent,.e>rect,.w>rect").attr("height",u[1][1]-u[0][1])}function i(){function i(){var e=d3.event.changedTouches;return e?d3.touches(v,e)[0]:d3.mouse(v)}function c(){32==d3.event.keyCode&&(w||(m=null,_[0]-=u[1][0],_[1]-=u[1][1],w=2),R())}function d(){32==d3.event.keyCode&&2==w&&(_[0]+=u[1][0],_[1]+=u[1][1],w=0,R())}function h(){var e=i(),a=!1;g&&(e[0]+=g[0],e[1]+=g[1]),w||(d3.event.altKey?(m||(m=[(u[0][0]+u[1][0])/2,(u[0][1]+u[1][1])/2]),_[0]=u[+(e[0]<m[0])][0],_[1]=u[+(e[1]<m[1])][1]):m=null),E&&f(e,r,0)&&(t(T),a=!0),D&&f(e,s,1)&&(n(T),a=!0),a&&(l(T),b({type:"brush",mode:w?"move":"resize"}))}function f(e,l,t){var n,i,o=Ml(l),r=o[0],s=o[1],c=_[t],d=u[1][t]-u[0][t];return w&&(r-=c,s-=d+c),n=Math.max(r,Math.min(s,e[t])),w?i=(n+=c)+d:(m&&(c=Math.max(r,Math.min(s,2*m[t]-n))),n>c?(i=n,n=c):i=c),u[0][t]!==n||u[1][t]!==i?(a=null,u[0][t]=n,u[1][t]=i,!0):void 0}function p(){h(),T.style("pointer-events","all").selectAll(".resize").style("display",e.empty()?"none":null),d3.select("body").style("cursor",null),I.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),b({type:"brushend"}),R()}var m,g,v=this,y=d3.select(d3.event.target),b=o.of(v,arguments),T=d3.select(v),C=y.datum(),E=!/^(n|s)$/.test(C)&&r,D=!/^(e|w)$/.test(C)&&s,w=y.classed("extent"),_=i(),I=d3.select(window).on("mousemove.brush",h).on("mouseup.brush",p).on("touchmove.brush",h).on("touchend.brush",p).on("keydown.brush",c).on("keyup.brush",d);if(w)_[0]=u[0][0]-_[0],_[1]=u[0][1]-_[1];else if(C){var S=+/w$/.test(C),k=+/^n/.test(C);g=[u[1-S][0]-_[0],u[1-k][1]-_[1]],_[0]=u[S][0],_[1]=u[k][1]}else d3.event.altKey&&(m=_.slice());T.style("pointer-events","none").selectAll(".resize").style("display",null),d3.select("body").style("cursor",y.style("cursor")),b({type:"brushstart"}),h(),R()}var a,o=N(e,"brushstart","brush","brushend"),r=null,s=null,c=ao[0],u=[[0,0],[0,0]];return e.x=function(l){return arguments.length?(r=l,c=ao[!r<<1|!s],e):r},e.y=function(l){return arguments.length?(s=l,c=ao[!r<<1|!s],e):s},e.extent=function(l){var t,n,i,o,c;return arguments.length?(a=[[0,0],[0,0]],r&&(t=l[0],n=l[1],s&&(t=t[0],n=n[0]),a[0][0]=t,a[1][0]=n,r.invert&&(t=r(t),n=r(n)),t>n&&(c=t,t=n,n=c),u[0][0]=0|t,u[1][0]=0|n),s&&(i=l[0],o=l[1],r&&(i=i[1],o=o[1]),a[0][1]=i,a[1][1]=o,s.invert&&(i=s(i),o=s(o)),i>o&&(c=i,i=o,o=c),u[0][1]=0|i,u[1][1]=0|o),e):(l=a||u,r&&(t=l[0][0],n=l[1][0],a||(t=u[0][0],n=u[1][0],r.invert&&(t=r.invert(t),n=r.invert(n)),t>n&&(c=t,t=n,n=c))),s&&(i=l[0][1],o=l[1][1],a||(i=u[0][1],o=u[1][1],s.invert&&(i=s.invert(i),o=s.invert(o)),i>o&&(c=i,i=o,o=c))),r&&s?[[t,i],[n,o]]:r?[t,n]:s&&[i,o])},e.clear=function(){return a=null,u[0][0]=u[0][1]=u[1][0]=u[1][1]=0,e},e.empty=function(){return r&&u[0][0]===u[1][0]||s&&u[0][1]===u[1][1]},d3.rebind(e,o,"on")};var io={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},ao=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]];d3.behavior={},d3.behavior.drag=function(){function e(){this.on("mousedown.drag",l).on("touchstart.drag",l)}function l(){function e(){var e=r.parentNode;return u?d3.touches(e).filter(function(e){return e.identifier===u})[0]:d3.mouse(e)}function l(){if(!r.parentNode)return i();var l=e(),t=l[0]-d[0],n=l[1]-d[1];h|=t|n,d=l,R(),s({type:"drag",x:l[0]+o[0],y:l[1]+o[1],dx:t,dy:n})}function i(){s({type:"dragend"}),h&&(R(),d3.event.target===c&&f.on("click.drag",a,!0)),f.on(u?"touchmove.drag-"+u:"mousemove.drag",null).on(u?"touchend.drag-"+u:"mouseup.drag",null)}function a(){R(),f.on("click.drag",null)}var o,r=this,s=t.of(r,arguments),c=d3.event.target,u=d3.event.touches&&d3.event.changedTouches[0].identifier,d=e(),h=0,f=d3.select(window).on(u?"touchmove.drag-"+u:"mousemove.drag",l).on(u?"touchend.drag-"+u:"mouseup.drag",i,!0);n?(o=n.apply(r,arguments),o=[o.x-d[0],o.y-d[1]]):o=[0,0],u||R(),s({type:"dragstart"})}var t=N(e,"drag","dragstart","dragend"),n=null;return e.origin=function(l){return arguments.length?(n=l,e):n},d3.rebind(e,t,"on")},d3.behavior.zoom=function(){function e(){this.on("mousedown.zoom",o).on("mousewheel.zoom",r).on("mousemove.zoom",s).on("DOMMouseScroll.zoom",r).on("dblclick.zoom",c).on("touchstart.zoom",u).on("touchmove.zoom",d).on("touchend.zoom",u)}function l(e){return[(e[0]-b[0])/T,(e[1]-b[1])/T]}function t(e){return[e[0]*T+b[0],e[1]*T+b[1]]}function n(e){T=Math.max(C[0],Math.min(C[1],e))}function i(e,l){l=t(l),b[0]+=e[0]-l[0],b[1]+=e[1]-l[1]}function a(e){m&&m.domain(p.range().map(function(e){return(e-b[0])/T}).map(p.invert)),v&&v.domain(g.range().map(function(e){return(e-b[1])/T}).map(g.invert)),d3.event.preventDefault(),e({type:"zoom",scale:T,translate:b})}function o(){function e(){c=1,i(d3.mouse(o),d),a(r)}function t(){c&&R(),u.on("mousemove.zoom",null).on("mouseup.zoom",null),c&&d3.event.target===s&&u.on("click.zoom",n,!0)}function n(){R(),u.on("click.zoom",null)}var o=this,r=E.of(o,arguments),s=d3.event.target,c=0,u=d3.select(window).on("mousemove.zoom",e).on("mouseup.zoom",t),d=l(d3.mouse(o));window.focus(),R()}function r(){h||(h=l(d3.mouse(this))),n(Math.pow(2,.002*Ft())*T),i(d3.mouse(this),h),a(E.of(this,arguments))}function s(){h=null}function c(){var e=d3.mouse(this),t=l(e);n(d3.event.shiftKey?T/2:2*T),i(e,t),a(E.of(this,arguments))}function u(){var e=d3.touches(this),t=Date.now();if(f=T,h={},e.forEach(function(e){h[e.identifier]=l(e)}),R(),1===e.length){if(500>t-y){var o=e[0],r=l(e[0]);n(2*T),i(o,r),a(E.of(this,arguments))}y=t}}function d(){var e=d3.touches(this),l=e[0],t=h[l.identifier];if(o=e[1]){var o,r=h[o.identifier];l=[(l[0]+o[0])/2,(l[1]+o[1])/2],t=[(t[0]+r[0])/2,(t[1]+r[1])/2],n(d3.event.scale*f)}i(l,t),y=null,a(E.of(this,arguments))}var h,f,p,m,g,v,y,b=[0,0],T=1,C=ro,E=N(e,"zoom");return e.translate=function(l){return arguments.length?(b=l.map(Number),e):b},e.scale=function(l){return arguments.length?(T=+l,e):T},e.scaleExtent=function(l){return arguments.length?(C=null==l?ro:l.map(Number),e):C},e.x=function(l){return arguments.length?(m=l,p=l.copy(),e):m},e.y=function(l){return arguments.length?(v=l,g=l.copy(),e):v},d3.rebind(e,E,"on")};var oo,ro=[0,1/0];d3.layout={},d3.layout.bundle=function(){return function(e){for(var l=[],t=-1,n=e.length;++t<n;)l.push(Bt(e[t]));return l}},d3.layout.chord=function(){function e(){var e,c,d,h,f,p={},m=[],g=d3.range(a),v=[];for(t=[],n=[],e=0,h=-1;++h<a;){for(c=0,f=-1;++f<a;)c+=i[h][f];m.push(c),v.push(d3.range(a)),e+=c}for(o&&g.sort(function(e,l){return o(m[e],m[l])}),r&&v.forEach(function(e,l){e.sort(function(e,t){return r(i[l][e],i[l][t])})}),e=(2*Math.PI-u*a)/e,c=0,h=-1;++h<a;){for(d=c,f=-1;++f<a;){var y=g[h],b=v[y][f],T=i[y][b],C=c,E=c+=T*e;p[y+"-"+b]={index:y,subindex:b,startAngle:C,endAngle:E,value:T}}n[y]={index:y,startAngle:d,endAngle:c,value:(c-d)/e},c+=u}for(h=-1;++h<a;)for(f=h-1;++f<a;){var D=p[h+"-"+f],w=p[f+"-"+h];(D.value||w.value)&&t.push(D.value<w.value?{source:w,target:D}:{source:D,target:w})}s&&l()}function l(){t.sort(function(e,l){return s((e.source.value+e.target.value)/2,(l.source.value+l.target.value)/2)})}var t,n,i,a,o,r,s,c={},u=0;return c.matrix=function(e){return arguments.length?(a=(i=e)&&i.length,t=n=null,c):i},c.padding=function(e){return arguments.length?(u=e,t=n=null,c):u},c.sortGroups=function(e){return arguments.length?(o=e,t=n=null,c):o},c.sortSubgroups=function(e){return arguments.length?(r=e,t=null,c):r},c.sortChords=function(e){return arguments.length?(s=e,t&&l(),c):s},c.chords=function(){return t||e(),t},c.groups=function(){return n||e(),n},c},d3.layout.force=function(){function e(e){return function(l,t,n,i){if(l.point!==e){var a=l.cx-e.x,o=l.cy-e.y,r=1/Math.sqrt(a*a+o*o);if(v>(i-t)*r){var s=l.charge*r*r;return e.px-=a*s,e.py-=o*s,!0}if(l.point&&isFinite(r)){var s=l.pointCharge*r*r;e.px-=a*s,e.py-=o*s}}return!l.charge}}function l(e){e.px=d3.event.x,e.py=d3.event.y,c.resume()}var t,n,a,o,s,c={},u=d3.dispatch("start","tick","end"),d=[1,1],h=.9,f=Gt,p=Vt,m=-30,g=.1,v=.8,y=[],b=[];return c.tick=function(){if((n*=.99)<.005)return u.end({type:"end",alpha:n=0}),!0;var l,t,i,r,c,f,p,v,T,C=y.length,E=b.length;for(t=0;E>t;++t)i=b[t],r=i.source,c=i.target,v=c.x-r.x,T=c.y-r.y,(f=v*v+T*T)&&(f=n*o[t]*((f=Math.sqrt(f))-a[t])/f,v*=f,T*=f,c.x-=v*(p=r.weight/(c.weight+r.weight)),c.y-=T*p,r.x+=v*(p=1-p),r.y+=T*p);if((p=n*g)&&(v=d[0]/2,T=d[1]/2,t=-1,p))for(;++t<C;)i=y[t],i.x+=(v-i.x)*p,i.y+=(T-i.y)*p;if(m)for(Wt(l=d3.geom.quadtree(y),n,s),t=-1;++t<C;)(i=y[t]).fixed||l.visit(e(i));for(t=-1;++t<C;)i=y[t],i.fixed?(i.x=i.px,i.y=i.py):(i.x-=(i.px-(i.px=i.x))*h,i.y-=(i.py-(i.py=i.y))*h);u.tick({type:"tick",alpha:n})},c.nodes=function(e){return arguments.length?(y=e,c):y},c.links=function(e){return arguments.length?(b=e,c):b},c.size=function(e){return arguments.length?(d=e,c):d},c.linkDistance=function(e){return arguments.length?(f=r(e),c):f},c.distance=c.linkDistance,c.linkStrength=function(e){return arguments.length?(p=r(e),c):p},c.friction=function(e){return arguments.length?(h=e,c):h},c.charge=function(e){return arguments.length?(m="function"==typeof e?e:+e,c):m},c.gravity=function(e){return arguments.length?(g=e,c):g},c.theta=function(e){return arguments.length?(v=e,c):v},c.alpha=function(e){return arguments.length?(n?n=e>0?e:0:e>0&&(u.start({type:"start",alpha:n=e}),d3.timer(c.tick)),c):n},c.start=function(){function e(e,n){for(var i,a=l(t),o=-1,r=a.length;++o<r;)if(!isNaN(i=a[o][e]))return i;return Math.random()*n}function l(){if(!i){for(i=[],n=0;u>n;++n)i[n]=[];for(n=0;h>n;++n){var e=b[n];i[e.source.index].push(e.target),i[e.target.index].push(e.source)}}return i[t]}var t,n,i,r,u=y.length,h=b.length,g=d[0],v=d[1];for(t=0;u>t;++t)(r=y[t]).index=t,r.weight=0;for(a=[],o=[],t=0;h>t;++t)r=b[t],"number"==typeof r.source&&(r.source=y[r.source]),"number"==typeof r.target&&(r.target=y[r.target]),a[t]=f.call(this,r,t),o[t]=p.call(this,r,t),++r.source.weight,++r.target.weight;for(t=0;u>t;++t)r=y[t],isNaN(r.x)&&(r.x=e("x",g)),isNaN(r.y)&&(r.y=e("y",v)),isNaN(r.px)&&(r.px=r.x),isNaN(r.py)&&(r.py=r.y);if(s=[],"function"==typeof m)for(t=0;u>t;++t)s[t]=+m.call(this,y[t],t);else for(t=0;u>t;++t)s[t]=m;return c.resume()},c.resume=function(){return c.alpha(.1)},c.stop=function(){return c.alpha(0)},c.drag=function(){t||(t=d3.behavior.drag().origin(i).on("dragstart",Zt).on("drag",l).on("dragend",Ut)),this.on("mouseover.force",zt).on("mouseout.force",jt).call(t)},d3.rebind(c,u,"on")},d3.layout.partition=function(){function e(l,t,n,i){var a=l.children;if(l.x=t,l.y=l.depth*i,l.dx=n,l.dy=i,a&&(o=a.length)){var o,r,s,c=-1;for(n=l.value?n/l.value:0;++c<o;)e(r=a[c],t,s=r.value*n,i),t+=s}}function l(e){var t=e.children,n=0;if(t&&(i=t.length))for(var i,a=-1;++a<i;)n=Math.max(n,l(t[a]));return 1+n}function t(t,a){var o=n.call(this,t,a);return e(o[0],0,i[0],i[1]/l(o[0])),o}var n=d3.layout.hierarchy(),i=[1,1];return t.size=function(e){return arguments.length?(i=e,t):i},rn(t,n)},d3.layout.pie=function(){function e(a){var o=a.map(function(t,n){return+l.call(e,t,n)}),r=+("function"==typeof n?n.apply(this,arguments):n),s=(("function"==typeof i?i.apply(this,arguments):i)-n)/d3.sum(o),c=d3.range(a.length);null!=t&&c.sort(t===so?function(e,l){return o[l]-o[e]}:function(e,l){return t(a[e],a[l])});var u=[];return c.forEach(function(e){var l;u[e]={data:a[e],value:l=o[e],startAngle:r,endAngle:r+=l*s}}),u}var l=Number,t=so,n=0,i=2*Math.PI;return e.value=function(t){return arguments.length?(l=t,e):l},e.sort=function(l){return arguments.length?(t=l,e):t},e.startAngle=function(l){return arguments.length?(n=l,e):n},e.endAngle=function(l){return arguments.length?(i=l,e):i},e};var so={};d3.layout.stack=function(){function e(i,s){var c=i.map(function(t,n){return l.call(e,t,n)}),u=c.map(function(l){return l.map(function(l,t){return[o.call(e,l,t),r.call(e,l,t)]})}),d=t.call(e,u,s);c=d3.permute(c,d),u=d3.permute(u,d);var h,f,p,m=n.call(e,u,s),g=c.length,v=c[0].length;for(f=0;v>f;++f)for(a.call(e,c[0][f],p=m[f],u[0][f][1]),h=1;g>h;++h)a.call(e,c[h][f],p+=u[h-1][f][1],u[h][f][1]);return i}var l=i,t=Xt,n=Qt,a=Jt,o=qt,r=Yt;return e.values=function(t){return arguments.length?(l=t,e):l},e.order=function(l){return arguments.length?(t="function"==typeof l?l:co.get(l)||Xt,e):t},e.offset=function(l){return arguments.length?(n="function"==typeof l?l:uo.get(l)||Qt,e):n},e.x=function(l){return arguments.length?(o=l,e):o},e.y=function(l){return arguments.length?(r=l,e):r},e.out=function(l){return arguments.length?(a=l,e):a},e};var co=d3.map({"inside-out":function(e){var l,t,n=e.length,i=e.map(en),a=e.map(ln),o=d3.range(n).sort(function(e,l){return i[e]-i[l]}),r=0,s=0,c=[],u=[];for(l=0;n>l;++l)t=o[l],s>r?(r+=a[t],c.push(t)):(s+=a[t],u.push(t));return u.reverse().concat(c)},reverse:function(e){return d3.range(e.length).reverse()},"default":Xt}),uo=d3.map({silhouette:function(e){var l,t,n,i=e.length,a=e[0].length,o=[],r=0,s=[];for(t=0;a>t;++t){for(l=0,n=0;i>l;l++)n+=e[l][t][1];n>r&&(r=n),o.push(n)}for(t=0;a>t;++t)s[t]=(r-o[t])/2;return s},wiggle:function(e){var l,t,n,i,a,o,r,s,c,u=e.length,d=e[0],h=d.length,f=[];for(f[0]=s=c=0,t=1;h>t;++t){for(l=0,i=0;u>l;++l)i+=e[l][t][1];for(l=0,a=0,r=d[t][0]-d[t-1][0];u>l;++l){for(n=0,o=(e[l][t][1]-e[l][t-1][1])/(2*r);l>n;++n)o+=(e[n][t][1]-e[n][t-1][1])/r;a+=o*e[l][t][1]}f[t]=s-=i?a/i*r:0,c>s&&(c=s)}for(t=0;h>t;++t)f[t]-=c;return f},expand:function(e){var l,t,n,i=e.length,a=e[0].length,o=1/i,r=[];for(t=0;a>t;++t){for(l=0,n=0;i>l;l++)n+=e[l][t][1];if(n)for(l=0;i>l;l++)e[l][t][1]/=n;else for(l=0;i>l;l++)e[l][t][1]=o}for(t=0;a>t;++t)r[t]=0;return r},zero:Qt});d3.layout.histogram=function(){function e(e,a){for(var o,r,s=[],c=e.map(t,this),u=n.call(this,c,a),d=i.call(this,u,c,a),a=-1,h=c.length,f=d.length-1,p=l?1:1/h;++a<f;)o=s[a]=[],o.dx=d[a+1]-(o.x=d[a]),o.y=0;if(f>0)for(a=-1;++a<h;)r=c[a],r>=u[0]&&r<=u[1]&&(o=s[d3.bisect(d,r,1,f)-1],o.y+=p,o.push(e[a]));return s}var l=!0,t=Number,n=on,i=nn;return e.value=function(l){return arguments.length?(t=l,e):t},e.range=function(l){return arguments.length?(n=r(l),e):n},e.bins=function(l){return arguments.length?(i="number"==typeof l?function(e){return an(e,l)}:r(l),e):i},e.frequency=function(t){return arguments.length?(l=!!t,e):l},e},d3.layout.hierarchy=function(){function e(l,o,r){var s=i.call(t,l,o),c=ho?l:{data:l};if(c.depth=o,r.push(c),s&&(u=s.length)){for(var u,d,h=-1,f=c.children=[],p=0,m=o+1;++h<u;)d=e(s[h],m,r),d.parent=c,f.push(d),p+=d.value;n&&f.sort(n),a&&(c.value=p)}else a&&(c.value=+a.call(t,l,o)||0);return c}function l(e,n){var i=e.children,o=0;if(i&&(r=i.length))for(var r,s=-1,c=n+1;++s<r;)o+=l(i[s],c);else a&&(o=+a.call(t,ho?e:e.data,n)||0);return a&&(e.value=o),o}function t(l){var t=[];return e(l,0,t),t}var n=un,i=sn,a=cn;return t.sort=function(e){return arguments.length?(n=e,t):n},t.children=function(e){return arguments.length?(i=e,t):i},t.value=function(e){return arguments.length?(a=e,t):a},t.revalue=function(e){return l(e,0),e},t};var ho=!1;d3.layout.pack=function(){function e(e,i){var a=l.call(this,e,i),o=a[0];o.x=0,o.y=0,Mn(o,function(e){e.r=Math.sqrt(e.value)}),Mn(o,gn);var r=n[0],s=n[1],c=Math.max(2*o.r/r,2*o.r/s);if(t>0){var u=t*c/2;Mn(o,function(e){e.r+=u}),Mn(o,gn),Mn(o,function(e){e.r-=u}),c=Math.max(2*o.r/r,2*o.r/s)}return bn(o,r/2,s/2,1/c),a}var l=d3.layout.hierarchy().sort(hn),t=0,n=[1,1];return e.size=function(l){return arguments.length?(n=l,e):n},e.padding=function(l){return arguments.length?(t=+l,e):t},rn(e,l)},d3.layout.cluster=function(){function e(e,i){var a,o=l.call(this,e,i),r=o[0],s=0;Mn(r,function(e){var l=e.children;l&&l.length?(e.x=En(l),e.y=Cn(l)):(e.x=a?s+=t(e,a):0,e.y=0,a=e)});var c=Dn(r),u=wn(r),d=c.x-t(c,u)/2,h=u.x+t(u,c)/2;return Mn(r,function(e){e.x=(e.x-d)/(h-d)*n[0],e.y=(1-(r.y?e.y/r.y:1))*n[1]}),o}var l=d3.layout.hierarchy().sort(null).value(null),t=_n,n=[1,1];return e.separation=function(l){return arguments.length?(t=l,e):t},e.size=function(l){return arguments.length?(n=l,e):n},rn(e,l)},d3.layout.tree=function(){function e(e,i){function a(e,l){var n=e.children,i=e._tree;if(n&&(o=n.length)){for(var o,s,c,u=n[0],d=u,h=-1;++h<o;)c=n[h],a(c,s),d=r(c,s,d),s=c;Nn(e);var f=.5*(u._tree.prelim+c._tree.prelim);l?(i.prelim=l._tree.prelim+t(e,l),i.mod=i.prelim-f):i.prelim=f}else l&&(i.prelim=l._tree.prelim+t(e,l))}function o(e,l){e.x=e._tree.prelim+l;var t=e.children;if(t&&(n=t.length)){var n,i=-1;for(l+=e._tree.mod;++i<n;)o(t[i],l)}}function r(e,l,n){if(l){for(var i,a=e,o=e,r=l,s=e.parent.children[0],c=a._tree.mod,u=o._tree.mod,d=r._tree.mod,h=s._tree.mod;r=Sn(r),a=In(a),r&&a;)s=In(s),o=Sn(o),o._tree.ancestor=e,i=r._tree.prelim+d-a._tree.prelim-c+t(r,a),i>0&&(An(Kn(r,e,n),e,i),c+=i,u+=i),d+=r._tree.mod,c+=a._tree.mod,h+=s._tree.mod,u+=o._tree.mod;r&&!Sn(o)&&(o._tree.thread=r,o._tree.mod+=d-u),a&&!In(s)&&(s._tree.thread=a,s._tree.mod+=c-h,n=e)}return n}var s=l.call(this,e,i),c=s[0];Mn(c,function(e,l){e._tree={ancestor:e,prelim:0,mod:0,change:0,shift:0,number:l?l._tree.number+1:0}}),a(c),o(c,-c._tree.prelim);var u=kn(c,On),d=kn(c,xn),h=kn(c,Rn),f=u.x-t(u,d)/2,p=d.x+t(d,u)/2,m=h.depth||1;return Mn(c,function(e){e.x=(e.x-f)/(p-f)*n[0],e.y=e.depth/m*n[1],delete e._tree}),s}var l=d3.layout.hierarchy().sort(null).value(null),t=_n,n=[1,1];return e.separation=function(l){return arguments.length?(t=l,e):t},e.size=function(l){return arguments.length?(n=l,e):n},rn(e,l)},d3.layout.treemap=function(){function e(e,l){for(var t,n,i=-1,a=e.length;++i<a;)n=(t=e[i]).value*(0>l?0:l),t.area=isNaN(n)||0>=n?0:n}function l(t){var a=t.children;if(a&&a.length){var o,r,s,c=d(t),u=[],h=a.slice(),f=1/0,p=Math.min(c.dx,c.dy);for(e(h,c.dx*c.dy/t.value),u.area=0;(s=h.length)>0;)u.push(o=h[s-1]),u.area+=o.area,(r=n(u,p))<=f?(h.pop(),f=r):(u.area-=u.pop().area,i(u,p,c,!1),p=Math.min(c.dx,c.dy),u.length=u.area=0,f=1/0);u.length&&(i(u,p,c,!0),u.length=u.area=0),a.forEach(l)}}function t(l){var n=l.children;if(n&&n.length){var a,o=d(l),r=n.slice(),s=[];for(e(r,o.dx*o.dy/l.value),s.area=0;a=r.pop();)s.push(a),s.area+=a.area,null!=a.z&&(i(s,a.z?o.dx:o.dy,o,!r.length),s.length=s.area=0);n.forEach(t)}}function n(e,l){for(var t,n=e.area,i=0,a=1/0,o=-1,r=e.length;++o<r;)(t=e[o].area)&&(a>t&&(a=t),t>i&&(i=t));return n*=n,l*=l,n?Math.max(l*i*f/n,n/(l*a*f)):1/0}function i(e,l,t,n){var i,a=-1,o=e.length,r=t.x,c=t.y,u=l?s(e.area/l):0;if(l==t.dx){for((n||u>t.dy)&&(u=t.dy);++a<o;)i=e[a],i.x=r,i.y=c,i.dy=u,r+=i.dx=Math.min(t.x+t.dx-r,u?s(i.area/u):0);i.z=!0,i.dx+=t.x+t.dx-r,t.y+=u,t.dy-=u}else{for((n||u>t.dx)&&(u=t.dx);++a<o;)i=e[a],i.x=r,i.y=c,i.dx=u,c+=i.dy=Math.min(t.y+t.dy-c,u?s(i.area/u):0);i.z=!1,i.dy+=t.y+t.dy-c,t.x+=u,t.dx-=u}}function a(n){var i=o||r(n),a=i[0];return a.x=0,a.y=0,a.dx=c[0],a.dy=c[1],o&&r.revalue(a),e([a],a.dx*a.dy/a.value),(o?t:l)(a),h&&(o=i),i}var o,r=d3.layout.hierarchy(),s=Math.round,c=[1,1],u=null,d=Ln,h=!1,f=.5*(1+Math.sqrt(5));return a.size=function(e){return arguments.length?(c=e,a):c},a.padding=function(e){function l(l){var t=e.call(a,l,l.depth);return null==t?Ln(l):Pn(l,"number"==typeof t?[t,t,t,t]:t)}function t(l){return Pn(l,e)}if(!arguments.length)return u;var n;return d=null==(u=e)?Ln:"function"==(n=typeof e)?l:"number"===n?(e=[e,e,e,e],t):t,a},a.round=function(e){return arguments.length?(s=e?Math.round:Number,a):s!=Number},a.sticky=function(e){return arguments.length?(h=e,o=null,a):h},a.ratio=function(e){return arguments.length?(f=e,a):f},rn(a,r)},d3.csv=Fn(",","text/csv"),d3.tsv=Fn(" ","text/tab-separated-values"),d3.geo={};var fo=Math.PI/180;d3.geo.azimuthal=function(){function e(e){var l,n=e[0]*fo-t,c=e[1]*fo,u=Math.cos(n),d=Math.sin(n),h=Math.cos(c),f=Math.sin(c),p="orthographic"!==o?a*f+i*h*u:null,m="stereographic"===o?1/(1+p):"gnomonic"===o?1/p:"equidistant"===o?(l=Math.acos(p),l?l/Math.sin(l):0):"equalarea"===o?Math.sqrt(2/(1+p)):1,g=m*h*d,v=m*(a*h*u-i*f);return[r*g+s[0],r*v+s[1]]}var l,t,n,i,a,o="orthographic",r=200,s=[480,250];return e.invert=function(e){var l=(e[0]-s[0])/r,n=(e[1]-s[1])/r,c=Math.sqrt(l*l+n*n),u="stereographic"===o?2*Math.atan(c):"gnomonic"===o?Math.atan(c):"equidistant"===o?c:"equalarea"===o?2*Math.asin(.5*c):Math.asin(c),d=Math.sin(u),h=Math.cos(u);return[(t+Math.atan2(l*d,c*i*h+n*a*d))/fo,Math.asin(h*a-(c?n*d*i/c:0))/fo]},e.mode=function(l){return arguments.length?(o=l+"",e):o},e.origin=function(o){return arguments.length?(l=o,t=l[0]*fo,n=l[1]*fo,i=Math.cos(n),a=Math.sin(n),e):l},e.scale=function(l){return arguments.length?(r=+l,e):r},e.translate=function(l){return arguments.length?(s=[+l[0],+l[1]],e):s},e.origin([0,0])},d3.geo.albers=function(){function e(e){var l=n*(fo*e[0]-t),o=Math.sqrt(i-2*n*Math.sin(fo*e[1]))/n;return[s*o*Math.sin(l)+c[0],s*(o*Math.cos(l)-a)+c[1]]}function l(){var l=fo*r[0],s=fo*r[1],c=fo*o[1],u=Math.sin(l),d=Math.cos(l);
return t=fo*o[0],n=.5*(u+Math.sin(s)),i=d*d+2*n*u,a=Math.sqrt(i-2*n*Math.sin(c))/n,e}var t,n,i,a,o=[-98,38],r=[29.5,45.5],s=1e3,c=[480,250];return e.invert=function(e){var l=(e[0]-c[0])/s,o=(e[1]-c[1])/s,r=a+o,u=Math.atan2(l,r),d=Math.sqrt(l*l+r*r);return[(t+u/n)/fo,Math.asin((i-d*d*n*n)/(2*n))/fo]},e.origin=function(e){return arguments.length?(o=[+e[0],+e[1]],l()):o},e.parallels=function(e){return arguments.length?(r=[+e[0],+e[1]],l()):r},e.scale=function(l){return arguments.length?(s=+l,e):s},e.translate=function(l){return arguments.length?(c=[+l[0],+l[1]],e):c},l()},d3.geo.albersUsa=function(){function e(e){var a=e[0],o=e[1];return(o>50?t:-140>a?n:21>o?i:l)(e)}var l=d3.geo.albers(),t=d3.geo.albers().origin([-160,60]).parallels([55,65]),n=d3.geo.albers().origin([-160,20]).parallels([8,18]),i=d3.geo.albers().origin([-60,10]).parallels([8,18]);return e.scale=function(a){return arguments.length?(l.scale(a),t.scale(.6*a),n.scale(a),i.scale(1.5*a),e.translate(l.translate())):l.scale()},e.translate=function(a){if(!arguments.length)return l.translate();var o=l.scale()/1e3,r=a[0],s=a[1];return l.translate(a),t.translate([r-400*o,s+170*o]),n.translate([r-190*o,s+200*o]),i.translate([r+580*o,s+430*o]),e},e.scale(l.scale())},d3.geo.bonne=function(){function e(e){var r=e[0]*fo-l,s=e[1]*fo-t;if(n){var c=i+n-s,u=r*Math.cos(s)/c;r=c*Math.sin(u),s=c*Math.cos(u)-i}else r*=Math.cos(s),s*=-1;return[a*r+o[0],a*s+o[1]]}var l,t,n,i,a=200,o=[480,250];return e.invert=function(e){var t=(e[0]-o[0])/a,r=(e[1]-o[1])/a;if(n){var s=i+r,c=Math.sqrt(t*t+s*s);r=i+n-c,t=l+c*Math.atan2(t,s)/Math.cos(r)}else r*=-1,t/=Math.cos(r);return[t/fo,r/fo]},e.parallel=function(l){return arguments.length?(i=1/Math.tan(n=l*fo),e):n/fo},e.origin=function(n){return arguments.length?(l=n[0]*fo,t=n[1]*fo,e):[l/fo,t/fo]},e.scale=function(l){return arguments.length?(a=+l,e):a},e.translate=function(l){return arguments.length?(o=[+l[0],+l[1]],e):o},e.origin([0,0]).parallel(45)},d3.geo.equirectangular=function(){function e(e){var n=e[0]/360,i=-e[1]/360;return[l*n+t[0],l*i+t[1]]}var l=500,t=[480,250];return e.invert=function(e){var n=(e[0]-t[0])/l,i=(e[1]-t[1])/l;return[360*n,-360*i]},e.scale=function(t){return arguments.length?(l=+t,e):l},e.translate=function(l){return arguments.length?(t=[+l[0],+l[1]],e):t},e},d3.geo.mercator=function(){function e(e){var n=e[0]/360,i=-(Math.log(Math.tan(Math.PI/4+e[1]*fo/2))/fo)/360;return[l*n+t[0],l*Math.max(-.5,Math.min(.5,i))+t[1]]}var l=500,t=[480,250];return e.invert=function(e){var n=(e[0]-t[0])/l,i=(e[1]-t[1])/l;return[360*n,2*Math.atan(Math.exp(-360*i*fo))/fo-90]},e.scale=function(t){return arguments.length?(l=+t,e):l},e.translate=function(l){return arguments.length?(t=[+l[0],+l[1]],e):t},e},d3.geo.path=function(){function e(e){"function"==typeof a&&(o=$n(a.apply(this,arguments))),c(e);var l=s.length?s.join(""):null;return s=[],l}function l(e){return r(e).join(",")}function t(e){for(var l=i(e[0]),t=0,n=e.length;++t<n;)l-=i(e[t]);return l}function n(e){for(var l=d3.geom.polygon(e[0].map(r)),t=l.area(),n=l.centroid(0>t?(t*=-1,1):-1),i=n[0],a=n[1],o=t,s=0,c=e.length;++s<c;)l=d3.geom.polygon(e[s].map(r)),t=l.area(),n=l.centroid(0>t?(t*=-1,1):-1),i-=n[0],a-=n[1],o-=t;return[i,a,6*o]}function i(e){return Math.abs(d3.geom.polygon(e.map(r)).area())}var a=4.5,o=$n(a),r=d3.geo.albersUsa(),s=[],c=Bn({FeatureCollection:function(e){for(var l=e.features,t=-1,n=l.length;++t<n;)s.push(c(l[t].geometry))},Feature:function(e){c(e.geometry)},Point:function(e){s.push("M",l(e.coordinates),o)},MultiPoint:function(e){for(var t=e.coordinates,n=-1,i=t.length;++n<i;)s.push("M",l(t[n]),o)},LineString:function(e){var t=e.coordinates,n=-1,i=t.length;for(s.push("M");++n<i;)s.push(l(t[n]),"L");s.pop()},MultiLineString:function(e){for(var t,n,i,a=e.coordinates,o=-1,r=a.length;++o<r;){for(t=a[o],n=-1,i=t.length,s.push("M");++n<i;)s.push(l(t[n]),"L");s.pop()}},Polygon:function(e){for(var t,n,i,a=e.coordinates,o=-1,r=a.length;++o<r;)if(t=a[o],n=-1,(i=t.length-1)>0){for(s.push("M");++n<i;)s.push(l(t[n]),"L");s[s.length-1]="Z"}},MultiPolygon:function(e){for(var t,n,i,a,o,r,c=e.coordinates,u=-1,d=c.length;++u<d;)for(t=c[u],n=-1,i=t.length;++n<i;)if(a=t[n],o=-1,(r=a.length-1)>0){for(s.push("M");++o<r;)s.push(l(a[o]),"L");s[s.length-1]="Z"}},GeometryCollection:function(e){for(var l=e.geometries,t=-1,n=l.length;++t<n;)s.push(c(l[t]))}}),u=e.area=Bn({FeatureCollection:function(e){for(var l=0,t=e.features,n=-1,i=t.length;++n<i;)l+=u(t[n]);return l},Feature:function(e){return u(e.geometry)},Polygon:function(e){return t(e.coordinates)},MultiPolygon:function(e){for(var l=0,n=e.coordinates,i=-1,a=n.length;++i<a;)l+=t(n[i]);return l},GeometryCollection:function(e){for(var l=0,t=e.geometries,n=-1,i=t.length;++n<i;)l+=u(t[n]);return l}},0),d=e.centroid=Bn({Feature:function(e){return d(e.geometry)},Polygon:function(e){var l=n(e.coordinates);return[l[0]/l[2],l[1]/l[2]]},MultiPolygon:function(e){for(var l,t=e.coordinates,i=0,a=0,o=0,r=-1,s=t.length;++r<s;)l=n(t[r]),i+=l[0],a+=l[1],o+=l[2];return[i/o,a/o]}});return e.projection=function(l){return r=l,e},e.pointRadius=function(l){return"function"==typeof l?a=l:(a=+l,o=$n(a)),e},e},d3.geo.bounds=function(e){var l=1/0,t=1/0,n=-1/0,i=-1/0;return Hn(e,function(e,a){l>e&&(l=e),e>n&&(n=e),t>a&&(t=a),a>i&&(i=a)}),[[l,t],[n,i]]};var po={Feature:Zn,FeatureCollection:Un,GeometryCollection:zn,LineString:jn,MultiLineString:Wn,MultiPoint:jn,MultiPolygon:Gn,Point:Vn,Polygon:qn};d3.geo.circle=function(){function e(){}function l(e){return s.distance(e)<r}function t(e){for(var l,t,i,a,o,c=-1,u=e.length,d=[];++c<u;)o=s.distance(i=e[c]),r>o?(t&&d.push(Qn(t,i)((a-r)/(a-o))),d.push(i),l=t=null):(t=i,!l&&d.length&&(d.push(Qn(d[d.length-1],t)((r-a)/(o-a))),l=t)),a=o;return l=e[0],t=d[0],!t||i[0]!==l[0]||i[1]!==l[1]||i[0]===t[0]&&i[1]===t[1]||d.push(t),n(d)}function n(e){for(var l,t,n,i=0,a=e.length,o=a?[e[0]]:e,r=s.source();++i<a;)for(n=s.source(e[i-1])(e[i]).coordinates,l=0,t=n.length;++l<t;)o.push(n[l]);return s.source(r),o}var a=[0,0],o=89.99,r=o*fo,s=d3.geo.greatArc().source(a).target(i);e.clip=function(e){return"function"==typeof a&&s.source(a.apply(this,arguments)),c(e)||null};var c=Bn({FeatureCollection:function(e){var l=e.features.map(c).filter(i);return l&&(e=Object.create(e),e.features=l,e)},Feature:function(e){var l=c(e.geometry);return l&&(e=Object.create(e),e.geometry=l,e)},Point:function(e){return l(e.coordinates)&&e},MultiPoint:function(e){var t=e.coordinates.filter(l);return t.length&&{type:e.type,coordinates:t}},LineString:function(e){var l=t(e.coordinates);return l.length&&(e=Object.create(e),e.coordinates=l,e)},MultiLineString:function(e){var l=e.coordinates.map(t).filter(function(e){return e.length});return l.length&&(e=Object.create(e),e.coordinates=l,e)},Polygon:function(e){var l=e.coordinates.map(t);return l[0].length&&(e=Object.create(e),e.coordinates=l,e)},MultiPolygon:function(e){var l=e.coordinates.map(function(e){return e.map(t)}).filter(function(e){return e[0].length});return l.length&&(e=Object.create(e),e.coordinates=l,e)},GeometryCollection:function(e){var l=e.geometries.map(c).filter(i);return l.length&&(e=Object.create(e),e.geometries=l,e)}});return e.origin=function(l){return arguments.length?(a=l,"function"!=typeof a&&s.source(a),e):a},e.angle=function(l){return arguments.length?(r=(o=+l)*fo,e):o},d3.rebind(e,s,"precision")},d3.geo.greatArc=function(){function e(){for(var n=e.distance.apply(this,arguments),i=0,r=a/n,s=[l];(i+=r)<1;)s.push(o(i));return s.push(t),{type:"LineString",coordinates:s}}var l,t,n=Yn,i=Jn,a=6*fo,o=Xn();return e.distance=function(){return"function"==typeof n&&o.source(l=n.apply(this,arguments)),"function"==typeof i&&o.target(t=i.apply(this,arguments)),o.distance()},e.source=function(t){return arguments.length?(n=t,"function"!=typeof n&&o.source(l=n),e):n},e.target=function(l){return arguments.length?(i=l,"function"!=typeof i&&o.target(t=i),e):i},e.precision=function(l){return arguments.length?(a=l*fo,e):a/fo},e},d3.geo.greatCircle=d3.geo.circle,d3.geom={},d3.geom.contour=function(e,l){var t=l||ei(e),n=[],i=t[0],a=t[1],o=0,r=0,s=0/0,c=0/0,u=0;do u=0,e(i-1,a-1)&&(u+=1),e(i,a-1)&&(u+=2),e(i-1,a)&&(u+=4),e(i,a)&&(u+=8),6===u?(o=-1===c?-1:1,r=0):9===u?(o=0,r=1===s?-1:1):(o=mo[u],r=go[u]),o!=s&&r!=c&&(n.push([i,a]),s=o,c=r),i+=o,a+=r;while(t[0]!=i||t[1]!=a);return n};var mo=[1,0,1,1,-1,0,-1,1,0,0,0,0,-1,0,-1,0/0],go=[0,-1,0,0,0,-1,0,0,1,-1,1,1,0,-1,0,0/0];d3.geom.hull=function(e){if(e.length<3)return[];var l,t,n,i,a,o,r,s,c,u,d=e.length,h=d-1,f=[],p=[],m=0;for(l=1;d>l;++l)e[l][1]<e[m][1]?m=l:e[l][1]==e[m][1]&&(m=e[l][0]<e[m][0]?l:m);for(l=0;d>l;++l)l!==m&&(i=e[l][1]-e[m][1],n=e[l][0]-e[m][0],f.push({angle:Math.atan2(i,n),index:l}));for(f.sort(function(e,l){return e.angle-l.angle}),c=f[0].angle,s=f[0].index,r=0,l=1;h>l;++l)t=f[l].index,c==f[l].angle?(n=e[s][0]-e[m][0],i=e[s][1]-e[m][1],a=e[t][0]-e[m][0],o=e[t][1]-e[m][1],n*n+i*i>=a*a+o*o?f[l].index=-1:(f[r].index=-1,c=f[l].angle,r=l,s=t)):(c=f[l].angle,r=l,s=t);for(p.push(m),l=0,t=0;2>l;++t)-1!==f[t].index&&(p.push(f[t].index),l++);for(u=p.length;h>t;++t)if(-1!==f[t].index){for(;!li(p[u-2],p[u-1],f[t].index,e);)--u;p[u++]=f[t].index}var g=[];for(l=0;u>l;++l)g.push(e[p[l]]);return g},d3.geom.polygon=function(e){return e.area=function(){for(var l=0,t=e.length,n=e[t-1][0]*e[0][1],i=e[t-1][1]*e[0][0];++l<t;)n+=e[l-1][0]*e[l][1],i+=e[l-1][1]*e[l][0];return.5*(i-n)},e.centroid=function(l){var t,n,i=-1,a=e.length,o=0,r=0,s=e[a-1];for(arguments.length||(l=-1/(6*e.area()));++i<a;)t=s,s=e[i],n=t[0]*s[1]-s[0]*t[1],o+=(t[0]+s[0])*n,r+=(t[1]+s[1])*n;return[o*l,r*l]},e.clip=function(l){for(var t,n,i,a,o,r,s=-1,c=e.length,u=e[c-1];++s<c;){for(t=l.slice(),l.length=0,a=e[s],o=t[(i=t.length)-1],n=-1;++n<i;)r=t[n],ti(r,u,a)?(ti(o,u,a)||l.push(ni(o,r,u,a)),l.push(r)):ti(o,u,a)&&l.push(ni(o,r,u,a)),o=r;u=a}return l},e},d3.geom.voronoi=function(e){var l=e.map(function(){return[]});return ii(e,function(e){var t,n,i,a,o,r;1===e.a&&e.b>=0?(t=e.ep.r,n=e.ep.l):(t=e.ep.l,n=e.ep.r),1===e.a?(o=t?t.y:-1e6,i=e.c-e.b*o,r=n?n.y:1e6,a=e.c-e.b*r):(i=t?t.x:-1e6,o=e.c-e.a*i,a=n?n.x:1e6,r=e.c-e.a*a);var s=[i,o],c=[a,r];l[e.region.l.index].push(s,c),l[e.region.r.index].push(s,c)}),l.map(function(l,t){var n=e[t][0],i=e[t][1];return l.forEach(function(e){e.angle=Math.atan2(e[0]-n,e[1]-i)}),l.sort(function(e,l){return e.angle-l.angle}).filter(function(e,t){return!t||e.angle-l[t-1].angle>1e-10})})};var vo={l:"r",r:"l"};d3.geom.delaunay=function(e){var l=e.map(function(){return[]}),t=[];return ii(e,function(t){l[t.region.l.index].push(e[t.region.r.index])}),l.forEach(function(l,n){var i=e[n],a=i[0],o=i[1];l.forEach(function(e){e.angle=Math.atan2(e[0]-a,e[1]-o)}),l.sort(function(e,l){return e.angle-l.angle});for(var r=0,s=l.length-1;s>r;r++)t.push([i,l[r],l[r+1]])}),t},d3.geom.quadtree=function(e,l,t,n,i){function a(e,l,t,n,i,a){if(!isNaN(l.x)&&!isNaN(l.y))if(e.leaf){var r=e.point;r?Math.abs(r.x-l.x)+Math.abs(r.y-l.y)<.01?o(e,l,t,n,i,a):(e.point=null,o(e,r,t,n,i,a),o(e,l,t,n,i,a)):e.point=l}else o(e,l,t,n,i,a)}function o(e,l,t,n,i,o){var r=.5*(t+i),s=.5*(n+o),c=l.x>=r,u=l.y>=s,d=(u<<1)+c;e.leaf=!1,e=e.nodes[d]||(e.nodes[d]=ai()),c?t=r:i=r,u?n=s:o=s,a(e,l,t,n,i,o)}var r,s=-1,c=e.length;if(c&&isNaN(e[0].x)&&(e=e.map(ri)),arguments.length<5)if(3===arguments.length)i=n=t,t=l;else{for(l=t=1/0,n=i=-1/0;++s<c;)r=e[s],r.x<l&&(l=r.x),r.y<t&&(t=r.y),r.x>n&&(n=r.x),r.y>i&&(i=r.y);var u=n-l,d=i-t;u>d?i=t+u:n=l+d}var h=ai();return h.add=function(e){a(h,e,l,t,n,i)},h.visit=function(e){oi(e,h,l,t,n,i)},e.forEach(h.add),h},d3.time={};var yo=Date,bo=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];si.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){To.setUTCDate.apply(this._,arguments)},setDay:function(){To.setUTCDay.apply(this._,arguments)},setFullYear:function(){To.setUTCFullYear.apply(this._,arguments)},setHours:function(){To.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){To.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){To.setUTCMinutes.apply(this._,arguments)},setMonth:function(){To.setUTCMonth.apply(this._,arguments)},setSeconds:function(){To.setUTCSeconds.apply(this._,arguments)},setTime:function(){To.setTime.apply(this._,arguments)}};var To=Date.prototype,Co="%a %b %e %H:%M:%S %Y",Eo="%m/%d/%y",Do="%H:%M:%S",wo=bo,_o=wo.map(ci),Io=["January","February","March","April","May","June","July","August","September","October","November","December"],So=Io.map(ci);d3.time.format=function(e){function l(l){for(var n,i,a=[],o=-1,r=0;++o<t;)37==e.charCodeAt(o)&&(a.push(e.substring(r,o),(i=Fo[n=e.charAt(++o)])?i(l):n),r=o+1);return a.push(e.substring(r,o)),a.join("")}var t=e.length;return l.parse=function(l){var t={y:1900,m:0,d:1,H:0,M:0,S:0,L:0},n=ui(t,e,l,0);if(n!=l.length)return null;"p"in t&&(t.H=t.H%12+12*t.p);var i=new yo;return i.setFullYear(t.y,t.m,t.d),i.setHours(t.H,t.M,t.S,t.L),i},l.toString=function(){return e},l};var ko=d3.format("02d"),xo=d3.format("03d"),Oo=d3.format("04d"),Ro=d3.format("2d"),Mo=di(wo),No=di(_o),Ao=di(Io),Ko=hi(Io),Lo=di(So),Po=hi(So),Fo={a:function(e){return _o[e.getDay()]},A:function(e){return wo[e.getDay()]},b:function(e){return So[e.getMonth()]},B:function(e){return Io[e.getMonth()]},c:d3.time.format(Co),d:function(e){return ko(e.getDate())},e:function(e){return Ro(e.getDate())},H:function(e){return ko(e.getHours())},I:function(e){return ko(e.getHours()%12||12)},j:function(e){return xo(1+d3.time.dayOfYear(e))},L:function(e){return xo(e.getMilliseconds())},m:function(e){return ko(e.getMonth()+1)},M:function(e){return ko(e.getMinutes())},p:function(e){return e.getHours()>=12?"PM":"AM"},S:function(e){return ko(e.getSeconds())},U:function(e){return ko(d3.time.sundayOfYear(e))},w:function(e){return e.getDay()},W:function(e){return ko(d3.time.mondayOfYear(e))},x:d3.time.format(Eo),X:d3.time.format(Do),y:function(e){return ko(e.getFullYear()%100)},Y:function(e){return Oo(e.getFullYear()%1e4)},Z:Oi,"%":function(){return"%"}},Bo={a:fi,A:pi,b:mi,B:gi,c:vi,d:wi,e:wi,H:_i,I:_i,L:ki,m:Di,M:Ii,p:xi,S:Si,x:yi,X:bi,y:Ci,Y:Ti},$o=/^s*d+/,Ho=d3.map({am:0,pm:1});d3.time.format.utc=function(e){function l(e){try{yo=si;var l=new yo;return l._=e,t(l)}finally{yo=Date}}var t=d3.time.format(e);return l.parse=function(e){try{yo=si;var l=t.parse(e);return l&&l._}finally{yo=Date}},l.toString=t.toString,l};var Zo=d3.time.format.utc("%Y-%m-%dT%H:%M:%S.%LZ");d3.time.format.iso=Date.prototype.toISOString?Ri:Zo,Ri.parse=function(e){var l=new Date(e);return isNaN(l)?null:l},Ri.toString=Zo.toString,d3.time.second=Mi(function(e){return new yo(1e3*Math.floor(e/1e3))},function(e,l){e.setTime(e.getTime()+1e3*Math.floor(l))},function(e){return e.getSeconds()}),d3.time.seconds=d3.time.second.range,d3.time.seconds.utc=d3.time.second.utc.range,d3.time.minute=Mi(function(e){return new yo(6e4*Math.floor(e/6e4))},function(e,l){e.setTime(e.getTime()+6e4*Math.floor(l))},function(e){return e.getMinutes()}),d3.time.minutes=d3.time.minute.range,d3.time.minutes.utc=d3.time.minute.utc.range,d3.time.hour=Mi(function(e){var l=e.getTimezoneOffset()/60;return new yo(36e5*(Math.floor(e/36e5-l)+l))},function(e,l){e.setTime(e.getTime()+36e5*Math.floor(l))},function(e){return e.getHours()}),d3.time.hours=d3.time.hour.range,d3.time.hours.utc=d3.time.hour.utc.range,d3.time.day=Mi(function(e){var l=new yo(1970,0);return l.setFullYear(e.getFullYear(),e.getMonth(),e.getDate()),l},function(e,l){e.setDate(e.getDate()+l)},function(e){return e.getDate()-1}),d3.time.days=d3.time.day.range,d3.time.days.utc=d3.time.day.utc.range,d3.time.dayOfYear=function(e){var l=d3.time.year(e);return Math.floor((e-l-6e4*(e.getTimezoneOffset()-l.getTimezoneOffset()))/864e5)},bo.forEach(function(e,l){e=e.toLowerCase(),l=7-l;var t=d3.time[e]=Mi(function(e){return(e=d3.time.day(e)).setDate(e.getDate()-(e.getDay()+l)%7),e},function(e,l){e.setDate(e.getDate()+7*Math.floor(l))},function(e){var t=d3.time.year(e).getDay();return Math.floor((d3.time.dayOfYear(e)+(t+l)%7)/7)-(t!==l)});d3.time[e+"s"]=t.range,d3.time[e+"s"].utc=t.utc.range,d3.time[e+"OfYear"]=function(e){var t=d3.time.year(e).getDay();return Math.floor((d3.time.dayOfYear(e)+(t+l)%7)/7)}}),d3.time.week=d3.time.sunday,d3.time.weeks=d3.time.sunday.range,d3.time.weeks.utc=d3.time.sunday.utc.range,d3.time.weekOfYear=d3.time.sundayOfYear,d3.time.month=Mi(function(e){return e=d3.time.day(e),e.setDate(1),e},function(e,l){e.setMonth(e.getMonth()+l)},function(e){return e.getMonth()}),d3.time.months=d3.time.month.range,d3.time.months.utc=d3.time.month.utc.range,d3.time.year=Mi(function(e){return e=d3.time.day(e),e.setMonth(0,1),e},function(e,l){e.setFullYear(e.getFullYear()+l)},function(e){return e.getFullYear()}),d3.time.years=d3.time.year.range,d3.time.years.utc=d3.time.year.utc.range;var Uo=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],zo=[[d3.time.second,1],[d3.time.second,5],[d3.time.second,15],[d3.time.second,30],[d3.time.minute,1],[d3.time.minute,5],[d3.time.minute,15],[d3.time.minute,30],[d3.time.hour,1],[d3.time.hour,3],[d3.time.hour,6],[d3.time.hour,12],[d3.time.day,1],[d3.time.day,2],[d3.time.week,1],[d3.time.month,1],[d3.time.month,3],[d3.time.year,1]],jo=[[d3.time.format("%Y"),function(){return!0}],[d3.time.format("%B"),function(e){return e.getMonth()}],[d3.time.format("%b %d"),function(e){return 1!=e.getDate()}],[d3.time.format("%a %d"),function(e){return e.getDay()&&1!=e.getDate()}],[d3.time.format("%I %p"),function(e){return e.getHours()}],[d3.time.format("%I:%M"),function(e){return e.getMinutes()}],[d3.time.format(":%S"),function(e){return e.getSeconds()}],[d3.time.format(".%L"),function(e){return e.getMilliseconds()}]],Wo=d3.scale.linear(),Go=Pi(jo);zo.year=function(e,l){return Wo.domain(e.map(Bi)).ticks(l).map(Fi)},d3.time.scale=function(){return Ai(d3.scale.linear(),zo,Go)};var Vo=zo.map(function(e){return[e[0].utc,e[1]]}),qo=[[d3.time.format.utc("%Y"),function(){return!0}],[d3.time.format.utc("%B"),function(e){return e.getUTCMonth()}],[d3.time.format.utc("%b %d"),function(e){return 1!=e.getUTCDate()}],[d3.time.format.utc("%a %d"),function(e){return e.getUTCDay()&&1!=e.getUTCDate()}],[d3.time.format.utc("%I %p"),function(e){return e.getUTCHours()}],[d3.time.format.utc("%I:%M"),function(e){return e.getUTCMinutes()}],[d3.time.format.utc(":%S"),function(e){return e.getUTCSeconds()}],[d3.time.format.utc(".%L"),function(e){return e.getUTCMilliseconds()}]],Yo=Pi(qo);Vo.year=function(e,l){return Wo.domain(e.map(Hi)).ticks(l).map($i)},d3.time.scale.utc=function(){return Ai(d3.scale.linear(),Vo,Yo)}}();
?>