window.Modernizr=function(n,t,i){function l(n){c.cssText=n}function pt(n,t){return l(w.join(n+";")+(t||""))}function h(n,t){return typeof n===t}function v(n,t){return!!~(""+n).indexOf(t)}function ft(n,t){var u,r;for(u in n)if(r=n[u],!v(r,"-")&&c[r]!==i)return"pfx"==t?r:!0;return!1}function yt(n,t,r){var f,u;for(f in n)if(u=t[n[f]],u!==i)return r===!1?n[f]:h(u,"function")?u.bind(r||t):u;return!1}function f(n,t,i){var r=n.charAt(0).toUpperCase()+n.slice(1),u=(n+" "+ot.join(r+" ")+r).split(" ");return h(t,"string")||h(t,"undefined")?ft(u,t):(u=(n+" "+ht.join(r+" ")+r).split(" "),yt(u,t,i))}function at(){u.input=function(i){for(var r=0,u=i.length;u>r;r++)b[i[r]]=!!(i[r]in e);return b.list&&(b.list=!(!t.createElement("datalist")||!n.HTMLDataListElement)),b}("autocomplete autofocus list placeholder max min multiple pattern required step".split(" ")),u.inputtypes=function(n){for(var r,f,o,u=0,h=n.length;h>u;u++)e.setAttribute("type",f=n[u]),r="text"!==e.type,r&&(e.value=nt,e.style.cssText="position:absolute;visibility:hidden;",/^range$/.test(f)&&e.style.WebkitAppearance!==i?(s.appendChild(e),o=t.defaultView,r=o.getComputedStyle&&"textfield"!==o.getComputedStyle(e,null).WebkitAppearance&&0!==e.offsetHeight,s.removeChild(e)):/^(search|tel)$/.test(f)||(r=/^(url|email)$/.test(f)?e.checkValidity&&e.checkValidity()===!1:e.value!=nt)),ut[n[u]]=!!r;return ut}("search tel url email datetime date month week time datetime-local number range color".split(" "))}var k,rt,vt="2.8.3",u={},it=!0,s=t.documentElement,o="modernizr",lt=t.createElement(o),c=lt.style,e=t.createElement("input"),nt=":)",st={}.toString,w=" -webkit- -moz- -o- -ms- ".split(" "),ct="Webkit Moz O ms",ot=ct.split(" "),ht=ct.toLowerCase().split(" "),y={svg:"http://www.w3.org/2000/svg"},r={},ut={},b={},d=[],g=d.slice,a=function(n,i,r,u){var v,l,c,a,f=t.createElement("div"),h=t.body,e=h||t.createElement("body");if(parseInt(r,10))for(;r--;)c=t.createElement("div"),c.id=u?u[r]:o+(r+1),f.appendChild(c);return v=["&#173;",'<style id="s',o,'">',n,"</style>"].join(""),f.id=o,(h?f:e).innerHTML+=v,e.appendChild(f),h||(e.style.background="",e.style.overflow="hidden",a=s.style.overflow,s.style.overflow="hidden",s.appendChild(e)),l=i(f,n),h?f.parentNode.removeChild(f):(e.parentNode.removeChild(e),s.style.overflow=a),!!l},wt=function(t){var i=n.matchMedia||n.msMatchMedia,r;return i?i(t)&&i(t).matches||!1:(a("@media "+t+" { #"+o+" { position: absolute; } }",function(t){r="absolute"==(n.getComputedStyle?getComputedStyle(t,null):t.currentStyle).position}),r)},et=function(){function r(r,u){u=u||t.createElement(n[r]||"div"),r="on"+r;var f=r in u;return f||(u.setAttribute||(u=t.createElement("div")),u.setAttribute&&u.removeAttribute&&(u.setAttribute(r,""),f=h(u[r],"function"),h(u[r],"undefined")||(u[r]=i),u.removeAttribute(r))),u=null,f}var n={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return r}(),tt={}.hasOwnProperty,p;rt=h(tt,"undefined")||h(tt.call,"undefined")?function(n,t){return t in n&&h(n.constructor.prototype[t],"undefined")}:function(n,t){return tt.call(n,t)},Function.prototype.bind||(Function.prototype.bind=function(n){var t=this,r,i;if("function"!=typeof t)throw new TypeError;return r=g.call(arguments,1),i=function(){var f,e,u;return this instanceof i?(f=function(){},f.prototype=t.prototype,e=new f,u=t.apply(e,r.concat(g.call(arguments))),Object(u)===u?u:e):t.apply(n,r.concat(g.call(arguments)))},i}),r.flexbox=function(){return f("flexWrap")},r.flexboxlegacy=function(){return f("boxDirection")},r.canvas=function(){var n=t.createElement("canvas");return!(!n.getContext||!n.getContext("2d"))},r.canvastext=function(){return!(!u.canvas||!h(t.createElement("canvas").getContext("2d").fillText,"function"))},r.webgl=function(){return!!n.WebGLRenderingContext},r.touch=function(){var i;return"ontouchstart"in n||n.DocumentTouch&&t instanceof DocumentTouch?i=!0:a(["@media (",w.join("touch-enabled),("),o,")","{#modernizr{top:9px;position:absolute}}"].join(""),function(n){i=9===n.offsetTop}),i},r.geolocation=function(){return"geolocation"in navigator},r.postmessage=function(){return!!n.postMessage},r.websqldatabase=function(){return!!n.openDatabase},r.indexedDB=function(){return!!f("indexedDB",n)},r.hashchange=function(){return et("hashchange",n)&&(t.documentMode===i||t.documentMode>7)},r.history=function(){return!(!n.history||!history.pushState)},r.draganddrop=function(){var n=t.createElement("div");return"draggable"in n||"ondragstart"in n&&"ondrop"in n},r.websockets=function(){return"WebSocket"in n||"MozWebSocket"in n},r.rgba=function(){return l("background-color:rgba(150,255,150,.5)"),v(c.backgroundColor,"rgba")},r.hsla=function(){return l("background-color:hsla(120,40%,100%,.5)"),v(c.backgroundColor,"rgba")||v(c.backgroundColor,"hsla")},r.multiplebgs=function(){return l("background:url(https://),url(https://),red url(https://)"),/(url\s*\(.*?){3}/.test(c.background)},r.backgroundsize=function(){return f("backgroundSize")},r.borderimage=function(){return f("borderImage")},r.borderradius=function(){return f("borderRadius")},r.boxshadow=function(){return f("boxShadow")},r.textshadow=function(){return""===t.createElement("div").style.textShadow},r.opacity=function(){return pt("opacity:.55"),/^0.55$/.test(c.opacity)},r.cssanimations=function(){return f("animationName")},r.csscolumns=function(){return f("columnCount")},r.cssgradients=function(){var n="background-image:",i="gradient(linear,left top,right bottom,from(#9f9),to(white));",t="linear-gradient(left top,#9f9, white);";return l((n+"-webkit- ".split(" ").join(i+n)+w.join(t+n)).slice(0,-n.length)),v(c.backgroundImage,"gradient")},r.cssreflections=function(){return f("boxReflect")},r.csstransforms=function(){return!!f("transform")},r.csstransforms3d=function(){var n=!!f("perspective");return n&&"webkitPerspective"in s.style&&a("@media (transform-3d),(-webkit-transform-3d){#modernizr{left:9px;position:absolute;height:3px;}}",function(t){n=9===t.offsetLeft&&3===t.offsetHeight}),n},r.csstransitions=function(){return f("transition")},r.fontface=function(){var n;return a('@font-face {font-family:"font";src:url("https://")}',function(i,r){var e=t.getElementById("smodernizr"),u=e.sheet||e.styleSheet,f=u?u.cssRules&&u.cssRules[0]?u.cssRules[0].cssText:u.cssText||"":"";n=/src/i.test(f)&&0===f.indexOf(r.split(" ")[0])}),n},r.generatedcontent=function(){var n;return a(["#",o,"{font:0/0 a}#",o,':after{content:"',nt,'";visibility:hidden;font:3px/1 a}'].join(""),function(t){n=t.offsetHeight>=3}),n},r.video=function(){var i=t.createElement("video"),n=!1;try{(n=!!i.canPlayType)&&(n=new Boolean(n),n.ogg=i.canPlayType('video/ogg; codecs="theora"').replace(/^no$/,""),n.h264=i.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/^no$/,""),n.webm=i.canPlayType('video/webm; codecs="vp8, vorbis"').replace(/^no$/,""))}catch(r){}return n},r.audio=function(){var i=t.createElement("audio"),n=!1;try{(n=!!i.canPlayType)&&(n=new Boolean(n),n.ogg=i.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,""),n.mp3=i.canPlayType("audio/mpeg;").replace(/^no$/,""),n.wav=i.canPlayType('audio/wav; codecs="1"').replace(/^no$/,""),n.m4a=(i.canPlayType("audio/x-m4a;")||i.canPlayType("audio/aac;")).replace(/^no$/,""))}catch(r){}return n},r.localstorage=function(){try{return localStorage.setItem(o,o),localStorage.removeItem(o),!0}catch(n){return!1}},r.sessionstorage=function(){try{return sessionStorage.setItem(o,o),sessionStorage.removeItem(o),!0}catch(n){return!1}},r.webworkers=function(){return!!n.Worker},r.applicationcache=function(){return!!n.applicationCache},r.svg=function(){return!!t.createElementNS&&!!t.createElementNS(y.svg,"svg").createSVGRect},r.inlinesvg=function(){var n=t.createElement("div");return n.innerHTML="<svg/>",(n.firstChild&&n.firstChild.namespaceURI)==y.svg},r.smil=function(){return!!t.createElementNS&&/SVGAnimate/.test(st.call(t.createElementNS(y.svg,"animate")))},r.svgclippaths=function(){return!!t.createElementNS&&/SVGClipPath/.test(st.call(t.createElementNS(y.svg,"clipPath")))};for(p in r)rt(r,p)&&(k=p.toLowerCase(),u[k]=r[p](),d.push((u[k]?"":"no-")+k));return u.input||at(),u.addTest=function(n,t){if("object"==typeof n)for(var r in n)rt(n,r)&&u.addTest(r,n[r]);else{if(n=n.toLowerCase(),u[n]!==i)return u;t="function"==typeof t?t():t,"undefined"!=typeof it&&it&&(s.className+=" "+(t?"":"no-")+n),u[n]=t}return u},l(""),lt=e=null,function(n,t){function w(n,t){var r=n.createElement("p"),i=n.getElementsByTagName("head")[0]||n.documentElement;return r.innerHTML="x<style>"+t+"</style>",i.insertBefore(r.lastChild,i.firstChild)}function a(){var n=i.elements;return"string"==typeof n?n.split(" "):n}function o(n){var t=h[n[s]];return t||(t={},e++,n[s]=e,h[e]=t),t}function c(n,i,u){if(i||(i=t),r)return i.createElement(n);u||(u=o(i));var f;return f=u.cache[n]?u.cache[n].cloneNode():y.test(n)?(u.cache[n]=u.createElem(n)).cloneNode():u.createElem(n),!f.canHaveChildren||b.test(n)||f.tagUrn?f:u.frag.appendChild(f)}function p(n,i){if(n||(n=t),r)return n.createDocumentFragment();i=i||o(n);for(var e=i.frag.cloneNode(),u=0,f=a(),s=f.length;s>u;u++)e.createElement(f[u]);return e}function k(n,t){t.cache||(t.cache={},t.createElem=n.createElement,t.createFrag=n.createDocumentFragment,t.frag=t.createFrag()),n.createElement=function(r){return i.shivMethods?c(r,n,t):t.createElem(r)},n.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+a().join().replace(/[\w\-]+/g,function(n){return t.createElem(n),t.frag.createElement(n),'c("'+n+'")'})+");return n}")(i,t.frag)}function l(n){n||(n=t);var f=o(n);return!i.shivCSS||u||f.hasCSS||(f.hasCSS=!!w(n,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),r||k(n,f),n}var u,r,v="3.7.0",f=n.html5||{},b=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,y=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,s="_html5shiv",e=0,h={},i;!function(){try{var n=t.createElement("a");n.innerHTML="<xyz></xyz>",u="hidden"in n,r=1==n.childNodes.length||function(){t.createElement("a");var n=t.createDocumentFragment();return"undefined"==typeof n.cloneNode||"undefined"==typeof n.createDocumentFragment||"undefined"==typeof n.createElement}()}catch(i){u=!0,r=!0}}(),i={elements:f.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video",version:v,shivCSS:f.shivCSS!==!1,supportsUnknownElements:r,shivMethods:f.shivMethods!==!1,type:"default",shivDocument:l,createElement:c,createDocumentFragment:p},n.html5=i,l(t)}(this,t),u._version=vt,u._prefixes=w,u._domPrefixes=ht,u._cssomPrefixes=ot,u.mq=wt,u.hasEvent=et,u.testProp=function(n){return ft([n])},u.testAllProps=f,u.testStyles=a,u.prefixed=function(n,t,i){return t?f(n,t,i):f(n,"pfx")},s.className=s.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(it?" js "+d.join(" "):""),u}(this,this.document),!function(){function ar(n,t){return n<t?-1:n>t?1:n>=t?0:NaN}function we(n){return n!=null&&!isNaN(n)}function ub(n){return{left:function(t,i,r,u){for(arguments.length<3&&(r=0),arguments.length<4&&(u=t.length);r<u;){var f=r+u>>>1;n(t[f],i)<0?r=f+1:u=f}return r},right:function(t,i,r,u){for(arguments.length<3&&(r=0),arguments.length<4&&(u=t.length);r<u;){var f=r+u>>>1;n(t[f],i)>0?u=f:r=f+1}return r}}}function ig(n){return n.length}function kd(n){for(var t=1;n*t%1;)t*=10;return t}function aw(n,t){try{for(var i in t)Object.defineProperty(n.prototype,i,{value:t[i],enumerable:!1})}catch(r){n.prototype=t}}function ht(){}function gw(n){return ni+n in this}function od(n){return n=ni+n,n in this&&delete this[n]}function cb(){var n=[];return this.forEach(function(t){n.push(t)}),n}function nk(){var t=0,n;for(n in this)n.charCodeAt(0)===gr&&++t;return t}function ik(){for(var n in this)if(n.charCodeAt(0)===gr)return!1;return!0}function fo(){}function cd(n,t,i){return function(){var r=i.apply(t,arguments);return r===t?n:r}}function eo(n,t){var i,u,r;if(t in n)return t;for(t=t.charAt(0).toUpperCase()+t.substring(1),i=0,u=io.length;i<u;++i)if(r=io[i]+t,r in n)return r}function c(){}function oo(){}function pb(n){function r(){for(var u=t,r=-1,f=u.length,i;++r<f;)(i=u[r].on)&&i.apply(this,arguments);return n}var t=[],i=new ht;return r.on=function(r,u){var f=i.get(r),e;return arguments.length<2?f&&f.on:(f&&(f.on=null,t=t.slice(0,e=t.indexOf(f)).concat(t.slice(e+1)),i.remove(r)),u&&t.push(i.set(r,{on:u})),n)},r}function fi(){n.event.preventDefault()}function po(){for(var t=n.event,i;i=t.sourceEvent;)t=i;return t}function lo(t){for(var i=new oo,r=0,u=arguments.length;++r<u;)i[arguments[r]]=pb(i);return i.of=function(r,u){return function(f){try{var e=f.sourceEvent=n.event;f.target=t,n.event=f,i[f.type].apply(r,u)}finally{n.event=e}}},i}function kt(n){return yu(n,e),n}function uc(n){return typeof n=="function"?n:function(){return hh(n,this)}}function gy(n){return typeof n=="function"?n:function(){return yh(n,this)}}function ky(t,i){function e(){this.removeAttribute(t)}function o(){this.removeAttributeNS(t.space,t.local)}function s(){this.setAttribute(t,i)}function r(){this.setAttributeNS(t.space,t.local,i)}function u(){var n=i.apply(this,arguments);n==null?this.removeAttribute(t):this.setAttribute(t,n)}function f(){var n=i.apply(this,arguments);n==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}return t=n.ns.qualify(t),i==null?t.local?o:e:typeof i=="function"?t.local?f:u:t.local?r:s}function dy(n){return n.trim().replace(/\s+/g," ")}function ip(t){return new RegExp("(?:^|\\s+)"+n.requote(t)+"(?:\\s+|$)","g")}function ep(n){return(n+"").trim().split(/^|\s+/)}function op(n,t){function u(){for(var r=-1;++r<i;)n[r](this,t)}function r(){for(var r=-1,u=t.apply(this,arguments);++r<i;)n[r](this,u)}n=ep(n).map(vd);var i=n.length;return typeof t=="function"?r:u}function vd(n){var t=ip(n);return function(i,r){if(u=i.classList)return r?u.add(n):u.remove(n);var u=i.getAttribute("class")||"";r?(t.lastIndex=0,t.test(u)||i.setAttribute("class",dy(u+" "+n))):i.setAttribute("class",dy(u.replace(t," ")))}}function fp(n,t,i){function f(){this.style.removeProperty(n)}function u(){this.style.setProperty(n,t,i)}function r(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(n):this.style.setProperty(n,r,i)}return t==null?f:typeof t=="function"?r:u}function rp(n,t){function u(){delete this[n]}function r(){this[n]=t}function i(){var i=t.apply(this,arguments);i==null?delete this[n]:this[n]=i}return t==null?u:typeof t=="function"?i:r}function up(t){return typeof t=="function"?t:(t=n.ns.qualify(t)).local?function(){return this.ownerDocument.createElementNS(t.space,t.local)}:function(){return this.ownerDocument.createElementNS(this.namespaceURI,t)}}function nc(n){return{__data__:n}}function hy(n){return function(){return tp(this,n)}}function id(n){return arguments.length||(n=ar),function(t,i){return t&&i?n(t.__data__,i.__data__):!t-!i}}function ui(n,t){for(var i=0,f=n.length;i<f;i++)for(var e=n[i],r=0,o=e.length,u;r<o;r++)(u=e[r])&&t(u,r,i);return n}function sy(n){return yu(n,lt),n}function sd(n){var t,i;return function(r,u,f){var o=n[f].update,s=o.length,e;for(f!=i&&(i=f,t=0),u>=t&&(t=u+1);!(e=o[t])&&++t<s;);return e}}function ue(){var n=this.__transition__;n&&++n.active}function oy(t,i,r){function o(){var n=this[e];n&&(this.removeEventListener(t,n,n.$),delete this[e])}function l(){var n=s(i,ti(arguments));o.call(this),this.addEventListener(t,this[e]=n,n.$=r),n._=i}function h(){var f=new RegExp("^__on([^.]+)"+n.requote(t)+"$"),u,i,r;for(i in this)(u=i.match(f))&&(r=this[i],this.removeEventListener(u[1],r,r.$),delete this[i])}var e="__on"+t,f=t.indexOf("."),s=ly,u;return f>0&&(t=t.substring(0,f)),u=ye.get(t),u&&(t=u,s=eg),f?i?l:o:i?c:h}function ly(t,i){return function(r){var u=n.event;n.event=r,i[0]=this.__data__;try{t.apply(this,i)}finally{n.event=u}}}function eg(n,t){var i=ly(n,t);return function(n){var r=this,t=n.relatedTarget;t&&(t===r||t.compareDocumentPosition(r)&8)||i.call(r,n)}}function ee(){var t=".dragsuppress-"+ ++wy,f="click"+t,r=n.select(w).on("touchmove"+t,fi).on("dragstart"+t,fi).on("selectstart"+t,fi),i,u;return lr&&(i=at.style,u=i[lr],i[lr]="none"),function(n){r.on(t,null);if(lr&&(i[lr]=u),n){function e(){r.on(f,null)}r.on(f,function(){fi(),e()},!0);setTimeout(e,0)}}}function lc(t,i){var u,r,e,f;return(i.changedTouches&&(i=i.changedTouches[0]),u=t.ownerSVGElement||t,u.createSVGPoint)?(r=u.createSVGPoint(),no<0&&(w.scrollX||w.scrollY)&&(u=n.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important"),e=u[0][0].getScreenCTM(),no=!(e.f||e.e),u.remove()),no?(r.x=i.pageX,r.y=i.pageY):(r.x=i.clientX,r.y=i.clientY),r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]):(f=t.getBoundingClientRect(),[i.clientX-f.left-t.clientLeft,i.clientY-f.top-t.clientTop])}function fg(){return n.event.changedTouches[0].identifier}function hg(){return n.event.target}function ug(){return w}function sp(n){return n>0?1:n<0?-1:0}function rl(n,t,i){return(t[0]-n[0])*(i[1]-n[1])-(t[1]-n[1])*(i[0]-n[0])}function rw(n){return n>1?0:n<-1?f:Math.acos(n)}function sr(n){return n>1?y:n<-1?-y:Math.asin(n)}function ng(n){return((n=Math.exp(n))-1/n)/2}function uw(n){return((n=Math.exp(n))+1/n)/2}function rg(n){return((n=Math.exp(2*n))-1)/(n+1)}function tw(n){return(n=Math.sin(n/2))*n}function ci(){}function et(n,t,i){return this instanceof et?void(this.h=+n,this.s=+t,this.l=+i):arguments.length<2?n instanceof et?new et(n.h,n.s,n.l):hp(""+n,cp,et):new et(n,t,i)}function oh(n,t,i){function e(n){return(n>360?n-=360:n<0&&(n+=360),n<60)?r+(u-r)*n/60:n<180?u:n<240?r+(u-r)*(240-n)/60:r}function f(n){return Math.round(e(n)*255)}var r,u;return n=isNaN(n)?0:(n%=360)<0?n+360:n,t=isNaN(t)?0:t<0?0:t>1?1:t,i=i<0?0:i>1?1:i,u=i<=.5?i*(1+t):i+t-i*t,r=2*i-u,new k(f(n+120),f(n),f(n-120))}function ft(t,i,r){return this instanceof ft?void(this.h=+t,this.c=+i,this.l=+r):arguments.length<2?t instanceof ft?new ft(t.h,t.c,t.l):t instanceof rt?ap(t.l,t.a,t.b):ap((t=yp((t=n.rgb(t)).r,t.g,t.b)).l,t.a,t.b):new ft(t,i,r)}function tc(n,t,i){return isNaN(n)&&(n=0),isNaN(t)&&(t=0),new rt(i,Math.cos(n*=u)*t,Math.sin(n)*t)}function rt(n,t,i){return this instanceof rt?void(this.l=+n,this.a=+t,this.b=+i):arguments.length<2?n instanceof rt?new rt(n.l,n.a,n.b):n instanceof ft?tc(n.l,n.c,n.h):yp((n=k(n)).r,n.g,n.b):new rt(n,t,i)}function gp(n,t,i){var r=(n+16)/116,f=r+t/500,u=r-i/200;return f=yc(f)*cw,r=yc(r)*sw,u=yc(u)*ew,new k(ol(3.2404542*f-1.5371385*r-.4985314*u),ol(-.969266*f+1.8760108*r+.041556*u),ol(.0556434*f-.2040259*r+1.0572252*u))}function ap(n,t,i){return n>0?new ft(Math.atan2(i,t)*s,Math.sqrt(t*t+i*i),n):new ft(NaN,NaN,n)}function yc(n){return n>.206893034?n*n*n:(n-4/29)/7.787037}function gc(n){return n>.008856?Math.pow(n,1/3):7.787037*n+4/29}function ol(n){return Math.round(255*(n<=.00304?12.92*n:1.055*Math.pow(n,1/2.4)-.055))}function k(n,t,i){return this instanceof k?void(this.r=~~n,this.g=~~t,this.b=~~i):arguments.length<2?n instanceof k?new k(n.r,n.g,n.b):hp(""+n,k,oh):new k(n,t,i)}function vp(n){return new k(n>>16,n>>8&255,n&255)}function pe(n){return vp(n)+""}function er(n){return n<16?"0"+Math.max(0,n).toString(16):Math.min(255,n).toString(16)}function hp(n,t,i){var e=0,f=0,o=0,s,u,r;if(s=/([a-z]+)\((.*)\)/i.exec(n),s){u=s[2].split(",");switch(s[1]){case"hsl":return i(parseFloat(u[0]),parseFloat(u[1])/100,parseFloat(u[2])/100);case"rgb":return t(tl(u[0]),tl(u[1]),tl(u[2]))}}return(r=uu.get(n))?t(r.r,r.g,r.b):(n==null||n.charAt(0)!=="#"||isNaN(r=parseInt(n.substring(1),16))||(n.length===4?(e=(r&3840)>>4,e=e>>4|e,f=r&240,f=f>>4|f,o=r&15,o=o<<4|o):n.length===7&&(e=(r&16711680)>>16,f=(r&65280)>>8,o=r&255)),t(e,f,o))}function cp(n,t,i){var o=Math.min(n/=255,t/=255,i/=255),f=Math.max(n,t,i),u=f-o,r,s,e=(f+o)/2;return u?(s=e<.5?u/(f+o):u/(2-f-o),r=n==f?(t-i)/u+(t<i?6:0):t==f?(i-n)/u+2:(n-t)/u+4,r*=60):(r=NaN,s=e>0&&e<1?0:r),new et(r,s,e)}function yp(n,t,i){n=nl(n),t=nl(t),i=nl(i);var f=gc((.4124564*n+.3575761*t+.1804375*i)/cw),r=gc((.2126729*n+.7151522*t+.072175*i)/sw),u=gc((.0193339*n+.119192*t+.9503041*i)/ew);return rt(116*r-16,500*(f-r),200*(r-u))}function nl(n){return(n/=255)<=.04045?n/12.92:Math.pow((n+.055)/1.055,2.4)}function tl(n){var t=parseFloat(n);return n.charAt(n.length-1)==="%"?Math.round(t*2.55):t}function o(n){return typeof n=="function"?n:function(){return n}}function a(n){return n}function uh(n){return function(t,i,r){return arguments.length===2&&typeof i=="function"&&(r=i,i=null),nf(t,i,n,r)}}function nf(t,i,r,u){function c(){var n=e.status,t;if(!n&&e.responseText||n>=200&&n<300||n===304){try{t=r.call(f,e)}catch(i){s.error.call(f,i);return}s.load.call(f,t)}else s.error.call(f,e)}var f={},s=n.dispatch("beforesend","progress","load","error"),o={},e=new XMLHttpRequest,h=null;return!w.XDomainRequest||"withCredentials"in e||!/^(http(s)?:)?\/\//.test(t)||(e=new XDomainRequest),"onload"in e?e.onload=e.onerror=c:e.onreadystatechange=function(){e.readyState>3&&c()},e.onprogress=function(t){var i=n.event;n.event=t;try{s.progress.call(f,e)}finally{n.event=i}},f.header=function(n,t){return(n=(n+"").toLowerCase(),arguments.length<2)?o[n]:(t==null?delete o[n]:o[n]=t+"",f)},f.mimeType=function(n){return arguments.length?(i=n==null?null:n+"",f):i},f.responseType=function(n){return arguments.length?(h=n,f):h},f.response=function(n){return r=n,f},["get","post"].forEach(function(n){f[n]=function(){return f.send.apply(f,[n].concat(ti(arguments)))}}),f.send=function(n,r,u){if(arguments.length===2&&typeof r=="function"&&(u=r,r=null),e.open(n,t,!0),i==null||"accept"in o||(o.accept=i+",*/*"),e.setRequestHeader)for(var c in o)e.setRequestHeader(c,o[c]);if(i!=null&&e.overrideMimeType&&e.overrideMimeType(i),h!=null&&(e.responseType=h),u!=null)f.on("error",u).on("load",function(n){u(null,n)});return s.beforesend.call(f,e),e.send(r==null?null:r),f},f.abort=function(){return e.abort(),f},n.rebind(f,s,"on"),u==null?f:f.get(hk(u))}function hk(n){return n.length===1?function(t,i){n(t==null?i:null)}:n}function bh(){var t=kp(),n=dp()-t;n>24?(isFinite(n)&&(clearTimeout(pu),pu=setTimeout(bh,n)),bu=0):(bu=1,fc(bh))}function kp(){var n=Date.now();for(yt=sf;yt;)n>=yt.t&&(yt.f=yt.c(n-yt.t)),yt=yt.n;return n}function dp(){for(var t,n=sf,i=Infinity;n;)n.f?n=t?t.n=n.n:sf=n.n:(n.t<i&&(i=n.t),n=(t=n).n);return ef=t,i}function ch(n,t){return t-(n?Math.ceil(Math.log(n)/Math.LN10):1)}function kk(n,t){var i=Math.pow(10,r(8-t)*3);return{scale:t>8?function(n){return n/i}:function(n){return n*i},symbol:n}}function pk(t){var e=t.decimal,f=t.thousands,i=t.grouping,r=t.currency,u=i?function(n){for(var r=n.length,u=[],e=0,t=i[0];r>0&&t>0;)u.push(n.substring(r-=t,r+t)),t=i[e=(e+1)%i.length];return u.reverse().join(f)}:a;return function(t){var o=gh.exec(t),w=o[1]||" ",c=o[2]||">",d=o[3]||"",b=o[4]||"",v=o[5],y=+o[6],p=o[7],f=o[8],i=o[9],s=1,l="",h="",k=!1,a;f&&(f=+f.substring(1)),(v||w==="0"&&c==="=")&&(v=w="0",c="=",p&&(y-=Math.floor((y-1)/4)));switch(i){case"n":p=!0,i="g";break;case"%":s=100,h="%",i="f";break;case"p":s=100,h="%",i="r";break;case"b":case"o":case"x":case"X":b==="#"&&(l="0"+i.toLowerCase());case"c":case"d":k=!0,f=0;break;case"s":s=-1,i="r"}return b==="$"&&(l=r[0],h=r[1]),i!="r"||f||(i="g"),f!=null&&(i=="g"?f=Math.max(1,Math.min(21,f)):(i=="e"||i=="f")&&(f=Math.max(0,Math.min(20,f)))),i=pp.get(i)||vk,a=v&&p,function(t){var rt=h,o,tt,b,r;if(k&&t%1)return"";o=t<0||t===0&&1/t<0?(t=-t,"-"):d,s<0?(tt=n.formatPrefix(t,f),t=tt.scale(t),rt=tt.symbol+h):t*=s,t=i(t,f);var nt=t.lastIndexOf("."),g=nt<0?t:t.substring(0,nt),it=nt<0?"":e+t.substring(nt+1);return!v&&p&&(g=u(g)),b=l.length+g.length+it.length+(a?0:o.length),r=b<y?new Array(b=y-b+1).join(w):"",a&&(g=u(r+g)),o+=l,t=g+it,(c==="<"?o+t+r:c===">"?r+o+t:c==="^"?r.substring(0,b>>=1)+o+t+r.substring(b):o+(a?t:r+t))+rt}}}function vk(n){return n+""}function wt(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function bi(n,t,i){function e(t){var i=n(t),r=u(i,1);return t-i<r-t?i:r}function f(i){return t(i=n(new v(i-1)),1),i}function u(n,i){return t(n=new v(+n),i),n}function o(n,r,u){var e=f(n),o=[];if(u>1)while(e<r)i(e)%u||o.push(new Date(+e)),t(e,1);else while(e<r)o.push(new Date(+e)),t(e,1);return o}function s(n,t,i){try{v=wt;var r=new wt;return r._=n,o(r,t,i)}finally{v=Date}}n.floor=n,n.round=e,n.ceil=f,n.offset=u,n.range=o;var r=n.utc=rf(n);return r.floor=r,r.round=rf(e),r.ceil=rf(f),r.offset=rf(u),r.range=s,n}function rf(n){return function(t,i){try{v=wt;var r=new wt;return r._=t,n(r,i)._}finally{v=Date}}}function rk(t){function r(n){function t(t){for(var e=[],r=-1,s=0,f,o,h;++r<i;)n.charCodeAt(r)===37&&(e.push(n.substring(s,r)),(o=by[f=n.charAt(++r)])!=null&&(f=n.charAt(++r)),(h=u[f])&&(f=h(t,o==null?f==="e"?" ":"0":o)),e.push(f),s=r+1);return e.push(n.substring(s,r)),e.join("")}var i=n.length;return t.parse=function(t){var i={y:1900,m:0,d:1,H:0,M:0,S:0,L:0,Z:null},e=f(i,n,t,0),u,r;return e!=t.length?null:("p"in i&&(i.H=i.H%12+i.p*12),u=i.Z!=null&&v!==wt,r=new(u?wt:v),"j"in i?r.setFullYear(i.y,0,i.j):"w"in i&&("W"in i||"U"in i)?(r.setFullYear(i.y,0,1),r.setFullYear(i.y,0,"W"in i?(i.w+6)%7+i.W*7-(r.getDay()+5)%7:i.w+i.U*7-(r.getDay()+6)%7)):r.setFullYear(i.y,i.m,i.d),r.setHours(i.H+Math.floor(i.Z/100),i.M+i.Z%100,i.S,i.L),u?r._:r)},t.toString=function(){return n},t}function f(n,t,i,r){for(var e,o,f,u=0,h=t.length,s=i.length;u<h;){if(r>=s)return-1;if(e=t.charCodeAt(u++),e===37){if(f=t.charAt(u++),o=c[f in by?t.charAt(u++):f],!o||(r=o(n,i,r))<0)return-1}else if(e!=i.charCodeAt(r++))return-1}return r}function ft(n,t,i){l.lastIndex=0;var r=l.exec(t.substring(i));return r?(n.w=ot.get(r[0].toLowerCase()),i+r[0].length):-1}function g(n,t,i){w.lastIndex=0;var r=w.exec(t.substring(i));return r?(n.w=st.get(r[0].toLowerCase()),i+r[0].length):-1}function nt(n,t,i){y.lastIndex=0;var r=y.exec(t.substring(i));return r?(n.m=at.get(r[0].toLowerCase()),i+r[0].length):-1}function d(n,t,i){a.lastIndex=0;var r=a.exec(t.substring(i));return r?(n.m=et.get(r[0].toLowerCase()),i+r[0].length):-1}function tt(n,t,i){return f(n,u.c.toString(),t,i)}function ut(n,t,i){return f(n,u.x.toString(),t,i)}function rt(n,t,i){return f(n,u.X.toString(),t,i)}function it(n,t,i){var r=k.get(t.substring(i,i+=2).toLowerCase());return r==null?-1:(n.p=r,i)}var ct=t.dateTime,lt=t.date,ht=t.time,b=t.periods,h=t.days,s=t.shortDays,e=t.months,o=t.shortMonths,u,c;r.utc=function(n){function t(n){try{v=wt;var t=new v;return t._=n,i(t)}finally{v=Date}}var i=r(n);return t.parse=function(n){try{v=wt;var t=i.parse(n);return t&&t._}finally{v=Date}},t.toString=i.toString,t},r.multi=r.utc.multi=prt;var k=n.map(),w=vf(h),st=yf(h),l=vf(s),ot=yf(s),a=vf(e),et=yf(e),y=vf(o),at=yf(o);return b.forEach(function(n,t){k.set(n.toLowerCase(),t)}),u={a:function(n){return s[n.getDay()]},A:function(n){return h[n.getDay()]},b:function(n){return o[n.getMonth()]},B:function(n){return e[n.getMonth()]},c:r(ct),d:function(n,t){return p(n.getDate(),t,2)},e:function(n,t){return p(n.getDate(),t,2)},H:function(n,t){return p(n.getHours(),t,2)},I:function(n,t){return p(n.getHours()%12||12,t,2)},j:function(n,t){return p(1+i.dayOfYear(n),t,3)},L:function(n,t){return p(n.getMilliseconds(),t,3)},m:function(n,t){return p(n.getMonth()+1,t,2)},M:function(n,t){return p(n.getMinutes(),t,2)},p:function(n){return b[+(n.getHours()>=12)]},S:function(n,t){return p(n.getSeconds(),t,2)},U:function(n,t){return p(i.sundayOfYear(n),t,2)},w:function(n){return n.getDay()},W:function(n,t){return p(i.mondayOfYear(n),t,2)},x:r(lt),X:r(ht),y:function(n,t){return p(n.getFullYear()%100,t,2)},Y:function(n,t){return p(n.getFullYear()%1e4,t,4)},Z:eit,"%":function(){return"%"}},c={a:ft,A:g,b:nt,B:d,c:tt,d:lp,e:lp,H:ow,I:ow,j:tit,L:hit,m:rit,M:uit,p:it,S:sit,U:vit,w:pit,W:lit,x:ut,X:rt,y:wit,Y:ait,Z:cit,"%":yrt},r}function p(n,t,i){var f=n<0?"-":"",r=(f?-n:n)+"",u=r.length;return f+(u<i?new Array(i-u+1).join(t)+r:r)}function vf(t){return new RegExp("^(?:"+t.map(n.requote).join("|")+")","i")}function yf(n){for(var i=new ht,t=-1,r=n.length;++t<r;)i.set(n[t].toLowerCase(),t);return i}function pit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+1));return r?(n.w=+r[0],i+r[0].length):-1}function vit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i));return r?(n.U=+r[0],i+r[0].length):-1}function lit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i));return r?(n.W=+r[0],i+r[0].length):-1}function ait(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+4));return r?(n.y=+r[0],i+r[0].length):-1}function wit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+2));return r?(n.y=iit(+r[0]),i+r[0].length):-1}function cit(n,t,i){return/^[+-]\d{4}$/.test(t=t.substring(i,i+5))?(n.Z=-t,i+5):-1}function iit(n){return n+(n>68?1900:2e3)}function rit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+2));return r?(n.m=r[0]-1,i+r[0].length):-1}function lp(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+2));return r?(n.d=+r[0],i+r[0].length):-1}function tit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+3));return r?(n.j=+r[0],i+r[0].length):-1}function ow(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+2));return r?(n.H=+r[0],i+r[0].length):-1}function uit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+2));return r?(n.M=+r[0],i+r[0].length):-1}function sit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+2));return r?(n.S=+r[0],i+r[0].length):-1}function hit(n,t,i){h.lastIndex=0;var r=h.exec(t.substring(i,i+3));return r?(n.L=+r[0],i+r[0].length):-1}function eit(n){var t=n.getTimezoneOffset(),f=t>0?"-":"+",u=~~(r(t)/60),i=r(t)%60;return f+p(u,"0",2)+p(i,"0",2)}function yrt(n,t,i){wp.lastIndex=0;var r=wp.exec(t.substring(i,i+1));return r?i+r[0].length:-1}function prt(n){for(var i=n.length,t=-1;++t<i;)n[t][0]=this(n[t][0]);return function(t){for(var r=0,i=n[r];!i[1](t);)i=n[++r];return i[0](t)}}function pc(){}function nw(n,t,i){var u=i.s=n+t,r=u-n,f=u-r;i.t=n-f+(t-r)}function gu(n,t){n&&ac.hasOwnProperty(n.type)&&ac[n.type](n,t)}function vc(n,t,i){var u=-1,f=n.length-i,r;for(t.lineStart();++u<f;)r=n[u],t.point(r[0],r[1],r[2]);t.lineEnd()}function iw(n,t){var i=-1,r=n.length;for(t.polygonStart();++i<r;)vc(n[i],t,1);t.polygonEnd()}function tut(){function r(r,e){r*=u,e=e*u/2+f/4;var c=r-i,l=c>=0?1:-1,a=l*c,o=Math.cos(e),s=Math.sin(e),h=n*s,y=t*o+h*Math.cos(a),v=h*l*Math.sin(a);ei.add(Math.atan2(v,y)),i=r,t=o,n=s}var o,e,i,t,n;b.point=function(s,h){b.point=r,i=(o=s)*u,t=Math.cos(h=(e=h)*u/2+f/4),n=Math.sin(h)},b.lineEnd=function(){r(o,e)}}function ai(n){var r=n[0],i=n[1],t=Math.cos(i);return[t*Math.cos(r),t*Math.sin(r),Math.sin(i)]}function ff(n,t){return n[0]*t[0]+n[1]*t[1]+n[2]*t[2]}function ur(n,t){return[n[1]*t[2]-n[2]*t[1],n[2]*t[0]-n[0]*t[2],n[0]*t[1]-n[1]*t[0]]}function ns(n,t){n[0]+=t[0],n[1]+=t[1],n[2]+=t[2]}function gf(n,t){return[n[0]*t,n[1]*t,n[2]*t]}function kf(n){var t=Math.sqrt(n[0]*n[0]+n[1]*n[1]+n[2]*n[2]);n[0]/=t,n[1]/=t,n[2]/=t}function re(n){return[Math.atan2(n[1],n[0]),sr(n[2])]}function te(n,i){return r(n[0]-i[0])<t&&r(n[1]-i[1])<t}function ws(n,t){n*=u;var i=Math.cos(t*=u);au(i*Math.cos(n),i*Math.sin(n),Math.sin(t))}function au(n,t,i){++cu,vi+=(n-vi)/cu,pi+=(t-pi)/cu,pt+=(i-pt)/cu}function vy(){function r(r,f){r*=u;var c=Math.cos(f*=u),s=c*Math.cos(r),h=c*Math.sin(r),o=Math.sin(f),e=Math.atan2(Math.sqrt((e=t*o-n*h)*e+(e=n*s-i*o)*e+(e=i*h-t*s)*e),i*s+t*h+n*o);hf+=e,si+=e*(i+(i=s)),ri+=e*(t+(t=h)),ct+=e*(n+(n=o)),au(i,t,n)}var i,t,n;nt.point=function(f,e){f*=u;var o=Math.cos(e*=u);i=o*Math.cos(f),t=o*Math.sin(f),n=Math.sin(e),nt.point=r,au(i,t,n)}}function ay(){nt.point=ws}function ert(){function r(r,f){r*=u;var p=Math.cos(f*=u),h=p*Math.cos(r),s=p*Math.sin(r),e=Math.sin(f),a=t*e-n*s,v=n*h-i*e,y=i*s-t*h,c=Math.sqrt(a*a+v*v+y*y),w=i*h+t*s+n*e,l=c&&-rw(w)/c,o=Math.atan2(c,w);hr+=l*a,cr+=l*v,gt+=l*y,hf+=o,si+=o*(i+(i=h)),ri+=o*(t+(t=s)),ct+=o*(n+(n=e)),au(i,t,n)}var e,f,i,t,n;nt.point=function(o,s){e=o,f=s,nt.point=r,o*=u;var h=Math.cos(s*=u);i=h*Math.cos(o),t=h*Math.sin(o),n=Math.sin(s),au(i,t,n)},nt.lineEnd=function(){r(e,f),nt.lineEnd=ay,nt.point=ws}}function or(){return!0}function yy(n,t,i,r,u){var h=[],s=[],a,o,l,f,c,v,e;if(n.forEach(function(n){var o,r,f,e,t,i;if(!((o=n.length-1)<=0)){if(r=n[0],f=n[o],te(r,f)){for(u.lineStart(),e=0;e<o;++e)u.point((r=n[e])[0],r[1]);u.lineEnd();return}t=new af(r,n,null,!0),i=new af(r,null,t,!1),t.o=i,h.push(t),s.push(i),t=new af(f,n,null,!1),i=new af(f,null,t,!0),t.o=i,h.push(t),s.push(i)}}),s.sort(t),py(h),py(s),h.length){for(var e=0,y=i,v=s.length;e<v;++e)s[e].e=y=!y;for(a=h[0];;){for(f=a,c=!0;f.v;)if((f=f.n)===a)return;o=f.z,u.lineStart();do{if(f.v=f.o.v=!0,f.e){if(c)for(e=0,v=o.length;e<v;++e)u.point((l=o[e])[0],l[1]);else r(f.x,f.n.x,1,u);f=f.n}else{if(c)for(o=f.p.z,e=o.length-1;e>=0;--e)u.point((l=o[e])[0],l[1]);else r(f.x,f.p.x,-1,u);f=f.p}f=f.o,o=f.z,c=!c}while(!f.v);u.lineEnd()}}}function py(n){if(u=n.length){for(var u,r=0,t=n[0],i;++r<u;)t.n=i=n[r],i.p=t,t=i;t.n=i=n[0],i.p=t}}function af(n,t,i,r){this.x=n,this.z=t,this.o=i,this.e=r,this.v=!1,this.n=this.p=null}function ey(t,i,r,u){return function(f,e){function y(n,i){var r=f(n,i);t(n=r[0],i=r[1])&&e.point(n,i)}function nt(n,t){var i=f(n,t);v.point(i[0],i[1])}function w(){o.point=nt,v.lineStart()}function b(){o.point=y,v.lineEnd()}function p(n,t){h.push([n,t]);var i=f(n,t);a.point(i[0],i[1])}function d(){a.lineStart(),h=[]}function g(){var t,i,u;p(h[0][0],h[0][1]),a.lineEnd();var f=a.clean(),n=k.buffer(),r,t=n.length;if(h.pop(),l.push(h),h=null,t){if(f&1){if(r=n[0],t=r.length-1,i=-1,t>0){for(s||(e.polygonStart(),s=!0),e.lineStart();++i<t;)e.point((u=r[i])[0],u[1]);e.lineEnd()}return}t>1&&f&2&&n.push(n.pop().concat(n.shift())),c.push(n.filter(hn))}}var v=i(e),tt=f.invert(u[0],u[1]),o={point:y,lineStart:w,lineEnd:b,polygonStart:function(){o.point=p,o.lineStart=d,o.lineEnd=g,c=[],l=[]},polygonEnd:function(){o.point=y,o.lineStart=w,o.lineEnd=b,c=n.merge(c);var t=en(tt,l);c.length?(s||(e.polygonStart(),s=!0),yy(c,fn,t,r,e)):t&&(s||(e.polygonStart(),s=!0),e.lineStart(),r(null,null,1,e),e.lineEnd()),s&&(e.polygonEnd(),s=!1),c=l=null},sphere:function(){e.polygonStart(),e.lineStart(),r(null,null,1,e),e.lineEnd(),e.polygonEnd()}},c,k=cy(),a=i(k),s=!1,l,h;return o}}function hn(n){return n.length>1}function cy(){var n=[],t;return{lineStart:function(){n.push(t=[])},point:function(n,i){t.push([n,i])},lineEnd:c,buffer:function(){var i=n;return n=[],t=null,i},rejoin:function(){n.length>1&&n.push(n.pop().concat(n.shift()))}}}function fn(n,i){return((n=n.x)[0]<0?n[1]-y-t:y-n[1])-((i=i.x)[0]<0?i[1]-y-t:y-i[1])}function en(n,i){var c=n[0],rt=n[1],ct=[Math.sin(c),-Math.cos(c),0],k=0,nt=0,e,ut,o,g,u,p,w;for(ei.reset(),e=0,ut=i.length;e<ut;++e)if(o=i[e],g=o.length,g)for(var s=o[0],b=s[0],et=s[1]/2+f/4,it=Math.sin(et),st=Math.cos(et),l=1;;){l===g&&(l=0),n=o[l];var v=n[0],ft=n[1]/2+f/4,ot=Math.sin(ft),ht=Math.cos(ft),r=v-b,y=r>=0?1:-1,a=y*r,h=a>f,tt=it*ot;if(ei.add(Math.atan2(tt*y*Math.sin(a),st*ht+tt*Math.cos(a))),k+=h?r+y*d:r,h^b>=c^v>=c&&(u=ur(ai(s),ai(n)),kf(u),p=ur(ct,u),kf(p),w=(h^r>=0?-1:1)*sr(p[2]),(rt>w||rt===w&&(u[0]||u[1]))&&(nt+=h^r>=0?1:-1)),!l++)break;b=v,it=ot,st=ht,s=n}return(k<-t||k<t&&ei<0)^nt&1}function cn(n){var u=NaN,i=NaN,e=NaN,o;return{lineStart:function(){n.lineStart(),o=1},point:function(s,h){var c=s>0?f:-f,l=r(s-u);r(l-f)<t?(n.point(u,i=(i+h)/2>0?y:-y),n.point(e,i),n.lineEnd(),n.lineStart(),n.point(c,i),n.point(s,i),o=0):e!==c&&l>=f&&(r(u-e)<t&&(u-=e*t),r(s-c)<t&&(s-=c*t),i=rn(u,i,s,h),n.point(e,i),n.lineEnd(),n.lineStart(),n.point(c,i),o=0),n.point(u=s,i=h),e=c},lineEnd:function(){n.lineEnd(),u=i=NaN},clean:function(){return 2-o}}}function rn(n,i,u,f){var s,o,e=Math.sin(n-u);return r(e)>t?Math.atan((Math.sin(i)*(o=Math.cos(f))*Math.sin(u)-Math.sin(f)*(s=Math.cos(i))*Math.sin(n))/(s*o*e)):(i+f)/2}function nn(n,i,u,e){var o,s;n==null?(o=u*y,e.point(-f,o),e.point(0,o),e.point(f,o),e.point(f,0),e.point(f,-o),e.point(0,-o),e.point(-f,-o),e.point(-f,0),e.point(-f,o)):r(n[0]-i[0])>t?(s=n[0]<i[0]?f:-f,o=u*s/2,e.point(-s,o),e.point(0,o),e.point(s,o)):e.point(i[0],i[1])}function ltt(n){function s(n,t){return Math.cos(n)*Math.cos(t)>e}function a(n){var r,a,u,c,e;return{lineStart:function(){c=u=!1,e=1},point:function(v,y){var p=[v,y],b,w=s(v,y),d=i?w?0:h(v,y):w?h(v+(v<0?f:-f),y):0,k;!r&&(c=u=w)&&n.lineStart(),w!==u&&(b=o(r,p),(te(r,b)||te(p,b))&&(p[0]+=t,p[1]+=t,w=s(p[0],p[1]))),w!==u?(e=0,w?(n.lineStart(),b=o(p,r),n.point(b[0],b[1])):(b=o(r,p),n.point(b[0],b[1]),n.lineEnd()),r=b):l&&r&&i^w&&!(d&a)&&(k=o(p,r,!0))&&(e=0,i?(n.lineStart(),n.point(k[0][0],k[0][1]),n.point(k[1][0],k[1][1]),n.lineEnd()):(n.point(k[1][0],k[1][1]),n.lineEnd(),n.lineStart(),n.point(k[0][0],k[0][1]))),!w||r&&te(r,p)||n.point(p[0],p[1]),r=p,u=w,a=d},lineEnd:function(){u&&n.lineEnd(),r=null},clean:function(){return e|(c&&u)<<1}}}function o(n,i,u){var ot=ai(n),ht=ai(i),ut=[1,0,0],y=ur(ot,ht),ft=ff(y,y),tt=y[0],nt=ft-tt*tt,b,o,it;if(!nt)return!u&&n;var lt=e*ft/nt,ct=-e*tt/nt,at=ur(ut,y),c=gf(ut,lt),st=gf(y,ct);ns(c,st);var a=at,p=ff(c,a),k=ff(a,a),rt=p*p-k*(ff(c,c)-1);if(!(rt<0)){if(b=Math.sqrt(rt),o=gf(a,(-p-b)/k),ns(o,c),o=re(o),!u)return o;var h=n[0],v=i[0],s=n[1],l=i[1],w;v<h&&(w=h,h=v,v=w);var d=v-h,g=r(d-f)<t,et=g||d<t;return!g&&l<s&&(w=s,s=l,l=w),(et?g?s+l>0^o[1]<(r(o[0]-h)<t?s:l):s<=o[1]&&o[1]<=l:d>f^(h<=o[0]&&o[0]<=v))?(it=gf(a,(-p+b)/k),ns(it,c),[o,re(it)]):void 0}}function h(t,r){var e=i?n:f-n,u=0;return t<-e?u|=1:t>e&&(u|=2),r<-e?u|=4:r>e&&(u|=8),u}var e=Math.cos(n),i=e>0,l=r(e)>t,c=rs(n,6*u);return ey(s,a,c,i?[0,-n]:[-f,n-f])}function lb(n,t,i,r){return function(u){var a=u.a,v=u.b,l=a.x,c=a.y,y=v.x,p=v.y,o=0,e=1,s=y-l,h=p-c,f;if(f=n-l,s||!(f>0)){if(f/=s,s<0){if(f<o)return;f<e&&(e=f)}else if(s>0){if(f>e)return;f>o&&(o=f)}if(f=i-l,s||!(f<0)){if(f/=s,s<0){if(f>e)return;f>o&&(o=f)}else if(s>0){if(f<o)return;f<e&&(e=f)}if(f=t-c,h||!(f>0)){if(f/=h,h<0){if(f<o)return;f<e&&(e=f)}else if(h>0){if(f>e)return;f>o&&(o=f)}if(f=r-c,h||!(f<0)){if(f/=h,h<0){if(f>e)return;f>o&&(o=f)}else if(h>0){if(f<o)return;f<e&&(e=f)}return o>0&&(u.a={x:l+o*s,y:c+o*h}),e<1&&(u.b={x:l+e*s,y:c+e*h}),u}}}}}}function bb(i,u,f,e){function o(n,e){return r(n[0]-i)<t?e>0?0:3:r(n[0]-f)<t?e>0?2:1:r(n[1]-u)<t?e>0?1:0:e>0?3:2}function h(n,t){return s(n.x,t.x)}function s(n,t){var i=o(n,1),r=o(t,1);return i!==r?i-r:i===0?t[1]-n[1]:i===1?n[0]-t[0]:i===2?n[1]-t[1]:t[0]-n[0]}return function(t){function st(n){for(var o=0,s=c.length,e=n[1],r=0;r<s;++r)for(var f=1,u=c[r],h=u.length,i=u[0],t;f<h;++f)t=u[f],i[1]<=e?t[1]>e&&rl(i,t,n)>0&&++o:t[1]<=e&&rl(i,t,n)<0&&--o,i=t;return o!==0}function it(n,t,r,h){var c=0,l=0;if(n==null||(c=o(n,r))!==(l=o(t,r))||s(n,t)<0^r>0){do h.point(c===0||c===3?i:f,c>1?e:u);while((c=(c+r+4)%4)!==l)}else h.point(t[0],t[1])}function tt(n,t){return i<=n&&n<=f&&u<=t&&t<=e}function ut(n,i){tt(n,i)&&t.point(n,i)}function ot(){k.point=g,c&&c.push(b=[]),v=!0,l=!1,y=p=NaN}function ft(){r&&(g(rt,nt),d&&l&&w.rejoin(),r.push(w.buffer())),k.point=ut,l&&t.lineEnd()}function g(n,i){var r,u;n=Math.max(-vr,Math.min(vr,n)),i=Math.max(-vr,Math.min(vr,i)),r=tt(n,i),c&&b.push([n,i]),v?(rt=n,nt=i,d=r,v=!1,r&&(t.lineStart(),t.point(n,i))):r&&l?t.point(n,i):(u={a:{x:y,y:p},b:{x:n,y:i}},ht(u)?(l||(t.lineStart(),t.point(u.a.x,u.a.y)),t.point(u.b.x,u.b.y),r||t.lineEnd(),a=!1):r&&(t.lineStart(),t.point(n,i),a=!1)),y=n,p=i,l=r}var et=t,w=cy(),ht=lb(i,u,f,e),r,c,b,k={point:ut,lineStart:ot,lineEnd:ft,polygonStart:function(){t=w,r=[],c=[],a=!0},polygonEnd:function(){t=et,r=n.merge(r);var o=st([i,e]),f=a&&o,u=r.length;(f||u)&&(t.polygonStart(),f&&(t.lineStart(),it(null,null,1,t),t.lineEnd()),u&&yy(r,h,o,it,t),t.polygonEnd()),r=c=b=null}},rt,nt,d,y,p,l,v,a;return k}}function wb(n,t){function i(i,r){return i=n(i,r),t(i[0],i[1])}return n.invert&&t.invert&&(i.invert=function(i,r){return i=t.invert(i,r),i&&n.invert(i[0],i[1])}),i}function us(n){var i=0,t=f/3,u=ls(n),r=u(i,t);return r.parallels=function(n){return arguments.length?u(i=n[0]*f/180,t=n[1]*f/180):[i/f*180,t/f*180]},r}function db(n,t){function f(n,t){var u=Math.sqrt(r-2*i*Math.sin(t))/i;return[u*Math.sin(n*=i),e-u*Math.cos(n)]}var u=Math.sin(n),i=(u+Math.sin(t))/2,r=1+u*(2*i-u),e=Math.sqrt(r)/i;return f.invert=function(n,t){var u=e-t;return[Math.atan2(n,u)/i,sr((r-(n*n+u*u)*i*i)/(2*i))]},f}function att(){function i(i,r){ts+=n*i-t*r,t=i,n=r}var u,r,t,n;bt.point=function(f,e){bt.point=i,u=t=f,r=n=e},bt.lineEnd=function(){i(u,r)}}function ctt(n,t){n<df&&(df=n),n>ku&&(ku=n),t<du&&(du=t),t>wu&&(wu=t)}function stt(){function i(n,i){t.push("M",n,",",i,u)}function e(i,r){t.push("M",i,",",r),n.point=o}function o(n,i){t.push("L",n,",",i)}function r(){n.point=i}function f(){t.push("Z")}var u=vb(4.5),t=[],n={point:i,lineStart:function(){n.point=e},lineEnd:r,polygonStart:function(){n.lineEnd=f},polygonEnd:function(){n.lineEnd=r,n.point=i},pointRadius:function(t){return u=vb(t),n},result:function(){if(t.length){var n=t.join("");return t=[],n}}};return n}function vb(n){return"m0,"+n+"a"+n+","+n+" 0 1,1 0,"+-2*n+"a"+n+","+n+" 0 1,1 0,"+2*n+"z"}function li(n,t){vi+=n,pi+=t,++pt}function tk(){function i(i,r){var f=i-t,e=r-n,u=Math.sqrt(f*f+e*e);si+=u*(t+i)/2,ri+=u*(n+r)/2,ct+=u,li(t=i,n=r)}var t,n;it.point=function(r,u){it.point=i,li(t=r,n=u)}}function ww(){it.point=li}function wtt(){function i(i,r){var f=i-t,e=r-n,u=Math.sqrt(f*f+e*e);si+=u*(t+i)/2,ri+=u*(n+r)/2,ct+=u,u=n*i-t*r,hr+=u*(t+i),cr+=u*(n+r),gt+=u*3,li(t=i,n=r)}var u,r,t,n;it.point=function(f,e){it.point=i,li(u=t=f,r=n=e)},it.lineEnd=function(){i(u,r)}}function ytt(n){function i(t,i){n.moveTo(t,i),n.arc(t,i,u,0,d)}function e(i,r){n.moveTo(i,r),t.point=o}function o(t,i){n.lineTo(t,i)}function r(){t.point=i}function f(){n.closePath()}var u=4.5,t={point:i,lineStart:function(){t.point=e},lineEnd:r,polygonStart:function(){t.lineEnd=f},polygonEnd:function(){t.lineEnd=r,t.point=i},pointRadius:function(n){return u=n,t},result:c};return t}function dw(n){function o(n){return(i?h:c)(n)}function c(t){return yw(t,function(i,r){i=n(i,r),t.point(i[0],i[1])})}function h(t){function y(i,r){i=n(i,r),t.point(i[0],i[1])}function v(){u=NaN,r.point=a,t.lineStart()}function a(r,l){var a=ai([r,l]),v=n(r,l);f(u,e,c,s,h,o,u=v[0],e=v[1],c=r,s=a[0],h=a[1],o=a[2],i,t),t.point(u,e)}function l(){r.point=y,t.lineEnd()}function rt(){v(),r.point=nt,r.lineEnd=tt}function nt(n,t){a(p=n,it=t),g=u,d=e,k=s,b=h,w=o,r.point=a}function tt(){f(u,e,c,s,h,o,g,d,p,k,b,w,i,t),r.lineEnd=l,l()}var p,it,g,d,k,b,w,c,u,e,s,h,o,r={point:y,lineStart:v,lineEnd:l,polygonStart:function(){t.polygonStart(),r.lineStart=rt},polygonEnd:function(){t.polygonEnd(),r.lineStart=v}};return r}function f(i,u,o,h,c,l,a,v,y,p,w,b,k,d){var ft=a-i,ut=v-u,et=ft*ft+ut*ut;if(et>4*e&&k--){var nt=h+p,tt=c+w,g=l+b,st=Math.sqrt(nt*nt+tt*tt+g*g),vt=Math.asin(g/=st),ot=r(r(g)-1)<t||r(o-y)<t?(o+y)/2:Math.atan2(tt,nt),at=n(ot,vt),rt=at[0],it=at[1],lt=rt-i,ht=it-u,ct=ut*lt-ft*ht;(ct*ct/et>e||r((ft*lt+ut*ht)/et-.5)>.3||h*p+c*w+l*b<s)&&(f(i,u,o,h,c,l,rt,it,ot,nt/=st,tt/=st,g,k,d),d.point(rt,it),f(rt,it,ot,nt,tt,g,a,v,y,p,w,b,k,d))}}var e=.5,s=Math.cos(30*u),i=16;return o.precision=function(n){return arguments.length?(i=(e=n*n)>0&&16,o):Math.sqrt(e)},o}function ptt(n){var t=dw(function(t,i){return n([t*s,i*s])});return function(n){return eb(t(n))}}function pw(n){this.stream=n}function yw(n,t){return{point:t,sphere:function(){n.sphere()},lineStart:function(){n.lineStart()},lineEnd:function(){n.lineEnd()},polygonStart:function(){n.polygonStart()},polygonEnd:function(){n.polygonEnd()}}}function ii(n){return ls(function(){return n})()}function ls(t){function i(n){return n=k(n[0]*u,n[1]*u),[n[0]*r+h,c-n[1]*r]}function et(n){return n=k.invert((n[0]-h)/r,(c-n[1])/r),n&&[n[0]*s,n[1]*s]}function e(){k=wb(it=is(g,p,l),o);var n=o(d,nt);return h=b-n[0]*r,c=w+n[1]*r,y()}function y(){return f&&(f.valid=!1,f=null),i}var o,it,k,tt=dw(function(n,t){return n=o(n,t),[n[0]*r+h,c-n[1]*r]}),r=150,b=480,w=250,d=0,nt=0,g=0,p=0,l=0,h,c,ft=ih,ut=a,v=null,rt=null,f;return i.stream=function(n){return f&&(f.valid=!1),f=eb(ft(it,tt(ut(n)))),f.valid=!0,f},i.clipAngle=function(n){return arguments.length?(ft=n==null?(v=n,ih):ltt((v=+n)*u),y()):v},i.clipExtent=function(n){return arguments.length?(rt=n,ut=n?bb(n[0][0],n[0][1],n[1][0],n[1][1]):a,y()):rt},i.scale=function(n){return arguments.length?(r=+n,e()):r},i.translate=function(n){return arguments.length?(b=+n[0],w=+n[1],e()):[b,w]},i.center=function(n){return arguments.length?(d=n[0]%360*u,nt=n[1]%360*u,e()):[d*s,nt*s]},i.rotate=function(n){return arguments.length?(g=n[0]%360*u,p=n[1]%360*u,l=n.length>2?n[2]%360*u:0,e()):[g*s,p*s,l*s]},n.rebind(i,tt,"precision"),function(){return o=t.apply(this,arguments),i.invert=o.invert&&et,e()}}function eb(n){return yw(n,function(t,i){n.point(t*u,i*u)})}function eu(n,t){return[n,t]}function fb(n,t){return[n>f?n-d:n<-f?n+d:n,t]}function is(n,t,i){return n?t||i?wb(nb(n),rb(t,i)):nb(n):t||i?rb(t,i):fb}function sb(n){return function(t,i){return t+=n,[t>f?t-d:t<-f?t+d:t,i]}}function nb(n){var t=sb(n);return t.invert=sb(-n),t}function rb(n,t){function e(n,t){var h=Math.cos(t),c=Math.cos(n)*h,s=Math.sin(n)*h,e=Math.sin(t),o=e*u+c*f;return[Math.atan2(s*i-o*r,c*u-e*f),sr(o*i+s*r)]}var u=Math.cos(n),f=Math.sin(n),i=Math.cos(t),r=Math.sin(t);return e.invert=function(n,t){var h=Math.cos(t),c=Math.cos(n)*h,s=Math.sin(n)*h,e=Math.sin(t),o=e*i-s*r;return[Math.atan2(s*i+e*r,c*u+o*f),sr(o*u-c*f)]},e}function rs(n,t){var i=Math.cos(n),r=Math.sin(n);return function(u,f,e,o){var h=e*t,c,s;for(u!=null?(u=ib(i,u),f=ib(i,f),(e>0?u<f:u>f)&&(u+=e*d)):(u=n+e*d,f=n-.5*h),s=u;e>0?s>f:s<f;s-=h)o.point((c=re([i,-r*Math.cos(s),-r*Math.sin(s)]))[0],c[1])}}function ib(n,i){var r=ai(i),u;return r[0]-=n,kf(r),u=rw(-r[1]),((-r[2]<0?-u:u)+2*Math.PI-t)%(2*Math.PI)}function tb(i,r,u){var f=n.range(i,r-t,u).concat(r);return function(n){return f.map(function(t){return[n,t]})}}function ob(i,r,u){var f=n.range(i,r-t,u).concat(r);return function(n){return f.map(function(t){return[t,n]})}}function as(n){return n.source}function gs(n){return n.target}function ttt(n,t,i,r){var e=Math.cos(t),l=Math.sin(t),f=Math.cos(r),c=Math.sin(r),v=e*Math.cos(n),y=e*Math.sin(n),p=f*Math.cos(i),a=f*Math.sin(i),u=2*Math.asin(Math.sqrt(tw(r-t)+e*f*tw(i-n))),o=1/Math.sin(u),h=u?function(n){var r=Math.sin(n*=u)*o,f=Math.sin(u-n)*o,t=f*v+r*p,i=f*y+r*a,e=f*l+r*c;return[Math.atan2(i,t)*s,Math.atan2(e,Math.sqrt(t*t+i*i))*s]}:function(){return[n*s,t*s]};return h.distance=u,h}function utt(){function f(f,e){var h=Math.sin(e*=u),s=Math.cos(e),o=r((f*=u)-i),c=Math.cos(o);ds+=Math.atan2(Math.sqrt((o=s*Math.sin(o))*o+(o=n*h-t*s*c)*o),t*h+n*s*c),i=f,t=h,n=s}var i,t,n;ki.point=function(r,e){i=r*u,t=Math.sin(e*=u),n=Math.cos(e),ki.point=f},ki.lineEnd=function(){ki.point=ki.lineEnd=c}}function dr(n,t){function i(t,i){var f=Math.cos(t),r=Math.cos(i),u=n(f*r);return[u*r*Math.sin(t),u*Math.sin(i)]}return i.invert=function(n,i){var r=Math.sqrt(n*n+i*i),f=t(r),u=Math.sin(f),e=Math.cos(f);return[Math.atan2(n*u,r*e),Math.asin(r&&i*u/r)]},i}function lw(n,i){function o(n,i){u>0?i<-y+t&&(i=-y+t):i>y-t&&(i=y-t);var f=u/Math.pow(e(i),r);return[f*Math.sin(r*n),u-f*Math.cos(r*n)]}var s=Math.cos(n),e=function(n){return Math.tan(f/4+n/2)},r=n===i?Math.sin(n):Math.log(s/Math.cos(i))/Math.log(e(i)/e(n)),u=s*Math.pow(e(n),r)/r;return r?(o.invert=function(n,t){var i=u-t,f=sp(r)*Math.sqrt(n*n+i*i);return[Math.atan2(n,i)/r,2*Math.atan(Math.pow(u/f,1/r))-y]},o):de}function kw(n,i){function e(n,t){var i=f-t;return[i*Math.sin(u*n),f-i*Math.cos(u*n)]}var o=Math.cos(n),u=n===i?Math.sin(n):(o-Math.cos(i))/(i-n),f=o/u+n;return r(u)<t?eu:(e.invert=function(n,t){var i=f-t;return[Math.atan2(n,i)/u,f-sp(u)*Math.sqrt(n*n+i*i)]},e)}function de(n,t){return[n,Math.log(Math.tan(f/4+t/2))]}function bw(n){var t=ii(n),r=t.scale,e=t.translate,u=t.clipExtent,i;return t.scale=function(){var n=r.apply(t,arguments);return n===t?i?t.clipExtent(null):t:n},t.translate=function(){var n=e.apply(t,arguments);return n===t?i?t.clipExtent(null):t:n},t.clipExtent=function(n){var h=u.apply(t,arguments),o,s;return h===t?(i=n==null)&&(o=f*r(),s=e(),u([[s[0]-o,s[1]-o],[s[0]+o,s[1]+o]])):i&&(h=null),h},t.clipExtent(null)}function bo(n,t){return[Math.log(Math.tan(f/4+t/2)),-n]}function tr(n){return n[0]}function su(n){return n[1]}function gb(n){for(var u=n.length,r=[0,1],t=2,i=2;i<u;i++){while(t>1&&rl(n[r[t-2]],n[r[t-1]],n[i])<=0)--t;r[t++]=i}return r.slice(0,t)}function rtt(n,t){return n[0]-t[0]||n[1]-t[1]}function yo(n,t,i){return(i[0]-t[0])*(n[1]-t[1])<(i[1]-t[1])*(n[0]-t[0])}function yb(n,t,i,r){var f=n[0],c=i[0],l=t[0]-f,a=r[0]-c,u=n[1],h=i[1],o=t[1]-u,s=r[1]-h,e=(a*(u-h)-s*(f-c))/(s*l-a*o);return[f+e*l,u+e*o]}function ab(n){var i=n[0],t=n[n.length-1];return!(i[0]-t[0]||i[1]-t[1])}function itt(){be(this),this.edge=this.site=this.circle=null}function gl(n){var t=go.pop()||new itt;return t.site=n,t}function th(n){nr(n),gi.remove(n),go.push(n),be(n)}function ett(n){var v=n.circle,c=v.x,h=v.cy,a={x:c,y:h},o=n.P,l=n.N,f=[n],u,i,s,e;for(th(n),u=o;u.circle&&r(c-u.circle.x)<t&&r(h-u.circle.cy)<t;)o=u.P,f.unshift(u),th(u),u=o;for(f.unshift(u),nr(u),i=l;i.circle&&r(c-i.circle.x)<t&&r(h-i.circle.cy)<t;)l=i.N,f.push(i),th(i),i=l;for(f.push(i),nr(i),s=f.length,e=1;e<s;++e)i=f[e],u=f[e-1],oe(i.edge,u.site,i.site,a);u=f[0],i=f[s-1],i.edge=ou(u.site,i.site,null,a),ir(u),ir(i)}function ftt(n){for(var k=n.x,g=n.y,i,r,y,v,u=gi._,f;u;)if(y=oa(u,g)-k,y>t)u=u.L;else if(v=k-kn(u,g),v>t){if(!u.R){i=u;break}u=u.R}else{y>-t?(i=u.P,r=u):v>-t?(i=u,r=u.N):i=r=u;break}if(f=gl(n),gi.insert(i,f),i||r){if(i===r){nr(i),r=gl(i.site),gi.insert(f,r),f.edge=r.edge=ou(i.site,f.site),ir(i),ir(r);return}if(!r){f.edge=ou(i.site,f.site);return}nr(i),nr(r);var s=i.site,w=s.x,p=s.y,o=n.x-w,e=n.y-p,l=r.site,c=l.x-w,h=l.y-p,nt=2*(o*h-e*c),d=o*o+e*e,b=c*c+h*h,a={x:(h*d-e*b)/nt+w,y:(o*b-c*d)/nt+p};oe(r.edge,s,l,a),f.edge=ou(s,n,null,a),r.edge=ou(n,l,null,a),ir(i),ir(r)}}function oa(n,t){var r=n.site,u=r.x,l=r.y,s=l-t,c;if(!s)return u;if(c=n.P,!c)return-Infinity;r=c.site;var h=r.x,a=r.y,i=a-t;if(!i)return h;var e=h-u,f=1/s-1/i,o=e/i;return f?(-o+Math.sqrt(o*o-2*f*(e*e/(-2*i)-a+i/2+l-s/2)))/f+u:(u+h)/2}function kn(n,t){var r=n.N,i;return r?oa(r,t):(i=n.site,i.y===t?i.x:Infinity)}function ea(n){this.site=n,this.edges=[]}function bn(n){for(var s=n[0][0],l=n[1][0],v=n[0][1],a=n[1][1],o,u,i,e,b=hi,k=b.length,f,h,c,y,w,p;k--;)if(f=b[k],f&&f.prepare())for(c=f.edges,y=c.length,h=0;h<y;)p=c[h].end(),i=p.x,e=p.y,w=c[++h%y].start(),o=w.x,u=w.y,(r(i-o)>t||r(e-u)>t)&&(c.splice(h,0,new ge(ott(f.site,p,r(i-s)<t&&a-e>t?{x:s,y:r(o-s)<t?u:a}:r(e-a)<t&&l-i>t?{x:r(u-a)<t?o:l,y:a}:r(i-l)<t&&e-v>t?{x:l,y:r(o-l)<t?u:v}:r(e-v)<t&&i-s>t?{x:r(u-v)<t?o:s,y:v}:null),f.site,null)),++y)}function ta(n,t){return t.angle-n.angle}function dn(){be(this),this.x=this.y=this.arc=this.site=this.cy=null}function ir(n){var b=n.P,w=n.N,u,t;if(b&&w){var h=b.site,y=n.site,p=w.site;if(h!==p){var v=y.x,a=y.y,f=h.x-v,e=h.y-a,o=p.x-v,r=p.y-a,s=2*(f*r-e*o);if(!(s>=-fl)){var k=f*f+e*e,d=o*o+r*r,l=(r*k-e*d)/s,c=(f*d-o*k)/s,r=c+a,i=vs.pop()||new dn;for(i.arc=n,i.site=y,i.x=l+v,i.y=r+Math.sqrt(l*l+c*c),i.cy=r,n.circle=i,u=null,t=vu._;t;)if(i.y<t.y||i.y===t.y&&i.x<=t.x)if(t.L)t=t.L;else{u=t.P;break}else if(t.R)t=t.R;else{u=t;break}vu.insert(u,i),u||(ko=i)}}}}function nr(n){var t=n.circle;t&&(t.P||(ko=t.N),vu.remove(t),vs.push(t),be(t),n.circle=null)}function ntt(n){for(var f=fr,e=lb(n[0][0],n[0][1],n[1][0],n[1][1]),u=f.length,i;u--;)i=f[u],(!gn(i,n)||!e(i)||r(i.a.x-i.b.x)<t&&r(i.a.y-i.b.y)<t)&&(i.a=i.b=null,f.splice(u,1))}function gn(n,t){var e=n.b;if(e)return!0;var i=n.a,c=t[0][0],h=t[1][0],o=t[0][1],f=t[1][1],w=n.l,p=n.r,v=w.x,y=w.y,a=p.x,l=p.y,s=(v+a)/2,b=(y+l)/2,r,u;if(l===y){if(s<c||s>=h)return;if(v>a){if(i){if(i.y>=f)return}else i={x:s,y:o};e={x:s,y:f}}else{if(i){if(i.y<o)return}else i={x:s,y:f};e={x:s,y:o}}}else if(r=(v-a)/(l-y),u=b-r*s,r<-1||r>1)if(v>a){if(i){if(i.y>=f)return}else i={x:(o-u)/r,y:o};e={x:(f-u)/r,y:f}}else{if(i){if(i.y<o)return}else i={x:(f-u)/r,y:f};e={x:(o-u)/r,y:o}}else if(y<l){if(i){if(i.x>=h)return}else i={x:c,y:r*c+u};e={x:h,y:r*h+u}}else{if(i){if(i.x<c)return}else i={x:h,y:r*h+u};e={x:c,y:r*c+u}}return n.a=i,n.b=e,!0}function ll(n,t){this.l=n,this.r=t,this.a=this.b=null}function ou(n,t,i,r){var u=new ll(n,t);return fr.push(u),i&&oe(u,n,t,i),r&&oe(u,t,n,r),hi[n.i].edges.push(new ge(u,n,t)),hi[t.i].edges.push(new ge(u,t,n)),u}function ott(n,t,i){var r=new ll(n,null);return r.a=t,r.b=i,fr.push(r),r}function oe(n,t,i,r){n.a||n.b?n.l===i?n.b=r:n.a=r:(n.a=r,n.l=t,n.r=i)}function ge(n,t,i){var u=n.a,r=n.b;this.edge=n,this.site=t,this.angle=i?Math.atan2(i.y-t.y,i.x-t.x):n.l===t?Math.atan2(r.x-u.x,u.y-r.y):Math.atan2(u.x-r.x,r.y-u.y)}function hs(){this._=null}function be(n){n.U=n.C=n.L=n.R=n.P=n.N=null}function nu(n,t){var i=t,r=t.R,u=i.U;u?u.L===i?u.L=r:u.R=r:n._=r,r.U=u,i.U=r,i.R=r.L,i.R&&(i.R.U=i),r.L=i}function ru(n,t){var i=t,r=t.L,u=i.U;u?u.L===i?u.L=r:u.R=r:n._=r,r.U=u,i.U=r,i.L=r.R,i.L&&(i.L.U=i),r.R=i}function wv(n){while(n.L)n=n.L;return n}function os(n,t){var i=n.sort(ktt).pop(),f,e,r,u;for(fr=[],hi=new Array(n.length),gi=new hs,vu=new hs;;)if(r=ko,i&&(!r||i.y<r.y||i.y===r.y&&i.x<r.x))(i.x!==f||i.y!==e)&&(hi[i.i]=new ea(i),ftt(i),f=i.x,e=i.y),i=n.pop();else if(r)ett(r.arc);else break;return t&&(ntt(t),bn(t)),u={cells:hi,edges:fr},gi=vu=fr=hi=null,u}function ktt(n,t){return t.y-n.y||t.x-n.x}function btt(n,t,i){return(n.x-i.x)*(t.y-n.y)-(n.x-t.x)*(i.y-n.y)}function vtt(n){return n.x}function htt(n){return n.y}function pv(){return{leaf:!0,nodes:[],point:null,x:null,y:null}}function wr(n,t,i,r,u,f){if(!n(t,i,r,u,f)){var o=(i+u)*.5,s=(r+f)*.5,e=t.nodes;e[0]&&wr(n,e[0],i,r,o,s),e[1]&&wr(n,e[1],o,r,u,s),e[2]&&wr(n,e[2],i,s,o,f),e[3]&&wr(n,e[3],o,s,u,f)}}function cs(t,i){t=n.rgb(t),i=n.rgb(i);var f=t.r,u=t.g,r=t.b,s=i.r-f,o=i.g-u,e=i.b-r;return function(n){return"#"+er(Math.round(f+s*n))+er(Math.round(u+o*n))+er(Math.round(r+e*n))}}function sv(n,t){var u={},r={},i;for(i in n)i in t?u[i]=wi(n[i],t[i]):r[i]=n[i];for(i in t)i in n||(r[i]=t[i]);return function(n){for(i in u)r[i]=u[i](n);return r}}function vt(n,t){return t-=n=+n,function(i){return n+t*i}}function cv(n,t){var e=bf.lastIndex=ie.lastIndex=0,s,f,u,r=-1,i=[],o=[];for(n=n+"",t=t+"";(s=bf.exec(n))&&(f=ie.exec(t));)(u=f.index)>e&&(u=t.substring(e,u),i[r]?i[r]+=u:i[++r]=u),(s=s[0])===(f=f[0])?i[r]?i[r]+=f:i[++r]=f:(i[++r]=null,o.push({i:r,x:vt(s,f)})),e=ie.lastIndex;return e<t.length&&(u=t.substring(e),i[r]?i[r]+=u:i[++r]=u),i.length<2?o[0]?(t=o[0].x,function(n){return t(n)+""}):function(){return t}:(t=o.length,function(n){for(var r=0,u;r<t;++r)i[(u=o[r]).i]=u.x(n);return i.join("")})}function wi(t,i){for(var u=n.interpolators.length,r;--u>=0&&!(r=n.interpolators[u](t,i)););return r}function lf(n,t){for(var f=[],r=[],o=n.length,e=t.length,u=Math.min(n.length,t.length),i=0;i<u;++i)f.push(wi(n[i],t[i]));for(;i<o;++i)r[i]=n[i];for(;i<e;++i)r[i]=t[i];return function(n){for(i=0;i<u;++i)r[i]=f[i](n);return r}}function dg(n){return function(t){return t<=0?0:t>=1?1:n(t)}}function uy(n){return function(t){return 1-n(1-t)}}function ty(n){return function(t){return.5*(t<.5?n(2*t):2-n(2-2*t))}}function tn(n){return n*n}function kg(n){return n*n*n}function yg(n){if(n<=0)return 0;if(n>=1)return 1;var i=n*n,t=i*n;return 4*(n<.5?t:3*(n-i)+t-.75)}function vg(n){return function(t){return Math.pow(t,n)}}function pg(n){return 1-Math.cos(n*y)}function bg(n){return Math.pow(2,10*(n-1))}function wg(n){return 1-Math.sqrt(1-n*n)}function un(n,t){var i;return arguments.length<2&&(t=.45),arguments.length?i=t/d*Math.asin(1/n):(n=1,i=t/4),function(r){return 1+n*Math.pow(2,-10*r)*Math.sin((r-i)*d/t)}}function an(n){return n||(n=1.70158),function(t){return t*t*((n+1)*t-n)}}function ln(n){return n<1/2.75?7.5625*n*n:n<2/2.75?7.5625*(n-=1.5/2.75)*n+.75:n<2.5/2.75?7.5625*(n-=2.25/2.75)*n+.9375:7.5625*(n-=2.625/2.75)*n+.984375}function vn(t,i){t=n.hcl(t),i=n.hcl(i);var f=t.h,u=t.c,o=t.l,r=i.h-f,e=i.c-u,s=i.l-o;return isNaN(e)&&(e=0,u=isNaN(u)?i.c:u),isNaN(r)?(r=0,f=isNaN(f)?i.h:f):r>180?r-=360:r<-180&&(r+=360),function(n){return tc(f+r*n,u+e*n,o+s*n)+""}}function pn(t,i){t=n.hsl(t),i=n.hsl(i);var f=t.h,u=t.s,o=t.l,r=i.h-f,e=i.s-u,s=i.l-o;return isNaN(e)&&(e=0,u=isNaN(u)?i.s:u),isNaN(r)?(r=0,f=isNaN(f)?i.h:f):r>180?r-=360:r<-180&&(r+=360),function(n){return oh(f+r*n,u+e*n,o+s*n)+""}}function yn(t,i){t=n.lab(t),i=n.lab(i);var f=t.l,u=t.a,r=t.b,s=i.l-f,o=i.a-u,e=i.b-r;return function(n){return gp(f+s*n,u+o*n,r+e*n)+""}}function dv(n,t){return t-=n,function(i){return Math.round(n+t*i)}}function ny(n){var t=[n.a,n.b],i=[n.c,n.d],f=ov(t),u=gv(t,i),r=ov(on(i,t,-u))||0;t[0]*i[1]<i[0]*t[1]&&(t[0]*=-1,t[1]*=-1,f*=-1,u*=-1),this.rotate=(f?Math.atan2(t[1],t[0]):Math.atan2(-i[0],i[1]))*s,this.translate=[n.e,n.f],this.scale=[f,r],this.skew=r?Math.atan2(u,r)*s:0}function gv(n,t){return n[0]*t[0]+n[1]*t[1]}function ov(n){var t=Math.sqrt(gv(n,n));return t&&(n[0]/=t,n[1]/=t),t}function on(n,t,i){return n[0]+=i*t[0],n[1]+=i*t[1],n}function ya(t,i){var r=[],o=[],h,v=n.transform(t),y=n.transform(i),a=v.translate,f=y.translate,s=v.rotate,e=y.rotate,p=v.skew,c=y.skew,l=v.scale,u=y.scale;return a[0]!=f[0]||a[1]!=f[1]?(r.push("translate(",null,",",null,")"),o.push({i:1,x:vt(a[0],f[0])},{i:3,x:vt(a[1],f[1])})):f[0]||f[1]?r.push("translate("+f+")"):r.push(""),s!=e?(s-e>180?e+=360:e-s>180&&(s+=360),o.push({i:r.push(r.pop()+"rotate(",null,")")-2,x:vt(s,e)})):e&&r.push(r.pop()+"rotate("+e+")"),p!=c?o.push({i:r.push(r.pop()+"skewX(",null,")")-2,x:vt(p,c)}):c&&r.push(r.pop()+"skewX("+c+")"),l[0]!=u[0]||l[1]!=u[1]?(h=r.push(r.pop()+"scale(",null,",",null,")"),o.push({i:h-4,x:vt(l[0],u[0])},{i:h-2,x:vt(l[1],u[1])})):(u[0]!=1||u[1]!=1)&&r.push(r.pop()+"scale("+u+")"),h=o.length,function(n){for(var i=-1,t;++i<h;)r[(t=o[i]).i]=t.x(n);return r.join("")}}function sn(n,t){return t=t-(n=+n)?1/(t-n):0,function(i){return(i-n)*t}}function dtt(n,t){return t=t-(n=+n)?1/(t-n):0,function(i){return Math.max(0,Math.min(1,(i-n)*t))}}function hrt(n){for(var t=n.source,i=n.target,f=srt(t,i),r=[t],u;t!==f;)t=t.parent,r.push(t);for(u=r.length;i!==f;)r.splice(u,0,i),i=i.parent;return r}function ba(n){for(var i=[],t=n.parent;t!=null;)i.push(n),n=t,t=t.parent;return i.push(n),i}function srt(n,t){if(n===t)return n;for(var f=ba(n),e=ba(t),i=f.pop(),u=e.pop(),r=null;i===u;)r=i,i=f.pop(),u=e.pop();return r}function crt(n){n.fixed|=2}function art(n){n.fixed&=-7}function lrt(n){n.fixed|=4,n.px=n.x,n.py=n.y}function ort(n){n.fixed&=-5}function wa(n,t,i){var f=0,e=0,u;if(n.charge=0,!n.leaf)for(var o=n.nodes,h=o.length,s=-1,r;++s<h;)(r=o[s],r!=null)&&(wa(r,t,i),n.charge+=r.charge,f+=r.charge*r.cx,e+=r.charge*r.cy);n.point&&(n.leaf||(n.point.x+=Math.random()-.5,n.point.y+=Math.random()-.5),u=t*i[n.point.index],n.charge+=n.pointCharge=u,f+=u*n.point.x,e+=u*n.point.y),n.cx=f/n.charge,n.cy=e/n.charge}function br(t,i){return n.rebind(t,i,"sort","children","value"),t.nodes=t,t.links=grt,t}function kr(n,t){for(var u=[n],i,r;(n=u.pop())!=null;)if(t(n),(r=n.children)&&(i=r.length))while(--i>=0)u.push(r[i])}function st(n,t){for(var e=[n],u=[],i,f,r;(n=e.pop())!=null;)if(u.push(n),(r=n.children)&&(f=r.length))for(i=-1;++i<f;)e.push(r[i]);while((n=u.pop())!=null)t(n)}function frt(n){return n.children}function vrt(n){return n.value}function nut(n,t){return t.value-n.value}function grt(t){return n.merge(t.map(function(n){return(n.children||[]).map(function(t){return{source:n,target:t}})}))}function rut(n){return n.x}function iut(n){return n.y}function drt(n,t,i){n.y0=t,n.y=i}function oc(t){return n.range(t.length)}function ec(n){for(var i=-1,r=n[0].length,t=[];++i<r;)t[i]=0;return t}function wrt(n){for(var t=1,u=0,r=n[0][1],i,f=n.length;t<f;++t)(i=n[t][1])>r&&(u=t,r=i);return u}function krt(n){return n.reduce(brt,0)}function brt(n,t){return n+t[1]}function trt(n,t){return da(n,Math.ceil(Math.log(t.length)/Math.LN2+1))}function da(n,t){for(var i=-1,u=+n[0],f=(n[1]-u)/t,r=[];++i<=t;)r[i]=f*i+u;return r}function fit(t){return[n.min(t),n.max(t)]}function oit(n,t){return n.value-t.value}function cc(n,t){var i=n._pack_next;n._pack_next=t,t._pack_prev=n,t._pack_next=i,i._pack_prev=t}function ga(n,t){n._pack_next=t,t._pack_prev=n}function iv(n,t){var u=t.x-n.x,r=t.y-n.y,i=n.r+t.r;return.999*i*i>u*u+r*r}function fv(n){function h(n){b=Math.min(n.x-n.r,b),y=Math.max(n.x+n.r,y),p=Math.min(n.y-n.r,p),w=Math.max(n.y+n.r,w)}if((f=n.children)&&(s=f.length)){var f,b=Infinity,y=-Infinity,p=Infinity,w=-Infinity,i,r,t,u,e,o,s;if(f.forEach(nit),i=f[0],i.x=-i.r,i.y=0,h(i),s>1&&(r=f[1],r.x=r.r,r.y=0,h(r),s>2))for(t=f[2],rv(i,r,t),h(t),cc(i,t),i._pack_prev=t,cc(t,r),r=i._pack_next,u=3;u<s;u++){rv(i,r,t=f[u]);var c=0,l=1,a=1;for(e=r._pack_next;e!==r;e=e._pack_next,l++)if(iv(e,t)){c=1;break}if(c==1)for(o=i._pack_prev;o!==e._pack_prev;o=o._pack_prev,a++)if(iv(o,t))break;c?(l<a||l==a&&r.r<i.r?ga(i,r=e):ga(i=o,r),u--):(cc(i,t),r=t,h(t))}var k=(b+y)/2,d=(p+w)/2,v=0;for(u=0;u<s;u++)t=f[u],t.x-=k,t.y-=d,v=Math.max(v,t.r+Math.sqrt(t.x*t.x+t.y*t.y));n.r=v,f.forEach(gtt)}}function nit(n){n._pack_next=n._pack_prev=n}function gtt(n){delete n._pack_next,delete n._pack_prev}function ev(n,t,i,r){var f=n.children,u,e;if(n.x=t+=r*n.x,n.y=i+=r*n.y,n.r*=r,f)for(u=-1,e=f.length;++u<e;)ev(f[u],t,i,r)}function rv(n,t,i){var r=n.r+i.r,e=t.x-n.x,o=t.y-n.y,u,f,h,s;r&&(e||o)?(u=t.r+i.r,f=e*e+o*o,u*=u,r*=r,h=.5+(r-u)/(2*f),s=Math.sqrt(Math.max(0,2*u*(r+f)-(r-=f)*r-u*u))/(2*f),i.x=n.x+h*e+s*o,i.y=n.y+h*o-s*e):(i.x=n.x+r,i.y=n.y)}function uv(n,t){return n.parent==t.parent?1:2}function el(n){var t=n.children;return t.length?t[0]:n.t}function il(n){var i=n.children,t;return(t=i.length)?i[t-1]:n.t}function kit(n,t,i){var r=i/(t.i-n.i);t.c-=r,t.s+=i,n.c+=r,t.z+=i,t.m+=i}function bit(n){for(var i=0,f=0,u=n.children,r=u.length,t;--r>=0;)t=u[r],t.z+=i,t.m+=i,i+=t.s+(f+=t.c)}function dit(n,t,i){return n.a.parent===t.parent?n.a:i}function nrt(t){return 1+n.max(t,function(n){return n.y})}function git(n){return n.reduce(function(n,t){return n+t.x},0)/n.length}function ha(n){var t=n.children;return t&&t.length?ha(t[0]):n}function ca(n){var t=n.children,i;return t&&(i=t.length)?ca(t[i-1]):n}function lh(n){return{x:n.x,y:n.y,dx:n.dx,dy:n.dy}}function va(n,t){var u=n.x+t[3],f=n.y+t[0],i=n.dx-t[1]-t[3],r=n.dy-t[0]-t[2];return i<0&&(u+=i/2,i=0),r<0&&(f+=r/2,r=0),{x:u,y:f,dx:i,dy:r}}function rr(n){var i=n[0],t=n[n.length-1];return i<t?[i,t]:[t,i]}function pf(n){return n.rangeExtent?n.rangeExtent():rr(n.range())}function yit(n,t,i,r){var f=i(n[0],n[1]),u=r(t[0],t[1]);return function(n){return u(f(n))}}function ah(n,t){var f=0,e=n.length-1,u=n[f],i=n[e],r;return i<u&&(r=f,f=e,e=r,r=u,u=i,i=r),n[f]=t.floor(u),n[e]=t.ceil(i),n}function ag(n){return n?{floor:function(t){return Math.floor(t/n)*n},ceil:function(t){return Math.ceil(t/n)*n}}:kv}function bk(t,i,r,u){var o=[],s=[],f=0,e=Math.min(t.length,i.length)-1;for(t[e]<t[0]&&(t=t.slice().reverse(),i=i.slice().reverse());++f<=e;)o.push(r(t[f-1],t[f])),s.push(u(i[f-1],i[f]));return function(i){var r=n.bisect(t,i,1,e)-1;return s[r](o[r](i))}}function bl(n,t,i,r){function f(){var s=Math.min(n.length,t.length)>2?bk:yit,f=r?dtt:sn;return e=s(n,t,f,i),o=s(t,n,f,wi),u}function u(n){return e(n)}var e,o;return u.invert=function(n){return o(n)},u.domain=function(t){return arguments.length?(n=t.map(Number),f()):n},u.range=function(n){return arguments.length?(t=n,f()):t},u.rangeRound=function(n){return u.range(n).interpolate(dv)},u.clamp=function(n){return arguments.length?(r=n,f()):r},u.interpolate=function(n){return arguments.length?(i=n,f()):i},u.ticks=function(t){return dh(n,t)},u.tickFormat=function(t,i){return kh(n,t,i)},u.nice=function(t){return ry(n,t),f()},u.copy=function(){return bl(n,t,i,r)},f()}function ph(t,i){return n.rebind(t,i,"range","rangeRound","interpolate","clamp")}function ry(n,t){return ah(n,ag(fu(n,t)[2]))}function fu(n,t){t==null&&(t=10);var r=rr(n),f=r[1]-r[0],i=Math.pow(10,Math.floor(Math.log(f/t)/Math.LN10)),u=t/f*i;return u<=.15?i*=10:u<=.35?i*=5:u<=.75&&(i*=2),r[0]=Math.ceil(r[0]/i)*i,r[1]=Math.floor(r[1]/i)*i+i*.5,r[2]=i,r}function dh(t,i){return n.range.apply(n,fu(t,i))}function kh(t,i,u){var e=fu(t,i),f,o;if(u){if(f=gh.exec(u),f.shift(),f[8]==="s")return o=n.formatPrefix(Math.max(r(e[0]),r(e[1]))),f[7]||(f[7]="."+of(o.scale(e[2]))),f[8]="f",u=n.format(f.join("")),function(n){return u(o.scale(n))+o.symbol};f[7]||(f[7]="."+uk(f[8],e)),u=f.join("")}else u=",."+of(e[2])+"f";return n.format(u)}function of(n){return-Math.floor(Math.log(n)/Math.LN10+.01)}function uk(n,t){var i=of(t[2]);return n in lv?Math.abs(i-of(Math.max(r(t[0]),r(t[1]))))+ +(n!=="e"):i-(n==="%")*2}function vv(t,i,r,u){function e(n){return(r?Math.log(n<0?0:n):-Math.log(n>0?0:-n))/Math.log(i)}function o(n){return r?Math.pow(i,n):-Math.pow(i,-n)}function f(n){return t(e(n))}return f.invert=function(n){return o(t.invert(n))},f.domain=function(n){return arguments.length?(r=n[0]>=0,t.domain((u=n.map(Number)).map(e)),f):u},f.base=function(n){return arguments.length?(i=+n,t.domain(u.map(e)),f):i},f.nice=function(){var n=ah(u.map(e),r?Math:yv);return t.domain(n),u=n.map(o),f},f.ticks=function(){var h=rr(u),t=[],l=h[0],a=h[1],n=Math.floor(e(l)),s=Math.ceil(e(a)),c=i%1?2:i,f;if(isFinite(s-n)){if(r){for(;n<s;n++)for(f=1;f<c;f++)t.push(o(n)*f);t.push(o(n))}else for(t.push(o(n));n++<s;)for(f=c-1;f>0;f--)t.push(o(n)*f);for(n=0;t[n]<l;n++);for(s=t.length;t[s-1]>a;s--);t=t.slice(n,s)}return t},f.tickFormat=function(t,i){if(!arguments.length)return wc;arguments.length<2?i=wc:typeof i!="function"&&(i=n.format(i));var s=Math.max(.1,t/f.ticks().length),h=r?(u=1e-12,Math.ceil):(u=-1e-12,Math.floor),u;return function(n){return n/o(h(e(n)+u))<=s?i(n):""}},f.copy=function(){return vv(t.copy(),i,r,u)},ph(f,t)}function sl(n,t,i){function r(t){return n(u(t))}var u=se(t),f=se(1/t);return r.invert=function(t){return f(n.invert(t))},r.domain=function(t){return arguments.length?(n.domain((i=t.map(Number)).map(u)),r):i},r.ticks=function(n){return dh(i,n)},r.tickFormat=function(n,t){return kh(i,n,t)},r.nice=function(n){return r.domain(ry(i,n))},r.exponent=function(e){return arguments.length?(u=se(t=e),f=se(1/t),n.domain(i.map(u)),r):t},r.copy=function(){return sl(n.copy(),t,i)},ph(r,n)}function se(n){return function(t){return t<0?-Math.pow(-t,n):Math.pow(t,n)}}function cl(t,i){function r(n){return u[((f.get(n)||(i.t==="range"?f.set(n,t.push(n)):NaN))-1)%u.length]}function o(i,r){return n.range(t.length).map(function(n){return i+r*n})}var f,u,e;return r.domain=function(n){if(!arguments.length)return t;t=[],f=new ht;for(var e=-1,o=n.length,u;++e<o;)f.has(u=n[e])||f.set(u,t.push(u));return r[i.t].apply(r,i.a)},r.range=function(n){return arguments.length?(u=n,e=0,i={t:"range",a:arguments},r):u},r.rangePoints=function(n,f){arguments.length<2&&(f=0);var s=n[0],c=n[1],h=(c-s)/(Math.max(1,t.length-1)+f);return u=o(t.length<2?(s+c)/2:s+h*f/2,h),e=0,i={t:"rangePoints",a:arguments},r},r.rangeBands=function(n,f,s){arguments.length<2&&(f=0),arguments.length<3&&(s=f);var c=n[1]<n[0],l=n[+c],a=n[1-c],h=(a-l)/(t.length-f+2*s);return u=o(l+h*s,h),c&&u.reverse(),e=h*(1-f),i={t:"rangeBands",a:arguments},r},r.rangeRoundBands=function(n,f,s){arguments.length<2&&(f=0),arguments.length<3&&(s=f);var l=n[1]<n[0],c=n[+l],a=n[1-l],h=Math.floor((a-c)/(t.length-f+2*s)),v=a-c-(t.length-f)*h;return u=o(c+Math.round(v/2),h),l&&u.reverse(),e=Math.round(h*(1-f)),i={t:"rangeRoundBands",a:arguments},r},r.rangeBand=function(){return e},r.rangeExtent=function(){return rr(i.a[0])},r.copy=function(){return cl(t,i)},r.domain(t)}function ia(t,i){function f(){var f=0,e=i.length;for(r=[];++f<e;)r[f-1]=n.quantile(t,f/e);return u}function u(t){if(!isNaN(t=+t))return i[n.bisect(r,t)]}var r;return u.domain=function(n){return arguments.length?(t=n.filter(we).sort(ar),f()):t},u.range=function(n){return arguments.length?(i=n,f()):i},u.quantiles=function(){return r},u.invertExtent=function(n){return n=i.indexOf(n),n<0?[NaN,NaN]:[n>0?r[n-1]:t[0],n<r.length?r[n]:t[t.length-1]]},u.copy=function(){return ia(t,i)},f()}function ra(n,t,i){function r(t){return i[Math.max(0,Math.min(e,Math.floor(u*(t-n))))]}function f(){return u=i.length/(t-n),e=i.length-1,r}var u,e;return r.domain=function(i){return arguments.length?(n=+i[0],t=+i[i.length-1],f()):[n,t]},r.range=function(n){return arguments.length?(i=n,f()):i},r.invertExtent=function(t){return t=i.indexOf(t),t=t<0?NaN:t/u+n,[t,t+1/u]},r.copy=function(){return ra(n,t,i)},f()}function na(t,i){function r(r){if(r<=r)return i[n.bisect(t,r)]}return r.domain=function(n){return arguments.length?(t=n,r):t},r.range=function(n){return arguments.length?(i=n,r):i},r.invertExtent=function(n){return n=i.indexOf(n),[t[n-1],t[n]]},r.copy=function(){return na(t,i)},r}function fa(n){function t(n){return+n}return t.invert=t,t.domain=t.range=function(i){return arguments.length?(n=i.map(t),t):n},t.ticks=function(t){return dh(n,t)},t.tickFormat=function(t,i){return kh(n,t,i)},t.copy=function(){return fa(n)},t}function td(n){return n.innerRadius}function tg(n){return n.outerRadius}function pl(n){return n.startAngle}function al(n){return n.endAngle}function vl(n){function t(t){function a(){l.push("M",i(n(h),r))}for(var l=[],h=[],f=-1,v=t.length,c,p=o(e),y=o(s);++f<v;)u.call(this,c=t[f],f)?h.push([+p.call(this,c,f),+y.call(this,c,f)]):h.length&&(a(),h=[]);return h.length&&a(),l.length?l.join(""):null}var e=tr,s=su,u=or,i=g,f=i.key,r=.7;return t.x=function(n){return arguments.length?(e=n,t):e},t.y=function(n){return arguments.length?(s=n,t):s},t.defined=function(n){return arguments.length?(u=n,t):u},t.interpolate=function(n){return arguments.length?(f=typeof n=="function"?i=n:(i=ce.get(n)||g).key,t):f},t.tension=function(n){return arguments.length?(r=n,t):r},t}function g(n){return n.join("L")}function dd(n){return g(n)+"Z"}function gd(n){for(var u=0,r=n.length,t=n[0],i=[t[0],",",t[1]];++u<r;)i.push("H",(t[0]+(t=n[u])[0])/2,"V",t[1]);return r>1&&i.push("H",t[0]),i.join("")}function kc(n){for(var r=0,u=n.length,t=n[0],i=[t[0],",",t[1]];++r<u;)i.push("V",(t=n[r])[1],"H",t[0]);return i.join("")}function hc(n){for(var r=0,u=n.length,t=n[0],i=[t[0],",",t[1]];++r<u;)i.push("H",(t=n[r])[0],"V",t[1]);return i.join("")}function cg(n,t){return n.length<4?g(n):n[1]+ke(n.slice(1,n.length-1),ul(n,t))}function lg(n,t){return n.length<3?g(n):n[0]+ke((n.push(n[0]),n),ul([n[n.length-2]].concat(n,[n[1]]),t))}function sg(n,t){return n.length<3?g(n):n[0]+ke(n,ul(n,t))}function ke(n,t){var o,s;if(t.length<1||n.length!=t.length&&n.length!=t.length+2)return g(n);var c=n.length!=t.length,e="",h=n[0],i=n[1],f=t[0],r=f,u=1;if(c&&(e+="Q"+(i[0]-f[0]*2/3)+","+(i[1]-f[1]*2/3)+","+i[0]+","+i[1],h=n[1],u=2),t.length>1)for(r=t[1],i=n[u],u++,e+="C"+(h[0]+f[0])+","+(h[1]+f[1])+","+(i[0]-r[0])+","+(i[1]-r[1])+","+i[0]+","+i[1],o=2;o<t.length;o++,u++)i=n[u],r=t[o],e+="S"+(i[0]-r[0])+","+(i[1]-r[1])+","+i[0]+","+i[1];return c&&(s=n[u],e+="Q"+(i[0]+r[0]*2/3)+","+(i[1]+r[1]*2/3)+","+s[0]+","+s[1]),e}function ul(n,t){for(var u=[],e=(1-t)/2,r,o=n[0],i=n[1],f=1,s=n.length;++f<s;)r=o,o=i,i=n[f],u.push([e*(i[0]-r[0]),e*(i[1]-r[1])]);return u}function dl(n){if(n.length<3)return g(n);var s=1,o=n.length,t=n[0],f=t[0],i=t[1],u=[f,f,f,(t=n[1])[0]],r=[i,i,i,t[1]],e=[f,",",i,"L",tt(oi,u),",",tt(oi,r)];for(n.push(n[o-1]);++s<=o;)t=n[s],u.shift(),u.push(t[0]),r.shift(),r.push(t[1]),sh(e,u,r);return n.pop(),e.push("L",t),e.join("")}function og(n){if(n.length<4)return g(n);for(var f=[],u=-1,e=n.length,t,i=[0],r=[0];++u<3;)t=n[u],i.push(t[0]),r.push(t[1]);for(f.push(tt(oi,i)+","+tt(oi,r)),--u;++u<e;)t=n[u],i.shift(),i.push(t[0]),r.shift(),r.push(t[1]),sh(f,i,r);return f.join("")}function bd(n){for(var f,u=-1,e=n.length,o=e+4,t,i=[],r=[];++u<4;)t=n[u%e],i.push(t[0]),r.push(t[1]);for(f=[tt(oi,i),",",tt(oi,r)],--u;++u<o;)t=n[u%e],i.shift(),i.push(t[0]),r.shift(),r.push(t[1]),sh(f,i,r);return f.join("")}function ed(n,t){var r=n.length-1;if(r)for(var e=n[0][0],o=n[0][1],s=n[r][0]-e,h=n[r][1]-o,u=-1,i,f;++u<=r;)i=n[u],f=u/r,i[0]=t*i[0]+(1-t)*(e+f*s),i[1]=t*i[1]+(1-t)*(o+f*h);return dl(n)}function tt(n,t){return n[0]*t[0]+n[1]*t[1]+n[2]*t[2]+n[3]*t[3]}function sh(n,t,i){n.push("C",tt(kl,t),",",tt(kl,i),",",tt(ua,t),",",tt(ua,i),",",tt(oi,t),",",tt(oi,i))}function eh(n,t){return(t[1]-n[1])/(t[0]-n[0])}function rd(n){for(var i=0,e=n.length-1,t=[],f=n[0],r=n[1],u=t[0]=eh(f,r);++i<e;)t[i]=(u+(u=eh(f=r,r=n[i+1])))/2;return t[i]=u,t}function sk(n){for(var c=[],e,o,s,f,u=rd(n),i=-1,h=n.length-1;++i<h;)e=eh(n[i],n[i+1]),r(e)<t?u[i]=u[i+1]=0:(o=u[i]/e,s=u[i+1]/e,f=o*o+s*s,f>9&&(f=e*3/Math.sqrt(f),u[i]=f*o,u[i+1]=f*s));for(i=-1;++i<=h;)f=(n[Math.min(h,i+1)][0]-n[Math.max(0,i-1)][0])/(6*(1+u[i]*u[i])),c.push([f||0,u[i]*f||0]);return c}function ud(n){return n.length<3?g(n):n[0]+ke(n,sk(n))}function hl(n){for(var t,u=-1,f=n.length,i,r;++u<f;)t=n[u],i=t[0],r=t[1]+dt,t[0]=i*Math.cos(r),t[1]=i*Math.sin(r);return n}function sa(n){function t(t){function d(){p.push("M",i(n(w),s),a,l(n(y.reverse()),s),"Z")}for(var p=[],y=[],w=[],c=-1,g=t.length,v,tt=o(e),nt=o(f),it=e===r?function(){return b}:o(r),rt=f===u?function(){return k}:o(u),b,k;++c<g;)h.call(this,v=t[c],c)?(y.push([b=+tt.call(this,v,c),k=+nt.call(this,v,c)]),w.push([+it.call(this,v,c),+rt.call(this,v,c)])):y.length&&(d(),y=[],w=[]);return y.length&&d(),p.length?p.join(""):null}var e=tr,r=tr,f=0,u=su,h=or,i=g,c=i.key,l=i,a="L",s=.7;return t.x=function(n){return arguments.length?(e=r=n,t):r},t.x0=function(n){return arguments.length?(e=n,t):e},t.x1=function(n){return arguments.length?(r=n,t):r},t.y=function(n){return arguments.length?(f=u=n,t):u},t.y0=function(n){return arguments.length?(f=n,t):f},t.y1=function(n){return arguments.length?(u=n,t):u},t.defined=function(n){return arguments.length?(h=n,t):h},t.interpolate=function(n){return arguments.length?(c=typeof n=="function"?i=n:(i=ce.get(n)||g).key,l=i.reverse||i,a=i.closed?"M":"L",t):c},t.tension=function(n){return arguments.length?(s=n,t):s},t}function hd(n){return n.radius}function av(n){return[n.x,n.y]}function yd(n){return function(){var r=n.apply(this,arguments),i=r[0],t=r[1]+dt;return[i*Math.cos(t),i*Math.sin(t)]}}function pd(){return 64}function wd(){return"circle"}function hv(n){var t=Math.sqrt(n/f);return"M0,"+t+"A"+t+","+t+" 0 1,1 0,"+-t+"A"+t+","+t+" 0 1,1 0,"+t+"Z"}function pr(n,t){return yu(n,l),n.id=t,n}function ao(n,t,i,r){var u=n.id;return ui(n,typeof i=="function"?function(n,f,e){n.__transition__[u].tween.set(t,r(i.call(n,n.__data__,f,e)))}:(i=r(i),function(n){n.__transition__[u].tween.set(t,i)}))}function ld(n){return n==null&&(n=""),function(){this.textContent=n}}function wf(t,i,r,u){var e=t.__transition__||(t.__transition__={active:0,count:0}),f=e[r],o;f||(o=u.time,f=e[r]={tween:new ht,time:o,ease:u.ease,delay:u.delay,duration:u.duration},++e.count,n.timer(function(u){function y(u){if(e.active>r)return s();e.active=r,f.event&&f.event.start.call(t,l,i),f.tween.forEach(function(n,r){(r=r.call(t,l,i))&&c.push(r)}),n.timer(function(){return h.c=v(u||1)?or:v,1},0,o)}function v(n){if(e.active!==r)return s();for(var o=n/p,h=w(o),u=c.length;u>0;)c[--u].call(t,h);if(o>=1)return f.event&&f.event.end.call(t,l,i),s()}function s(){return--e.count?delete e[r]:delete t.__transition__,1}var l=t.__data__,w=f.ease,a=f.delay,p=f.duration,h=yt,c=[];if(h.t=a+o,a<=u)return y(u-a);h.c=y},0,o))}function la(n,t){n.attr("transform",function(n){return"translate("+t(n)+",0)"})}function aa(n,t){n.attr("transform",function(n){return"translate(0,"+t(n)+")"})}function es(n){return n.toISOString()}function ss(t,i,r){function u(n){return t(n)}function f(t,r){var e=t[1]-t[0],f=e/r,u=n.bisect(fe,f);return u==fe.length?[i.year,fu(t.map(function(n){return n/31536e6}),r)[2]]:u?i[f/fe[u-1]<fe[u]/f?u-1:u]:[ak,fu(t,r)[2]]}return u.invert=function(n){return yi(t.invert(n))},u.domain=function(n){return arguments.length?(t.domain(n),u):t.domain().map(yi)},u.nice=function(n,t){function r(i){return!isNaN(i)&&!n.range(i,yi(+i+1),t).length}var e=u.domain(),o=rr(e),i=n==null?f(o,10):typeof n=="number"&&f(o,n);return i&&(n=i[0],t=i[1]),u.domain(ah(e,t>1?{floor:function(t){while(r(t=n.floor(t)))t=yi(t-1);return t},ceil:function(t){while(r(t=n.ceil(t)))t=yi(+t+1);return t}}:n))},u.ticks=function(n,t){var i=rr(u.domain()),r=n==null?f(i,10):typeof n=="number"?f(i,n):!n.range&&[{range:n},t];return r&&(n=r[0],t=r[1]),n.range(i[0],yi(+i[1]+1),t<1?1:t)},u.tickFormat=function(){return r},u.copy=function(){return ss(t.copy(),i,r)},ph(u,t)}function yi(n){return new Date(n)}function yk(n){return JSON.parse(n.responseText)}function ek(n){var t=ut.createRange();return t.selectNode(ut.body),t.createContextualFragment(n.responseText)}var n={version:"3.4.11"},vo,r,ni,gr,io,np,yu,e,ne,lt,dc,ye,lr,wy,no,fh,he,hw,le,ae,tu,uu,sf,ef,bu,pu,yt,fc,bp,gh,pp,i,v,ot,sc,hu,bc,ac,tf,ei,b,cu,hf,vi,pi,pt,si,ri,ct,hr,cr,gt,nt,ih,vr,fs,ts,bt,df,du,ku,wu,kb,it,ds,ki,ks,ys,ps,ro,ho,lu,fr,hi,gi,go,ko,vu,vs,iu,bf,ie,pa,co,nv,tv,kv,lv,wc,yv,dt,yl,ce,rh,yr,wh,l,rc,di,cf,so,ka,wo,wl;Date.now||(Date.now=function(){return+new Date});var vw=[].slice,ti=function(n){return vw.call(n)},ut=document,at=ut.documentElement,w=window;try{ti(at.childNodes)[0].nodeType}catch(fut){ti=function(n){for(var t=n.length,i=new Array(t);t--;)i[t]=n[t];return i}}try{ut.createElement("div").style.setProperty("opacity",0,"")}catch(uut){var uf=w.Element.prototype,wk=uf.setAttribute,gk=uf.setAttributeNS,hb=w.CSSStyleDeclaration.prototype,ok=hb.setProperty;uf.setAttribute=function(n,t){wk.call(this,n,t+"")},uf.setAttributeNS=function(n,t,i){gk.call(this,n,t,i+"")},hb.setProperty=function(n,t,i){ok.call(this,n,t+"",i)}}n.ascending=ar,n.descending=function(n,t){return t<n?-1:t>n?1:t>=n?0:NaN},n.min=function(n,t){var r=-1,f=n.length,i,u;if(arguments.length===1){while(++r<f&&!((i=n[r])!=null&&i<=i))i=undefined;while(++r<f)(u=n[r])!=null&&i>u&&(i=u)}else{while(++r<f&&!((i=t.call(n,n[r],r))!=null&&i<=i))i=undefined;while(++r<f)(u=t.call(n,n[r],r))!=null&&i>u&&(i=u)}return i},n.max=function(n,t){var r=-1,f=n.length,i,u;if(arguments.length===1){while(++r<f&&!((i=n[r])!=null&&i<=i))i=undefined;while(++r<f)(u=n[r])!=null&&u>i&&(i=u)}else{while(++r<f&&!((i=t.call(n,n[r],r))!=null&&i<=i))i=undefined;while(++r<f)(u=t.call(n,n[r],r))!=null&&u>i&&(i=u)}return i},n.extent=function(n,t){var r=-1,e=n.length,i,u,f;if(arguments.length===1){while(++r<e&&!((i=f=n[r])!=null&&i<=i))i=f=undefined;while(++r<e)(u=n[r])!=null&&(i>u&&(i=u),f<u&&(f=u))}else{while(++r<e&&!((i=f=t.call(n,n[r],r))!=null&&i<=i))i=undefined;while(++r<e)(u=t.call(n,n[r],r))!=null&&(i>u&&(i=u),f<u&&(f=u))}return[i,f]},n.sum=function(n,t){var u=0,f=n.length,r,i=-1;if(arguments.length===1)while(++i<f)isNaN(r=+n[i])||(u+=r);else while(++i<f)isNaN(r=+t.call(n,n[i],i))||(u+=r);return u},n.mean=function(n,t){var e=0,f=n.length,r,i=-1,u=f;if(arguments.length===1)while(++i<f)we(r=n[i])?e+=r:--u;else while(++i<f)we(r=t.call(n,n[i],i))?e+=r:--u;return u?e/u:undefined},n.quantile=function(n,t){var f=(n.length-1)*t+1,i=Math.floor(f),r=+n[i-1],u=f-i;return u?r+u*(n[i]-r):r},n.median=function(t,i){return arguments.length>1&&(t=t.map(i)),t=t.filter(we),t.length?n.quantile(t.sort(ar),.5):undefined},vo=ub(ar),n.bisectLeft=vo.left,n.bisect=n.bisectRight=vo.right,n.bisector=function(n){return ub(n.length===1?function(t,i){return ar(n(t),i)}:n)},n.shuffle=function(n){for(var t=n.length,r,i;t;)i=Math.random()*t--|0,r=n[t],n[t]=n[i],n[i]=r;return n},n.permute=function(n,t){for(var i=t.length,r=new Array(i);i--;)r[i]=n[t[i]];return r},n.pairs=function(n){for(var i=0,t=n.length-1,f,r=n[0],u=new Array(t<0?0:t);i<t;)u[i]=[f=r,r=n[++i]];return u},n.zip=function(){var t,i,u;if(!(i=arguments.length))return[];for(var r=-1,f=n.min(arguments,ig),e=new Array(f);++r<f;)for(t=-1,u=e[r]=new Array(i);++t<i;)u[t]=arguments[t][r];return e},n.transpose=function(t){return n.zip.apply(n,t)},n.keys=function(n){var i=[],t;for(t in n)i.push(t);return i},n.values=function(n){var i=[],t;for(t in n)i.push(n[t]);return i},n.entries=function(n){var i=[],t;for(t in n)i.push({key:t,value:n[t]});return i},n.merge=function(n){for(var u=n.length,f,e=-1,t=0,i,r;++e<u;)t+=n[e].length;for(i=new Array(t);--u>=0;)for(r=n[u],f=r.length;--f>=0;)i[--t]=r[f];return i},r=Math.abs,n.range=function(n,t,i){if(arguments.length<3&&(i=1,arguments.length<2&&(t=n,n=0)),(t-n)/i==Infinity)throw new Error("infinite range");var e=[],u=kd(r(i)),o=-1,f;if(n*=u,t*=u,i*=u,i<0)while((f=n+i*++o)>t)e.push(f/u);else while((f=n+i*++o)<t)e.push(f/u);return e},n.map=function(n){var i=new ht,t;if(n instanceof ht)n.forEach(function(n,t){i.set(n,t)});else for(t in n)i.set(t,n[t]);return i},aw(ht,{has:gw,get:function(n){return this[ni+n]},set:function(n,t){return this[ni+n]=t},remove:od,keys:cb,values:function(){var n=[];return this.forEach(function(t,i){n.push(i)}),n},entries:function(){var n=[];return this.forEach(function(t,i){n.push({key:t,value:i})}),n},size:nk,empty:ik,forEach:function(n){for(var t in this)t.charCodeAt(0)===gr&&n.call(this,t.substring(1),this[t])}}),ni="\x00",gr=ni.charCodeAt(0),n.nest=function(){function r(n,e,o){if(o>=i.length)return u?u.call(t,e):f?e.sort(f):e;for(var a=-1,p=e.length,y=i[o++],l,s,c,h=new ht,v;++a<p;)(v=h.get(l=y(s=e[a])))?v.push(s):h.set(l,[s]);return n?(s=n(),c=function(t,i){s.set(t,r(n,i,o))}):(s={},c=function(t,i){s[t]=r(n,i,o)}),h.forEach(c),s}function e(n,t){if(t>=i.length)return n;var r=[],u=o[t++];return n.forEach(function(n,i){r.push({key:n,values:e(i,t)})}),u?r.sort(function(n,t){return u(n.key,t.key)}):r}var t={},i=[],o=[],f,u;return t.map=function(n,t){return r(t,n,0)},t.entries=function(t){return e(r(n.map,t,0),0)},t.key=function(n){return i.push(n),t},t.sortKeys=function(n){return o[i.length-1]=n,t},t.sortValues=function(n){return f=n,t},t.rollup=function(n){return u=n,t},t},n.set=function(n){var r=new fo,t,i;if(n)for(t=0,i=n.length;t<i;++t)r.add(n[t]);return r},aw(fo,{has:gw,add:function(n){return this[ni+n]=!0,n},remove:function(n){return n=ni+n,n in this&&delete this[n]},values:cb,size:nk,empty:ik,forEach:function(n){for(var t in this)t.charCodeAt(0)===gr&&n.call(this,t.substring(1))}}),n.behavior={},n.rebind=function(n,t){for(var r=1,u=arguments.length,i;++r<u;)n[i=arguments[r]]=cd(n,t,t[i]);return n},io=["webkit","ms","moz","Moz","o","O"],n.dispatch=function(){for(var n=new oo,t=-1,i=arguments.length;++t<i;)n[arguments[t]]=pb(n);return n},oo.prototype.on=function(n,t){var r=n.indexOf("."),i="";if(r>=0&&(i=n.substring(r+1),n=n.substring(0,r)),n)return arguments.length<2?this[n].on(i):this[n].on(i,t);if(arguments.length===2){if(t==null)for(n in this)if(this.hasOwnProperty(n))this[n].on(i,null);return this}},n.event=null,n.requote=function(n){return n.replace(np,"\\$&")},np=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,yu={}.__proto__?function(n,t){n.__proto__=t}:function(n,t){for(var i in t)n[i]=t[i]};var hh=function(n,t){return t.querySelector(n)},yh=function(n,t){return t.querySelectorAll(n)},ad=at.matches||at[eo(at,"matchesSelector")],tp=function(n,t){return ad.call(n,t)};typeof Sizzle=="function"&&(hh=function(n,t){return Sizzle(n,t)[0]||null},yh=Sizzle,tp=Sizzle.matchesSelector),n.selection=function(){return dc},e=n.selection.prototype=[],e.select=function(n){var s=[],i,f,e,t,r,h,u,o;for(n=uc(n),r=-1,h=this.length;++r<h;)for(s.push(i=[]),i.parentNode=(e=this[r]).parentNode,u=-1,o=e.length;++u<o;)(t=e[u])?(i.push(f=n.call(t,t.__data__,u,r)),f&&"__data__"in t&&(f.__data__=t.__data__)):i.push(null);return kt(s)},e.selectAll=function(n){var o=[],e,t,i,f;for(n=gy(n),i=-1,f=this.length;++i<f;)for(var u=this[i],r=-1,s=u.length;++r<s;)(t=u[r])&&(o.push(e=ti(n.call(t,t.__data__,r,i))),e.parentNode=t);return kt(o)},ne={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/"},n.ns={prefix:ne,qualify:function(n){var i=n.indexOf(":"),t=n;return i>=0&&(t=n.substring(0,i),n=n.substring(i+1)),ne.hasOwnProperty(t)?{space:ne[t],local:n}:n}},e.attr=function(t,i){if(arguments.length<2){if(typeof t=="string"){var r=this.node();return t=n.ns.qualify(t),t.local?r.getAttributeNS(t.space,t.local):r.getAttribute(t)}for(i in t)this.each(ky(i,t[i]));return this}return this.each(ky(t,i))},e.classed=function(n,t){if(arguments.length<2){if(typeof n=="string"){var r=this.node(),u=(n=ep(n)).length,i=-1;if(t=r.classList){while(++i<u)if(!t.contains(n[i]))return!1}else for(t=r.getAttribute("class");++i<u;)if(!ip(n[i]).test(t))return!1;return!0}for(t in n)this.each(op(t,n[t]));return this}return this.each(op(n,t))},e.style=function(n,t,i){var r=arguments.length;if(r<3){if(typeof n!="string"){r<2&&(t="");for(i in n)this.each(fp(i,n[i],t));return this}if(r<2)return w.getComputedStyle(this.node(),null).getPropertyValue(n);i=""}return this.each(fp(n,t,i))},e.property=function(n,t){if(arguments.length<2){if(typeof n=="string")return this.node()[n];for(t in n)this.each(rp(t,n[t]));return this}return this.each(rp(n,t))},e.text=function(n){return arguments.length?this.each(typeof n=="function"?function(){var t=n.apply(this,arguments);this.textContent=t==null?"":t}:n==null?function(){this.textContent=""}:function(){this.textContent=n}):this.node().textContent},e.html=function(n){return arguments.length?this.each(typeof n=="function"?function(){var t=n.apply(this,arguments);this.innerHTML=t==null?"":t}:n==null?function(){this.innerHTML=""}:function(){this.innerHTML=n}):this.node().innerHTML},e.append=function(n){return n=up(n),this.select(function(){return this.appendChild(n.apply(this,arguments))})},e.insert=function(n,t){return n=up(n),t=uc(t),this.select(function(){return this.insertBefore(n.apply(this,arguments),t.apply(this,arguments)||null)})},e.remove=function(){return this.each(function(){var n=this.parentNode;n&&n.removeChild(this)})},e.data=function(n,t){function h(n,i){var r,l=n.length,y=i.length,k=Math.min(l,y),v=new Array(y),c=new Array(y),p=new Array(l),f,h;if(t){var a=new ht,b=new ht,w=[],s;for(r=-1;++r<l;)s=t.call(f=n[r],f.__data__,r),a.has(s)?p[r]=f:a.set(s,f),w.push(s);for(r=-1;++r<y;)s=t.call(i,h=i[r],r),(f=a.get(s))?(v[r]=f,f.__data__=h):b.has(s)||(c[r]=nc(h)),b.set(s,h),a.remove(s);for(r=-1;++r<l;)a.has(w[r])&&(p[r]=n[r])}else{for(r=-1;++r<k;)f=n[r],h=i[r],f?(f.__data__=h,v[r]=f):c[r]=nc(h);for(;r<y;++r)c[r]=nc(i[r]);for(;r<l;++r)p[r]=n[r]}c.update=v,c.parentNode=v.parentNode=p.parentNode=n.parentNode,o.push(c),u.push(v),e.push(p)}var i=-1,f=this.length,r,s;if(!arguments.length){for(n=new Array(f=(r=this[0]).length);++i<f;)(s=r[i])&&(n[i]=s.__data__);return n}var o=sy([]),u=kt([]),e=kt([]);if(typeof n=="function")while(++i<f)h(r=this[i],n.call(r,r.parentNode.__data__,i));else while(++i<f)h(r=this[i],n);return u.enter=function(){return o},u.exit=function(){return e},u},e.datum=function(n){return arguments.length?this.property("__data__",n):this.property("__data__")},e.filter=function(n){var o=[],u,f,r,t,s,i,e;for(typeof n!="function"&&(n=hy(n)),t=0,s=this.length;t<s;t++)for(o.push(u=[]),u.parentNode=(f=this[t]).parentNode,i=0,e=f.length;i<e;i++)(r=f[i])&&n.call(r,r.__data__,i,t)&&u.push(r);return kt(o)},e.order=function(){for(var i=-1,f=this.length;++i<f;)for(var u=this[i],r=u.length-1,n=u[r],t;--r>=0;)(t=u[r])&&(n&&n!==t.nextSibling&&n.parentNode.insertBefore(t,n),n=t);return this},e.sort=function(n){n=id.apply(this,arguments);for(var t=-1,i=this.length;++t<i;)this[t].sort(n);return this.order()},e.each=function(n){return ui(this,function(t,i,r){n.call(t,t.__data__,i,r)})},e.call=function(n){var t=ti(arguments);return n.apply(t[0]=this,t),this},e.empty=function(){return!this.node()},e.node=function(){for(var i,n=0,u=this.length;n<u;n++)for(var r=this[n],t=0,f=r.length;t<f;t++)if(i=r[t],i)return i;return null},e.size=function(){var n=0;return this.each(function(){++n}),n},lt=[],n.selection.enter=sy,n.selection.enter.prototype=lt,lt.append=e.append,lt.empty=e.empty,lt.node=e.node,lt.call=e.call,lt.size=e.size,lt.select=function(n){for(var o=[],u,c,h,t,f,i,e,r=-1,s=this.length;++r<s;)for(h=(t=this[r]).update,o.push(u=[]),u.parentNode=t.parentNode,i=-1,e=t.length;++i<e;)(f=t[i])?(u.push(h[i]=c=n.call(t.parentNode,f.__data__,i,r)),c.__data__=f.__data__):u.push(null);return kt(o)},lt.insert=function(n,t){return arguments.length<2&&(t=sd(this)),e.insert.call(this,n,t)},e.transition=function(){for(var o=di||++rc,f=[],e,t,h=cf||{time:Date.now(),ease:yg,delay:0,duration:250},n=-1,r=this.length;++n<r;){f.push(e=[]);for(var u=this[n],i=-1,s=u.length;++i<s;)(t=u[i])&&wf(t,i,o,h),e.push(t)}return pr(f,o)},e.interrupt=function(){return this.each(ue)},n.select=function(n){var t=[typeof n=="string"?hh(n,ut):n];return t.parentNode=at,kt([t])},n.selectAll=function(n){var t=ti(typeof n=="string"?yh(n,ut):n);return t.parentNode=at,kt([t])},dc=n.select(at),e.on=function(n,t,i){var r=arguments.length;if(r<3){if(typeof n!="string"){r<2&&(t=!1);for(i in n)this.each(oy(i,n[i],t));return this}if(r<2)return(r=this.node()["__on"+n])&&r._;i=!1}return this.each(oy(n,t,i))},ye=n.map({mouseenter:"mouseover",mouseleave:"mouseout"}),ye.forEach(function(n){"on"+n in ut&&ye.remove(n)}),lr="onselectstart"in ut?null:eo(at.style,"userSelect"),wy=0,n.mouse=function(n){return lc(n,po())},no=/WebKit/.test(w.navigator.userAgent)?-1:0,n.touches=function(n,t){return arguments.length<2&&(t=po().touches),t?ti(t).map(function(t){var i=lc(n,t);return i.identifier=t.identifier,i}):[]},n.behavior.drag=function(){function i(){this.on("mousedown.drag",f).on("touchstart.drag",e)}function r(i,r,f,e,o){return function(){function w(){var n=r(y,h),i,t;n&&(i=n[0]-c[0],t=n[1]-c[1],p|=i|t,c=n,v({type:"drag",x:n[0]+s[0],y:n[1]+s[1],dx:i,dy:t}))}function b(){if(r(y,h)){d.on(e+l,null).on(o+l,null);g(p&&n.event.target===k),v({type:"dragend"})}}var a=this,k=n.event.target,y=a.parentNode,v=u.of(a,arguments),p=0,h=i(),l=".drag"+(h==null?"":"-"+h),s,d=n.select(f()).on(e+l,w).on(o+l,b),g=ee(),c=r(y,h);t?(s=t.apply(a,arguments),s=[s.x-c[0],s.y-c[1]]):s=[0,0],v({type:"dragstart"})}}var u=lo(i,"drag","dragstart","dragend"),t=null,f=r(c,n.mouse,ug,"mousemove","mouseup"),e=r(fg,n.touch,hg,"touchmove","touchend");return i.origin=function(n){return arguments.length?(t=n,i):t},n.rebind(i,u,"on")};var f=Math.PI,d=2*f,y=f/2,t=1e-6,fl=t*t,u=f/180,s=180/f;var to=Math.SQRT2,vh=2,fw=4;n.interpolateZoom=function(n,t){function p(n){var s=n*y,r,t;return v?(r=uw(u),t=i/(vh*o)*(r*rg(to*s+u)-ng(u)),[h+t*e,a+t*f,i*r/uw(to*s+u)]):[h+n*e,a+n*f,i*Math.exp(to*s)]}var h=n[0],a=n[1],i=n[2],b=t[0],w=t[1],r=t[2],e=b-h,f=w-a,c=e*e+f*f,o=Math.sqrt(c),l=(r*r-i*i+fw*c)/(2*i*vh*o),s=(r*r-i*i-fw*c)/(2*r*vh*o),u=Math.log(Math.sqrt(l*l+1)-l),k=Math.log(Math.sqrt(s*s+1)-s),v=k-u,y=(v||Math.log(r/i))/to;return p.duration=y*1e3,p},n.behavior.zoom=function(){function i(n){n.on(b,ut).on(hw+".zoom",ht).on("dblclick.zoom",st).on(tt,rt)}function c(n){return[(n[0]-t.x)/t.k,(n[1]-t.y)/t.k]}function ct(n){return[n[0]*t.k+t.x,n[1]*t.k+t.y]}function h(n){t.k=Math.max(y[0],Math.min(y[1],n))}function o(n,i){i=ct(i),t.x+=n[0]-i[0],t.y+=n[1]-i[1]}function d(){s&&s.domain(g.range().map(function(n){return(n-t.x)/t.k}).map(g.invert)),l&&l.domain(nt.range().map(function(n){return(n-t.y)/t.k}).map(nt.invert))}function f(n){n({type:"zoomstart"})}function r(n){d(),n({type:"zoom",scale:t.k,translate:[t.x,t.y]})}function e(n){n({type:"zoomend"})}function ut(){function l(){s=1,o(n.mouse(t),p),r(i)}function a(){y.on(ot,null).on(et,null);h(s&&n.event.target===v),e(i)}var t=this,v=n.event.target,i=u.of(t,arguments),s=0,y=n.select(w).on(ot,l).on(et,a),p=c(n.mouse(t)),h=ee();ue.call(t),f(i)}function rt(){function k(){var r=n.touches(s);return d=t.k,r.forEach(function(n){n.identifier in i&&(i[n.identifier]=c(n))}),r}function w(){var tt=n.event.target,c,e,d,u,s,f,rt;n.select(tt).on(ft,g).on(it,nt);for(y.push(tt),c=n.event.changedTouches,e=0,d=c.length;e<d;++e)i[c[e].identifier]=null;if(u=k(),s=Date.now(),u.length===1)s-p<500&&(f=u[0],rt=i[f.identifier],h(t.k*2),o(f,rt),fi(),r(l)),p=s;else if(u.length>1){var f=u[0],a=u[1],b=f[0]-a[0],w=f[1]-a[1];v=b*b+w*w}}function g(){for(var w=n.touches(s),t,c,u,e,f,y,a=0,b=w.length;a<b;++a,e=null)if(u=w[a],e=i[u.identifier]){if(c)break;t=u,c=e}e&&(f=(f=u[0]-t[0])*f+(f=u[1]-t[1])*f,y=v&&Math.sqrt(f/v),t=[(t[0]+u[0])/2,(t[1]+u[1])/2],c=[(c[0]+e[0])/2,(c[1]+e[1])/2],h(y*d)),p=null,o(t,c),r(l)}function nt(){var r,t,u,f;if(n.event.touches.length){for(r=n.event.changedTouches,t=0,u=r.length;t<u;++t)delete i[r[t].identifier];for(f in i)return void k()}n.selectAll(y).on(a,null);ot.on(b,ut).on(tt,rt);et(),e(l)}var s=this,l=u.of(s,arguments),i={},v=0,d,a=".zoom-"+n.event.changedTouches[0].identifier,ft="touchmove"+a,it="touchend"+a,y=[],ot=n.select(s).on(b,null).on(tt,w),et=ee();ue.call(s),w(),f(l)}function ht(){var i=u.of(this,arguments);a?clearTimeout(a):(it=c(ft=k||n.mouse(this)),ue.call(this),f(i)),a=setTimeout(function(){a=null,e(i)},50),fi(),h(Math.pow(2,he()*.002)*t.k),o(ft,it),r(i)}function st(){var i=u.of(this,arguments),l=n.mouse(this),a=c(l),s=Math.log(t.k)/Math.LN2;f(i),h(Math.pow(2,n.event.shiftKey?Math.ceil(s)-1:Math.floor(s)+1)),o(l,a),r(i),e(i)}var t={x:0,y:0,k:1},it,ft,k,v=[960,500],y=fh,b="mousedown.zoom",ot="mousemove.zoom",et="mouseup.zoom",a,tt="touchstart.zoom",p,u=lo(i,"zoomstart","zoom","zoomend"),g,s,nt,l;return i.event=function(i){i.each(function(){var i=u.of(this,arguments),o=t;di?n.select(this).transition().each("start.zoom",function(){t=this.__chart__||{x:0,y:0,k:1},f(i)}).tween("zoom:zoom",function(){var u=v[0],h=v[1],e=u/2,f=h/2,s=n.interpolateZoom([(e-t.x)/t.k,(f-t.y)/t.k,u/t.k],[(e-o.x)/o.k,(f-o.y)/o.k,u/o.k]);return function(n){var h=s(n),o=u/h[2];this.__chart__=t={x:e-h[0]*o,y:f-h[1]*o,k:o},r(i)}}).each("end.zoom",function(){e(i)}):(this.__chart__=t,f(i),r(i),e(i))})},i.translate=function(n){return arguments.length?(t={x:+n[0],y:+n[1],k:t.k},d(),i):[t.x,t.y]},i.scale=function(n){return arguments.length?(t={x:t.x,y:t.y,k:+n},d(),i):t.k},i.scaleExtent=function(n){return arguments.length?(y=n==null?fh:[+n[0],+n[1]],i):y},i.center=function(n){return arguments.length?(k=n&&[+n[0],+n[1]],i):k},i.size=function(n){return arguments.length?(v=n&&[+n[0],+n[1]],i):v},i.x=function(n){return arguments.length?(s=n,g=n.copy(),t={x:0,y:0,k:1},i):s},i.y=function(n){return arguments.length?(l=n,nt=n.copy(),t={x:0,y:0,k:1},i):l},n.rebind(i,u,"on")},fh=[0,Infinity],hw="onwheel"in ut?(he=function(){return-n.event.deltaY*(n.event.deltaMode?120:1)},"wheel"):"onmousewheel"in ut?(he=function(){return n.event.wheelDelta},"mousewheel"):(he=function(){return-n.event.detail},"MozMousePixelScroll"),n.color=ci,ci.prototype.toString=function(){return this.rgb()+""},n.hsl=et,le=et.prototype=new ci,le.brighter=function(n){return n=Math.pow(.7,arguments.length?n:1),new et(this.h,this.s,this.l/n)},le.darker=function(n){return n=Math.pow(.7,arguments.length?n:1),new et(this.h,this.s,n*this.l)},le.rgb=function(){return oh(this.h,this.s,this.l)},n.hcl=ft,ae=ft.prototype=new ci,ae.brighter=function(n){return new ft(this.h,this.c,Math.min(100,this.l+ve*(arguments.length?n:1)))},ae.darker=function(n){return new ft(this.h,this.c,Math.max(0,this.l-ve*(arguments.length?n:1)))},ae.rgb=function(){return tc(this.h,this.c,this.l).rgb()},n.lab=rt;var ve=18,cw=.95047,sw=1,ew=1.08883,ic=rt.prototype=new ci;ic.brighter=function(n){return new rt(Math.min(100,this.l+ve*(arguments.length?n:1)),this.a,this.b)},ic.darker=function(n){return new rt(Math.max(0,this.l-ve*(arguments.length?n:1)),this.a,this.b)},ic.rgb=function(){return gp(this.l,this.a,this.b)},n.rgb=k,tu=k.prototype=new ci,tu.brighter=function(n){n=Math.pow(.7,arguments.length?n:1);var u=this.r,i=this.g,r=this.b,t=30;return!u&&!i&&!r?new k(t,t,t):(u&&u<t&&(u=t),i&&i<t&&(i=t),r&&r<t&&(r=t),new k(Math.min(255,u/n),Math.min(255,i/n),Math.min(255,r/n)))},tu.darker=function(n){return n=Math.pow(.7,arguments.length?n:1),new k(n*this.r,n*this.g,n*this.b)},tu.hsl=function(){return cp(this.r,this.g,this.b)},tu.toString=function(){return"#"+er(this.r)+er(this.g)+er(this.b)},uu=n.map({aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074}),uu.forEach(function(n,t){uu.set(n,vp(t))}),n.functor=o,n.xhr=uh(a),n.dsv=function(n,t){function i(n,i,r){arguments.length<3&&(r=i,i=null);var e=nf(n,t,i==null?f:u(i),r);return e.row=function(n){return arguments.length?e.response((i=n)==null?f:u(n)):i},e}function f(n){return i.parse(n.responseText)}function u(n){return function(t){return i.parse(t.responseText,n)}}function o(t){return t.map(r).join(n)}function r(n){return s.test(n)?'"'+n.replace(/\"/g,'""')+'"':n}var s=new RegExp('["'+n+"\n]"),e=n.charCodeAt(0);return i.parse=function(n,t){var r;return i.parseRows(n,function(n,i){if(r)return r(n,i-1);var u=new Function("d","return {"+n.map(function(n,t){return JSON.stringify(n)+": d["+t+"]"}).join(",")+"}");r=t?function(n,i){return t(u(n),i)}:u})},i.parseRows=function(n,t){function h(){var f,t,u,h;if(i>=o)return s;if(r)return r=!1,l;if(f=i,n.charCodeAt(f)===34){for(t=f;t++<o;)if(n.charCodeAt(t)===34){if(n.charCodeAt(t+1)!==34)break;++t}return i=t+2,u=n.charCodeAt(t+1),u===13?(r=!0,n.charCodeAt(t+2)===10&&++i):u===10&&(r=!0),n.substring(f+1,t).replace(/""/g,'"')}while(i<o){if(u=n.charCodeAt(i++),h=1,u===10)r=!0;else if(u===13)r=!0,n.charCodeAt(i)===10&&(++i,++h);else if(u!==e)continue;return n.substring(f,i-h)}return n.substring(f)}for(var l={},s={},c=[],o=n.length,i=0,a=0,u,r,f;(u=h())!==s;){for(f=[];u!==l&&u!==s;)f.push(u),u=h();(!t||(f=t(f,a++)))&&c.push(f)}return c},i.format=function(t){if(Array.isArray(t[0]))return i.formatRows(t);var f=new fo,u=[];return t.forEach(function(n){for(var t in n)f.has(t)||u.push(f.add(t))}),[u.map(r).join(n)].concat(t.map(function(t){return u.map(function(n){return r(t[n])}).join(n)})).join("\n")},i.formatRows=function(n){return n.map(o).join("\n")},i},n.csv=n.dsv(",","text/csv"),n.tsv=n.dsv("\t","text/tab-separated-values"),n.touch=function(n,t,i){if(arguments.length<3&&(i=t,t=po().changedTouches),t)for(var r=0,f=t.length,u;r<f;++r)if((u=t[r]).identifier===i)return lc(n,u)},fc=w[eo(w,"requestAnimationFrame")]||function(n){setTimeout(n,17)},n.timer=function(n,t,i){var u=arguments.length,f,r;u<2&&(t=0),u<3&&(i=Date.now()),f=i+t,r={c:n,t:f,f:!1,n:null},ef?ef.n=r:sf=r,ef=r,bu||(pu=clearTimeout(pu),bu=1,fc(bh))},n.timer.flush=function(){kp(),dp()},n.round=function(n,t){return t?Math.round(n*(t=Math.pow(10,t)))/t:Math.round(n)},bp=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"].map(kk),n.formatPrefix=function(t,i){var r=0;return t&&(t<0&&(t*=-1),i&&(t=n.round(t,ch(t,i))),r=1+Math.floor(1e-12+Math.log(t)/Math.LN10),r=Math.max(-24,Math.min(24,Math.floor((r-1)/3)*3))),bp[8+r/3]},gh=/(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,pp=n.map({b:function(n){return n.toString(2)},c:function(n){return String.fromCharCode(n)},o:function(n){return n.toString(8)},x:function(n){return n.toString(16)},X:function(n){return n.toString(16).toUpperCase()},g:function(n,t){return n.toPrecision(t)},e:function(n,t){return n.toExponential(t)},f:function(n,t){return n.toFixed(t)},r:function(t,i){return(t=n.round(t,ch(t,i))).toFixed(Math.max(0,Math.min(20,ch(t*(1+1e-15),i))))}}),i=n.time={},v=Date,wt.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(){ot.setUTCDate.apply(this._,arguments)},setDay:function(){ot.setUTCDay.apply(this._,arguments)},setFullYear:function(){ot.setUTCFullYear.apply(this._,arguments)},setHours:function(){ot.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){ot.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){ot.setUTCMinutes.apply(this._,arguments)},setMonth:function(){ot.setUTCMonth.apply(this._,arguments)},setSeconds:function(){ot.setUTCSeconds.apply(this._,arguments)},setTime:function(){ot.setTime.apply(this._,arguments)}},ot=Date.prototype,i.year=bi(function(n){return n=i.day(n),n.setMonth(0,1),n},function(n,t){n.setFullYear(n.getFullYear()+t)},function(n){return n.getFullYear()}),i.years=i.year.range,i.years.utc=i.year.utc.range,i.day=bi(function(n){var t=new v(2e3,0);return t.setFullYear(n.getFullYear(),n.getMonth(),n.getDate()),t},function(n,t){n.setDate(n.getDate()+t)},function(n){return n.getDate()-1}),i.days=i.day.range,i.days.utc=i.day.utc.range,i.dayOfYear=function(n){var t=i.year(n);return Math.floor((n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*6e4)/864e5)},["sunday","monday","tuesday","wednesday","thursday","friday","saturday"].forEach(function(n,t){t=7-t;var r=i[n]=bi(function(n){return(n=i.day(n)).setDate(n.getDate()-(n.getDay()+t)%7),n},function(n,t){n.setDate(n.getDate()+Math.floor(t)*7)},function(n){var r=i.year(n).getDay();return Math.floor((i.dayOfYear(n)+(r+t)%7)/7)-(r!==t)});i[n+"s"]=r.range,i[n+"s"].utc=r.utc.range,i[n+"OfYear"]=function(n){var r=i.year(n).getDay();return Math.floor((i.dayOfYear(n)+(r+t)%7)/7)}}),i.week=i.sunday,i.weeks=i.sunday.range,i.weeks.utc=i.sunday.utc.range,i.weekOfYear=i.sundayOfYear;var by={"-":"",_:" ","0":"0"},h=/^\s*\d+/,wp=/^%/;n.locale=function(n){return{numberFormat:pk(n),timeFormat:rk(n)}},sc=n.locale({decimal:".",thousands:",",grouping:[3],currency:["$",""],dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),n.format=sc.numberFormat,n.geo={},pc.prototype={s:0,t:0,add:function(n){nw(n,this.t,hu),nw(hu.s,this.s,this),this.s?this.t+=hu.t:this.s=hu.t},reset:function(){this.s=this.t=0},valueOf:function(){return this.s}},hu=new pc,n.geo.stream=function(n,t){n&&bc.hasOwnProperty(n.type)?bc[n.type](n,t):gu(n,t)},bc={Feature:function(n,t){gu(n.geometry,t)},FeatureCollection:function(n,t){for(var r=n.features,i=-1,u=r.length;++i<u;)gu(r[i].geometry,t)}},ac={Sphere:function(n,t){t.sphere()},Point:function(n,t){n=n.coordinates,t.point(n[0],n[1],n[2])},MultiPoint:function(n,t){for(var r=n.coordinates,i=-1,u=r.length;++i<u;)n=r[i],t.point(n[0],n[1],n[2])},LineString:function(n,t){vc(n.coordinates,t,0)},MultiLineString:function(n,t){for(var r=n.coordinates,i=-1,u=r.length;++i<u;)vc(r[i],t,0)},Polygon:function(n,t){iw(n.coordinates,t)},MultiPolygon:function(n,t){for(var r=n.coordinates,i=-1,u=r.length;++i<u;)iw(r[i],t)},GeometryCollection:function(n,t){for(var r=n.geometries,i=-1,u=r.length;++i<u;)gu(r[i],t)}},n.geo.area=function(t){return tf=0,n.geo.stream(t,b),tf},ei=new pc,b={sphere:function(){tf+=4*f},point:c,lineStart:c,lineEnd:c,polygonStart:function(){ei.reset(),b.lineStart=tut},polygonEnd:function(){var n=2*ei;tf+=n<0?4*f+n:n,b.lineStart=b.lineEnd=b.point=c}},n.geo.bounds=function(){function w(n,t){v.push(l=[i=n,f=n]),t<o&&(o=t),t>h&&(h=t)}function it(n,t){var g=ai([n*u,t*u]),v;if(y){var b=ur(y,g),nt=[b[1],-b[0],0],c=ur(nt,b);kf(c),c=re(c);var d=n-a,p=d>0?1:-1,l=c[0]*s*p,k=r(d)>180;k^(p*a<l&&l<p*n)?(v=c[1]*s,v>h&&(h=v)):(l=(l+360)%360-180,k^(p*a<l&&l<p*n))?(v=-c[1]*s,v<o&&(o=v)):(t<o&&(o=t),t>h&&(h=t)),k?n<a?e(i,n)>e(i,f)&&(f=n):e(n,f)>e(i,f)&&(i=n):f>=i?(n<i&&(i=n),n>f&&(f=n)):n>a?e(i,n)>e(i,f)&&(f=n):e(n,f)>e(i,f)&&(i=n)}else w(n,t);y=g,a=n}function rt(){c.point=it}function k(){l[0]=i,l[1]=f,c.point=w,y=null}function d(n,t){if(y){var i=n-a;p+=r(i)>180?i+(i>0?360:-360):i}else tt=n,nt=t;b.point(n,t),it(n,t)}function et(){b.lineStart()}function ut(){d(tt,nt),b.lineEnd(),r(p)>t&&(i=-(f=180)),l[0]=i,l[1]=f,y=null}function e(n,t){return(t-=n)<0?t+360:t}function ft(n,t){return n[0]-t[0]}function g(n,t){return t[0]<=t[1]?t[0]<=n&&n<=t[1]:n<t[0]||t[1]<n}var i,o,f,h,a,tt,nt,y,p,v,l,c={point:w,lineStart:rt,lineEnd:k,polygonStart:function(){c.point=d,c.lineStart=et,c.lineEnd=ut,p=0,b.polygonStart()},polygonEnd:function(){b.polygonEnd(),c.point=w,c.lineStart=rt,c.lineEnd=k,ei<0?(i=-(f=180),o=-(h=90)):p>t?h=90:p<-t&&(o=-90),l[0]=i,l[1]=f}};return function(t){var a,p,w;if(h=f=-(i=o=Infinity),v=[],n.geo.stream(t,c),a=v.length,a){v.sort(ft);for(var s=1,r=v[0],u,y=[r];s<a;++s)u=v[s],g(u[0],r)||g(u[1],r)?(e(r[0],u[1])>e(r[0],r[1])&&(r[1]=u[1]),e(u[0],r[1])>e(r[0],r[1])&&(r[0]=u[0])):y.push(r=u);p=-Infinity;for(var a=y.length-1,s=0,r=y[a],u;s<=a;r=u,++s)u=y[s],(w=e(r[1],u[0]))>p&&(p=w,i=u[0],f=r[1])}return v=l=null,i===Infinity||o===Infinity?[[NaN,NaN],[NaN,NaN]]:[[i,o],[f,h]]}}(),n.geo.centroid=function(i){cu=hf=vi=pi=pt=si=ri=ct=hr=cr=gt=0,n.geo.stream(i,nt);var f=hr,u=cr,r=gt,e=f*f+u*u+r*r;return e<fl&&(f=si,u=ri,r=ct,hf<t&&(f=vi,u=pi,r=pt),e=f*f+u*u+r*r,e<fl)?[NaN,NaN]:[Math.atan2(u,f)*s,sr(r/Math.sqrt(e))*s]},nt={sphere:c,point:ws,lineStart:vy,lineEnd:ay,polygonStart:function(){nt.lineStart=ert},polygonEnd:function(){nt.lineStart=vy}},ih=ey(or,cn,nn,[-f,-f/2]),vr=1e9,n.geo.clipExtent=function(){var u,f,e,r,n,i,t={stream:function(t){return n&&(n.valid=!1),n=i(t),n.valid=!0,n},extent:function(o){return arguments.length?(i=bb(u=+o[0][0],f=+o[0][1],e=+o[1][0],r=+o[1][1]),n&&(n.valid=!1,n=null),t):[[u,f],[e,r]]}};return t.extent([[0,0],[960,500]])},(n.geo.conicEqualArea=function(){return us(db)}).raw=db,n.geo.albers=function(){return n.geo.conicEqualArea().rotate([96,0]).center([-.6,38.7]).parallels([29.5,45.5]).scale(1070)},n.geo.albersUsa=function(){function r(n){var i=n[0],t=n[1];return f=null,(s(i,t),f)||(c(i,t),f)||h(i,t),f}var i=n.geo.albers(),u=n.geo.conicEqualArea().rotate([154,0]).center([-2,58.5]).parallels([55,65]),e=n.geo.conicEqualArea().rotate([157,0]).center([-3,19.9]).parallels([8,18]),f,o={point:function(n,t){f=[n,t]}},s,c,h;return r.invert=function(n){var o=i.scale(),f=i.translate(),t=(n[0]-f[0])/o,r=(n[1]-f[1])/o;return(r>=.12&&r<.234&&t>=-.425&&t<-.214?u:r>=.166&&r<.234&&t>=-.214&&t<-.115?e:i).invert(n)},r.stream=function(n){var f=i.stream(n),r=u.stream(n),t=e.stream(n);return{point:function(n,i){f.point(n,i),r.point(n,i),t.point(n,i)},sphere:function(){f.sphere(),r.sphere(),t.sphere()},lineStart:function(){f.lineStart(),r.lineStart(),t.lineStart()},lineEnd:function(){f.lineEnd(),r.lineEnd(),t.lineEnd()},polygonStart:function(){f.polygonStart(),r.polygonStart(),t.polygonStart()},polygonEnd:function(){f.polygonEnd(),r.polygonEnd(),t.polygonEnd()}}},r.precision=function(n){return arguments.length?(i.precision(n),u.precision(n),e.precision(n),r):i.precision()},r.scale=function(n){return arguments.length?(i.scale(n),u.scale(n*.35),e.scale(n),r.translate(i.translate())):i.scale()},r.translate=function(n){if(!arguments.length)return i.translate();var f=i.scale(),a=+n[0],l=+n[1];return s=i.translate(n).clipExtent([[a-.455*f,l-.238*f],[a+.455*f,l+.238*f]]).stream(o).point,c=u.translate([a-.307*f,l+.201*f]).clipExtent([[a-.425*f+t,l+.12*f+t],[a-.214*f-t,l+.234*f-t]]).stream(o).point,h=e.translate([a-.205*f,l+.212*f]).clipExtent([[a-.214*f+t,l+.166*f+t],[a-.115*f-t,l+.234*f-t]]).stream(o).point,r},r.scale(1070)},bt={point:c,lineStart:c,lineEnd:c,polygonStart:function(){ts=0,bt.lineStart=att},polygonEnd:function(){bt.lineStart=bt.lineEnd=bt.point=c,fs+=r(ts/2)}},kb={point:ctt,lineStart:c,lineEnd:c,polygonStart:c,polygonEnd:c},it={point:li,lineStart:tk,lineEnd:ww,polygonStart:function(){it.lineStart=wtt},polygonEnd:function(){it.point=li,it.lineStart=tk,it.lineEnd=ww}},n.geo.path=function(){function t(t){return t&&(typeof r=="function"&&i.pointRadius(+r.apply(this,arguments)),u&&u.valid||(u=f(i)),n.geo.stream(t,u)),i.result()}function e(){return u=null,t}var r=4.5,o,s,f,i,u;return t.area=function(t){return fs=0,n.geo.stream(t,f(bt)),fs},t.centroid=function(t){return vi=pi=pt=si=ri=ct=hr=cr=gt=0,n.geo.stream(t,f(it)),gt?[hr/gt,cr/gt]:ct?[si/ct,ri/ct]:pt?[vi/pt,pi/pt]:[NaN,NaN]},t.bounds=function(t){return ku=wu=-(df=du=Infinity),n.geo.stream(t,f(kb)),[[df,du],[ku,wu]]},t.projection=function(n){return arguments.length?(f=(o=n)?n.stream||ptt(n):a,e()):o},t.context=function(n){return arguments.length?(i=(s=n)==null?new stt:new ytt(n),typeof r!="function"&&i.pointRadius(r),e()):s},t.pointRadius=function(n){return arguments.length?(r=typeof n=="function"?n:(i.pointRadius(+n),+n),t):r},t.projection(n.geo.albersUsa()).context(null)},n.geo.transform=function(n){return{stream:function(t){var r=new pw(t),i;for(i in n)r[i]=n[i];return r}}},pw.prototype={point:function(n,t){this.stream.point(n,t)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}},n.geo.projection=ii,n.geo.projectionMutator=ls,(n.geo.equirectangular=function(){return ii(eu)}).raw=eu.invert=eu,n.geo.rotation=function(n){function t(t){return t=n(t[0]*u,t[1]*u),t[0]*=s,t[1]*=s,t}return n=is(n[0]%360*u,n[1]*u,n.length>2?n[2]*u:0),t.invert=function(t){return t=n.invert(t[0]*u,t[1]*u),t[0]*=s,t[1]*=s,t},t},fb.invert=eu,n.geo.circle=function(){function n(){var i=typeof t=="function"?t.apply(this,arguments):t,f=is(-i[0]*u,-i[1]*u,0).invert,n=[];return r(null,null,1,{point:function(t,i){n.push(t=f(t,i)),t[0]*=s,t[1]*=s}}),{type:"Polygon",coordinates:[n]}}var t=[0,0],f,i=6,r;return n.origin=function(i){return arguments.length?(t=i,n):t},n.angle=function(t){return arguments.length?(r=rs((f=+t)*u,i*u),n):f},n.precision=function(t){return arguments.length?(r=rs(f*u,(i=+t)*u),n):i},n.angle(90)},n.geo.distance=function(n,t){var l=(t[0]-n[0])*u,h=n[1]*u,s=t[1]*u,a=Math.sin(l),c=Math.cos(l),f=Math.sin(h),e=Math.cos(h),o=Math.sin(s),r=Math.cos(s),i;return Math.atan2(Math.sqrt((i=r*a)*i+(i=e*o-f*r*c)*i),f*o+e*r*c)},n.geo.graticule=function(){function i(){return{type:"MultiLineString",coordinates:d()}}function d(){return n.range(Math.ceil(u/p)*p,o,p).map(k).concat(n.range(Math.ceil(f/a)*a,e,a).map(b)).concat(n.range(Math.ceil(h/y)*y,s,y).filter(function(n){return r(n%p)>t}).map(nt)).concat(n.range(Math.ceil(l/w)*w,c,w).filter(function(n){return r(n%a)>t}).map(g))}var s,h,o,u,c,l,e,f,y=10,w=y,p=90,a=360,nt,g,k,b,v=2.5;return i.lines=function(){return d().map(function(n){return{type:"LineString",coordinates:n}})},i.outline=function(){return{type:"Polygon",coordinates:[k(u).concat(b(e).slice(1),k(o).reverse().slice(1),b(f).reverse().slice(1))]}},i.extent=function(n){return arguments.length?i.majorExtent(n).minorExtent(n):i.minorExtent()},i.majorExtent=function(n){return arguments.length?(u=+n[0][0],o=+n[1][0],f=+n[0][1],e=+n[1][1],u>o&&(n=u,u=o,o=n),f>e&&(n=f,f=e,e=n),i.precision(v)):[[u,f],[o,e]]},i.minorExtent=function(n){return arguments.length?(h=+n[0][0],s=+n[1][0],l=+n[0][1],c=+n[1][1],h>s&&(n=h,h=s,s=n),l>c&&(n=l,l=c,c=n),i.precision(v)):[[h,l],[s,c]]},i.step=function(n){return arguments.length?i.majorStep(n).minorStep(n):i.minorStep()},i.majorStep=function(n){return arguments.length?(p=+n[0],a=+n[1],i):[p,a]},i.minorStep=function(n){return arguments.length?(y=+n[0],w=+n[1],i):[y,w]},i.precision=function(n){return arguments.length?(v=+n,nt=tb(l,c,90),g=ob(h,s,v),k=tb(f,e,90),b=ob(u,o,v),i):v},i.majorExtent([[-180,-90+t],[180,90-t]]).minorExtent([[-180,-80-t],[180,80+t]])},n.geo.greatArc=function(){function t(){return{type:"LineString",coordinates:[u||i.apply(this,arguments),f||r.apply(this,arguments)]}}var i=as,u,r=gs,f;return t.distance=function(){return n.geo.distance(u||i.apply(this,arguments),f||r.apply(this,arguments))},t.source=function(n){return arguments.length?(i=n,u=typeof n=="function"?null:n,t):i},t.target=function(n){return arguments.length?(r=n,f=typeof n=="function"?null:n,t):r},t.precision=function(){return arguments.length?t:0},t},n.geo.interpolate=function(n,t){return ttt(n[0]*u,n[1]*u,t[0]*u,t[1]*u)},n.geo.length=function(t){return ds=0,n.geo.stream(t,ki),ds},ki={sphere:c,point:c,lineStart:utt,lineEnd:c,polygonStart:c,polygonEnd:c},ks=dr(function(n){return Math.sqrt(2/(1+n))},function(n){return 2*Math.asin(n/2)}),(n.geo.azimuthalEqualArea=function(){return ii(ks)}).raw=ks,ys=dr(function(n){var t=Math.acos(n);return t&&t/Math.sin(t)},a),(n.geo.azimuthalEquidistant=function(){return ii(ys)}).raw=ys,(n.geo.conicConformal=function(){return us(lw)}).raw=lw,(n.geo.conicEquidistant=function(){return us(kw)}).raw=kw,ps=dr(function(n){return 1/n},Math.atan),(n.geo.gnomonic=function(){return ii(ps)}).raw=ps,de.invert=function(n,t){return[n,2*Math.atan(Math.exp(t))-y]},(n.geo.mercator=function(){return bw(de)}).raw=de,ro=dr(function(){return 1},Math.asin),(n.geo.orthographic=function(){return ii(ro)}).raw=ro,ho=dr(function(n){return 1/(1+n)},function(n){return 2*Math.atan(n)}),(n.geo.stereographic=function(){return ii(ho)}).raw=ho,bo.invert=function(n,t){return[-t,2*Math.atan(Math.exp(n))-y]},(n.geo.transverseMercator=function(){var n=bw(bo),i=n.center,t=n.rotate;return n.center=function(n){return n?i([-n[1],n[0]]):(n=i(),[n[1],-n[0]])},n.rotate=function(n){return n?t([n[0],n[1],n.length>2?n[2]+90:90]):(n=t(),[n[0],n[1],n[2]-90])},t([0,0,90])}).raw=bo,n.geom={},n.geom.hull=function(n){function t(n){if(n.length<3)return[];for(var v=o(i),a=o(r),h=n.length,u=[],c=[],t=0;t<h;t++)u.push([+v.call(this,n[t],t),+a.call(this,n[t],t),t]);for(u.sort(rtt),t=0;t<h;t++)c.push([u[t][0],-u[t][1]]);var e=gb(u),f=gb(c),y=f[0]===e[0],l=f[f.length-1]===e[e.length-1],s=[];for(t=e.length-1;t>=0;--t)s.push(n[u[e[t]][2]]);for(t=+y;t<f.length-l;++t)s.push(n[u[f[t]][2]]);return s}var i=tr,r=su;return arguments.length?t(n):(t.x=function(n){return arguments.length?(i=n,t):i},t.y=function(n){return arguments.length?(r=n,t):r},t)},n.geom.polygon=function(n){return yu(n,lu),n},lu=n.geom.polygon.prototype=[],lu.area=function(){for(var u=-1,r=this.length,t,n=this[r-1],i=0;++u<r;)t=n,n=this[u],i+=t[1]*n[0]-t[0]*n[1];return i*.5},lu.centroid=function(n){var u=-1,o=this.length,f=0,e=0,i,t=this[o-1],r;for(arguments.length||(n=-1/(6*this.area()));++u<o;)i=t,t=this[u],r=i[0]*t[1]-t[0]*i[1],f+=(i[0]+t[0])*r,e+=(i[1]+t[1])*r;return[f*n,e*n]},lu.clip=function(n){for(var f,s=ab(n),c=-1,o=this.length-ab(this),e,h,r=this[o-1],t,u,i;++c<o;){for(f=n.slice(),n.length=0,t=this[c],u=f[(h=f.length-s)-1],e=-1;++e<h;)i=f[e],yo(i,r,t)?(yo(u,r,t)||n.push(yb(u,i,r,t)),n.push(i)):yo(u,r,t)&&n.push(yb(u,i,r,t)),u=i;s&&n.push(n[0]),r=t}return n},go=[],vs=[],ea.prototype.prepare=function(){for(var n=this.edges,i=n.length,t;i--;)t=n[i].edge,t.b&&t.a||n.splice(i,1);return n.sort(ta),n.length},ge.prototype={start:function(){return this.edge.l===this.site?this.edge.a:this.edge.b},end:function(){return this.edge.l===this.site?this.edge.b:this.edge.a}},hs.prototype={insert:function(n,t){var i,r,u;if(n){if(t.P=n,t.N=n.N,n.N&&(n.N.P=t),n.N=t,n.R){for(n=n.R;n.L;)n=n.L;n.L=t}else n.R=t;i=n}else this._?(n=wv(this._),t.P=null,t.N=n,n.P=n.L=t,i=n):(t.P=t.N=null,this._=t,i=null);for(t.L=t.R=null,t.U=i,t.C=!0,n=t;i&&i.C;)r=i.U,i===r.L?(u=r.R,u&&u.C?(i.C=u.C=!1,r.C=!0,n=r):(n===i.R&&(nu(this,i),n=i,i=n.U),i.C=!1,r.C=!0,ru(this,r))):(u=r.L,u&&u.C?(i.C=u.C=!1,r.C=!0,n=r):(n===i.L&&(ru(this,i),n=i,i=n.U),i.C=!1,r.C=!0,nu(this,r))),i=n.U;this._.C=!1},remove:function(n){n.N&&(n.N.P=n.P),n.P&&(n.P.N=n.N),n.N=n.P=null;var i=n.U,t,f=n.L,u=n.R,r,e;if(r=f?u?wv(u):f:u,i?i.L===n?i.L=r:i.R=r:this._=r,f&&u?(e=r.C,r.C=n.C,r.L=f,f.U=r,r!==u?(i=r.U,r.U=n.U,n=r.R,i.L=n,r.R=u,u.U=r):(r.U=i,i=r,n=r.R)):(e=n.C,n=r),n&&(n.U=i),!e){if(n&&n.C){n.C=!1;return}do{if(n===this._)break;if(n===i.L){if(t=i.R,t.C&&(t.C=!1,i.C=!0,nu(this,i),t=i.R),t.L&&t.L.C||t.R&&t.R.C){t.R&&t.R.C||(t.L.C=!1,t.C=!0,ru(this,t),t=i.R),t.C=i.C,i.C=t.R.C=!1,nu(this,i),n=this._;break}}else if(t=i.L,t.C&&(t.C=!1,i.C=!0,ru(this,i),t=i.L),t.L&&t.L.C||t.R&&t.R.C){t.L&&t.L.C||(t.R.C=!1,t.C=!0,nu(this,t),t=i.L),t.C=i.C,i.C=t.L.C=!1,ru(this,i),n=this._;break}t.C=!0,n=i,i=i.U}while(!n.C);n&&(n.C=!1)}}},n.geom.voronoi=function(n){function i(n){var o=new Array(n.length),e=r[0][0],f=r[0][1],t=r[1][0],i=r[1][1];return os(u(n),r).cells.forEach(function(r,u){var h=r.edges,s=r.site,c=o[u]=h.length?h.map(function(n){var t=n.start();return[t.x,t.y]}):s.x>=e&&s.x<=t&&s.y>=f&&s.y<=i?[[e,i],[t,i],[t,f],[e,f]]:[];c.point=n[u]}),o}function u(n){return n.map(function(n,i){return{x:Math.round(s(n,i)/t)*t,y:Math.round(h(n,i)/t)*t,i:i}})}var f=tr,e=su,s=f,h=e,r=iu;return n?i(n):(i.links=function(n){return os(u(n)).edges.filter(function(n){return n.l&&n.r}).map(function(t){return{source:n[t.l.i],target:n[t.r.i]}})},i.triangles=function(n){var t=[];return os(u(n)).cells.forEach(function(i,r){for(var s=i.site,o=i.edges.sort(ta),c=-1,h=o.length,l,e,u=o[h-1].edge,f=u.l===s?u.r:u.l;++c<h;)l=u,e=f,u=o[c].edge,f=u.l===s?u.r:u.l,r<e.i&&r<f.i&&btt(s,e,f)<0&&t.push([n[r],n[e.i],n[f.i]])}),t},i.x=function(n){return arguments.length?(s=o(f=n),i):f},i.y=function(n){return arguments.length?(h=o(e=n),i):e},i.clipExtent=function(n){return arguments.length?(r=n==null?iu:n,i):r===iu?null:r},i.size=function(n){return arguments.length?i.clipExtent(n&&[[0,0],n]):r===iu?null:r&&r[1]},i)},iu=[[-1e6,-1e6],[1e6,1e6]],n.geom.delaunay=function(t){return n.geom.voronoi().triangles(t)},n.geom.quadtree=function(n,t,i,u,f){function e(n){function it(n,t,i,u,f,e,o,s){var h,c,l;isNaN(i)||isNaN(u)||(n.leaf?(h=n.x,c=n.y,h!=null?r(h-i)+r(c-u)<.01?tt(n,t,i,u,f,e,o,s):(l=n.point,n.x=n.y=n.point=null,tt(n,l,h,c,f,e,o,s),tt(n,t,i,u,f,e,o,s)):(n.x=i,n.y=u,n.point=t)):tt(n,t,i,u,f,e,o,s))}function tt(n,t,i,r,u,f,e,o){var h=(u+e)*.5,s=(f+o)*.5,a=i>=h,l=r>=s,c=(l<<1)+a;n.leaf=!1,n=n.nodes[c]||(n.nodes[c]=pv()),a?u=h:e=h,l?f=s:o=s,it(n,t,i,r,u,f,e,o)}var l,et=o(s),ft=o(h),g,d,e,nt,a,p,v,y,b,k,ut,rt,w;if(t!=null)a=t,p=i,v=u,y=f;else if(v=y=-(a=p=Infinity),g=[],d=[],nt=n.length,c)for(e=0;e<nt;++e)l=n[e],l.x<a&&(a=l.x),l.y<p&&(p=l.y),l.x>v&&(v=l.x),l.y>y&&(y=l.y),g.push(l.x),d.push(l.y);else for(e=0;e<nt;++e)b=+et(l=n[e],e),k=+ft(l,e),b<a&&(a=b),k<p&&(p=k),b>v&&(v=b),k>y&&(y=k),g.push(b),d.push(k);if(ut=v-a,rt=y-p,ut>rt?y=p+ut:v=a+rt,w=pv(),w.add=function(n){it(w,n,+et(n,++e),+ft(n,e),a,p,v,y)},w.visit=function(n){wr(n,w,a,p,v,y)},e=-1,t==null){while(++e<nt)it(w,n[e],g[e],d[e],a,p,v,y);--e}else n.forEach(w.add);return g=d=n=l=null,w}var s=tr,h=su,c;return(c=arguments.length)?(s=vtt,h=htt,c===3&&(f=i,u=t,i=t=0),e(n)):(e.x=function(n){return arguments.length?(s=n,e):s},e.y=function(n){return arguments.length?(h=n,e):h},e.extent=function(n){return arguments.length?(n==null?t=i=u=f=null:(t=+n[0][0],i=+n[0][1],u=+n[1][0],f=+n[1][1]),e):t==null?null:[[t,i],[u,f]]},e.size=function(n){return arguments.length?(n==null?t=i=u=f=null:(t=i=0,u=+n[0],f=+n[1]),e):t==null?null:[u-t,f-i]},e)},n.interpolateRgb=cs,n.interpolateObject=sv,n.interpolateNumber=vt,n.interpolateString=cv,bf=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ie=new RegExp(bf.source,"g"),n.interpolate=wi,n.interpolators=[function(n,t){var i=typeof t;return(i==="string"?uu.has(t)||/^(#|rgb\(|hsl\()/.test(t)?cs:cv:t instanceof ci?cs:Array.isArray(t)?lf:i==="object"&&isNaN(t)?sv:vt)(n,t)}],n.interpolateArray=lf;var fy=function(){return a},wn=n.map({linear:fy,poly:vg,quad:function(){return tn},cubic:function(){return kg},sin:function(){return pg},exp:function(){return bg},circle:function(){return wg},elastic:un,back:an,bounce:function(){return ln}}),gg=n.map({"in":a,out:uy,"in-out":ty,"out-in":function(n){return ty(uy(n))}});n.ease=function(n){var t=n.indexOf("-"),r=t>=0?n.substring(0,t):n,i=t>=0?n.substring(t+1):"in";return r=wn.get(r)||fy,i=gg.get(i)||a,dg(i(r.apply(null,vw.call(arguments,1))))},n.interpolateHcl=vn,n.interpolateHsl=pn,n.interpolateLab=yn,n.interpolateRound=dv,n.transform=function(t){var i=ut.createElementNS(n.ns.prefix.svg,"g");return(n.transform=function(n){if(n!=null){i.setAttribute("transform",n);var t=i.transform.baseVal.consolidate()}return new ny(t?t.matrix:pa)})(t)},ny.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"},pa={a:1,b:0,c:0,d:1,e:0,f:0},n.interpolateTransform=ya,n.layout={},n.layout.bundle=function(){return function(n){for(var i=[],t=-1,r=n.length;++t<r;)i.push(hrt(n[t]));return i}},n.layout.chord=function(){function l(){var k={},g=[],rt=n.range(i),nt=[],v,t,tt,l,a,w,p;for(r=[],f=[],v=0,l=-1;++l<i;){for(t=0,a=-1;++a<i;)t+=u[l][a];g.push(t),nt.push(n.range(i)),v+=t}for(h&&rt.sort(function(n,t){return h(g[n],g[t])}),e&&nt.forEach(function(n,t){n.sort(function(n,i){return e(u[t][n],u[t][i])})}),v=(d-s*i)/v,t=0,l=-1;++l<i;){for(tt=t,a=-1;++a<i;){var y=rt[l],b=nt[y][a],it=u[y][b],ut=t,ft=t+=it*v;k[y+"-"+b]={index:y,subindex:b,startAngle:ut,endAngle:ft,value:it}}f[y]={index:y,startAngle:tt,endAngle:t,value:(t-tt)/v},t+=s}for(l=-1;++l<i;)for(a=l-1;++a<i;)w=k[l+"-"+a],p=k[a+"-"+l],(w.value||p.value)&&r.push(w.value<p.value?{source:p,target:w}:{source:w,target:p});o&&c()}function c(){r.sort(function(n,t){return o((n.source.value+n.target.value)/2,(t.source.value+t.target.value)/2)})}var t={},r,f,u,i,s=0,h,e,o;return t.matrix=function(n){return arguments.length?(i=(u=n)&&u.length,r=f=null,t):u},t.padding=function(n){return arguments.length?(s=n,r=f=null,t):s},t.sortGroups=function(n){return arguments.length?(h=n,r=f=null,t):h},t.sortSubgroups=function(n){return arguments.length?(e=n,r=null,t):e},t.sortChords=function(n){return arguments.length?(o=n,r&&c(),t):o},t.chords=function(){return r||l(),r},t.groups=function(){return f||l(),f},t},n.layout.force=function(){function g(n){return function(t,i,r,u){var e;if(t.point!==n){var o=t.cx-n.x,s=t.cy-n.y,h=u-i,f=o*o+s*s;if(h*h/k<f)return f<v&&(e=t.charge/f,n.px-=o*e,n.py-=s*e),!0;t.point&&f&&f<v&&(e=t.pointCharge/f,n.px-=o*e,n.py-=s*e)}return!t.charge}}function d(i){i.px=n.event.x,i.py=n.event.y,t.resume()}var t={},w=n.dispatch("start","tick","end"),e=[1,1],y,r,p=.9,s=rrt,o=irt,f=-30,v=urt,b=.1,k=.64,i=[],u=[],h,c,l;return t.tick=function(){if((r*=.99)<.005)return w.end({type:"end",alpha:r=0}),!0;for(var nt=i.length,it=u.length,tt,t,k,d,y,s,a,v,o=0;o<it;++o)t=u[o],k=t.source,d=t.target,a=d.x-k.x,v=d.y-k.y,(y=a*a+v*v)&&(y=r*c[o]*((y=Math.sqrt(y))-h[o])/y,a*=y,v*=y,d.x-=a*(s=k.weight/(d.weight+k.weight)),d.y-=v*s,k.x+=a*(s=1-s),k.y+=v*s);if((s=r*b)&&(a=e[0]/2,v=e[1]/2,o=-1,s))while(++o<nt)t=i[o],t.x+=(a-t.x)*s,t.y+=(v-t.y)*s;if(f)for(wa(tt=n.geom.quadtree(i),r,l),o=-1;++o<nt;)(t=i[o]).fixed||tt.visit(g(t));for(o=-1;++o<nt;)t=i[o],t.fixed?(t.x=t.px,t.y=t.py):(t.x-=(t.px-(t.px=t.x))*p,t.y-=(t.py-(t.py=t.y))*p);w.tick({type:"tick",alpha:r})},t.nodes=function(n){return arguments.length?(i=n,t):i},t.links=function(n){return arguments.length?(u=n,t):u},t.size=function(n){return arguments.length?(e=n,t):e},t.linkDistance=function(n){return arguments.length?(s=typeof n=="function"?n:+n,t):s},t.distance=t.linkDistance,t.linkStrength=function(n){return arguments.length?(o=typeof n=="function"?n:+n,t):o},t.friction=function(n){return arguments.length?(p=+n,t):p},t.charge=function(n){return arguments.length?(f=typeof n=="function"?n:+n,t):f},t.chargeDistance=function(n){return arguments.length?(v=n*n,t):Math.sqrt(v)},t.gravity=function(n){return arguments.length?(b=+n,t):b},t.theta=function(n){return arguments.length?(k=n*n,t):Math.sqrt(k)},t.alpha=function(i){return arguments.length?(i=+i,r?r=i>0?i:0:i>0&&(w.start({type:"start",alpha:r=i}),n.timer(t.tick)),t):r},t.start=function(){function p(t,i){var f;if(!a){for(a=new Array(v),r=0;r<v;++r)a[r]=[];for(r=0;r<o;++r)f=u[r],a[f.source.index].push(f.target),a[f.target.index].push(f.source)}for(var s=a[n],r=-1,o=s.length,e;++r<o;)if(!isNaN(e=s[r][t]))return e;return Math.random()*i}for(var v=i.length,y=u.length,w=e[0],b=e[1],a,r,n=0;n<v;++n)(r=i[n]).index=n,r.weight=0;for(n=0;n<y;++n)r=u[n],typeof r.source=="number"&&(r.source=i[r.source]),typeof r.target=="number"&&(r.target=i[r.target]),++r.source.weight,++r.target.weight;for(n=0;n<v;++n)r=i[n],isNaN(r.x)&&(r.x=p("x",w)),isNaN(r.y)&&(r.y=p("y",b)),isNaN(r.px)&&(r.px=r.x),isNaN(r.py)&&(r.py=r.y);if(h=[],typeof s=="function")for(n=0;n<y;++n)h[n]=+s.call(this,u[n],n);else for(n=0;n<y;++n)h[n]=s;if(c=[],typeof o=="function")for(n=0;n<y;++n)c[n]=+o.call(this,u[n],n);else for(n=0;n<y;++n)c[n]=o;if(l=[],typeof f=="function")for(n=0;n<v;++n)l[n]=+f.call(this,i[n],n);else for(n=0;n<v;++n)l[n]=f;return t.resume()},t.resume=function(){return t.alpha(.1)},t.stop=function(){return t.alpha(0)},t.drag=function(){if(y||(y=n.behavior.drag().origin(a).on("dragstart.force",crt).on("drag.force",d).on("dragend.force",art)),!arguments.length)return y;this.on("mouseover.force",lrt).on("mouseout.force",ort).call(y)},n.rebind(t,w,"on")};var rrt=20,irt=1,urt=Infinity;n.layout.hierarchy=function(){function n(u){var c=[u],h=[],f,s,e,o;for(u.depth=0;(f=c.pop())!=null;)if(h.push(f),(e=r.call(n,f,f.depth))&&(s=e.length)){while(--s>=0)c.push(o=e[s]),o.parent=f,o.depth=f.depth+1;t&&(f.value=0),f.children=e}else t&&(f.value=+t.call(n,f,f.depth)||0),delete f.children;return st(u,function(n){var u,r;i&&(u=n.children)&&u.sort(i),t&&(r=n.parent)&&(r.value+=n.value)}),h}var i=nut,r=frt,t=vrt;return n.sort=function(t){return arguments.length?(i=t,n):i},n.children=function(t){return arguments.length?(r=t,n):r},n.value=function(i){return arguments.length?(t=i,n):t},n.revalue=function(i){return t&&(kr(i,function(n){n.children&&(n.value=0)}),st(i,function(i){var r;i.children||(i.value=+t.call(n,i,i.depth)||0),(r=i.parent)&&(r.value+=i.value)})),i},n},n.layout.partition=function(){function f(n,t,i,r){var e=n.children,u,h,s,o;if(n.x=t,n.y=n.depth*r,n.dx=i,n.dy=r,e&&(h=e.length))for(u=-1,i=n.value?i/n.value:0;++u<h;)f(s=e[u],t,o=s.value*i,r),t+=o}function u(n){var r=n.children,i=0,t,f;if(r&&(f=r.length))for(t=-1;++t<f;)i=Math.max(i,u(r[t]));return 1+i}function i(n,i){var e=r.call(this,n,i);return f(e[0],0,t[0],t[1]/u(e[0])),e}var r=n.layout.hierarchy(),t=[1,1];return i.size=function(n){return arguments.length?(t=n,i):t},br(i,r)},n.layout.pie=function(){function t(e){var o=e.map(function(n,i){return+f.call(t,n,i)}),h=+(typeof r=="function"?r.apply(this,arguments):r),l=((typeof i=="function"?i.apply(this,arguments):i)-h)/n.sum(o),c=n.range(e.length),s;return u!=null&&c.sort(u===co?function(n,t){return o[t]-o[n]}:function(n,t){return u(e[n],e[t])}),s=[],c.forEach(function(n){var t;s[n]={data:e[n],value:t=o[n],startAngle:h,endAngle:h+=t*l}}),s}var f=Number,u=co,r=0,i=d;return t.value=function(n){return arguments.length?(f=n,t):f},t.sort=function(n){return arguments.length?(u=n,t):u},t.startAngle=function(n){return arguments.length?(r=n,t):r},t.endAngle=function(n){return arguments.length?(i=n,t):i},t},co={},n.layout.stack=function(){function t(s,h){var a=s.map(function(n,i){return u.call(t,n,i)}),l=a.map(function(n){return n.map(function(n,i){return[f.call(t,n,i),r.call(t,n,i)]})}),y=o.call(t,l,h);a=n.permute(a,y),l=n.permute(l,y);for(var w=e.call(t,l,h),k=a.length,b=a[0].length,v,p,c=0;c<b;++c)for(i.call(t,a[0][c],p=w[c],l[0][c][1]),v=1;v<k;++v)i.call(t,a[v][c],p+=l[v-1][c][1],l[v][c][1]);return s}var u=a,o=oc,e=ec,i=drt,f=rut,r=iut;return t.values=function(n){return arguments.length?(u=n,t):u},t.order=function(n){return arguments.length?(o=typeof n=="function"?n:nv.get(n)||oc,t):o},t.offset=function(n){return arguments.length?(e=typeof n=="function"?n:tv.get(n)||ec,t):e},t.x=function(n){return arguments.length?(f=n,t):f},t.y=function(n){return arguments.length?(r=n,t):r},t.out=function(n){return arguments.length?(i=n,t):i},t},nv=n.map({"inside-out":function(t){for(var h=t.length,i,s=t.map(wrt),c=t.map(krt),l=n.range(h).sort(function(n,t){return s[n]-s[t]}),f=0,u=0,o=[],e=[],r=0;r<h;++r)i=l[r],f<u?(f+=c[i],o.push(i)):(u+=c[i],e.push(i));return e.reverse().concat(o)},reverse:function(t){return n.range(t.length).reverse()},"default":oc}),tv=n.map({silhouette:function(n){for(var s=n.length,e=n[0].length,o=[],u=0,r,i,f=[],t=0;t<e;++t){for(r=0,i=0;r<s;r++)i+=n[r][t][1];i>u&&(u=i),o.push(i)}for(t=0;t<e;++t)f[t]=(u-o[t])/2;return f},wiggle:function(n){var v=n.length,c=n[0],a=c.length,i,t,r,u,l,h,f,e,s,o=[];for(o[0]=e=s=0,t=1;t<a;++t){for(i=0,u=0;i<v;++i)u+=n[i][t][1];for(i=0,l=0,f=c[t][0]-c[t-1][0];i<v;++i){for(r=0,h=(n[i][t][1]-n[i][t-1][1])/(2*f);r<i;++r)h+=(n[r][t][1]-n[r][t-1][1])/f;l+=h*n[i][t][1]}o[t]=e-=u?l/u*f:0,e<s&&(s=e)}for(t=0;t<a;++t)o[t]-=s;return o},expand:function(n){for(var u=n.length,f=n[0].length,o=1/u,t,r,e=[],i=0;i<f;++i){for(t=0,r=0;t<u;t++)r+=n[t][i][1];if(r)for(t=0;t<u;t++)n[t][i][1]/=r;else for(t=0;t<u;t++)n[t][i][1]=o}for(i=0;i<f;++i)e[i]=0;return e},zero:ec}),n.layout.histogram=function(){function t(t,e){for(var a=[],c=t.map(u,this),v=f.call(this,c,e),s=i.call(this,v,c,e),o,e=-1,y=c.length,l=s.length-1,p=r?1:1/y,h;++e<l;)o=a[e]=[],o.dx=s[e+1]-(o.x=s[e]),o.y=0;if(l>0)for(e=-1;++e<y;)h=c[e],h>=v[0]&&h<=v[1]&&(o=a[n.bisect(s,h,1,l)-1],o.y+=p,o.push(t[e]));return a}var r=!0,u=Number,f=fit,i=trt;return t.value=function(n){return arguments.length?(u=n,t):u},t.range=function(n){return arguments.length?(f=o(n),t):f},t.bins=function(n){return arguments.length?(i=typeof n=="number"?function(t){return da(t,n)}:o(n),t):i},t.frequency=function(n){return arguments.length?(r=!!n,t):r},t},n.layout.pack=function(){function i(n,i){var c=f.call(this,n,i),e=c[0],s=r[0],h=r[1],l=t==null?Math.sqrt:typeof t=="function"?t:function(){return t},o;return e.x=e.y=0,st(e,function(n){n.r=+l(n.value)}),st(e,fv),u&&(o=u*(t?1:Math.max(2*e.r/s,2*e.r/h))/2,st(e,function(n){n.r+=o}),st(e,fv),st(e,function(n){n.r-=o})),ev(e,s/2,h/2,t?1:1/Math.max(2*e.r/s,2*e.r/h)),c}var f=n.layout.hierarchy().sort(oit),u=0,r=[1,1],t;return i.size=function(n){return arguments.length?(r=n,i):r},i.radius=function(n){return arguments.length?(t=n==null||typeof n=="function"?n:+n,i):t},i.padding=function(n){return arguments.length?(u=+n,i):u},br(i,f)},n.layout.tree=function(){function r(n,r){var w=e.call(this,n,r),o=w[0],v=s(o);if(st(v,h),v.parent.m=-v.z,kr(v,c),u)kr(o,f);else{var l=o,a=o,y=o;kr(o,function(n){n.x<l.x&&(l=n),n.x>a.x&&(a=n),n.depth>y.depth&&(y=n)});var p=i(l,a)/2-l.x,k=t[0]/(a.x+i(a,l)/2+p),b=t[1]/(y.depth||1);kr(o,function(n){n.x=(n.x+p)*k,n.y=n.depth*b})}return w}function s(n){for(var f={A:null,children:[n]},e=[f],u;(u=e.pop())!=null;)for(var i=u.children,r,t=0,o=i.length;t<o;++t)e.push((i[t]=r={_:i[t],parent:u,children:(r=i[t].children)&&r.slice()||[],A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:t}).a=r);return f.children[0]}function h(n){var r=n.children,f=n.parent.children,t=n.i?f[n.i-1]:null,u;r.length?(bit(n),u=(r[0].z+r[r.length-1].z)/2,t?(n.z=t.z+i(n._,t._),n.m=n.z-u):n.z=u):t&&(n.z=t.z+i(n._,t._)),n.parent.A=o(n,t,n.parent.A||f[0])}function c(n){n._.x=n.z+n.parent.m,n.m+=n.parent.m}function o(n,t,r){if(t){for(var f=n,e=n,u=t,o=f.parent.children[0],h=f.m,c=e.m,l=u.m,a=o.m,s;u=il(u),f=el(f),u&&f;)o=el(o),e=il(e),e.a=n,s=u.z+l-f.z-h+i(u._,f._),s>0&&(kit(dit(u,n,r),n,s),h+=s,c+=s),l+=u.m,h+=f.m,a+=o.m,c+=e.m;u&&!il(e)&&(e.t=u,e.m+=l-c),f&&!el(o)&&(o.t=f,o.m+=h-a,r=n)}return r}function f(n){n.x*=t[0],n.y=n.depth*t[1]}var e=n.layout.hierarchy().sort(null).value(null),i=uv,t=[1,1],u=null;return r.separation=function(n){return arguments.length?(i=n,r):i},r.size=function(n){return arguments.length?(u=(t=n)==null?f:null,r):u?null:t},r.nodeSize=function(n){return arguments.length?(u=(t=n)==null?null:f,r):u?t:null},br(r,e)},n.layout.cluster=function(){function i(n,i){var l=f.call(this,n,i),e=l[0],h,v=0;st(e,function(n){var t=n.children;t&&t.length?(n.x=git(t),n.y=nrt(t)):(n.x=h?v+=u(n,h):0,n.y=0,h=n)});var o=ha(e),s=ca(e),c=o.x-u(o,s)/2,a=s.x+u(s,o)/2;return st(e,r?function(n){n.x=(n.x-e.x)*t[0],n.y=(e.y-n.y)*t[1]}:function(n){n.x=(n.x-c)/(a-c)*t[0],n.y=(1-(e.y?n.y/e.y:1))*t[1]}),l}var f=n.layout.hierarchy().sort(null).value(null),u=uv,t=[1,1],r=!1;return i.separation=function(n){return arguments.length?(u=n,i):u},i.size=function(n){return arguments.length?(r=(t=n)==null,i):r?null:t},i.nodeSize=function(n){return arguments.length?(r=(t=n)!=null,i):r?t:null},br(i,f)},n.layout.treemap=function(){function s(n,t){for(var r=-1,f=n.length,u,i;++r<f;)i=(u=n[r]).value*(t<0?0:t),u.area=isNaN(i)||i<=0?0:i}function v(n){var e=n.children;if(e&&e.length){var r=c(n),t=[],f=e.slice(),a,o=Infinity,y,u=i==="slice"?r.dx:i==="dice"?r.dy:i==="slice-dice"?n.depth&1?r.dy:r.dx:Math.min(r.dx,r.dy),l;for(s(f,r.dx*r.dy/n.value),t.area=0;(l=f.length)>0;)t.push(a=f[l-1]),t.area+=a.area,i!=="squarify"||(y=p(t,u))<=o?(f.pop(),o=y):(t.area-=t.pop().area,h(t,u,r,!1),u=Math.min(r.dx,r.dy),t.length=t.area=0,o=Infinity);t.length&&(h(t,u,r,!0),t.length=t.area=0),e.forEach(v)}}function y(n){var u=n.children;if(u&&u.length){var r=c(n),f=u.slice(),i,t=[];for(s(f,r.dx*r.dy/n.value),t.area=0;i=f.pop();)t.push(i),t.area+=i.area,i.z!=null&&(h(t,i.z?r.dx:r.dy,r,!f.length),t.length=t.area=0);u.forEach(y)}}function p(n,t){for(var r=n.area,i,e=0,u=Infinity,o=-1,s=n.length;++o<s;)(i=n[o].area)&&(i<u&&(u=i),i>e&&(e=i));return r*=r,t*=t,r?Math.max(t*e*f/r,r/(t*u*f)):Infinity}function h(n,t,i,r){var h=-1,c=n.length,s=i.x,o=i.y,e=t?u(n.area/t):0,f;if(t==i.dx){for((r||e>i.dy)&&(e=i.dy);++h<c;)f=n[h],f.x=s,f.y=o,f.dy=e,s+=f.dx=Math.min(i.x+i.dx-s,e?u(f.area/e):0);f.z=!0,f.dx+=i.x+i.dx-s,i.y+=e,i.dy-=e}else{for((r||e>i.dx)&&(e=i.dx);++h<c;)f=n[h],f.x=s,f.y=o,f.dx=e,o+=f.dy=Math.min(i.y+i.dy-o,e?u(f.area/e):0);f.z=!1,f.dy+=i.y+i.dy-o,i.x+=e,i.dx-=e}}function t(n){var i=r||o(n),t=i[0];return t.x=0,t.y=0,t.dx=e[0],t.dy=e[1],r&&o.revalue(t),s([t],t.dx*t.dy/t.value),(r?y:v)(t),l&&(r=i),i}var o=n.layout.hierarchy(),u=Math.round,e=[1,1],a=null,c=lh,l=!1,r,i="squarify",f=.5*(1+Math.sqrt(5));return t.size=function(n){return arguments.length?(e=n,t):e},t.padding=function(n){function u(i){var r=n.call(t,i,i.depth);return r==null?lh(i):va(i,typeof r=="number"?[r,r,r,r]:r)}function i(t){return va(t,n)}if(!arguments.length)return a;var r;return c=(a=n)==null?lh:(r=typeof n)=="function"?u:r==="number"?(n=[n,n,n,n],i):i,t},t.round=function(n){return arguments.length?(u=n?Math.round:Number,t):u!=Number},t.sticky=function(n){return arguments.length?(l=n,r=null,t):l},t.ratio=function(n){return arguments.length?(f=n,t):f},t.mode=function(n){return arguments.length?(i=n+"",t):i},br(t,o)},n.random={normal:function(n,t){var i=arguments.length;return i<2&&(t=1),i<1&&(n=0),function(){var r,u,i;do r=Math.random()*2-1,u=Math.random()*2-1,i=r*r+u*u;while(!i||i>1);return n+t*r*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(){var t=n.random.normal.apply(n,arguments);return function(){return Math.exp(t())}},bates:function(t){var i=n.random.irwinHall(t);return function(){return i()/t}},irwinHall:function(n){return function(){for(var i=0,t=0;t<n;t++)i+=Math.random();return i}}},n.scale={},kv={floor:a,ceil:a},n.scale.linear=function(){return bl([0,1],[0,1],wi,!1)},lv={s:1,g:1,p:1,r:1,e:1},n.scale.log=function(){return vv(n.scale.linear().domain([0,1]),10,!0,[1,10])},wc=n.format(".0e"),yv={floor:function(n){return-Math.ceil(-n)},ceil:function(n){return-Math.floor(-n)}},n.scale.pow=function(){return sl(n.scale.linear(),1,[0,1])},n.scale.sqrt=function(){return n.scale.pow().exponent(.5)},n.scale.ordinal=function(){return cl([],{t:"range",a:[[]]})},n.scale.category10=function(){return n.scale.ordinal().range(nd)},n.scale.category20=function(){return n.scale.ordinal().range(dk)},n.scale.category20b=function(){return n.scale.ordinal().range(lk)},n.scale.category20c=function(){return n.scale.ordinal().range(fk)};var nd=[2062260,16744206,2924588,14034728,9725885,9197131,14907330,8355711,12369186,1556175].map(pe),dk=[2062260,11454440,16744206,16759672,2924588,10018698,14034728,16750742,9725885,12955861,9197131,12885140,14907330,16234194,8355711,13092807,12369186,14408589,1556175,10410725].map(pe),lk=[3750777,5395619,7040719,10264286,6519097,9216594,11915115,13556636,9202993,12426809,15186514,15190932,8666169,11356490,14049643,15177372,8077683,10834324,13528509,14589654].map(pe),fk=[3244733,7057110,10406625,13032431,15095053,16616764,16625259,16634018,3253076,7652470,10607003,13101504,7695281,10394312,12369372,14342891,6513507,9868950,12434877,14277081].map(pe);n.scale.quantile=function(){return ia([],[])},n.scale.quantize=function(){return ra(0,1,[0,1])},n.scale.threshold=function(){return na([.5],[0,1])},n.scale.identity=function(){return fa([0,1])},n.svg={},n.svg.arc=function(){function n(){var e=i.apply(this,arguments),n=r.apply(this,arguments),s=u.apply(this,arguments)+dt,o=t.apply(this,arguments)+dt,h=(o<s&&(h=s,s=o,o=h),o-s),v=h<f?"0":"1",y=Math.cos(s),a=Math.sin(s),c=Math.cos(o),l=Math.sin(o);return h>=yl?e?"M0,"+n+"A"+n+","+n+" 0 1,1 0,"+-n+"A"+n+","+n+" 0 1,1 0,"+n+"M0,"+e+"A"+e+","+e+" 0 1,0 0,"+-e+"A"+e+","+e+" 0 1,0 0,"+e+"Z":"M0,"+n+"A"+n+","+n+" 0 1,1 0,"+-n+"A"+n+","+n+" 0 1,1 0,"+n+"Z":e?"M"+n*y+","+n*a+"A"+n+","+n+" 0 "+v+",1 "+n*c+","+n*l+"L"+e*c+","+e*l+"A"+e+","+e+" 0 "+v+",0 "+e*y+","+e*a+"Z":"M"+n*y+","+n*a+"A"+n+","+n+" 0 "+v+",1 "+n*c+","+n*l+"L0,0Z"}var i=td,r=tg,u=pl,t=al;return n.innerRadius=function(t){return arguments.length?(i=o(t),n):i},n.outerRadius=function(t){return arguments.length?(r=o(t),n):r},n.startAngle=function(t){return arguments.length?(u=o(t),n):u},n.endAngle=function(i){return arguments.length?(t=o(i),n):t},n.centroid=function(){var f=(i.apply(this,arguments)+r.apply(this,arguments))/2,n=(u.apply(this,arguments)+t.apply(this,arguments))/2+dt;return[Math.cos(n)*f,Math.sin(n)*f]},n},dt=-y,yl=d-t,n.svg.line=function(){return vl(a)},ce=n.map({linear:g,"linear-closed":dd,step:gd,"step-before":kc,"step-after":hc,basis:dl,"basis-open":og,"basis-closed":bd,bundle:ed,cardinal:sg,"cardinal-open":cg,"cardinal-closed":lg,monotone:ud}),ce.forEach(function(n,t){t.key=n,t.closed=/-closed$/.test(n)});var kl=[0,2/3,1/3,0],ua=[0,1/3,2/3,0],oi=[0,1/6,2/3,1/6];n.svg.line.radial=function(){var n=vl(hl);return n.radius=n.x,delete n.x,n.angle=n.y,delete n.y,n},kc.reverse=hc,hc.reverse=kc,n.svg.area=function(){return sa(a)},n.svg.area.radial=function(){var n=sa(hl);return n.radius=n.x,delete n.x,n.innerRadius=n.x0,delete n.x0,n.outerRadius=n.x1,delete n.x1,n.angle=n.y,delete n.y,n.startAngle=n.y0,delete n.y0,n.endAngle=n.y1,delete n.y1,n},n.svg.chord=function(){function n(n,t){var r=c(this,u,n,t),f=c(this,e,n,t);return"M"+r.p0+h(r.r,r.p1,r.a1-r.a0)+(l(r,f)?i(r.r,r.p1,r.r,r.p0):i(r.r,r.p1,f.r,f.p0)+h(f.r,f.p1,f.a1-f.a0)+i(f.r,f.p1,r.r,r.p0))+"Z"}function c(n,i,u,f){var c=i.call(n,u,f),e=s.call(n,c,f),h=r.call(n,c,f)+dt,o=t.call(n,c,f)+dt;return{r:e,a0:h,a1:o,p0:[e*Math.cos(h),e*Math.sin(h)],p1:[e*Math.cos(o),e*Math.sin(o)]}}function l(n,t){return n.a0==t.a0&&n.a1==t.a1}function h(n,t,i){return"A"+n+","+n+" 0 "+ +(i>f)+",1 "+t}function i(n,t,i,r){return"Q 0,0 "+r}var u=as,e=gs,s=hd,r=pl,t=al;return n.radius=function(t){return arguments.length?(s=o(t),n):s},n.source=function(t){return arguments.length?(u=o(t),n):u},n.target=function(t){return arguments.length?(e=o(t),n):e},n.startAngle=function(t){return arguments.length?(r=o(t),n):r},n.endAngle=function(i){return arguments.length?(t=o(i),n):t},n},n.svg.diagonal=function(){function n(n,u){var e=t.call(this,n,u),o=r.call(this,n,u),s=(e.y+o.y)/2,f=[e,{x:e.x,y:s},{x:o.x,y:s},o];return f=f.map(i),"M"+f[0]+"C"+f[1]+" "+f[2]+" "+f[3]}var t=as,r=gs,i=av;return n.source=function(i){return arguments.length?(t=o(i),n):t},n.target=function(t){return arguments.length?(r=o(t),n):r},n.projection=function(t){return arguments.length?(i=t,n):i},n},n.svg.diagonal.radial=function(){var t=n.svg.diagonal(),i=av,r=t.projection;return t.projection=function(n){return arguments.length?r(yd(i=n)):i},t},n.svg.symbol=function(){function n(n,r){return(rh.get(t.call(this,n,r))||hv)(i.call(this,n,r))}var t=wd,i=pd;return n.type=function(i){return arguments.length?(t=o(i),n):t},n.size=function(t){return arguments.length?(i=o(t),n):i},n},rh=n.map({circle:hv,cross:function(n){var t=Math.sqrt(n/5)/2;return"M"+-3*t+","+-t+"H"+-t+"V"+-3*t+"H"+t+"V"+-t+"H"+3*t+"V"+t+"H"+t+"V"+3*t+"H"+-t+"V"+t+"H"+-3*t+"Z"},diamond:function(n){var t=Math.sqrt(n/(2*wh)),i=t*wh;return"M0,"+-t+"L"+i+",0 0,"+t+" "+-i+",0Z"},square:function(n){var t=Math.sqrt(n)/2;return"M"+-t+","+-t+"L"+t+","+-t+" "+t+","+t+" "+-t+","+t+"Z"},"triangle-down":function(n){var i=Math.sqrt(n/yr),t=i*yr/2;return"M0,"+t+"L"+i+","+-t+" "+-i+","+-t+"Z"},"triangle-up":function(n){var i=Math.sqrt(n/yr),t=i*yr/2;return"M0,"+-t+"L"+i+","+t+" "+-i+","+t+"Z"}}),n.svg.symbolTypes=rh.keys(),yr=Math.sqrt(3),wh=Math.tan(30*u),l=[],rc=0,l.call=e.call,l.empty=e.empty,l.node=e.node,l.size=e.size,n.transition=function(n){return arguments.length?di?n.transition():n:dc.transition()},n.transition.prototype=l,l.select=function(n){var f=this.id,s=[],e,i,t,u,h;for(n=uc(n),u=-1,h=this.length;++u<h;){s.push(e=[]);for(var o=this[u],r=-1,c=o.length;++r<c;)(t=o[r])&&(i=n.call(t,t.__data__,r,u))?("__data__"in t&&(i.__data__=t.__data__),wf(i,r,f,t.__transition__[f]),e.push(i)):e.push(null)}return pr(s,f)},l.selectAll=function(n){var e=this.id,c=[],l,o,i,f,v,r,a,t,h;for(n=gy(n),r=-1,a=this.length;++r<a;)for(var s=this[r],u=-1,y=s.length;++u<y;)if(i=s[u])for(v=i.__transition__[e],o=n.call(i,i.__data__,u,r),c.push(l=[]),t=-1,h=o.length;++t<h;)(f=o[t])&&wf(f,t,e,v),l.push(f);return pr(c,e)},l.filter=function(n){var f=[],o,e,i,t,u;for(typeof n!="function"&&(n=hy(n)),t=0,u=this.length;t<u;t++){f.push(o=[]);for(var e=this[t],r=0,s=e.length;r<s;r++)(i=e[r])&&n.call(i,i.__data__,r,t)&&o.push(i)}return pr(f,this.id)},l.tween=function(n,t){var i=this.id;return arguments.length<2?this.node().__transition__[i].tween.get(n):ui(this,t==null?function(t){t.__transition__[i].tween.remove(n)}:function(r){r.__transition__[i].tween.set(n,t)})},l.attr=function(t,i){function o(){this.removeAttribute(r)}function s(){this.removeAttributeNS(r.space,r.local)}function f(n){return n==null?o:(n+="",function(){var i=this.getAttribute(r),t;return i!==n&&(t=u(i,n),function(n){this.setAttribute(r,t(n))})})}function e(n){return n==null?s:(n+="",function(){var i=this.getAttributeNS(r.space,r.local),t;return i!==n&&(t=u(i,n),function(n){this.setAttributeNS(r.space,r.local,t(n))})})}if(arguments.length<2){for(i in t)this.attr(i,t[i]);return this}var u=t=="transform"?ya:wi,r=n.ns.qualify(t);return ao(this,"attr."+t,i,r.local?e:f)},l.attrTween=function(t,i){function f(n,t){var u=i.call(this,n,t,this.getAttribute(r));return u&&function(n){this.setAttribute(r,u(n))}}function u(n,t){var u=i.call(this,n,t,this.getAttributeNS(r.space,r.local));return u&&function(n){this.setAttributeNS(r.space,r.local,u(n))}}var r=n.ns.qualify(t);return this.tween("attr."+t,r.local?u:f)},l.style=function(n,t,i){function f(){this.style.removeProperty(n)}function u(t){return t==null?f:(t+="",function(){var u=w.getComputedStyle(this,null).getPropertyValue(n),r;return u!==t&&(r=wi(u,t),function(t){this.style.setProperty(n,r(t),i)})})}var r=arguments.length;if(r<3){if(typeof n!="string"){r<2&&(t="");for(i in n)this.style(i,n[i],t);return this}i=""}return ao(this,"style."+n,t,u)},l.styleTween=function(n,t,i){function r(r,u){var f=t.call(this,r,u,w.getComputedStyle(this,null).getPropertyValue(n));return f&&function(t){this.style.setProperty(n,f(t),i)}}return arguments.length<3&&(i=""),this.tween("style."+n,r)},l.text=function(n){return ao(this,"text",n,ld)},l.remove=function(){return this.each("end.transition",function(){var n;this.__transition__.count<2&&(n=this.parentNode)&&n.removeChild(this)})},l.ease=function(t){var i=this.id;return arguments.length<1?this.node().__transition__[i].ease:(typeof t!="function"&&(t=n.ease.apply(n,arguments)),ui(this,function(n){n.__transition__[i].ease=t}))},l.delay=function(n){var t=this.id;return arguments.length<1?this.node().__transition__[t].delay:ui(this,typeof n=="function"?function(i,r,u){i.__transition__[t].delay=+n.call(i,i.__data__,r,u)}:(n=+n,function(i){i.__transition__[t].delay=n}))},l.duration=function(n){var t=this.id;return arguments.length<1?this.node().__transition__[t].duration:ui(this,typeof n=="function"?function(i,r,u){i.__transition__[t].duration=Math.max(1,n.call(i,i.__data__,r,u))}:(n=Math.max(1,n),function(i){i.__transition__[t].duration=n}))},l.each=function(t,i){var r=this.id,f,u;return arguments.length<2?(f=cf,u=di,di=r,ui(this,function(n,i,u){cf=n.__transition__[r],t.call(n,n.__data__,i,u)}),cf=f,di=u):ui(this,function(u){var f=u.__transition__[r];(f.event||(f.event=n.dispatch("start","end"))).on(t,i)}),this},l.transition=function(){for(var c=this.id,e=++rc,s=[],o,u,r,t,i=0,f=this.length;i<f;i++){s.push(o=[]);for(var u=this[i],n=0,h=u.length;n<h;n++)(r=u[n])&&(t=Object.create(r.__transition__[c]),t.delay+=t.duration,wf(r,n,e,t)),o.push(r)}return pr(s,e)},n.svg.axis=function(){function i(i){i.each(function(){var ft=n.select(this),g=this.__chart__||e,i=this.__chart__=e.copy(),ot=s==null?i.ticks?i.ticks.apply(i,h):i.domain():s,st=o==null?i.tickFormat?i.tickFormat.apply(i,h):a:o,tt=ft.selectAll(".tick").data(ot,i),y=tt.enter().insert("g",".domain").attr("class","tick").style("opacity",t),ht=n.transition(tt.exit()).style("opacity",t).remove(),it=n.transition(tt.order()).style("opacity",1),v,l=pf(i),et=ft.selectAll(".domain").data([0]),d=(et.enter().append("path").attr("class","domain"),n.transition(et)),rt,ut;y.append("line"),y.append("text");var k=y.select("line"),b=it.select("line"),w=tt.select("text").text(st),p=y.select("text"),nt=it.select("text");switch(c){case"bottom":v=la,k.attr("y2",r),p.attr("y",Math.max(r,0)+f),b.attr("x2",0).attr("y2",r),nt.attr("x",0).attr("y",Math.max(r,0)+f),w.attr("dy",".71em").style("text-anchor","middle"),d.attr("d","M"+l[0]+","+u+"V0H"+l[1]+"V"+u);break;case"top":v=la,k.attr("y2",-r),p.attr("y",-(Math.max(r,0)+f)),b.attr("x2",0).attr("y2",-r),nt.attr("x",0).attr("y",-(Math.max(r,0)+f)),w.attr("dy","0em").style("text-anchor","middle"),d.attr("d","M"+l[0]+","+-u+"V0H"+l[1]+"V"+-u);break;case"left":v=aa,k.attr("x2",-r),p.attr("x",-(Math.max(r,0)+f)),b.attr("x2",-r).attr("y2",0),nt.attr("x",-(Math.max(r,0)+f)).attr("y",0),w.attr("dy",".32em").style("text-anchor","end"),d.attr("d","M"+-u+","+l[0]+"H0V"+l[1]+"H"+-u);break;case"right":v=aa,k.attr("x2",r),p.attr("x",Math.max(r,0)+f),b.attr("x2",r).attr("y2",0),nt.attr("x",Math.max(r,0)+f).attr("y",0),w.attr("dy",".32em").style("text-anchor","start"),d.attr("d","M"+u+","+l[0]+"H0V"+l[1]+"H"+u)}i.rangeBand?(rt=i,ut=rt.rangeBand()/2,g=i=function(n){return rt(n)+ut}):g.rangeBand?g=i:ht.call(v,i),y.call(v,g),it.call(v,i)})}var e=n.scale.linear(),c=so,r=6,u=6,f=3,h=[10],s=null,o;return i.scale=function(n){return arguments.length?(e=n,i):e},i.orient=function(n){return arguments.length?(c=n in ka?n+"":so,i):c},i.ticks=function(){return arguments.length?(h=arguments,i):h},i.tickValues=function(n){return arguments.length?(s=n,i):s},i.tickFormat=function(n){return arguments.length?(o=n,i):o},i.tickSize=function(n){var t=arguments.length;return t?(r=+n,u=+arguments[t-1],i):r},i.innerTickSize=function(n){return arguments.length?(r=+n,i):r},i.outerTickSize=function(n){return arguments.length?(u=+n,i):u},i.tickPadding=function(n){return arguments.length?(f=+n,i):f},i.tickSubdivide=function(){return arguments.length&&i},i},so="bottom",ka={top:1,right:1,bottom:1,left:1},n.svg.brush=function(){function f(t){t.each(function(){var e=n.select(this).style("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush",y).on("touchstart.brush",y),h=e.selectAll(".background").data([0]),o,i,s,t;h.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),e.selectAll(".extent").data([0]).enter().append("rect").attr("class","extent").style("cursor","move"),o=e.selectAll(".resize").data(c,a),o.exit().remove(),o.enter().append("g").attr("class",function(n){return"resize "+n}).style("cursor",function(n){return fd[n]}).append("rect").attr("x",function(n){return/[ew]$/.test(n)?-3:null}).attr("y",function(n){return/^[ns]/.test(n)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),o.style("display",f.empty()?"none":null),i=n.transition(e),s=n.transition(h),r&&(t=pf(r),s.attr("x",t[0]).attr("width",t[1]-t[0]),b(i)),u&&(t=pf(u),s.attr("y",t[0]).attr("height",t[1]-t[0]),v(i)),p(i)})}function p(n){n.selectAll(".resize").attr("transform",function(n){return"translate("+t[+/e$/.test(n)]+","+i[+/^s/.test(n)]+")"})}function b(n){n.select(".extent").attr("x",t[0]),n.selectAll(".extent,.n>rect,.s>rect").attr("width",t[1]-t[0])}function v(n){n.select(".extent").attr("y",i[0]),n.selectAll(".extent,.e>rect,.w>rect").attr("height",i[1]-i[0])}function y(){function at(){n.event.keyCode==32&&(a||(y=null,c[0]-=t[1],c[1]-=i[1],a=2),fi())}function vt(){n.event.keyCode==32&&a==2&&(c[0]+=t[1],c[1]+=i[1],a=0,fi())}function tt(){var f=n.mouse(nt),e=!1;g&&(f[0]+=g[0],f[1]+=g[1]),a||(n.event.altKey?(y||(y=[(t[0]+t[1])/2,(i[0]+i[1])/2]),c[0]=t[+(f[0]<y[0])],c[1]=i[+(f[1]<y[1])]):y=null),lt&&ot(f,r,0)&&(b(k),e=!0),ht&&ot(f,u,1)&&(v(k),e=!0),e&&(p(k),it({type:"brush",mode:a?"move":"resize"}))}function ot(n,r,u){var d=pf(r),b=d[0],w=d[1],l=c[u],v=u?i:t,k=v[1]-v[0],f,p;return a&&(b-=l,w-=k+l),f=(u?s:h)?Math.max(b,Math.min(w,n[u])):n[u],a?p=(f+=l)+k:(y&&(l=Math.max(b,Math.min(w,2*y[u]-f))),l<f?(p=f,f=l):p=l),v[0]!=f||v[1]!=p?(u?e=null:o=null,v[0]=f,v[1]=p,!0):void 0}function st(){tt(),k.style("pointer-events","all").selectAll(".resize").style("display",f.empty()?"none":null),n.select("body").style("cursor",null);rt.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null);ct(),it({type:"brushend"})}var nt=this,et=n.select(n.event.target),it=l.of(nt,arguments),k=n.select(nt),d=et.datum(),lt=!/^(n|s)$/.test(d)&&r,ht=!/^(e|w)$/.test(d)&&u,a=et.classed("extent"),ct=ee(),y,c=n.mouse(nt),g,rt=n.select(w).on("keydown.brush",at).on("keyup.brush",vt),ft,ut;if(n.event.changedTouches)rt.on("touchmove.brush",tt).on("touchend.brush",st);else rt.on("mousemove.brush",tt).on("mouseup.brush",st);k.interrupt().selectAll("*").interrupt(),a?(c[0]=t[0]-c[0],c[1]=i[0]-c[1]):d?(ft=+/w$/.test(d),ut=+/^n/.test(d),g=[t[1-ft]-c[0],i[1-ut]-c[1]],c[0]=t[ft],c[1]=i[ut]):n.event.altKey&&(y=c.slice()),k.style("pointer-events","none").selectAll(".resize").style("display",null),n.select("body").style("cursor",et.style("cursor")),it({type:"brushstart"}),tt()}var l=lo(f,"brushstart","brush","brushend"),r=null,u=null,t=[0,0],i=[0,0],o,e,h=!0,s=!0,c=uo[0];return f.event=function(r){r.each(function(){var u=l.of(this,arguments),r={x:t,y:i,i:o,j:e},f=this.__chart__||r;this.__chart__=r,di?n.select(this).transition().each("start.brush",function(){o=f.i,e=f.j,t=f.x,i=f.y,u({type:"brushstart"})}).tween("brush:brush",function(){var f=lf(t,r.x),n=lf(i,r.y);return o=e=null,function(e){t=r.x=f(e),i=r.y=n(e),u({type:"brush",mode:"resize"})}}).each("end.brush",function(){o=r.i,e=r.j,u({type:"brush",mode:"resize"}),u({type:"brushend"})}):(u({type:"brushstart"}),u({type:"brush",mode:"resize"}),u({type:"brushend"}))})},f.x=function(n){return arguments.length?(r=n,c=uo[!r<<1|!u],f):r},f.y=function(n){return arguments.length?(u=n,c=uo[!r<<1|!u],f):u},f.clamp=function(n){return arguments.length?(r&&u?(h=!!n[0],s=!!n[1]):r?h=!!n:u&&(s=!!n),f):r&&u?[h,s]:r?h:u?s:null},f.extent=function(n){var c,l,s,h,a;return arguments.length?(r&&(c=n[0],l=n[1],u&&(c=c[0],l=l[0]),o=[c,l],r.invert&&(c=r(c),l=r(l)),l<c&&(a=c,c=l,l=a),(c!=t[0]||l!=t[1])&&(t=[c,l])),u&&(s=n[0],h=n[1],r&&(s=s[1],h=h[1]),e=[s,h],u.invert&&(s=u(s),h=u(h)),h<s&&(a=s,s=h,h=a),(s!=i[0]||h!=i[1])&&(i=[s,h])),f):(r&&(o?(c=o[0],l=o[1]):(c=t[0],l=t[1],r.invert&&(c=r.invert(c),l=r.invert(l)),l<c&&(a=c,c=l,l=a))),u&&(e?(s=e[0],h=e[1]):(s=i[0],h=i[1],u.invert&&(s=u.invert(s),h=u.invert(h)),h<s&&(a=s,s=h,h=a))),r&&u?[[c,s],[l,h]]:r?[c,l]:u&&[s,h])},f.clear=function(){return f.empty()||(t=[0,0],i=[0,0],o=e=null),f},f.empty=function(){return!!r&&t[0]==t[1]||!!u&&i[0]==i[1]},n.rebind(f,l,"on")};var fd={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},uo=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]],bs=i.format=sc.timeFormat,iy=bs.utc,bv=iy("%Y-%m-%dT%H:%M:%S.%LZ");bs.iso=Date.prototype.toISOString&&+new Date("2000-01-01T00:00:00.000Z")?es:bv,es.parse=function(n){var t=new Date(n);return isNaN(t)?null:t},es.toString=bv.toString,i.second=bi(function(n){return new v(Math.floor(n/1e3)*1e3)},function(n,t){n.setTime(n.getTime()+Math.floor(t)*1e3)},function(n){return n.getSeconds()}),i.seconds=i.second.range,i.seconds.utc=i.second.utc.range,i.minute=bi(function(n){return new v(Math.floor(n/6e4)*6e4)},function(n,t){n.setTime(n.getTime()+Math.floor(t)*6e4)},function(n){return n.getMinutes()}),i.minutes=i.minute.range,i.minutes.utc=i.minute.utc.range,i.hour=bi(function(n){var t=n.getTimezoneOffset()/60;return new v((Math.floor(n/36e5-t)+t)*36e5)},function(n,t){n.setTime(n.getTime()+Math.floor(t)*36e5)},function(n){return n.getHours()}),i.hours=i.hour.range,i.hours.utc=i.hour.utc.range,i.month=bi(function(n){return n=i.day(n),n.setDate(1),n},function(n,t){n.setMonth(n.getMonth()+t)},function(n){return n.getMonth()}),i.months=i.month.range,i.months.utc=i.month.utc.range;var fe=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],nh=[[i.second,1],[i.second,5],[i.second,15],[i.second,30],[i.minute,1],[i.minute,5],[i.minute,15],[i.minute,30],[i.hour,1],[i.hour,3],[i.hour,6],[i.hour,12],[i.day,1],[i.day,2],[i.week,1],[i.month,1],[i.month,3],[i.year,1]],ck=bs.multi([[".%L",function(n){return n.getMilliseconds()}],[":%S",function(n){return n.getSeconds()}],["%I:%M",function(n){return n.getMinutes()}],["%I %p",function(n){return n.getHours()}],["%a %d",function(n){return n.getDay()&&n.getDate()!=1}],["%b %d",function(n){return n.getDate()!=1}],["%B",function(n){return n.getMonth()}],["%Y",or]]),ak={range:function(t,i,r){return n.range(Math.ceil(t/r)*r,+i,r).map(yi)},floor:a,ceil:a};nh.year=i.year,i.scale=function(){return ss(n.scale.linear(),nh,ck)},wo=nh.map(function(n){return[n[0].utc,n[1]]}),wl=iy.multi([[".%L",function(n){return n.getUTCMilliseconds()}],[":%S",function(n){return n.getUTCSeconds()}],["%I:%M",function(n){return n.getUTCMinutes()}],["%I %p",function(n){return n.getUTCHours()}],["%a %d",function(n){return n.getUTCDay()&&n.getUTCDate()!=1}],["%b %d",function(n){return n.getUTCDate()!=1}],["%B",function(n){return n.getUTCMonth()}],["%Y",or]]),wo.year=i.year.utc,i.scale.utc=function(){return ss(n.scale.linear(),wo,wl)},n.text=uh(function(n){return n.responseText}),n.json=function(n,t){return nf(n,"application/json",yk,t)},n.html=function(n,t){return nf(n,"text/html",ek,t)},n.xml=uh(function(n){return n.responseXML}),typeof define=="function"&&define.amd?define(n):typeof module=="object"&&module.exports&&(module.exports=n),this.d3=n}()