1.3333333333333333-h?d:h}},70461:function(o,a,n){var l=n(71828),f=[["sw-resize","s-resize","se-resize"],["w-resize","move","e-resize"],["nw-resize","n-resize","ne-resize"]];o.exports=function(s,u,d,h){return s=d==="left"?0:d==="center"?1:d==="right"?2:l.constrain(Math.floor(3*s),0,2),u=h==="bottom"?0:h==="middle"?1:h==="top"?2:l.constrain(Math.floor(3*u),0,2),f[u][s]}},64505:function(o,a){a.selectMode=function(n){return n==="lasso"||n==="select"},a.drawMode=function(n){return n==="drawclosedpath"||n==="drawopenpath"||n==="drawline"||n==="drawrect"||n==="drawcircle"},a.openMode=function(n){return n==="drawline"||n==="drawopenpath"},a.rectMode=function(n){return n==="select"||n==="drawline"||n==="drawrect"||n==="drawcircle"},a.freeMode=function(n){return n==="lasso"||n==="drawclosedpath"||n==="drawopenpath"},a.selectingOrDrawing=function(n){return a.freeMode(n)||a.rectMode(n)}},28569:function(o,a,n){var l=n(48956),f=n(57035),s=n(38520),u=n(71828).removeElement,d=n(85555),h=o.exports={};h.align=n(92807),h.getCursor=n(70461);var p=n(26041);function g(){var v=document.createElement("div");v.className="dragcover";var m=v.style;return m.position="fixed",m.left=0,m.right=0,m.top=0,m.bottom=0,m.zIndex=999999999,m.background="none",document.body.appendChild(v),v}function y(v){return l(v.changedTouches?v.changedTouches[0]:v,document.body)}h.unhover=p.wrapped,h.unhoverRaw=p.raw,h.init=function(v){var m,b,x,_,w,k,T,M,S=v.gd,C=1,P=S._context.doubleClickDelay,D=v.element;S._mouseDownTime||(S._mouseDownTime=0),D.style.pointerEvents="all",D.onmousedown=R,s?(D._ontouchstart&&D.removeEventListener("touchstart",D._ontouchstart),D._ontouchstart=R,D.addEventListener("touchstart",R,{passive:!1})):D.ontouchstart=R;var O=v.clampFn||function(z,B,$){return Math.abs(z)<$&&(z=0),Math.abs(B)<$&&(B=0),[z,B]};function R(z){S._dragged=!1,S._dragging=!0;var B=y(z);m=B[0],b=B[1],T=z.target,k=z,M=z.buttons===2||z.ctrlKey,z.clientX===void 0&&z.clientY===void 0&&(z.clientX=m,z.clientY=b),(x=new Date().getTime())-S._mouseDownTimeP&&(C=Math.max(C-1,1)),S._dragged)v.doneFn&&v.doneFn();else if(v.clickFn&&v.clickFn(C,k),!M){var B;try{B=new MouseEvent("click",z)}catch{var $=y(z);(B=document.createEvent("MouseEvents")).initMouseEvent("click",z.bubbles,z.cancelable,z.view,z.detail,z.screenX,z.screenY,$[0],$[1],z.ctrlKey,z.altKey,z.shiftKey,z.metaKey,z.button,z.relatedTarget)}T.dispatchEvent(B)}S._dragging=!1,S._dragged=!1}else S._dragged=!1}},h.coverSlip=g},26041:function(o,a,n){var l=n(11086),f=n(79990),s=n(24401).getGraphDiv,u=n(26675),d=o.exports={};d.wrapped=function(h,p,g){(h=s(h))._fullLayout&&f.clear(h._fullLayout._uid+u.HOVERID),d.raw(h,p,g)},d.raw=function(h,p){var g=h._fullLayout,y=h._hoverdata;p||(p={}),p.target&&!h._dragged&&l.triggerHandler(h,"plotly_beforehover",p)===!1||(g._hoverlayer.selectAll("g").remove(),g._hoverlayer.selectAll("line").remove(),g._hoverlayer.selectAll("circle").remove(),h._hoverdata=void 0,p.target&&y&&h.emit("plotly_unhover",{event:p,points:y}))}},79952:function(o,a){a.P={valType:"string",values:["solid","dot","dash","longdash","dashdot","longdashdot"],dflt:"solid",editType:"style"},a.u={shape:{valType:"enumerated",values:["","/","\\","x","-","|","+","."],dflt:"",arrayOk:!0,editType:"style"},fillmode:{valType:"enumerated",values:["replace","overlay"],dflt:"replace",editType:"style"},bgcolor:{valType:"color",arrayOk:!0,editType:"style"},fgcolor:{valType:"color",arrayOk:!0,editType:"style"},fgopacity:{valType:"number",editType:"style",min:0,max:1},size:{valType:"number",min:0,dflt:8,arrayOk:!0,editType:"style"},solidity:{valType:"number",min:0,max:1,dflt:.3,arrayOk:!0,editType:"style"},editType:"style"}},91424:function(o,a,n){var l=n(39898),f=n(71828),s=f.numberFormat,u=n(92770),d=n(84267),h=n(73972),p=n(7901),g=n(21081),y=f.strTranslate,v=n(63893),m=n(77922),b=n(18783).LINE_SPACING,x=n(37822).DESELECTDIM,_=n(34098),w=n(39984),k=n(23469).appendArrayPointValue,T=o.exports={};function M(ce,ye,J){var ne=ye.fillpattern,de=ne&&T.getPatternAttr(ne.shape,0,"");if(de){var xe=T.getPatternAttr(ne.bgcolor,0,null),ue=T.getPatternAttr(ne.fgcolor,0,null),ge=ne.fgopacity,be=T.getPatternAttr(ne.size,0,8),we=T.getPatternAttr(ne.solidity,0,.3),ke=ye.uid;T.pattern(ce,"point",J,ke,de,be,we,void 0,ne.fillmode,xe,ue,ge)}else ye.fillcolor&&ce.call(p.fill,ye.fillcolor)}T.font=function(ce,ye,J,ne){f.isPlainObject(ye)&&(ne=ye.color,J=ye.size,ye=ye.family),ye&&ce.style("font-family",ye),J+1&&ce.style("font-size",J+"px"),ne&&ce.call(p.fill,ne)},T.setPosition=function(ce,ye,J){ce.attr("x",ye).attr("y",J)},T.setSize=function(ce,ye,J){ce.attr("width",ye).attr("height",J)},T.setRect=function(ce,ye,J,ne,de){ce.call(T.setPosition,ye,J).call(T.setSize,ne,de)},T.translatePoint=function(ce,ye,J,ne){var de=J.c2p(ce.x),xe=ne.c2p(ce.y);return!!(u(de)&&u(xe)&&ye.node())&&(ye.node().nodeName==="text"?ye.attr("x",de).attr("y",xe):ye.attr("transform",y(de,xe)),!0)},T.translatePoints=function(ce,ye,J){ce.each(function(ne){var de=l.select(this);T.translatePoint(ne,de,ye,J)})},T.hideOutsideRangePoint=function(ce,ye,J,ne,de,xe){ye.attr("display",J.isPtWithinRange(ce,de)&&ne.isPtWithinRange(ce,xe)?null:"none")},T.hideOutsideRangePoints=function(ce,ye){if(ye._hasClipOnAxisFalse){var J=ye.xaxis,ne=ye.yaxis;ce.each(function(de){var xe=de[0].trace,ue=xe.xcalendar,ge=xe.ycalendar,be=h.traceIs(xe,"bar-like")?".bartext":".point,.textpoint";ce.selectAll(be).each(function(we){T.hideOutsideRangePoint(we,l.select(this),J,ne,ue,ge)})})}},T.crispRound=function(ce,ye,J){return ye&&u(ye)?ce._context.staticPlot?ye:ye<1?1:Math.round(ye):J||0},T.singleLineStyle=function(ce,ye,J,ne,de){ye.style("fill","none");var xe=(((ce||[])[0]||{}).trace||{}).line||{},ue=J||xe.width||0,ge=de||xe.dash||"";p.stroke(ye,ne||xe.color),T.dashLine(ye,ge,ue)},T.lineGroupStyle=function(ce,ye,J,ne){ce.style("fill","none").each(function(de){var xe=(((de||[])[0]||{}).trace||{}).line||{},ue=ye||xe.width||0,ge=ne||xe.dash||"";l.select(this).call(p.stroke,J||xe.color).call(T.dashLine,ge,ue)})},T.dashLine=function(ce,ye,J){J=+J||0,ye=T.dashStyle(ye,J),ce.style({"stroke-dasharray":ye,"stroke-width":J+"px"})},T.dashStyle=function(ce,ye){ye=+ye||1;var J=Math.max(ye,3);return ce==="solid"?ce="":ce==="dot"?ce=J+"px,"+J+"px":ce==="dash"?ce=3*J+"px,"+3*J+"px":ce==="longdash"?ce=5*J+"px,"+5*J+"px":ce==="dashdot"?ce=3*J+"px,"+J+"px,"+J+"px,"+J+"px":ce==="longdashdot"&&(ce=5*J+"px,"+2*J+"px,"+J+"px,"+2*J+"px"),ce},T.singleFillStyle=function(ce,ye){var J=l.select(ce.node());M(ce,((J.data()[0]||[])[0]||{}).trace||{},ye)},T.fillGroupStyle=function(ce,ye){ce.style("stroke-width",0).each(function(J){var ne=l.select(this);J[0].trace&&M(ne,J[0].trace,ye)})};var S=n(90998);T.symbolNames=[],T.symbolFuncs=[],T.symbolBackOffs=[],T.symbolNeedLines={},T.symbolNoDot={},T.symbolNoFill={},T.symbolList=[],Object.keys(S).forEach(function(ce){var ye=S[ce],J=ye.n;T.symbolList.push(J,String(J),ce,J+100,String(J+100),ce+"-open"),T.symbolNames[J]=ce,T.symbolFuncs[J]=ye.f,T.symbolBackOffs[J]=ye.backoff||0,ye.needLine&&(T.symbolNeedLines[J]=!0),ye.noDot?T.symbolNoDot[J]=!0:T.symbolList.push(J+200,String(J+200),ce+"-dot",J+300,String(J+300),ce+"-open-dot"),ye.noFill&&(T.symbolNoFill[J]=!0)});var C=T.symbolNames.length;function P(ce,ye,J,ne){var de=ce%100;return T.symbolFuncs[de](ye,J,ne)+(ce>=200?"M0,0.5L0.5,0L0,-0.5L-0.5,0Z":"")}T.symbolNumber=function(ce){if(u(ce))ce=+ce;else if(typeof ce=="string"){var ye=0;ce.indexOf("-open")>0&&(ye=100,ce=ce.replace("-open","")),ce.indexOf("-dot")>0&&(ye+=200,ce=ce.replace("-dot","")),(ce=T.symbolNames.indexOf(ce))>=0&&(ce+=ye)}return ce%100>=C||ce>=400?0:Math.floor(Math.max(ce,0))};var D={x1:1,x2:0,y1:0,y2:0},O={x1:0,x2:0,y1:1,y2:0},R=s("~f"),F={radial:{node:"radialGradient"},radialreversed:{node:"radialGradient",reversed:!0},horizontal:{node:"linearGradient",attrs:D},horizontalreversed:{node:"linearGradient",attrs:D,reversed:!0},vertical:{node:"linearGradient",attrs:O},verticalreversed:{node:"linearGradient",attrs:O,reversed:!0}};T.gradient=function(ce,ye,J,ne,de,xe){for(var ue=de.length,ge=F[ne],be=new Array(ue),we=0;we=0&&ce.i===void 0&&(ce.i=xe.i),ye.style("opacity",ne.selectedOpacityFn?ne.selectedOpacityFn(ce):ce.mo===void 0?ue.opacity:ce.mo),ne.ms2mrc){var be;be=ce.ms==="various"||ue.size==="various"?3:ne.ms2mrc(ce.ms),ce.mrc=be,ne.selectedSizeFn&&(be=ce.mrc=ne.selectedSizeFn(ce));var we=T.symbolNumber(ce.mx||ue.symbol)||0;ce.om=we%200>=100;var ke=Me(ce,J),Ae=Y(ce,J);ye.attr("d",P(we,be,ke,Ae))}var Ee,De,Re,Ie=!1;if(ce.so)Re=ge.outlierwidth,De=ge.outliercolor,Ee=ue.outliercolor;else{var Be=(ge||{}).width;Re=(ce.mlw+1||Be+1||(ce.trace?(ce.trace.marker.line||{}).width:0)+1)-1||0,De="mlc"in ce?ce.mlcc=ne.lineScale(ce.mlc):f.isArrayOrTypedArray(ge.color)?p.defaultLine:ge.color,f.isArrayOrTypedArray(ue.color)&&(Ee=p.defaultLine,Ie=!0),Ee="mc"in ce?ce.mcc=ne.markerScale(ce.mc):ue.color||ue.colors||"rgba(0,0,0,0)",ne.selectedColorFn&&(Ee=ne.selectedColorFn(ce))}if(ce.om)ye.call(p.stroke,Ee).style({"stroke-width":(Re||1)+"px",fill:"none"});else{ye.style("stroke-width",(ce.isBlank?0:Re)+"px");var Ue=ue.gradient,qe=ce.mgt;qe?Ie=!0:qe=Ue&&Ue.type,f.isArrayOrTypedArray(qe)&&(qe=qe[0],F[qe]||(qe=0));var Ye=ue.pattern,at=Ye&&T.getPatternAttr(Ye.shape,ce.i,"");if(qe&&qe!=="none"){var lt=ce.mgc;lt?Ie=!0:lt=Ue.color;var ct=J.uid;Ie&&(ct+="-"+ce.i),T.gradient(ye,de,ct,qe,[[0,lt],[1,Ee]],"fill")}else if(at){var bt=!1,ze=Ye.fgcolor;!ze&&xe&&xe.color&&(ze=xe.color,bt=!0);var Ne=T.getPatternAttr(ze,ce.i,xe&&xe.color||null),Qe=T.getPatternAttr(Ye.bgcolor,ce.i,null),it=Ye.fgopacity,kt=T.getPatternAttr(Ye.size,ce.i,8),Je=T.getPatternAttr(Ye.solidity,ce.i,.3);bt=bt||ce.mcc||f.isArrayOrTypedArray(Ye.shape)||f.isArrayOrTypedArray(Ye.bgcolor)||f.isArrayOrTypedArray(Ye.fgcolor)||f.isArrayOrTypedArray(Ye.size)||f.isArrayOrTypedArray(Ye.solidity);var ut=J.uid;bt&&(ut+="-"+ce.i),T.pattern(ye,"point",de,ut,at,kt,Je,ce.mcc,Ye.fillmode,Qe,Ne,it)}else f.isArrayOrTypedArray(Ee)?p.fill(ye,Ee[ce.i]):p.fill(ye,Ee);Re&&p.stroke(ye,De)}},T.makePointStyleFns=function(ce){var ye={},J=ce.marker;return ye.markerScale=T.tryColorscale(J,""),ye.lineScale=T.tryColorscale(J,"line"),h.traceIs(ce,"symbols")&&(ye.ms2mrc=_.isBubble(ce)?w(ce):function(){return(J.size||6)/2}),ce.selectedpoints&&f.extendFlat(ye,T.makeSelectedPointStyleFns(ce)),ye},T.makeSelectedPointStyleFns=function(ce){var ye={},J=ce.selected||{},ne=ce.unselected||{},de=ce.marker||{},xe=J.marker||{},ue=ne.marker||{},ge=de.opacity,be=xe.opacity,we=ue.opacity,ke=be!==void 0,Ae=we!==void 0;(f.isArrayOrTypedArray(ge)||ke||Ae)&&(ye.selectedOpacityFn=function(at){var lt=at.mo===void 0?de.opacity:at.mo;return at.selected?ke?be:lt:Ae?we:x*lt});var Ee=de.color,De=xe.color,Re=ue.color;(De||Re)&&(ye.selectedColorFn=function(at){var lt=at.mcc||Ee;return at.selected?De||lt:Re||lt});var Ie=de.size,Be=xe.size,Ue=ue.size,qe=Be!==void 0,Ye=Ue!==void 0;return h.traceIs(ce,"symbols")&&(qe||Ye)&&(ye.selectedSizeFn=function(at){var lt=at.mrc||Ie/2;return at.selected?qe?Be/2:lt:Ye?Ue/2:lt}),ye},T.makeSelectedTextStyleFns=function(ce){var ye={},J=ce.selected||{},ne=ce.unselected||{},de=ce.textfont||{},xe=J.textfont||{},ue=ne.textfont||{},ge=de.color,be=xe.color,we=ue.color;return ye.selectedTextColorFn=function(ke){var Ae=ke.tc||ge;return ke.selected?be||Ae:we||(be?Ae:p.addOpacity(Ae,x))},ye},T.selectedPointStyle=function(ce,ye){if(ce.size()&&ye.selectedpoints){var J=T.makeSelectedPointStyleFns(ye),ne=ye.marker||{},de=[];J.selectedOpacityFn&&de.push(function(xe,ue){xe.style("opacity",J.selectedOpacityFn(ue))}),J.selectedColorFn&&de.push(function(xe,ue){p.fill(xe,J.selectedColorFn(ue))}),J.selectedSizeFn&&de.push(function(xe,ue){var ge=ue.mx||ne.symbol||0,be=J.selectedSizeFn(ue);xe.attr("d",P(T.symbolNumber(ge),be,Me(ue,ye),Y(ue,ye))),ue.mrc2=be}),de.length&&ce.each(function(xe){for(var ue=l.select(this),ge=0;ge0?J:0}function N(ce,ye,J){return J&&(ce=H(ce)),ye?W(ce[1]):E(ce[0])}function E(ce){var ye=l.round(ce,2);return A=ye,ye}function W(ce){var ye=l.round(ce,2);return z=ye,ye}function G(ce,ye,J,ne){var de=ce[0]-ye[0],xe=ce[1]-ye[1],ue=J[0]-ye[0],ge=J[1]-ye[1],be=Math.pow(de*de+xe*xe,.25),we=Math.pow(ue*ue+ge*ge,.25),ke=(we*we*de-be*be*ue)*ne,Ae=(we*we*xe-be*be*ge)*ne,Ee=3*we*(be+we),De=3*be*(be+we);return[[E(ye[0]+(Ee&&ke/Ee)),W(ye[1]+(Ee&&Ae/Ee))],[E(ye[0]-(De&&ke/De)),W(ye[1]-(De&&Ae/De))]]}T.textPointStyle=function(ce,ye,J){if(ce.size()){var ne;if(ye.selectedpoints){var de=T.makeSelectedTextStyleFns(ye);ne=de.selectedTextColorFn}var xe=ye.texttemplate,ue=J._fullLayout;ce.each(function(ge){var be=l.select(this),we=xe?f.extractOption(ge,ye,"txt","texttemplate"):f.extractOption(ge,ye,"tx","text");if(we||we===0){if(xe){var ke=ye._module.formatLabels,Ae=ke?ke(ge,ye,ue):{},Ee={};k(Ee,ye,ge.i);var De=ye._meta||{};we=f.texttemplateString(we,Ae,ue._d3locale,Ee,ge,De)}var Re=ge.tp||ye.textposition,Ie=j(ge,ye),Be=ne?ne(ge):ge.tc||ye.textfont.color;be.call(T.font,ge.tf||ye.textfont.family,Ie,Be).text(we).call(v.convertToTspans,J).call($,Re,Ie,ge.mrc)}else be.remove()})}},T.selectedTextStyle=function(ce,ye){if(ce.size()&&ye.selectedpoints){var J=T.makeSelectedTextStyleFns(ye);ce.each(function(ne){var de=l.select(this),xe=J.selectedTextColorFn(ne),ue=ne.tp||ye.textposition,ge=j(ne,ye);p.fill(de,xe);var be=h.traceIs(ye,"bar-like");$(de,ue,ge,ne.mrc2||ne.mrc,be)})}},T.smoothopen=function(ce,ye){if(ce.length<3)return"M"+ce.join("L");var J,ne="M"+ce[0],de=[];for(J=1;J=be||at>=ke&&at<=be)&&(lt<=Ae&<>=we||lt>=Ae&<<=we)&&(ce=[at,lt])}return ce}T.steps=function(ce){var ye=L[ce]||q;return function(J){for(var ne="M"+E(J[0][0])+","+W(J[0][1]),de=J.length,xe=1;xe=1e4&&(T.savedBBoxes={},V=0),J&&(T.savedBBoxes[J]=De),V++,f.extendFlat({},De)},T.setClipUrl=function(ce,ye,J){ce.attr("clip-path",ee(ye,J))},T.getTranslate=function(ce){var ye=(ce[ce.attr?"attr":"getAttribute"]("transform")||"").replace(/.*\btranslate\((-?\d*\.?\d*)[^-\d]*(-?\d*\.?\d*)[^\d].*/,function(J,ne,de){return[ne,de].join(" ")}).split(" ");return{x:+ye[0]||0,y:+ye[1]||0}},T.setTranslate=function(ce,ye,J){var ne=ce.attr?"attr":"getAttribute",de=ce.attr?"attr":"setAttribute",xe=ce[ne]("transform")||"";return ye=ye||0,J=J||0,xe=xe.replace(/(\btranslate\(.*?\);?)/,"").trim(),xe=(xe+=y(ye,J)).trim(),ce[de]("transform",xe),xe},T.getScale=function(ce){var ye=(ce[ce.attr?"attr":"getAttribute"]("transform")||"").replace(/.*\bscale\((\d*\.?\d*)[^\d]*(\d*\.?\d*)[^\d].*/,function(J,ne,de){return[ne,de].join(" ")}).split(" ");return{x:+ye[0]||1,y:+ye[1]||1}},T.setScale=function(ce,ye,J){var ne=ce.attr?"attr":"getAttribute",de=ce.attr?"attr":"setAttribute",xe=ce[ne]("transform")||"";return ye=ye||1,J=J||1,xe=xe.replace(/(\bscale\(.*?\);?)/,"").trim(),xe=(xe+="scale("+ye+","+J+")").trim(),ce[de]("transform",xe),xe};var U=/\s*sc.*/;T.setPointGroupScale=function(ce,ye,J){if(ye=ye||1,J=J||1,ce){var ne=ye===1&&J===1?"":"scale("+ye+","+J+")";ce.each(function(){var de=(this.getAttribute("transform")||"").replace(U,"");de=(de+=ne).trim(),this.setAttribute("transform",de)})}};var Q=/translate\([^)]*\)\s*$/;function Y(ce,ye){var J;return ce&&(J=ce.mf),J===void 0&&(J=ye.marker&&ye.marker.standoff||0),ye._geo||ye._xA?J:-J}T.setTextPointsScale=function(ce,ye,J){ce&&ce.each(function(){var ne,de=l.select(this),xe=de.select("text");if(xe.node()){var ue=parseFloat(xe.attr("x")||0),ge=parseFloat(xe.attr("y")||0),be=(de.attr("transform")||"").match(Q);ne=ye===1&&J===1?[]:[y(ue,ge),"scale("+ye+","+J+")",y(-ue,-ge)],be&&ne.push(be),de.attr("transform",ne.join(""))}})},T.getMarkerStandoff=Y;var Z,X,re,ie,le,se,pe=Math.atan2,Te=Math.cos,Se=Math.sin;function Oe(ce,ye){var J=ye[0],ne=ye[1];return[J*Te(ce)-ne*Se(ce),J*Se(ce)+ne*Te(ce)]}function Me(ce,ye){var J,ne,de=ce.ma;de===void 0&&(de=ye.marker.angle||0);var xe=ye.marker.angleref;if(xe==="previous"||xe==="north"){if(ye._geo){var ue=ye._geo.project(ce.lonlat);J=ue[0],ne=ue[1]}else{var ge=ye._xA,be=ye._yA;if(!ge||!be)return 90;J=ge.c2p(ce.x),ne=be.c2p(ce.y)}if(ye._geo){var we,ke=ce.lonlat[0],Ae=ce.lonlat[1],Ee=ye._geo.project([ke,Ae+1e-5]),De=ye._geo.project([ke+1e-5,Ae]),Re=pe(De[1]-ne,De[0]-J),Ie=pe(Ee[1]-ne,Ee[0]-J);if(xe==="north")we=de/180*Math.PI;else if(xe==="previous"){var Be=ke/180*Math.PI,Ue=Ae/180*Math.PI,qe=Z/180*Math.PI,Ye=X/180*Math.PI,at=qe-Be,lt=Te(Ye)*Se(at),ct=Se(Ye)*Te(Ue)-Te(Ye)*Se(Ue)*Te(at);we=-pe(lt,ct)-Math.PI,Z=ke,X=Ae}var bt=Oe(Re,[Te(we),0]),ze=Oe(Ie,[Se(we),0]);de=pe(bt[1]+ze[1],bt[0]+ze[0])/Math.PI*180,xe!=="previous"||se===ye.uid&&ce.i===le+1||(de=null)}if(xe==="previous"&&!ye._geo)if(se===ye.uid&&ce.i===le+1&&u(J)&&u(ne)){var Ne=J-re,Qe=ne-ie,it=ye.line&&ye.line.shape||"",kt=it.slice(it.length-1);kt==="h"&&(Qe=0),kt==="v"&&(Ne=0),de+=pe(Qe,Ne)/Math.PI*180+90}else de=null}return re=J,ie=ne,le=ce.i,se=ye.uid,de}T.getMarkerAngle=Me},90998:function(o,a,n){var l,f,s,u,d=n(95616),h=n(39898).round,p="M0,0Z",g=Math.sqrt(2),y=Math.sqrt(3),v=Math.PI,m=Math.cos,b=Math.sin;function x(w){return w===null}function _(w,k,T){if(!(w&&w%360!=0||k))return T;if(s===w&&u===k&&l===T)return f;function M(N,E){var W=m(N),G=b(N),L=E[0],q=E[1]+(k||0);return[L*W-q*G,L*G+q*W]}s=w,u=k,l=T;for(var S=w/180*v,C=0,P=0,D=d(T),O="",R=0;R0,b=d._context.staticPlot;h.each(function(x){var _,w=x[0].trace,k=w.error_x||{},T=w.error_y||{};w.ids&&(_=function(P){return P.id});var M=u.hasMarkers(w)&&w.marker.maxdisplayed>0;T.visible||k.visible||(x=[]);var S=l.select(this).selectAll("g.errorbar").data(x,_);if(S.exit().remove(),x.length){k.visible||S.selectAll("path.xerror").remove(),T.visible||S.selectAll("path.yerror").remove(),S.style("opacity",1);var C=S.enter().append("g").classed("errorbar",!0);m&&C.style("opacity",0).transition().duration(g.duration).style("opacity",1),s.setClipUrl(S,p.layerClipId,d),S.each(function(P){var D=l.select(this),O=function($,j,N){var E={x:j.c2p($.x),y:N.c2p($.y)};return $.yh!==void 0&&(E.yh=N.c2p($.yh),E.ys=N.c2p($.ys),f(E.ys)||(E.noYS=!0,E.ys=N.c2p($.ys,!0))),$.xh!==void 0&&(E.xh=j.c2p($.xh),E.xs=j.c2p($.xs),f(E.xs)||(E.noXS=!0,E.xs=j.c2p($.xs,!0))),E}(P,y,v);if(!M||P.vis){var R,F=D.select("path.yerror");if(T.visible&&f(O.x)&&f(O.yh)&&f(O.ys)){var A=T.width;R="M"+(O.x-A)+","+O.yh+"h"+2*A+"m-"+A+",0V"+O.ys,O.noYS||(R+="m-"+A+",0h"+2*A),F.size()?m&&(F=F.transition().duration(g.duration).ease(g.easing)):F=D.append("path").style("vector-effect",b?"none":"non-scaling-stroke").classed("yerror",!0),F.attr("d",R)}else F.remove();var z=D.select("path.xerror");if(k.visible&&f(O.y)&&f(O.xh)&&f(O.xs)){var B=(k.copy_ystyle?T:k).width;R="M"+O.xh+","+(O.y-B)+"v"+2*B+"m0,-"+B+"H"+O.xs,O.noXS||(R+="m0,-"+B+"v"+2*B),z.size()?m&&(z=z.transition().duration(g.duration).ease(g.easing)):z=D.append("path").style("vector-effect",b?"none":"non-scaling-stroke").classed("xerror",!0),z.attr("d",R)}else z.remove()}})}})}},62662:function(o,a,n){var l=n(39898),f=n(7901);o.exports=function(s){s.each(function(u){var d=u[0].trace,h=d.error_y||{},p=d.error_x||{},g=l.select(this);g.selectAll("path.yerror").style("stroke-width",h.thickness+"px").call(f.stroke,h.color),p.copy_ystyle&&(p=h),g.selectAll("path.xerror").style("stroke-width",p.thickness+"px").call(f.stroke,p.color)})}},77914:function(o,a,n){var l=n(41940),f=n(528).hoverlabel,s=n(1426).extendFlat;o.exports={hoverlabel:{bgcolor:s({},f.bgcolor,{arrayOk:!0}),bordercolor:s({},f.bordercolor,{arrayOk:!0}),font:l({arrayOk:!0,editType:"none"}),align:s({},f.align,{arrayOk:!0}),namelength:s({},f.namelength,{arrayOk:!0}),editType:"none"}}},30732:function(o,a,n){var l=n(71828),f=n(73972);function s(u,d,h,p){p=p||l.identity,Array.isArray(u)&&(d[0][h]=p(u))}o.exports=function(u){var d=u.calcdata,h=u._fullLayout;function p(b){return function(x){return l.coerceHoverinfo({hoverinfo:x},{_module:b._module},h)}}for(var g=0;g=0&&y.indexde[0]._length||pt<0||pt>xe[0]._length)return b.unhoverRaw(ie,le)}else ut="xpx"in le?le.xpx:de[0]._length/2,pt="ypx"in le?le.ypx:xe[0]._length/2;if(le.pointerX=ut+de[0]._offset,le.pointerY=pt+xe[0]._offset,De="xval"in le?w.flat(Se,le.xval):w.p2c(de,ut),Re="yval"in le?w.flat(Se,le.yval):w.p2c(xe,pt),!f(De[0])||!f(Re[0]))return u.warn("Fx.hover failed",le,ie),b.unhoverRaw(ie,le)}var zt=1/0;function wt(Zt,pn){for(Be=0;BeNe&&(Qe.splice(0,Ne),zt=Qe[0].distance),ye&&Ee!==0&&Qe.length===0){ze.distance=Ee,ze.index=!1;var Pn=qe._module.hoverPoints(ze,ct,bt,"closest",{hoverLayer:Oe._hoverlayer});if(Pn&&(Pn=Pn.filter(function(lr){return lr.spikeDistance<=Ee})),Pn&&Pn.length){var xn,Dn=Pn.filter(function(lr){return lr.xa.showspikes&&lr.xa.spikesnap!=="hovered data"});if(Dn.length){var tr=Dn[0];f(tr.x0)&&f(tr.y0)&&(xn=_e(tr),(!kt.vLinePoint||kt.vLinePoint.spikeDistance>xn.spikeDistance)&&(kt.vLinePoint=xn))}var ia=Pn.filter(function(lr){return lr.ya.showspikes&&lr.ya.spikesnap!=="hovered data"});if(ia.length){var fa=ia[0];f(fa.x0)&&f(fa.y0)&&(xn=_e(fa),(!kt.hLinePoint||kt.hLinePoint.spikeDistance>xn.spikeDistance)&&(kt.hLinePoint=xn))}}}}}function ve(Zt,pn,nn){for(var Kt,Cn=null,_n=1/0,Pn=0;Pn0&&Math.abs(Zt.distance)Ft-1;Vt--)gt(Qe[Vt]);Qe=St,Ze()}var ht=ie._hoverdata,yt=[],qt=te(ie),Et=ee(ie);for(Ie=0;Ie1||Qe.length>1)||ke==="closest"&&Je&&Qe.length>1,cn=m.combine(Oe.plot_bgcolor||m.background,Oe.paper_bgcolor),ln=j(Qe,{gd:ie,hovermode:ke,rotateLabels:tn,bgColor:cn,container:Oe._hoverlayer,outerContainer:Oe._paper.node(),commonLabelOpts:Oe.hoverlabel,hoverdistance:Oe.hoverdistance}),an=ln.hoverLabels;if(w.isUnifiedHover(ke)||(function(Zt,pn,nn,Kt){var Cn,_n,Pn,xn,Dn,tr,ia,fa=pn?"xa":"ya",lr=pn?"ya":"xa",ni=0,Ar=1,ur=Zt.size(),kr=new Array(ur),oa=0,On=Kt.minX,on=Kt.maxX,$n=Kt.minY,Pr=Kt.maxY,Ln=function(Tn){return Tn*nn._invScaleX},Bn=function(Tn){return Tn*nn._invScaleY};function jn(Tn){var Dr=Tn[0],Pa=Tn[Tn.length-1];if(_n=Dr.pmin-Dr.pos-Dr.dp+Dr.size,Pn=Pa.pos+Pa.dp+Pa.size-Dr.pmax,_n>.01){for(Dn=Tn.length-1;Dn>=0;Dn--)Tn[Dn].dp+=_n;Cn=!1}if(!(Pn<.01)){if(_n<-.01){for(Dn=Tn.length-1;Dn>=0;Dn--)Tn[Dn].dp-=Pn;Cn=!1}if(Cn){var Br=0;for(xn=0;xnDr.pmax&&Br++;for(xn=Tn.length-1;xn>=0&&!(Br<=0);xn--)(tr=Tn[xn]).pos>Dr.pmax-1&&(tr.del=!0,Br--);for(xn=0;xn=0;Dn--)Tn[Dn].dp-=Pn;for(xn=Tn.length-1;xn>=0&&!(Br<=0);xn--)(tr=Tn[xn]).pos+tr.dp+tr.size>Dr.pmax&&(tr.del=!0,Br--)}}}for(Zt.each(function(Tn){var Dr=Tn[fa],Pa=Tn[lr],Br=Dr._id.charAt(0)==="x",Ni=Dr.range;oa===0&&Ni&&Ni[0]>Ni[1]!==Br&&(Ar=-1);var ji=0,vi=Br?nn.width:nn.height;if(nn.hovermode==="x"||nn.hovermode==="y"){var ri,Xa,yi=E(Tn,pn),fs=Tn.anchor,rl=fs==="end"?-1:1;if(fs==="middle")Xa=(ri=Tn.crossPos+(Br?Bn(yi.y-Tn.by/2):Ln(Tn.bx/2+Tn.tx2width/2)))+(Br?Bn(Tn.by):Ln(Tn.bx));else if(Br)Xa=(ri=Tn.crossPos+Bn(R+yi.y)-Bn(Tn.by/2-R))+Bn(Tn.by);else{var ds=Ln(rl*R+yi.x),lo=ds+Ln(rl*Tn.bx);ri=Tn.crossPos+Math.min(ds,lo),Xa=Tn.crossPos+Math.max(ds,lo)}Br?$n!==void 0&&Pr!==void 0&&Math.min(Xa,Pr)-Math.max(ri,$n)>1&&(Pa.side==="left"?(ji=Pa._mainLinePosition,vi=nn.width):vi=Pa._mainLinePosition):On!==void 0&&on!==void 0&&Math.min(Xa,on)-Math.max(ri,On)>1&&(Pa.side==="top"?(ji=Pa._mainLinePosition,vi=nn.height):vi=Pa._mainLinePosition)}kr[oa++]=[{datum:Tn,traceIndex:Tn.trace.index,dp:0,pos:Tn.pos,posref:Tn.posref,size:Tn.by*(Br?P:1)/2,pmin:ji,pmax:vi}]}),kr.sort(function(Tn,Dr){return Tn[0].posref-Dr[0].posref||Ar*(Dr[0].traceIndex-Tn[0].traceIndex)});!Cn&&ni<=ur;){for(ni++,Cn=!0,xn=0;xn.01&&br.pmin===Mr.pmin&&br.pmax===Mr.pmax){for(Dn=Lr.length-1;Dn>=0;Dn--)Lr[Dn].dp+=_n;for(Un.push.apply(Un,Lr),kr.splice(xn+1,1),ia=0,Dn=Un.length-1;Dn>=0;Dn--)ia+=Un[Dn].dp;for(Pn=ia/Un.length,Dn=Un.length-1;Dn>=0;Dn--)Un[Dn].dp-=Pn;Cn=!1}else xn++}kr.forEach(jn)}for(xn=kr.length-1;xn>=0;xn--){var ja=kr[xn];for(Dn=ja.length-1;Dn>=0;Dn--){var _a=ja[Dn],la=_a.datum;la.offset=_a.dp,la.del=_a.del}}}(an,tn,Oe,ln.commonLabelBoundingBox),W(an,tn,Oe._invScaleX,Oe._invScaleY)),Te&&Te.tagName){var sn=_.getComponentMethod("annotations","hasClickToShow")(ie,yt);y(l.select(Te),sn?"pointer":"")}Te&&!pe&&function(Zt,pn,nn){if(!nn||nn.length!==Zt._hoverdata.length)return!0;for(var Kt=nn.length-1;Kt>=0;Kt--){var Cn=nn[Kt],_n=Zt._hoverdata[Kt];if(Cn.curveNumber!==_n.curveNumber||String(Cn.pointNumber)!==String(_n.pointNumber)||String(Cn.pointNumbers)!==String(_n.pointNumbers))return!0}return!1}(ie,0,ht)&&(ht&&ie.emit("plotly_unhover",{event:le,points:ht}),ie.emit("plotly_hover",{event:le,points:ie._hoverdata,xaxes:de,yaxes:xe,xvals:De,yvals:Re}))})(Q,Y,Z,X,re)})},a.loneHover=function(Q,Y){var Z=!0;Array.isArray(Q)||(Z=!1,Q=[Q]);var X=Y.gd,re=te(X),ie=ee(X),le=j(Q.map(function(Te){var Se=Te._x0||Te.x0||Te.x||0,Oe=Te._x1||Te.x1||Te.x||0,Me=Te._y0||Te.y0||Te.y||0,ce=Te._y1||Te.y1||Te.y||0,ye=Te.eventData;if(ye){var J=Math.min(Se,Oe),ne=Math.max(Se,Oe),de=Math.min(Me,ce),xe=Math.max(Me,ce),ue=Te.trace;if(_.traceIs(ue,"gl3d")){var ge=X._fullLayout[ue.scene]._scene.container,be=ge.offsetLeft,we=ge.offsetTop;J+=be,ne+=be,de+=we,xe+=we}ye.bbox={x0:J+ie,x1:ne+ie,y0:de+re,y1:xe+re},Y.inOut_bbox&&Y.inOut_bbox.push(ye.bbox)}else ye=!1;return{color:Te.color||m.defaultLine,x0:Te.x0||Te.x||0,x1:Te.x1||Te.x||0,y0:Te.y0||Te.y||0,y1:Te.y1||Te.y||0,xLabel:Te.xLabel,yLabel:Te.yLabel,zLabel:Te.zLabel,text:Te.text,name:Te.name,idealAlign:Te.idealAlign,borderColor:Te.borderColor,fontFamily:Te.fontFamily,fontSize:Te.fontSize,fontColor:Te.fontColor,nameLength:Te.nameLength,textAlign:Te.textAlign,trace:Te.trace||{index:0,hoverinfo:""},xa:{_offset:0},ya:{_offset:0},index:0,hovertemplate:Te.hovertemplate||!1,hovertemplateLabels:Te.hovertemplateLabels||!1,eventData:ye}}),{gd:X,hovermode:"closest",rotateLabels:!1,bgColor:Y.bgColor||m.background,container:l.select(Y.container),outerContainer:Y.outerContainer||Y.container}).hoverLabels,se=0,pe=0;return le.sort(function(Te,Se){return Te.y0-Se.y0}).each(function(Te,Se){var Oe=Te.y0-Te.by/2;Te.offset=Oe-5([\s\S]*)<\/extra>/;function j(Q,Y){var Z=Y.gd,X=Z._fullLayout,re=Y.hovermode,ie=Y.rotateLabels,le=Y.bgColor,se=Y.container,pe=Y.outerContainer,Te=Y.commonLabelOpts||{};if(Q.length===0)return[[]];var Se=Y.fontFamily||k.HOVERFONT,Oe=Y.fontSize||k.HOVERFONTSIZE,Me=Q[0],ce=Me.xa,ye=Me.ya,J=re.charAt(0),ne=J+"Label",de=Me[ne];if(de===void 0&&ce.type==="multicategory")for(var xe=0;xeX.width-jt?(ht=X.width-jt,Ft.attr("d","M"+(jt-R)+",0L"+jt+","+Et+R+"v"+Et+(2*F+qt.height)+"H-"+jt+"V"+Et+R+"H"+(jt-2*R)+"Z")):Ft.attr("d","M0,0L"+R+","+Et+R+"H"+jt+"v"+Et+(2*F+qt.height)+"H-"+jt+"V"+Et+R+"H-"+R+"Z"),Be.minX=ht-jt,Be.maxX=ht+jt,ce.side==="top"?(Be.minY=yt-(2*F+qt.height),Be.maxY=yt-F):(Be.minY=yt+F,Be.maxY=yt+(2*F+qt.height))}else{var Tt,Ot,At;ye.side==="right"?(Tt="start",Ot=1,At="",ht=ce._offset+ce._length):(Tt="end",Ot=-1,At="-",ht=ce._offset),yt=ye._offset+(Me.y0+Me.y1)/2,Vt.attr("text-anchor",Tt),Ft.attr("d","M0,0L"+At+R+","+R+"V"+(F+qt.height/2)+"h"+At+(2*F+qt.width)+"V-"+(F+qt.height/2)+"H"+At+R+"V-"+R+"Z"),Be.minY=yt-(F+qt.height/2),Be.maxY=yt+(F+qt.height/2),ye.side==="right"?(Be.minX=ht+R,Be.maxX=ht+R+(2*F+qt.width)):(Be.minX=ht-R-(2*F+qt.width),Be.maxX=ht-R);var Lt,Rt=qt.height/2,$t=ge-qt.top-Rt,Yt="clip"+X._uid+"commonlabel"+ye._id;if(ht=0?pt:It+wt=0?It:nt+wt=0?Je:ut+ve=0?ut:st+ve=0,tt.idealAlign!=="top"&&tn||!cn?tn?(Rt+=Yt/2,tt.anchor="start"):tt.anchor="middle":(Rt-=Yt/2,tt.anchor="end"),tt.crossPos=Rt;else{if(tt.pos=Rt,tn=Lt+$t/2+ln<=be,cn=Lt-$t/2-ln>=0,tt.idealAlign!=="left"&&tn||!cn)if(tn)Lt+=$t/2,tt.anchor="start";else{tt.anchor="middle";var an=ln/2,sn=Lt+an-be,Zt=Lt-an;sn>0&&(Lt-=sn),Zt<0&&(Lt+=-Zt)}else Lt-=$t/2,tt.anchor="end";tt.crossPos=Lt}Et.attr("text-anchor",tt.anchor),Tt&&jt.attr("text-anchor",tt.anchor),Ft.attr("transform",d(Lt,Rt)+(ie?h(S):""))}),{hoverLabels:mt,commonLabelBoundingBox:Be}}function N(Q,Y,Z,X,re,ie){var le="",se="";Q.nameOverride!==void 0&&(Q.name=Q.nameOverride),Q.name&&(Q.trace._meta&&(Q.name=u.templateString(Q.name,Q.trace._meta)),le=H(Q.name,Q.nameLength));var pe=Z.charAt(0),Te=pe==="x"?"y":"x";Q.zLabel!==void 0?(Q.xLabel!==void 0&&(se+="x: "+Q.xLabel+"
"),Q.yLabel!==void 0&&(se+="y: "+Q.yLabel+"
"),Q.trace.type!=="choropleth"&&Q.trace.type!=="choroplethmapbox"&&(se+=(se?"z: ":"")+Q.zLabel)):Y&&Q[pe+"Label"]===re?se=Q[Te+"Label"]||"":Q.xLabel===void 0?Q.yLabel!==void 0&&Q.trace.type!=="scattercarpet"&&(se=Q.yLabel):se=Q.yLabel===void 0?Q.xLabel:"("+Q.xLabel+", "+Q.yLabel+")",!Q.text&&Q.text!==0||Array.isArray(Q.text)||(se+=(se?"
":"")+Q.text),Q.extraText!==void 0&&(se+=(se?"
":"")+Q.extraText),ie&&se===""&&!Q.hovertemplate&&(le===""&&ie.remove(),se=le);var Se=Q.hovertemplate||!1;if(Se){var Oe=Q.hovertemplateLabels||Q;Q[pe+"Label"]!==re&&(Oe[pe+"other"]=Oe[pe+"Val"],Oe[pe+"otherLabel"]=Oe[pe+"Label"]),se=(se=u.hovertemplateString(Se,Oe,X._d3locale,Q.eventData[0]||{},Q.trace._meta)).replace($,function(Me,ce){return le=H(ce,Q.nameLength),""})}return[se,le]}function E(Q,Y){var Z=0,X=Q.offset;return Y&&(X*=-O,Z=Q.offset*D),{x:Z,y:X}}function W(Q,Y,Z,X){var re=function(le){return le*Z},ie=function(le){return le*X};Q.each(function(le){var se=l.select(this);if(le.del)return se.remove();var pe,Te,Se,Oe,Me=se.select("text.nums"),ce=le.anchor,ye=ce==="end"?-1:1,J=(Oe=(Se=(Te={start:1,end:-1,middle:0}[(pe=le).anchor])*(R+F))+Te*(pe.txwidth+F),pe.anchor==="middle"&&(Se-=pe.tx2width/2,Oe+=pe.txwidth/2+F),{alignShift:Te,textShiftX:Se,text2ShiftX:Oe}),ne=E(le,Y),de=ne.x,xe=ne.y,ue=ce==="middle";se.select("path").attr("d",ue?"M-"+re(le.bx/2+le.tx2width/2)+","+ie(xe-le.by/2)+"h"+re(le.bx)+"v"+ie(le.by)+"h-"+re(le.bx)+"Z":"M0,0L"+re(ye*R+de)+","+ie(R+xe)+"v"+ie(le.by/2-R)+"h"+re(ye*le.bx)+"v-"+ie(le.by)+"H"+re(ye*R+de)+"V"+ie(xe-R)+"Z");var ge=de+J.textShiftX,be=xe+le.ty0-le.by/2+F,we=le.textAlign||"auto";we!=="auto"&&(we==="left"&&ce!=="start"?(Me.attr("text-anchor","start"),ge=ue?-le.bx/2-le.tx2width/2+F:-le.bx-F):we==="right"&&ce!=="end"&&(Me.attr("text-anchor","end"),ge=ue?le.bx/2-le.tx2width/2-F:le.bx+F)),Me.call(g.positionText,re(ge),ie(be)),le.tx2width&&(se.select("text.name").call(g.positionText,re(J.text2ShiftX+J.alignShift*F+de),ie(xe+le.ty0-le.by/2+F)),se.select("rect").call(v.setRect,re(J.text2ShiftX+(J.alignShift-1)*le.tx2width/2+de),ie(xe-le.by/2-1),re(le.tx2width),ie(le.by+2)))})}function G(Q,Y){var Z=Q.index,X=Q.trace||{},re=Q.cd[0],ie=Q.cd[Z]||{};function le(Me){return Me||f(Me)&&Me===0}var se=Array.isArray(Z)?function(Me,ce){var ye=u.castOption(re,Z,Me);return le(ye)?ye:u.extractOption({},X,"",ce)}:function(Me,ce){return u.extractOption(ie,X,Me,ce)};function pe(Me,ce,ye){var J=se(ce,ye);le(J)&&(Q[Me]=J)}if(pe("hoverinfo","hi","hoverinfo"),pe("bgcolor","hbg","hoverlabel.bgcolor"),pe("borderColor","hbc","hoverlabel.bordercolor"),pe("fontFamily","htf","hoverlabel.font.family"),pe("fontSize","hts","hoverlabel.font.size"),pe("fontColor","htc","hoverlabel.font.color"),pe("nameLength","hnl","hoverlabel.namelength"),pe("textAlign","hta","hoverlabel.align"),Q.posref=Y==="y"||Y==="closest"&&X.orientation==="h"?Q.xa._offset+(Q.x0+Q.x1)/2:Q.ya._offset+(Q.y0+Q.y1)/2,Q.x0=u.constrain(Q.x0,0,Q.xa._length),Q.x1=u.constrain(Q.x1,0,Q.xa._length),Q.y0=u.constrain(Q.y0,0,Q.ya._length),Q.y1=u.constrain(Q.y1,0,Q.ya._length),Q.xLabelVal!==void 0&&(Q.xLabel="xLabel"in Q?Q.xLabel:x.hoverLabelText(Q.xa,Q.xLabelVal,X.xhoverformat),Q.xVal=Q.xa.c2d(Q.xLabelVal)),Q.yLabelVal!==void 0&&(Q.yLabel="yLabel"in Q?Q.yLabel:x.hoverLabelText(Q.ya,Q.yLabelVal,X.yhoverformat),Q.yVal=Q.ya.c2d(Q.yLabelVal)),Q.zLabelVal!==void 0&&Q.zLabel===void 0&&(Q.zLabel=String(Q.zLabelVal)),!(isNaN(Q.xerr)||Q.xa.type==="log"&&Q.xerr<=0)){var Te=x.tickText(Q.xa,Q.xa.c2l(Q.xerr),"hover").text;Q.xerrneg!==void 0?Q.xLabel+=" +"+Te+" / -"+x.tickText(Q.xa,Q.xa.c2l(Q.xerrneg),"hover").text:Q.xLabel+=" ± "+Te,Y==="x"&&(Q.distance+=1)}if(!(isNaN(Q.yerr)||Q.ya.type==="log"&&Q.yerr<=0)){var Se=x.tickText(Q.ya,Q.ya.c2l(Q.yerr),"hover").text;Q.yerrneg!==void 0?Q.yLabel+=" +"+Se+" / -"+x.tickText(Q.ya,Q.ya.c2l(Q.yerrneg),"hover").text:Q.yLabel+=" ± "+Se,Y==="y"&&(Q.distance+=1)}var Oe=Q.hoverinfo||Q.trace.hoverinfo;return Oe&&Oe!=="all"&&((Oe=Array.isArray(Oe)?Oe:Oe.split("+")).indexOf("x")===-1&&(Q.xLabel=void 0),Oe.indexOf("y")===-1&&(Q.yLabel=void 0),Oe.indexOf("z")===-1&&(Q.zLabel=void 0),Oe.indexOf("text")===-1&&(Q.text=void 0),Oe.indexOf("name")===-1&&(Q.name=void 0)),Q}function L(Q,Y,Z){var X,re,ie=Z.container,le=Z.fullLayout,se=le._size,pe=Z.event,Te=!!Y.hLinePoint,Se=!!Y.vLinePoint;if(ie.selectAll(".spikeline").remove(),Se||Te){var Oe=m.combine(le.plot_bgcolor,le.paper_bgcolor);if(Te){var Me,ce,ye=Y.hLinePoint;X=ye&&ye.xa,(re=ye&&ye.ya).spikesnap==="cursor"?(Me=pe.pointerX,ce=pe.pointerY):(Me=X._offset+ye.x,ce=re._offset+ye.y);var J,ne,de=s.readability(ye.color,Oe)<1.5?m.contrast(Oe):ye.color,xe=re.spikemode,ue=re.spikethickness,ge=re.spikecolor||de,be=x.getPxPosition(Q,re);if(xe.indexOf("toaxis")!==-1||xe.indexOf("across")!==-1){if(xe.indexOf("toaxis")!==-1&&(J=be,ne=Me),xe.indexOf("across")!==-1){var we=re._counterDomainMin,ke=re._counterDomainMax;re.anchor==="free"&&(we=Math.min(we,re.position),ke=Math.max(ke,re.position)),J=se.l+we*se.w,ne=se.l+ke*se.w}ie.insert("line",":first-child").attr({x1:J,x2:ne,y1:ce,y2:ce,"stroke-width":ue,stroke:ge,"stroke-dasharray":v.dashStyle(re.spikedash,ue)}).classed("spikeline",!0).classed("crisp",!0),ie.insert("line",":first-child").attr({x1:J,x2:ne,y1:ce,y2:ce,"stroke-width":ue+2,stroke:Oe}).classed("spikeline",!0).classed("crisp",!0)}xe.indexOf("marker")!==-1&&ie.insert("circle",":first-child").attr({cx:be+(re.side!=="right"?ue:-ue),cy:ce,r:ue,fill:ge}).classed("spikeline",!0)}if(Se){var Ae,Ee,De=Y.vLinePoint;X=De&&De.xa,re=De&&De.ya,X.spikesnap==="cursor"?(Ae=pe.pointerX,Ee=pe.pointerY):(Ae=X._offset+De.x,Ee=re._offset+De.y);var Re,Ie,Be=s.readability(De.color,Oe)<1.5?m.contrast(Oe):De.color,Ue=X.spikemode,qe=X.spikethickness,Ye=X.spikecolor||Be,at=x.getPxPosition(Q,X);if(Ue.indexOf("toaxis")!==-1||Ue.indexOf("across")!==-1){if(Ue.indexOf("toaxis")!==-1&&(Re=at,Ie=Ee),Ue.indexOf("across")!==-1){var lt=X._counterDomainMin,ct=X._counterDomainMax;X.anchor==="free"&&(lt=Math.min(lt,X.position),ct=Math.max(ct,X.position)),Re=se.t+(1-ct)*se.h,Ie=se.t+(1-lt)*se.h}ie.insert("line",":first-child").attr({x1:Ae,x2:Ae,y1:Re,y2:Ie,"stroke-width":qe,stroke:Ye,"stroke-dasharray":v.dashStyle(X.spikedash,qe)}).classed("spikeline",!0).classed("crisp",!0),ie.insert("line",":first-child").attr({x1:Ae,x2:Ae,y1:Re,y2:Ie,"stroke-width":qe+2,stroke:Oe}).classed("spikeline",!0).classed("crisp",!0)}Ue.indexOf("marker")!==-1&&ie.insert("circle",":first-child").attr({cx:Ae,cy:at-(X.side!=="top"?qe:-qe),r:qe,fill:Ye}).classed("spikeline",!0)}}}function q(Q,Y){return!Y}function H(Q,Y){return g.plainText(Q||"",{len:Y,allowedTags:["br","sub","sup","b","i","em"]})}function V(Q,Y,Z){var X=Y[Q+"a"],re=Y[Q+"Val"],ie=Y.cd[0];if(X.type==="category"||X.type==="multicategory")re=X._categoriesMap[re];else if(X.type==="date"){var le=Y.trace[Q+"periodalignment"];if(le){var se=Y.cd[Y.index],pe=se[Q+"Start"];pe===void 0&&(pe=se[Q]);var Te=se[Q+"End"];Te===void 0&&(Te=se[Q]);var Se=Te-pe;le==="end"?re+=Se:le==="middle"&&(re+=Se/2)}re=X.d2c(re)}return ie&&ie.t&&ie.t.posLetter===X._id&&(Z.boxmode!=="group"&&Z.violinmode!=="group"||(re+=ie.t.dPos)),re}function te(Q){return Q.offsetTop+Q.clientTop}function ee(Q){return Q.offsetLeft+Q.clientLeft}function U(Q,Y){var Z=Q._fullLayout,X=Y.getBoundingClientRect(),re=X.left,ie=X.top,le=re+X.width,se=ie+X.height,pe=u.apply3DTransform(Z._invTransform)(re,ie),Te=u.apply3DTransform(Z._invTransform)(le,se),Se=pe[0],Oe=pe[1],Me=Te[0],ce=Te[1];return{x:Se,y:Oe,width:Me-Se,height:ce-Oe,top:Math.min(Oe,ce),left:Math.min(Se,Me),right:Math.max(Se,Me),bottom:Math.max(Oe,ce)}}},38048:function(o,a,n){var l=n(71828),f=n(7901),s=n(23469).isUnifiedHover;o.exports=function(u,d,h,p){p=p||{};var g=d.legend;function y(v){p.font[v]||(p.font[v]=g?d.legend.font[v]:d.font[v])}d&&s(d.hovermode)&&(p.font||(p.font={}),y("size"),y("family"),y("color"),g?(p.bgcolor||(p.bgcolor=f.combine(d.legend.bgcolor,d.paper_bgcolor)),p.bordercolor||(p.bordercolor=d.legend.bordercolor)):p.bgcolor||(p.bgcolor=d.paper_bgcolor)),h("hoverlabel.bgcolor",p.bgcolor),h("hoverlabel.bordercolor",p.bordercolor),h("hoverlabel.namelength",p.namelength),l.coerceFont(h,"hoverlabel.font",p.font),h("hoverlabel.align",p.align)}},98212:function(o,a,n){var l=n(71828),f=n(528);o.exports=function(s,u){function d(h,p){return u[h]!==void 0?u[h]:l.coerce(s,u,f,h,p)}return d("clickmode"),d("hovermode")}},30211:function(o,a,n){var l=n(39898),f=n(71828),s=n(28569),u=n(23469),d=n(528),h=n(88335);o.exports={moduleType:"component",name:"fx",constants:n(26675),schema:{layout:d},attributes:n(77914),layoutAttributes:d,supplyLayoutGlobalDefaults:n(22774),supplyDefaults:n(54268),supplyLayoutDefaults:n(34938),calc:n(30732),getDistanceFunction:u.getDistanceFunction,getClosest:u.getClosest,inbox:u.inbox,quadrature:u.quadrature,appendArrayPointValue:u.appendArrayPointValue,castHoverOption:function(p,g,y){return f.castOption(p,g,"hoverlabel."+y)},castHoverinfo:function(p,g,y){return f.castOption(p,y,"hoverinfo",function(v){return f.coerceHoverinfo({hoverinfo:v},{_module:p._module},g)})},hover:h.hover,unhover:s.unhover,loneHover:h.loneHover,loneUnhover:function(p){var g=f.isD3Selection(p)?p:l.select(p);g.selectAll("g.hovertext").remove(),g.selectAll(".spikeline").remove()},click:n(75914)}},528:function(o,a,n){var l=n(26675),f=n(41940),s=f({editType:"none"});s.family.dflt=l.HOVERFONT,s.size.dflt=l.HOVERFONTSIZE,o.exports={clickmode:{valType:"flaglist",flags:["event","select"],dflt:"event",editType:"plot",extras:["none"]},dragmode:{valType:"enumerated",values:["zoom","pan","select","lasso","drawclosedpath","drawopenpath","drawline","drawrect","drawcircle","orbit","turntable",!1],dflt:"zoom",editType:"modebar"},hovermode:{valType:"enumerated",values:["x","y","closest",!1,"x unified","y unified"],dflt:"closest",editType:"modebar"},hoverdistance:{valType:"integer",min:-1,dflt:20,editType:"none"},spikedistance:{valType:"integer",min:-1,dflt:-1,editType:"none"},hoverlabel:{bgcolor:{valType:"color",editType:"none"},bordercolor:{valType:"color",editType:"none"},font:s,grouptitlefont:f({editType:"none"}),align:{valType:"enumerated",values:["left","right","auto"],dflt:"auto",editType:"none"},namelength:{valType:"integer",min:-1,dflt:15,editType:"none"},editType:"none"},selectdirection:{valType:"enumerated",values:["h","v","d","any"],dflt:"any",editType:"none"}}},34938:function(o,a,n){var l=n(71828),f=n(528),s=n(98212),u=n(38048);o.exports=function(d,h){function p(m,b){return l.coerce(d,h,f,m,b)}s(d,h)&&(p("hoverdistance"),p("spikedistance")),p("dragmode")==="select"&&p("selectdirection");var g=h._has("mapbox"),y=h._has("geo"),v=h._basePlotModules.length;h.dragmode==="zoom"&&((g||y)&&v===1||g&&y&&v===2)&&(h.dragmode="pan"),u(d,h,p),l.coerceFont(p,"hoverlabel.grouptitlefont",h.hoverlabel.font)}},22774:function(o,a,n){var l=n(71828),f=n(38048),s=n(528);o.exports=function(u,d){f(u,d,function(h,p){return l.coerce(u,d,s,h,p)})}},83312:function(o,a,n){var l=n(71828),f=n(30587).counter,s=n(27670).Y,u=n(85555).idRegex,d=n(44467),h={rows:{valType:"integer",min:1,editType:"plot"},roworder:{valType:"enumerated",values:["top to bottom","bottom to top"],dflt:"top to bottom",editType:"plot"},columns:{valType:"integer",min:1,editType:"plot"},subplots:{valType:"info_array",freeLength:!0,dimensions:2,items:{valType:"enumerated",values:[f("xy").toString(),""],editType:"plot"},editType:"plot"},xaxes:{valType:"info_array",freeLength:!0,items:{valType:"enumerated",values:[u.x.toString(),""],editType:"plot"},editType:"plot"},yaxes:{valType:"info_array",freeLength:!0,items:{valType:"enumerated",values:[u.y.toString(),""],editType:"plot"},editType:"plot"},pattern:{valType:"enumerated",values:["independent","coupled"],dflt:"coupled",editType:"plot"},xgap:{valType:"number",min:0,max:1,editType:"plot"},ygap:{valType:"number",min:0,max:1,editType:"plot"},domain:s({name:"grid",editType:"plot",noGridCell:!0},{}),xside:{valType:"enumerated",values:["bottom","bottom plot","top plot","top"],dflt:"bottom plot",editType:"plot"},yside:{valType:"enumerated",values:["left","left plot","right plot","right"],dflt:"left plot",editType:"plot"},editType:"plot"};function p(v,m,b){var x=m[b+"axes"],_=Object.keys((v._splomAxes||{})[b]||{});return Array.isArray(x)?x:_.length?_:void 0}function g(v,m,b,x,_,w){var k=m(v+"gap",b),T=m("domain."+v);m(v+"side",x);for(var M=new Array(_),S=T[0],C=(T[1]-S)/(_-k),P=C*(1-k),D=0;D<_;D++){var O=S+C*D;M[w?_-1-D:D]=[O,O+P]}return M}function y(v,m,b,x,_){var w,k=new Array(b);function T(M,S){m.indexOf(S)!==-1&&x[S]===void 0?(k[M]=S,x[S]=M):k[M]=""}if(Array.isArray(v))for(w=0;w1){T||M||S||$("pattern")==="independent"&&(T=!0),P._hasSubplotGrid=T;var R,F,A=$("roworder")==="top to bottom",z=T?.2:.1,B=T?.3:.1;C&&m._splomGridDflt&&(R=m._splomGridDflt.xside,F=m._splomGridDflt.yside),P._domains={x:g("x",$,z,R,O),y:g("y",$,B,F,D,A)}}else delete m.grid}function $(j,N){return l.coerce(b,P,h,j,N)}},contentDefaults:function(v,m){var b=m.grid;if(b&&b._domains){var x,_,w,k,T,M,S,C=v.grid||{},P=m._subplots,D=b._hasSubplotGrid,O=b.rows,R=b.columns,F=b.pattern==="independent",A=b._axisMap={};if(D){var z=C.subplots||[];M=b.subplots=new Array(O);var B=1;for(x=0;x(y==="legend"?1:0));if(B===!1&&(m[y]=void 0),(B!==!1||x.uirevision)&&(w("uirevision",m.uirevision),B!==!1)){w("borderwidth");var $,j,N,E=w("orientation")==="h",W=w("yref")==="paper",G=w("xref")==="paper",L="left";if(E?($=0,l.getComponentMethod("rangeslider","isVisible")(v.xaxis)?W?(j=1.1,N="bottom"):(j=1,N="top"):W?(j=-.1,N="top"):(j=0,N="bottom")):(j=1,N="auto",G?$=1.02:($=1,L="right")),f.coerce(x,_,{x:{valType:"number",editType:"legend",min:G?-2:0,max:G?3:1,dflt:$}},"x"),f.coerce(x,_,{y:{valType:"number",editType:"legend",min:W?-2:0,max:W?3:1,dflt:j}},"y"),w("traceorder",O),p.isGrouped(m[y])&&w("tracegroupgap"),w("entrywidth"),w("entrywidthmode"),w("itemsizing"),w("itemwidth"),w("itemclick"),w("itemdoubleclick"),w("groupclick"),w("xanchor",L),w("yanchor",N),w("valign"),f.noneOrAll(x,_,["x","y"]),w("title.text")){w("title.side",E?"left":"top");var q=f.extendFlat({},k,{size:f.bigFont(k.size)});f.coerceFont(w,"title.font",q)}}}}o.exports=function(y,v,m){var b,x=m.slice(),_=v.shapes;if(_)for(b=0;b<_.length;b++){var w=_[b];if(w.showlegend){var k={_input:w._input,visible:w.visible,showlegend:w.showlegend,legend:w.legend};x.push(k)}}var T=["legend"];for(b=0;b1)}var X=q.hiddenlabels||[];if(!(V||q.showlegend&&te.length))return G.selectAll("."+H).remove(),q._topdefs.select("#"+W).remove(),s.autoMargin(N,H);var re=f.ensureSingle(G,"g",H,function(ce){V||ce.attr("pointer-events","all")}),ie=f.ensureSingleById(q._topdefs,"clipPath",W,function(ce){ce.append("rect")}),le=f.ensureSingle(re,"rect","bg",function(ce){ce.attr("shape-rendering","crispEdges")});le.call(g.stroke,L.bordercolor).call(g.fill,L.bgcolor).style("stroke-width",L.borderwidth+"px");var se,pe=f.ensureSingle(re,"g","scrollbox"),Te=L.title;L._titleWidth=0,L._titleHeight=0,Te.text?((se=f.ensureSingle(pe,"text",H+"titletext")).attr("text-anchor","start").call(p.font,Te.font).text(Te.text),z(se,pe,N,L,S)):pe.selectAll("."+H+"titletext").remove();var Se=f.ensureSingle(re,"rect","scrollbar",function(ce){ce.attr(m.scrollBarEnterAttrs).call(g.fill,m.scrollBarColor)}),Oe=pe.selectAll("g.groups").data(te);Oe.enter().append("g").attr("class","groups"),Oe.exit().remove();var Me=Oe.selectAll("g.traces").data(f.identity);Me.enter().append("g").attr("class","traces"),Me.exit().remove(),Me.style("opacity",function(ce){var ye=ce[0].trace;return u.traceIs(ye,"pie-like")?X.indexOf(ce[0].label)!==-1?.5:1:ye.visible==="legendonly"?.5:1}).each(function(){l.select(this).call(R,N,L)}).call(T,N,L).each(function(){V||l.select(this).call(A,N,H)}),f.syncOrAsync([s.previousPromises,function(){return function(ce,ye,J,ne){var de=ce._fullLayout,xe=j(ne);ne||(ne=de[xe]);var ue=de._size,ge=M.isVertical(ne),be=M.isGrouped(ne),we=ne.entrywidthmode==="fraction",ke=ne.borderwidth,Ae=2*ke,Ee=m.itemGap,De=ne.itemwidth+2*Ee,Re=2*(ke+Ee),Ie=$(ne),Be=ne.y<0||ne.y===0&&Ie==="top",Ue=ne.y>1||ne.y===1&&Ie==="bottom",qe=ne.tracegroupgap,Ye={};ne._maxHeight=Math.max(Be||Ue?de.height/2:ue.h,30);var at=0;ne._width=0,ne._height=0;var lt=function(Ge){var Ke=0,nt=0,st=Ge.title.side;return st&&(st.indexOf("left")!==-1&&(Ke=Ge._titleWidth),st.indexOf("top")!==-1&&(nt=Ge._titleHeight)),[Ke,nt]}(ne);if(ge)J.each(function(Ge){var Ke=Ge[0].height;p.setTranslate(this,ke+lt[0],ke+lt[1]+ne._height+Ke/2+Ee),ne._height+=Ke,ne._width=Math.max(ne._width,Ge[0].width)}),at=De+ne._width,ne._width+=Ee+De+Ae,ne._height+=Re,be&&(ye.each(function(Ge,Ke){p.setTranslate(this,0,Ke*ne.tracegroupgap)}),ne._height+=(ne._lgroupsLength-1)*ne.tracegroupgap);else{var ct=B(ne),bt=ne.x<0||ne.x===0&&ct==="right",ze=ne.x>1||ne.x===1&&ct==="left",Ne=Ue||Be,Qe=de.width/2;ne._maxWidth=Math.max(bt?Ne&&ct==="left"?ue.l+ue.w:Qe:ze?Ne&&ct==="right"?ue.r+ue.w:Qe:ue.w,2*De);var it=0,kt=0;J.each(function(Ge){var Ke=D(Ge,ne,De);it=Math.max(it,Ke),kt+=Ke}),at=null;var Je=0;if(be){var ut=0,pt=0,It=0;ye.each(function(){var Ge=0,Ke=0;l.select(this).selectAll("g.traces").each(function(st){var mt=D(st,ne,De),tt=st[0].height;p.setTranslate(this,lt[0],lt[1]+ke+Ee+tt/2+Ke),Ke+=tt,Ge=Math.max(Ge,mt),Ye[st[0].trace.legendgroup]=Ge});var nt=Ge+Ee;pt>0&&nt+ke+pt>ne._maxWidth?(Je=Math.max(Je,pt),pt=0,It+=ut+qe,ut=Ke):ut=Math.max(ut,Ke),p.setTranslate(this,pt,It),pt+=nt}),ne._width=Math.max(Je,pt)+ke,ne._height=It+ut+Re}else{var Mt=J.size(),zt=kt+Ae+(Mt-1)*Ee=ne._maxWidth&&(Je=Math.max(Je,Ve),ve=0,_e+=wt,ne._height+=wt,wt=0),p.setTranslate(this,lt[0]+ke+ve,lt[1]+ke+_e+Ke/2+Ee),Ve=ve+nt+Ee,ve+=st,wt=Math.max(wt,Ke)}),zt?(ne._width=ve+Ae,ne._height=wt+Re):(ne._width=Math.max(Je,Ve)+Ae,ne._height+=wt+Re)}}ne._width=Math.ceil(Math.max(ne._width+lt[0],ne._titleWidth+2*(ke+m.titlePad))),ne._height=Math.ceil(Math.max(ne._height+lt[1],ne._titleHeight+2*(ke+m.itemGap))),ne._effHeight=Math.min(ne._height,ne._maxHeight);var We=ce._context.edits,Ze=We.legendText||We.legendPosition;J.each(function(Ge){var Ke=l.select(this).select("."+xe+"toggle"),nt=Ge[0].height,st=Ge[0].trace.legendgroup,mt=D(Ge,ne,De);be&&st!==""&&(mt=Ye[st]);var tt=Ze?De:at||mt;ge||we||(tt+=Ee/2),p.setRect(Ke,0,-nt/2,tt,nt)})}(N,Oe,Me,L)},function(){var ce,ye,J,ne,de=q._size,xe=L.borderwidth,ue=L.xref==="paper",ge=L.yref==="paper";if(Te.text&&function(Ne,Qe,it){if(Qe.title.side==="top center"||Qe.title.side==="top right"){var kt=Qe.title.font.size*x,Je=0,ut=Ne.node(),pt=p.bBox(ut).width;Qe.title.side==="top center"?Je=.5*(Qe._width-2*it-2*m.titlePad-pt):Qe.title.side==="top right"&&(Je=Qe._width-2*it-2*m.titlePad-pt),y.positionText(Ne,it+m.titlePad+Je,it+kt)}}(se,L,xe),!V){var be,we;be=ue?de.l+de.w*L.x-_[B(L)]*L._width:q.width*L.x-_[B(L)]*L._width,we=ge?de.t+de.h*(1-L.y)-_[$(L)]*L._effHeight:q.height*(1-L.y)-_[$(L)]*L._effHeight;var ke=function(Ne,Qe,it,kt){var Je=Ne._fullLayout,ut=Je[Qe],pt=B(ut),It=$(ut),Mt=ut.xref==="paper",zt=ut.yref==="paper";Ne._fullLayout._reservedMargin[Qe]={};var wt=ut.y<.5?"b":"t",ve=ut.x<.5?"l":"r",_e={r:Je.width-it,l:it+ut._width,b:Je.height-kt,t:kt+ut._effHeight};if(Mt&&zt)return s.autoMargin(Ne,Qe,{x:ut.x,y:ut.y,l:ut._width*_[pt],r:ut._width*w[pt],b:ut._effHeight*w[It],t:ut._effHeight*_[It]});Mt?Ne._fullLayout._reservedMargin[Qe][wt]=_e[wt]:zt||ut.orientation==="v"?Ne._fullLayout._reservedMargin[Qe][ve]=_e[ve]:Ne._fullLayout._reservedMargin[Qe][wt]=_e[wt]}(N,H,be,we);if(ke)return;if(q.margin.autoexpand){var Ae=be,Ee=we;be=ue?f.constrain(be,0,q.width-L._width):Ae,we=ge?f.constrain(we,0,q.height-L._effHeight):Ee,be!==Ae&&f.log("Constrain "+H+".x to make legend fit inside graph"),we!==Ee&&f.log("Constrain "+H+".y to make legend fit inside graph")}p.setTranslate(re,be,we)}if(Se.on(".drag",null),re.on("wheel",null),V||L._height<=L._maxHeight||N._context.staticPlot){var De=L._effHeight;V&&(De=L._height),le.attr({width:L._width-xe,height:De-xe,x:xe/2,y:xe/2}),p.setTranslate(pe,0,0),ie.select("rect").attr({width:L._width-2*xe,height:De-2*xe,x:xe,y:xe}),p.setClipUrl(pe,W,N),p.setRect(Se,0,0,0,0),delete L._scrollY}else{var Re,Ie,Be,Ue=Math.max(m.scrollBarMinHeight,L._effHeight*L._effHeight/L._height),qe=L._effHeight-Ue-2*m.scrollBarMargin,Ye=L._height-L._effHeight,at=qe/Ye,lt=Math.min(L._scrollY||0,Ye);le.attr({width:L._width-2*xe+m.scrollBarWidth+m.scrollBarMargin,height:L._effHeight-xe,x:xe/2,y:xe/2}),ie.select("rect").attr({width:L._width-2*xe+m.scrollBarWidth+m.scrollBarMargin,height:L._effHeight-2*xe,x:xe,y:xe+lt}),p.setClipUrl(pe,W,N),ze(lt,Ue,at),re.on("wheel",function(){ze(lt=f.constrain(L._scrollY+l.event.deltaY/qe*Ye,0,Ye),Ue,at),lt!==0&<!==Ye&&l.event.preventDefault()});var ct=l.behavior.drag().on("dragstart",function(){var Ne=l.event.sourceEvent;Re=Ne.type==="touchstart"?Ne.changedTouches[0].clientY:Ne.clientY,Be=lt}).on("drag",function(){var Ne=l.event.sourceEvent;Ne.buttons===2||Ne.ctrlKey||(Ie=Ne.type==="touchmove"?Ne.changedTouches[0].clientY:Ne.clientY,lt=function(Qe,it,kt){var Je=(kt-it)/at+Qe;return f.constrain(Je,0,Ye)}(Be,Re,Ie),ze(lt,Ue,at))});Se.call(ct);var bt=l.behavior.drag().on("dragstart",function(){var Ne=l.event.sourceEvent;Ne.type==="touchstart"&&(Re=Ne.changedTouches[0].clientY,Be=lt)}).on("drag",function(){var Ne=l.event.sourceEvent;Ne.type==="touchmove"&&(Ie=Ne.changedTouches[0].clientY,lt=function(Qe,it,kt){var Je=(it-kt)/at+Qe;return f.constrain(Je,0,Ye)}(Be,Re,Ie),ze(lt,Ue,at))});pe.call(bt)}function ze(Ne,Qe,it){L._scrollY=N._fullLayout[H]._scrollY=Ne,p.setTranslate(pe,0,-Ne),p.setRect(Se,L._width,m.scrollBarMargin+Ne*it,m.scrollBarWidth,Qe),ie.select("rect").attr("y",xe+Ne)}N._context.edits.legendPosition&&(re.classed("cursor-move",!0),h.init({element:re.node(),gd:N,prepFn:function(){var Ne=p.getTranslate(re);J=Ne.x,ne=Ne.y},moveFn:function(Ne,Qe){var it=J+Ne,kt=ne+Qe;p.setTranslate(re,it,kt),ce=h.align(it,L._width,de.l,de.l+de.w,L.xanchor),ye=h.align(kt+L._height,-L._height,de.t+de.h,de.t,L.yanchor)},doneFn:function(){if(ce!==void 0&&ye!==void 0){var Ne={};Ne[H+".x"]=ce,Ne[H+".y"]=ye,u.call("_guiRelayout",N,Ne)}},clickFn:function(Ne,Qe){var it=G.selectAll("g.traces").filter(function(){var kt=this.getBoundingClientRect();return Qe.clientX>=kt.left&&Qe.clientX<=kt.right&&Qe.clientY>=kt.top&&Qe.clientY<=kt.bottom});it.size()>0&&O(N,re,it,Ne,Qe)}}))}],N)}}function D(N,E,W){var G=N[0],L=G.width,q=E.entrywidthmode,H=G.trace.legendwidth||E.entrywidth;return q==="fraction"?E._maxWidth*H:W+(H||L)}function O(N,E,W,G,L){var q=W.data()[0][0].trace,H={event:L,node:W.node(),curveNumber:q.index,expandedIndex:q._expandedIndex,data:N.data,layout:N.layout,frames:N._transitionData._frames,config:N._context,fullData:N._fullData,fullLayout:N._fullLayout};q._group&&(H.group=q._group),u.traceIs(q,"pie-like")&&(H.label=W.datum()[0].label);var V=d.triggerHandler(N,"plotly_legendclick",H);if(G===1){if(V===!1)return;E._clickTimeout=setTimeout(function(){N._fullLayout&&v(W,N,G)},N._context.doubleClickDelay)}else G===2&&(E._clickTimeout&&clearTimeout(E._clickTimeout),N._legendMouseDownTime=0,d.triggerHandler(N,"plotly_legenddoubleclick",H)!==!1&&V!==!1&&v(W,N,G))}function R(N,E,W){var G,L,q=j(W),H=N.data()[0][0],V=H.trace,te=u.traceIs(V,"pie-like"),ee=!W._inHover&&E._context.edits.legendText&&!te,U=W._maxNameLength;H.groupTitle?(G=H.groupTitle.text,L=H.groupTitle.font):(L=W.font,W.entries?G=H.text:(G=te?H.label:V.name,V._meta&&(G=f.templateString(G,V._meta))));var Q=f.ensureSingle(N,"text",q+"text");Q.attr("text-anchor","start").call(p.font,L).text(ee?F(G,U):G);var Y=W.itemwidth+2*m.itemGap;y.positionText(Q,Y,0),ee?Q.call(y.makeEditable,{gd:E,text:G}).call(z,N,E,W).on("edit",function(Z){this.text(F(Z,U)).call(z,N,E,W);var X=H.trace._fullInput||{},re={};if(u.hasTransform(X,"groupby")){var ie=u.getTransformIndices(X,"groupby"),le=ie[ie.length-1],se=f.keyedContainer(X,"transforms["+le+"].styles","target","value.name");se.set(H.trace._group,Z),re=se.constructUpdate()}else re.name=Z;return X._isShape?u.call("_guiRelayout",E,"shapes["+V.index+"].name",re.name):u.call("_guiRestyle",E,re,V.index)}):z(Q,N,E,W)}function F(N,E){var W=Math.max(4,E);if(N&&N.trim().length>=W/2)return N;for(var G=W-(N=N||"").length;G>0;G--)N+=" ";return N}function A(N,E,W){var G,L=E._context.doubleClickDelay,q=1,H=f.ensureSingle(N,"rect",W+"toggle",function(V){E._context.staticPlot||V.style("cursor","pointer").attr("pointer-events","all"),V.call(g.fill,"rgba(0,0,0,0)")});E._context.staticPlot||(H.on("mousedown",function(){(G=new Date().getTime())-E._legendMouseDownTimeL&&(q=Math.max(q-1,1)),O(E,V,N,q,l.event)}}))}function z(N,E,W,G,L){G._inHover&&N.attr("data-notex",!0),y.convertToTspans(N,W,function(){(function(q,H,V,te){var ee=q.data()[0][0];if(V._inHover||!ee||ee.trace.showlegend){var U=q.select("g[class*=math-group]"),Q=U.node(),Y=j(V);V||(V=H._fullLayout[Y]);var Z,X,re=V.borderwidth,ie=(te===S?V.title.font:ee.groupTitle?ee.groupTitle.font:V.font).size*x;if(Q){var le=p.bBox(Q);Z=le.height,X=le.width,te===S?p.setTranslate(U,re,re+.75*Z):p.setTranslate(U,0,.25*Z)}else{var se="."+Y+(te===S?"title":"")+"text",pe=q.select(se),Te=y.lineCount(pe),Se=pe.node();if(Z=ie*Te,X=Se?p.bBox(Se).width:0,te===S)V.title.side==="left"&&(X+=2*m.itemGap),y.positionText(pe,re+m.titlePad,re+ie);else{var Oe=2*m.itemGap+V.itemwidth;ee.groupTitle&&(Oe=m.itemGap,X-=V.itemwidth),y.positionText(pe,Oe,-ie*((Te-1)/2-.3))}}te===S?(V._titleWidth=X,V._titleHeight=Z):(ee.lineHeight=ie,ee.height=Math.max(Z,16)+3,ee.width=X)}else q.remove()})(E,W,G,L)})}function B(N){return f.isRightAnchor(N)?"right":f.isCenterAnchor(N)?"center":"left"}function $(N){return f.isBottomAnchor(N)?"bottom":f.isMiddleAnchor(N)?"middle":"top"}function j(N){return N._id||"legend"}o.exports=function(N,E){if(E)P(N,E);else{var W=N._fullLayout,G=W._legends;W._infolayer.selectAll('[class^="legend"]').each(function(){var H=l.select(this),V=H.attr("class").split(" ")[0];V.match(C)&&G.indexOf(V)===-1&&H.remove()});for(var L=0;LB&&(z=B)}F[h][0]._groupMinRank=z,F[h][0]._preGroupSort=h}var $=function(G,L){return G.trace.legendrank-L.trace.legendrank||G._preSort-L._preSort};for(F.forEach(function(G,L){G[0]._preGroupSort=L}),F.sort(function(G,L){return G[0]._groupMinRank-L[0]._groupMinRank||G[0]._preGroupSort-L[0]._preGroupSort}),h=0;hT?T:w}o.exports=function(w,k,T){var M=k._fullLayout;T||(T=M.legend);var S=T.itemsizing==="constant",C=T.itemwidth,P=(C+2*m.itemGap)/2,D=u(P,0),O=function(A,z,B,$){var j;if(A+1)j=A;else{if(!(z&&z.width>0))return 0;j=z.width}return S?$:Math.min(j,B)};function R(A,z,B){var $=A[0].trace,j=$.marker||{},N=j.line||{},E=B?$.visible&&$.type===B:f.traceIs($,"bar"),W=l.select(z).select("g.legendpoints").selectAll("path.legend"+B).data(E?[A]:[]);W.enter().append("path").classed("legend"+B,!0).attr("d","M6,6H-6V-6H6Z").attr("transform",D),W.exit().remove(),W.each(function(G){var L=l.select(this),q=G[0],H=O(q.mlw,j.line,5,2);L.style("stroke-width",H+"px");var V=q.mcc;if(!T._inHover&&"mc"in q){var te=p(j),ee=te.mid;ee===void 0&&(ee=(te.max+te.min)/2),V=d.tryColorscale(j,"")(ee)}var U=V||q.mc||j.color,Q=j.pattern,Y=Q&&d.getPatternAttr(Q.shape,0,"");if(Y){var Z=d.getPatternAttr(Q.bgcolor,0,null),X=d.getPatternAttr(Q.fgcolor,0,null),re=Q.fgopacity,ie=_(Q.size,8,10),le=_(Q.solidity,.5,1),se="legend-"+$.uid;L.call(d.pattern,"legend",k,se,Y,ie,le,V,Q.fillmode,Z,X,re)}else L.call(h.fill,U);H&&h.stroke(L,q.mlc||N.color)})}function F(A,z,B){var $=A[0],j=$.trace,N=B?j.visible&&j.type===B:f.traceIs(j,B),E=l.select(z).select("g.legendpoints").selectAll("path.legend"+B).data(N?[A]:[]);if(E.enter().append("path").classed("legend"+B,!0).attr("d","M6,6H-6V-6H6Z").attr("transform",D),E.exit().remove(),E.size()){var W=j.marker||{},G=O(v(W.line.width,$.pts),W.line,5,2),L="pieLike",q=s.minExtend(j,{marker:{line:{width:G}}},L),H=s.minExtend($,{trace:q},L);y(E,H,q,k)}}w.each(function(A){var z=l.select(this),B=s.ensureSingle(z,"g","layers");B.style("opacity",A[0].trace.opacity);var $=T.valign,j=A[0].lineHeight,N=A[0].height;if($!=="middle"&&j&&N){var E={top:1,bottom:-1}[$]*(.5*(j-N+3));B.attr("transform",u(0,E))}else B.attr("transform",null);B.selectAll("g.legendfill").data([A]).enter().append("g").classed("legendfill",!0),B.selectAll("g.legendlines").data([A]).enter().append("g").classed("legendlines",!0);var W=B.selectAll("g.legendsymbols").data([A]);W.enter().append("g").classed("legendsymbols",!0),W.selectAll("g.legendpoints").data([A]).enter().append("g").classed("legendpoints",!0)}).each(function(A){var z,B=A[0].trace,$=[];if(B.visible)switch(B.type){case"histogram2d":case"heatmap":$=[["M-15,-2V4H15V-2Z"]],z=!0;break;case"choropleth":case"choroplethmapbox":$=[["M-6,-6V6H6V-6Z"]],z=!0;break;case"densitymapbox":$=[["M-6,0 a6,6 0 1,0 12,0 a 6,6 0 1,0 -12,0"]],z="radial";break;case"cone":$=[["M-6,2 A2,2 0 0,0 -6,6 V6L6,4Z"],["M-6,-6 A2,2 0 0,0 -6,-2 L6,-4Z"],["M-6,-2 A2,2 0 0,0 -6,2 L6,0Z"]],z=!1;break;case"streamtube":$=[["M-6,2 A2,2 0 0,0 -6,6 H6 A2,2 0 0,1 6,2 Z"],["M-6,-6 A2,2 0 0,0 -6,-2 H6 A2,2 0 0,1 6,-6 Z"],["M-6,-2 A2,2 0 0,0 -6,2 H6 A2,2 0 0,1 6,-2 Z"]],z=!1;break;case"surface":$=[["M-6,-6 A2,3 0 0,0 -6,0 H6 A2,3 0 0,1 6,-6 Z"],["M-6,1 A2,3 0 0,1 -6,6 H6 A2,3 0 0,0 6,0 Z"]],z=!0;break;case"mesh3d":$=[["M-6,6H0L-6,-6Z"],["M6,6H0L6,-6Z"],["M-6,-6H6L0,6Z"]],z=!1;break;case"volume":$=[["M-6,6H0L-6,-6Z"],["M6,6H0L6,-6Z"],["M-6,-6H6L0,6Z"]],z=!0;break;case"isosurface":$=[["M-6,6H0L-6,-6Z"],["M6,6H0L6,-6Z"],["M-6,-6 A12,24 0 0,0 6,-6 L0,6Z"]],z=!1}var j=l.select(this).select("g.legendpoints").selectAll("path.legend3dandfriends").data($);j.enter().append("path").classed("legend3dandfriends",!0).attr("transform",D).style("stroke-miterlimit",1),j.exit().remove(),j.each(function(N,E){var W,G=l.select(this),L=p(B),q=L.colorscale,H=L.reversescale;if(q){if(!z){var V=q.length;W=E===0?q[H?V-1:0][1]:E===1?q[H?0:V-1][1]:q[Math.floor((V-1)/2)][1]}}else{var te=B.vertexcolor||B.facecolor||B.color;W=s.isArrayOrTypedArray(te)?te[E]||te[0]:te}G.attr("d",N[0]),W?G.call(h.fill,W):G.call(function(ee){if(ee.size()){var U="legendfill-"+B.uid;d.gradient(ee,k,U,b(H,z==="radial"),q,"fill")}})})}).each(function(A){var z=A[0].trace,B=z.type==="waterfall";if(A[0]._distinct&&B){var $=A[0].trace[A[0].dir].marker;return A[0].mc=$.color,A[0].mlw=$.line.width,A[0].mlc=$.line.color,R(A,this,"waterfall")}var j=[];z.visible&&B&&(j=A[0].hasTotals?[["increasing","M-6,-6V6H0Z"],["totals","M6,6H0L-6,-6H-0Z"],["decreasing","M6,6V-6H0Z"]]:[["increasing","M-6,-6V6H6Z"],["decreasing","M6,6V-6H-6Z"]]);var N=l.select(this).select("g.legendpoints").selectAll("path.legendwaterfall").data(j);N.enter().append("path").classed("legendwaterfall",!0).attr("transform",D).style("stroke-miterlimit",1),N.exit().remove(),N.each(function(E){var W=l.select(this),G=z[E[0]].marker,L=O(void 0,G.line,5,2);W.attr("d",E[1]).style("stroke-width",L+"px").call(h.fill,G.color),L&&W.call(h.stroke,G.line.color)})}).each(function(A){R(A,this,"funnel")}).each(function(A){R(A,this)}).each(function(A){var z=A[0].trace,B=l.select(this).select("g.legendpoints").selectAll("path.legendbox").data(z.visible&&f.traceIs(z,"box-violin")?[A]:[]);B.enter().append("path").classed("legendbox",!0).attr("d","M6,6H-6V-6H6Z").attr("transform",D),B.exit().remove(),B.each(function(){var $=l.select(this);if(z.boxpoints!=="all"&&z.points!=="all"||h.opacity(z.fillcolor)!==0||h.opacity((z.line||{}).color)!==0){var j=O(void 0,z.line,5,2);$.style("stroke-width",j+"px").call(h.fill,z.fillcolor),j&&h.stroke($,z.line.color)}else{var N=s.minExtend(z,{marker:{size:S?12:s.constrain(z.marker.size,2,16),sizeref:1,sizemin:1,sizemode:"diameter"}});B.call(d.pointStyle,N,k)}})}).each(function(A){F(A,this,"funnelarea")}).each(function(A){F(A,this,"pie")}).each(function(A){var z,B,$=x(A),j=$.showFill,N=$.showLine,E=$.showGradientLine,W=$.showGradientFill,G=$.anyFill,L=$.anyLine,q=A[0],H=q.trace,V=p(H),te=V.colorscale,ee=V.reversescale,U=g.hasMarkers(H)||!G?"M5,0":L?"M5,-2":"M5,-3",Q=l.select(this),Y=Q.select(".legendfill").selectAll("path").data(j||W?[A]:[]);if(Y.enter().append("path").classed("js-fill",!0),Y.exit().remove(),Y.attr("d",U+"h"+C+"v6h-"+C+"z").call(function(re){if(re.size())if(j)d.fillGroupStyle(re,k);else{var ie="legendfill-"+H.uid;d.gradient(re,k,ie,b(ee),te,"fill")}}),N||E){var Z=O(void 0,H.line,10,5);B=s.minExtend(H,{line:{width:Z}}),z=[s.minExtend(q,{trace:B})]}var X=Q.select(".legendlines").selectAll("path").data(N||E?[z]:[]);X.enter().append("path").classed("js-line",!0),X.exit().remove(),X.attr("d",U+(E?"l"+C+",0.0001":"h"+C)).call(N?d.lineGroupStyle:function(re){if(re.size()){var ie="legendline-"+H.uid;d.lineGroupStyle(re),d.gradient(re,k,ie,b(ee),te,"stroke")}})}).each(function(A){var z,B,$=x(A),j=$.anyFill,N=$.anyLine,E=$.showLine,W=$.showMarker,G=A[0],L=G.trace,q=!W&&!N&&!j&&g.hasText(L);function H(X,re,ie,le){var se=s.nestedProperty(L,X).get(),pe=s.isArrayOrTypedArray(se)&&re?re(se):se;if(S&&pe&&le!==void 0&&(pe=le),ie){if(peie[1])return ie[1]}return pe}function V(X){return G._distinct&&G.index&&X[G.index]?X[G.index]:X[0]}if(W||q||E){var te={},ee={};if(W){te.mc=H("marker.color",V),te.mx=H("marker.symbol",V),te.mo=H("marker.opacity",s.mean,[.2,1]),te.mlc=H("marker.line.color",V),te.mlw=H("marker.line.width",s.mean,[0,5],2),ee.marker={sizeref:1,sizemin:1,sizemode:"diameter"};var U=H("marker.size",s.mean,[2,16],12);te.ms=U,ee.marker.size=U}E&&(ee.line={width:H("line.width",V,[0,10],5)}),q&&(te.tx="Aa",te.tp=H("textposition",V),te.ts=10,te.tc=H("textfont.color",V),te.tf=H("textfont.family",V)),z=[s.minExtend(G,te)],(B=s.minExtend(L,ee)).selectedpoints=null,B.texttemplate=null}var Q=l.select(this).select("g.legendpoints"),Y=Q.selectAll("path.scatterpts").data(W?z:[]);Y.enter().insert("path",":first-child").classed("scatterpts",!0).attr("transform",D),Y.exit().remove(),Y.call(d.pointStyle,B,k),W&&(z[0].mrc=3);var Z=Q.selectAll("g.pointtext").data(q?z:[]);Z.enter().append("g").classed("pointtext",!0).append("text").attr("transform",D),Z.exit().remove(),Z.selectAll("text").call(d.textPointStyle,B,k)}).each(function(A){var z=A[0].trace,B=l.select(this).select("g.legendpoints").selectAll("path.legendcandle").data(z.visible&&z.type==="candlestick"?[A,A]:[]);B.enter().append("path").classed("legendcandle",!0).attr("d",function($,j){return j?"M-15,0H-8M-8,6V-6H8Z":"M15,0H8M8,-6V6H-8Z"}).attr("transform",D).style("stroke-miterlimit",1),B.exit().remove(),B.each(function($,j){var N=l.select(this),E=z[j?"increasing":"decreasing"],W=O(void 0,E.line,5,2);N.style("stroke-width",W+"px").call(h.fill,E.fillcolor),W&&h.stroke(N,E.line.color)})}).each(function(A){var z=A[0].trace,B=l.select(this).select("g.legendpoints").selectAll("path.legendohlc").data(z.visible&&z.type==="ohlc"?[A,A]:[]);B.enter().append("path").classed("legendohlc",!0).attr("d",function($,j){return j?"M-15,0H0M-8,-6V0":"M15,0H0M8,6V0"}).attr("transform",D).style("stroke-miterlimit",1),B.exit().remove(),B.each(function($,j){var N=l.select(this),E=z[j?"increasing":"decreasing"],W=O(void 0,E.line,5,2);N.style("fill","none").call(d.dashLine,E.line.dash,W),W&&h.stroke(N,E.line.color)})})}},42068:function(o,a,n){n(93348),o.exports={editType:"modebar",orientation:{valType:"enumerated",values:["v","h"],dflt:"h",editType:"modebar"},bgcolor:{valType:"color",editType:"modebar"},color:{valType:"color",editType:"modebar"},activecolor:{valType:"color",editType:"modebar"},uirevision:{valType:"any",editType:"none"},add:{valType:"string",arrayOk:!0,dflt:"",editType:"modebar"},remove:{valType:"string",arrayOk:!0,dflt:"",editType:"modebar"}}},26023:function(o,a,n){var l=n(73972),f=n(74875),s=n(41675),u=n(24255),d=n(34031).eraseActiveShape,h=n(71828),p=h._,g=o.exports={};function y(M,S){var C,P,D=S.currentTarget,O=D.getAttribute("data-attr"),R=D.getAttribute("data-val")||!0,F=M._fullLayout,A={},z=s.list(M,null,!0),B=F._cartesianSpikesEnabled;if(O==="zoom"){var $,j=R==="in"?.5:2,N=(1+j)/2,E=(1-j)/2;for(P=0;P1?(U=["toggleHover"],Q=["resetViews"]):A?(ee=["zoomInGeo","zoomOutGeo"],U=["hoverClosestGeo"],Q=["resetGeo"]):F?(U=["hoverClosest3d"],Q=["resetCameraDefault3d","resetCameraLastSave3d"]):N?(ee=["zoomInMapbox","zoomOutMapbox"],U=["toggleHover"],Q=["resetViewMapbox"]):$?U=["hoverClosestGl2d"]:z?U=["hoverClosestPie"]:G?(U=["hoverClosestCartesian","hoverCompareCartesian"],Q=["resetViewSankey"]):U=["toggleHover"],R&&(U=["toggleSpikelines","hoverClosestCartesian","hoverCompareCartesian"]),(function(se){for(var pe=0;pe0)){var k=function(M,S,C){for(var P=C.filter(function(F){return S[F].anchor===M._id}),D=0,O=0;O=Se.max)pe=re[Te+1];else if(se=Se.pmax)pe=re[Te+1];else if(seTe._length||ge+Ie<0)return;Ee=ue+Ie,De=ge+Ie;break;case Me:if(Re="col-resize",ue+Ie>Te._length)return;Ee=ue+Ie,De=ge;break;case ce:if(Re="col-resize",ge+Ie<0)return;Ee=ue,De=ge+Ie;break;default:Re="ew-resize",Ee=xe,De=xe+Ie}if(De=0;$--){var j=S.append("path").attr(P).style("opacity",$?.1:D).call(u.stroke,R).call(u.fill,O).call(d.dashLine,$?"solid":A,$?4+F:F);if(b(j,_,T),z){var N=h(_.layout,"selections",T);j.style({cursor:"move"});var E={element:j.node(),plotinfo:M,gd:_,editHelpers:N,isActiveSelection:!0},W=l(C,_);f(W,j,E)}else j.style("pointer-events",$?"all":"none");B[$]=j}var G=B[0];B[1].node().addEventListener("click",function(){return function(L,q){if(v(L)){var H=+q.node().getAttribute("data-index");if(H>=0){if(H===L._fullLayout._activeSelectionIndex)return void x(L);L._fullLayout._activeSelectionIndex=H,L._fullLayout._deactivateSelection=x,y(L)}}}(_,G)})}(_._fullLayout._selectionLayer)}function b(_,w,k){var T=k.xref+k.yref;d.setClipUrl(_,"clip"+w._fullLayout._uid+T,w)}function x(_){v(_)&&_._fullLayout._activeSelectionIndex>=0&&(s(_),delete _._fullLayout._activeSelectionIndex,y(_))}o.exports={draw:y,drawOne:m,activateLastSelection:function(_){if(v(_)){var w=_._fullLayout.selections.length-1;_._fullLayout._activeSelectionIndex=w,_._fullLayout._deactivateSelection=x,y(_)}}}},53777:function(o,a,n){var l=n(79952).P,f=n(1426).extendFlat;o.exports={newselection:{mode:{valType:"enumerated",values:["immediate","gradual"],dflt:"immediate",editType:"none"},line:{color:{valType:"color",editType:"none"},width:{valType:"number",min:1,dflt:1,editType:"none"},dash:f({},l,{dflt:"dot",editType:"none"}),editType:"none"},editType:"none"},activeselection:{fillcolor:{valType:"color",dflt:"rgba(0,0,0,0)",editType:"none"},opacity:{valType:"number",min:0,max:1,dflt:.5,editType:"none"},editType:"none"}}},90849:function(o){o.exports=function(a,n,l){l("newselection.mode"),l("newselection.line.width")&&(l("newselection.line.color"),l("newselection.line.dash")),l("activeselection.fillcolor"),l("activeselection.opacity")}},35855:function(o,a,n){var l=n(64505).selectMode,f=n(51873).clearOutline,s=n(60165),u=s.readPaths,d=s.writePaths,h=s.fixDatesForPaths;o.exports=function(p,g){if(p.length){var y=p[0][0];if(y){var v=y.getAttribute("d"),m=g.gd,b=m._fullLayout.newselection,x=g.plotinfo,_=x.xaxis,w=x.yaxis,k=g.isActiveSelection,T=g.dragmode,M=(m.layout||{}).selections||[];if(!l(T)&&k!==void 0){var S=m._fullLayout._activeSelectionIndex;if(S-1,kt=[];if(function(Mt){return Mt&&Array.isArray(Mt)&&Mt[0].hoverOnBox!==!0}(Qe)){Z(ke,Ae,Ie);var Je=function(Mt,zt){var wt,ve,_e=Mt[0],Ve=-1,We=[];for(ve=0;ve0?function(Mt,zt){var wt,ve,_e,Ve=[];for(_e=0;_e0&&Ve.push(wt);if(Ve.length===1&&Ve[0]===zt.searchInfo&&(ve=zt.searchInfo.cd[0].trace).selectedpoints.length===zt.pointNumbers.length){for(_e=0;_e1||(ve+=zt.selectedpoints.length)>1))return!1;return ve===1}(Ue)&&(ct=se(Je))){for(Be&&Be.remove(),Ne=0;Ne=0})(Re)&&Re._fullLayout._deactivateShape(Re),function(lt){return lt._fullLayout._activeSelectionIndex>=0}(Re)&&Re._fullLayout._deactivateSelection(Re);var Ie=Re._fullLayout._zoomlayer,Be=m(Ee),Ue=x(Ee);if(Be||Ue){var qe,Ye,at=Ie.selectAll(".select-outline-"+De.id);at&&Re._fullLayout._outlining&&(Be&&(qe=P(at,ke)),qe&&s.call("_guiRelayout",Re,{shapes:qe}),Ue&&!te(ke)&&(Ye=D(at,ke)),Ye&&(Re._fullLayout._noEmitSelectedAtStart=!0,s.call("_guiRelayout",Re,{selections:Ye}).then(function(){Ae&&O(Re)})),Re._fullLayout._outlining=!1)}De.selection={},De.selection.selectionDefs=ke.selectionDefs=[],De.selection.mergedPolygons=ke.mergedPolygons=[]}function re(ke){return ke._id}function ie(ke,Ae,Ee,De){if(!ke.calcdata)return[];var Re,Ie,Be,Ue=[],qe=Ae.map(re),Ye=Ee.map(re);for(Be=0;Be0?De[0]:Ee;return!!Ae.selectedpoints&&Ae.selectedpoints.indexOf(Re)>-1}function pe(ke,Ae,Ee){var De,Re;for(De=0;De-1&&Ae;if(!Ie&&Ae){var Ot=ne(ke,!0);if(Ot.length){var At=Ot[0].xref,Lt=Ot[0].yref;if(At&&Lt){var Rt=ue(Ot);ge([B(ke,At,"x"),B(ke,Lt,"y")])(jt,Rt)}}ke._fullLayout._noEmitSelectedAtStart?ke._fullLayout._noEmitSelectedAtStart=!1:Tt&&be(ke,jt),ct._reselect=!1}if(!Ie&&ct._deselect){var $t=ct._deselect;(function(Yt,Xt,Bt){for(var Wt=0;Wt=0)bt._fullLayout._deactivateShape(bt);else if(!Ye){var Rt=ze.clickmode;z.done(Et).then(function(){if(z.clear(Et),At===2){for(Nt.remove(),_e=0;_e-1&&ee(Lt,bt,De.xaxes,De.yaxes,De.subplot,De,Nt),Rt==="event"&&be(bt,void 0);h.click(bt,Lt,kt.id)}).catch(R.error)}},De.doneFn=function(){yt.remove(),z.done(Et).then(function(){z.clear(Et),!Ne&&ve&&De.selectionDefs&&(ve.subtract=St,De.selectionDefs.push(ve),De.mergedPolygons.length=0,[].push.apply(De.mergedPolygons,wt)),(Ne||Ye)&&X(De,Ne),De.doneFnCompleted&&De.doneFnCompleted(jt),at&&be(bt,We)}).catch(R.error)}},clearOutline:T,clearSelectionsCache:X,selectOnClick:ee}},89827:function(o,a,n){var l=n(50215),f=n(41940),s=n(82196).line,u=n(79952).P,d=n(1426).extendFlat,h=n(44467).templatedArray,p=(n(24695),n(9012)),g=n(5386).R,y=n(37281);o.exports=h("shape",{visible:d({},p.visible,{editType:"calc+arraydraw"}),showlegend:{valType:"boolean",dflt:!1,editType:"calc+arraydraw"},legend:d({},p.legend,{editType:"calc+arraydraw"}),legendgroup:d({},p.legendgroup,{editType:"calc+arraydraw"}),legendgrouptitle:{text:d({},p.legendgrouptitle.text,{editType:"calc+arraydraw"}),font:f({editType:"calc+arraydraw"}),editType:"calc+arraydraw"},legendrank:d({},p.legendrank,{editType:"calc+arraydraw"}),legendwidth:d({},p.legendwidth,{editType:"calc+arraydraw"}),type:{valType:"enumerated",values:["circle","rect","path","line"],editType:"calc+arraydraw"},layer:{valType:"enumerated",values:["below","above"],dflt:"above",editType:"arraydraw"},xref:d({},l.xref,{}),xsizemode:{valType:"enumerated",values:["scaled","pixel"],dflt:"scaled",editType:"calc+arraydraw"},xanchor:{valType:"any",editType:"calc+arraydraw"},x0:{valType:"any",editType:"calc+arraydraw"},x1:{valType:"any",editType:"calc+arraydraw"},yref:d({},l.yref,{}),ysizemode:{valType:"enumerated",values:["scaled","pixel"],dflt:"scaled",editType:"calc+arraydraw"},yanchor:{valType:"any",editType:"calc+arraydraw"},y0:{valType:"any",editType:"calc+arraydraw"},y1:{valType:"any",editType:"calc+arraydraw"},path:{valType:"string",editType:"calc+arraydraw"},opacity:{valType:"number",min:0,max:1,dflt:1,editType:"arraydraw"},line:{color:d({},s.color,{editType:"arraydraw"}),width:d({},s.width,{editType:"calc+arraydraw"}),dash:d({},u,{editType:"arraydraw"}),editType:"calc+arraydraw"},fillcolor:{valType:"color",dflt:"rgba(0,0,0,0)",editType:"arraydraw"},fillrule:{valType:"enumerated",values:["evenodd","nonzero"],dflt:"evenodd",editType:"arraydraw"},editable:{valType:"boolean",dflt:!1,editType:"calc+arraydraw"},label:{text:{valType:"string",dflt:"",editType:"arraydraw"},texttemplate:g({},{keys:Object.keys(y)}),font:f({editType:"calc+arraydraw",colorEditType:"arraydraw"}),textposition:{valType:"enumerated",values:["top left","top center","top right","middle left","middle center","middle right","bottom left","bottom center","bottom right","start","middle","end"],editType:"arraydraw"},textangle:{valType:"angle",dflt:"auto",editType:"calc+arraydraw"},xanchor:{valType:"enumerated",values:["auto","left","center","right"],dflt:"auto",editType:"calc+arraydraw"},yanchor:{valType:"enumerated",values:["top","middle","bottom"],editType:"calc+arraydraw"},padding:{valType:"number",dflt:3,min:0,editType:"arraydraw"},editType:"arraydraw"},editType:"arraydraw"})},5627:function(o,a,n){var l=n(71828),f=n(89298),s=n(21459),u=n(30477);function d(y){return p(y.line.width,y.xsizemode,y.x0,y.x1,y.path,!1)}function h(y){return p(y.line.width,y.ysizemode,y.y0,y.y1,y.path,!0)}function p(y,v,m,b,x,_){var w=y/2,k=_;if(v==="pixel"){var T=x?u.extractPathCoords(x,_?s.paramIsY:s.paramIsX):[m,b],M=l.aggNums(Math.max,null,T),S=l.aggNums(Math.min,null,T),C=S<0?Math.abs(S)+w:w,P=M>0?M+w:w;return{ppad:w,ppadplus:k?C:P,ppadminus:k?P:C}}return{ppad:w}}function g(y,v,m,b,x){var _=y.type==="category"||y.type==="multicategory"?y.r2c:y.d2c;if(v!==void 0)return[_(v),_(m)];if(b){var w,k,T,M,S=1/0,C=-1/0,P=b.match(s.segmentRE);for(y.type==="date"&&(_=u.decodeDate(_)),w=0;wC&&(C=M)));return C>=S?[S,C]:void 0}}o.exports=function(y){var v=y._fullLayout,m=l.filterVisible(v.shapes);if(m.length&&y._fullData.length)for(var b=0;b=re?ie-se:se-ie,-180/Math.PI*Math.atan2(pe,Te)}(C,D,P,O):0),A.call(function(re){return re.call(u.font,F).attr({}),s.convertToTspans(re,v),re});var Q=function(re,ie,le,se,pe,Te,Se){var Oe,Me,ce,ye,J=pe.label.textposition,ne=pe.label.textangle,de=pe.label.padding,xe=pe.type,ue=Math.PI/180*Te,ge=Math.sin(ue),be=Math.cos(ue),we=pe.label.xanchor,ke=pe.label.yanchor;if(xe==="line"){J==="start"?(Oe=re,Me=ie):J==="end"?(Oe=le,Me=se):(Oe=(re+le)/2,Me=(ie+se)/2),we==="auto"&&(we=J==="start"?ne==="auto"?le>re?"left":lere?"right":lere?"right":lere?"left":le1&&(Oe.length!==2||Oe[1][0]!=="Z")&&(G===0&&(Oe[0][0]="M"),R[W]=Oe,$(),j())}}()}}function re(pe,Te){(function(Se,Oe){if(R.length)for(var Me=0;MeMe?(J=Se,ue="y0",ne=Me,ge="y1"):(J=Me,ue="y1",ne=Se,ge="y0"),ut(wt),Mt(se,ie),function(ve,_e,Ve){var We=_e.xref,Ze=_e.yref,Ge=u.getFromId(Ve,We),Ke=u.getFromId(Ve,Ze),nt="";We==="paper"||Ge.autorange||(nt+=We),Ze==="paper"||Ke.autorange||(nt+=Ze),v.setClipUrl(ve,nt?"clip"+Ve._fullLayout._uid+nt:null,Ve)}(re,ie,X),Je.moveFn=Ae==="move"?pt:It,Je.altKey=wt.altKey)},doneFn:function(){M(X)||(x(re),zt(se),P(re,X,ie),f.call("_guiRelayout",X,pe.getUpdateObj()))},clickFn:function(){M(X)||zt(se)}};function ut(wt){if(M(X))Ae=null;else if(Be)Ae=wt.target.tagName==="path"?"move":wt.target.attributes["data-line-point"].value==="start-point"?"resize-over-start-point":"resize-over-end-point";else{var ve=Je.element.getBoundingClientRect(),_e=ve.right-ve.left,Ve=ve.bottom-ve.top,We=wt.clientX-ve.left,Ze=wt.clientY-ve.top,Ge=!Ue&&_e>Ee&&Ve>De&&!wt.shiftKey?b.getCursor(We/_e,1-Ze/Ve):"move";x(re,Ge),Ae=Ge.split("-")[0]}}function pt(wt,ve){if(ie.type==="path"){var _e=function(Ze){return Ze},Ve=_e,We=_e;Re?qe("xanchor",ie.xanchor=Qe(ce+wt)):(Ve=function(Ze){return Qe(ze(Ze)+wt)},at&&at.type==="date"&&(Ve=w.encodeDate(Ve))),Ie?qe("yanchor",ie.yanchor=it(ye+ve)):(We=function(Ze){return it(Ne(Ze)+ve)},ct&&ct.type==="date"&&(We=w.encodeDate(We))),qe("path",ie.path=D(ke,Ve,We))}else Re?qe("xanchor",ie.xanchor=Qe(ce+wt)):(qe("x0",ie.x0=Qe(Te+wt)),qe("x1",ie.x1=Qe(Oe+wt))),Ie?qe("yanchor",ie.yanchor=it(ye+ve)):(qe("y0",ie.y0=it(Se+ve)),qe("y1",ie.y1=it(Me+ve)));re.attr("d",k(X,ie)),Mt(se,ie),p(X,le,ie,Ye)}function It(wt,ve){if(Ue){var _e=function(ht){return ht},Ve=_e,We=_e;Re?qe("xanchor",ie.xanchor=Qe(ce+wt)):(Ve=function(ht){return Qe(ze(ht)+wt)},at&&at.type==="date"&&(Ve=w.encodeDate(Ve))),Ie?qe("yanchor",ie.yanchor=it(ye+ve)):(We=function(ht){return it(Ne(ht)+ve)},ct&&ct.type==="date"&&(We=w.encodeDate(We))),qe("path",ie.path=D(ke,Ve,We))}else if(Be){if(Ae==="resize-over-start-point"){var Ze=Te+wt,Ge=Ie?Se-ve:Se+ve;qe("x0",ie.x0=Re?Ze:Qe(Ze)),qe("y0",ie.y0=Ie?Ge:it(Ge))}else if(Ae==="resize-over-end-point"){var Ke=Oe+wt,nt=Ie?Me-ve:Me+ve;qe("x1",ie.x1=Re?Ke:Qe(Ke)),qe("y1",ie.y1=Ie?nt:it(nt))}}else{var st=function(ht){return Ae.indexOf(ht)!==-1},mt=st("n"),tt=st("s"),Ft=st("w"),Vt=st("e"),St=mt?J+ve:J,Nt=tt?ne+ve:ne,Dt=Ft?de+wt:de,gt=Vt?xe+wt:xe;Ie&&(mt&&(St=J-ve),tt&&(Nt=ne-ve)),(!Ie&&Nt-St>De||Ie&&St-Nt>De)&&(qe(ue,ie[ue]=Ie?St:it(St)),qe(ge,ie[ge]=Ie?Nt:it(Nt))),gt-Dt>Ee&&(qe(be,ie[be]=Re?Dt:Qe(Dt)),qe(we,ie[we]=Re?gt:Qe(gt)))}re.attr("d",k(X,ie)),Mt(se,ie),p(X,le,ie,Ye)}function Mt(wt,ve){(Re||Ie)&&function(){var _e=ve.type!=="path",Ve=wt.selectAll(".visual-cue").data([0]);Ve.enter().append("path").attr({fill:"#fff","fill-rule":"evenodd",stroke:"#000","stroke-width":1}).classed("visual-cue",!0);var We=ze(Re?ve.xanchor:s.midRange(_e?[ve.x0,ve.x1]:w.extractPathCoords(ve.path,_.paramIsX))),Ze=Ne(Ie?ve.yanchor:s.midRange(_e?[ve.y0,ve.y1]:w.extractPathCoords(ve.path,_.paramIsY)));if(We=w.roundPositionForSharpStrokeRendering(We,1),Ze=w.roundPositionForSharpStrokeRendering(Ze,1),Re&&Ie){var Ge="M"+(We-1-1)+","+(Ze-1-1)+"h-8v2h8 v8h2v-8 h8v-2h-8 v-8h-2 Z";Ve.attr("d",Ge)}else if(Re){var Ke="M"+(We-1-1)+","+(Ze-9-1)+"v18 h2 v-18 Z";Ve.attr("d",Ke)}else{var nt="M"+(We-9-1)+","+(Ze-1-1)+"h18 v2 h-18 Z";Ve.attr("d",nt)}}()}function zt(wt){wt.selectAll(".visual-cue").remove()}b.init(Je),kt.node().onmousemove=ut}(R,Q,z,F,j,ee):z.editable===!0&&Q.style("pointer-events",V||y.opacity(G)*W<=.5?"stroke":"all");Q.node().addEventListener("click",function(){return function(X,re){if(S(X)){var ie=+re.node().getAttribute("data-index");if(ie>=0){if(ie===X._fullLayout._activeShapeIndex)return void O(X);X._fullLayout._activeShapeIndex=ie,X._fullLayout._deactivateShape=O,T(X)}}}(R,Q)})}z._input&&z.visible===!0&&(z.layer!=="below"?$(R._fullLayout._shapeUpperLayer):z.xref==="paper"||z.yref==="paper"?$(R._fullLayout._shapeLowerLayer):B._hadPlotinfo?$((B.mainplotinfo||B).shapelayer):$(R._fullLayout._shapeLowerLayer))}function P(R,F,A){var z=(A.xref+A.yref).replace(/paper/g,"").replace(/[xyz][1-9]* *domain/g,"");v.setClipUrl(R,z?"clip"+F._fullLayout._uid+z:null,F)}function D(R,F,A){return R.replace(_.segmentRE,function(z){var B=0,$=z.charAt(0),j=_.paramIsX[$],N=_.paramIsY[$],E=_.numParams[$];return $+z.substr(1).replace(_.paramRE,function(W){return B>=E||(j[B]?W=F(W):N[B]&&(W=A(W)),B++),W})})}function O(R){S(R)&&R._fullLayout._activeShapeIndex>=0&&(g(R),delete R._fullLayout._activeShapeIndex,T(R))}o.exports={draw:T,drawOne:C,eraseActiveShape:function(R){if(S(R)){g(R);var F=R._fullLayout._activeShapeIndex,A=(R.layout||{}).shapes||[];if(F0&&CU&&(Y="X"),Y});return H>U&&(Q=Q.replace(/[\s,]*X.*/,""),f.log("Ignoring extra params in segment "+q)),V+Q})}(d,p,y);if(d.xsizemode==="pixel"){var C=p(d.xanchor);v=C+d.x0,m=C+d.x1}else v=p(d.x0),m=p(d.x1);if(d.ysizemode==="pixel"){var P=y(d.yanchor);b=P-d.y0,x=P-d.y1}else b=y(d.y0),x=y(d.y1);if(_==="line")return"M"+v+","+b+"L"+m+","+x;if(_==="rect")return"M"+v+","+b+"H"+m+"V"+x+"H"+v+"Z";var D=(v+m)/2,O=(b+x)/2,R=Math.abs(D-v),F=Math.abs(O-b),A="A"+R+","+F,z=D+R+","+O;return"M"+z+A+" 0 1,1 "+D+","+(O-F)+A+" 0 0,1 "+z+"Z"}},89853:function(o,a,n){var l=n(34031);o.exports={moduleType:"component",name:"shapes",layoutAttributes:n(89827),supplyLayoutDefaults:n(84726),supplyDrawNewShapeDefaults:n(45547),includeBasePlot:n(76325)("shapes"),calcAutorange:n(5627),draw:l.draw,drawOne:l.drawOne}},37281:function(o){function a(s,u){return u?u.d2l(s):s}function n(s,u){return u?u.l2d(s):s}function l(s,u){return a(s.x1,u)-a(s.x0,u)}function f(s,u,d){return a(s.y1,d)-a(s.y0,d)}o.exports={x0:function(s){return s.x0},x1:function(s){return s.x1},y0:function(s){return s.y0},y1:function(s){return s.y1},slope:function(s,u,d){return s.type!=="line"?void 0:f(s,0,d)/l(s,u)},dx:l,dy:f,width:function(s,u){return Math.abs(l(s,u))},height:function(s,u,d){return Math.abs(f(s,0,d))},length:function(s,u,d){return s.type!=="line"?void 0:Math.sqrt(Math.pow(l(s,u),2)+Math.pow(f(s,0,d),2))},xcenter:function(s,u){return n((a(s.x1,u)+a(s.x0,u))/2,u)},ycenter:function(s,u,d){return n((a(s.y1,d)+a(s.y0,d))/2,d)}}},75067:function(o,a,n){var l=n(41940),f=n(35025),s=n(1426).extendDeepAll,u=n(30962).overrideAll,d=n(85594),h=n(44467).templatedArray,p=n(98292),g=h("step",{visible:{valType:"boolean",dflt:!0},method:{valType:"enumerated",values:["restyle","relayout","animate","update","skip"],dflt:"restyle"},args:{valType:"info_array",freeLength:!0,items:[{valType:"any"},{valType:"any"},{valType:"any"}]},label:{valType:"string"},value:{valType:"string"},execute:{valType:"boolean",dflt:!0}});o.exports=u(h("slider",{visible:{valType:"boolean",dflt:!0},active:{valType:"number",min:0,dflt:0},steps:g,lenmode:{valType:"enumerated",values:["fraction","pixels"],dflt:"fraction"},len:{valType:"number",min:0,dflt:1},x:{valType:"number",min:-2,max:3,dflt:0},pad:s(f({editType:"arraydraw"}),{},{t:{dflt:20}}),xanchor:{valType:"enumerated",values:["auto","left","center","right"],dflt:"left"},y:{valType:"number",min:-2,max:3,dflt:0},yanchor:{valType:"enumerated",values:["auto","top","middle","bottom"],dflt:"top"},transition:{duration:{valType:"number",min:0,dflt:150},easing:{valType:"enumerated",values:d.transition.easing.values,dflt:"cubic-in-out"}},currentvalue:{visible:{valType:"boolean",dflt:!0},xanchor:{valType:"enumerated",values:["left","center","right"],dflt:"left"},offset:{valType:"number",dflt:10},prefix:{valType:"string"},suffix:{valType:"string"},font:l({})},font:l({}),activebgcolor:{valType:"color",dflt:p.gripBgActiveColor},bgcolor:{valType:"color",dflt:p.railBgColor},bordercolor:{valType:"color",dflt:p.railBorderColor},borderwidth:{valType:"number",min:0,dflt:p.railBorderWidth},ticklen:{valType:"number",min:0,dflt:p.tickLength},tickcolor:{valType:"color",dflt:p.tickColor},tickwidth:{valType:"number",min:0,dflt:1},minorticklen:{valType:"number",min:0,dflt:p.minorTickLength}}),"arraydraw","from-root")},98292:function(o){o.exports={name:"sliders",containerClassName:"slider-container",groupClassName:"slider-group",inputAreaClass:"slider-input-area",railRectClass:"slider-rail-rect",railTouchRectClass:"slider-rail-touch-rect",gripRectClass:"slider-grip-rect",tickRectClass:"slider-tick-rect",inputProxyClass:"slider-input-proxy",labelsClass:"slider-labels",labelGroupClass:"slider-label-group",labelClass:"slider-label",currentValueClass:"slider-current-value",railHeight:5,menuIndexAttrName:"slider-active-index",autoMarginIdRoot:"slider-",minWidth:30,minHeight:30,textPadX:40,arrowOffsetX:4,railRadius:2,railWidth:5,railBorder:4,railBorderWidth:1,railBorderColor:"#bec8d9",railBgColor:"#f8fafc",railInset:8,stepInset:10,gripRadius:10,gripWidth:20,gripHeight:20,gripBorder:20,gripBorderWidth:1,gripBorderColor:"#bec8d9",gripBgColor:"#f6f8fa",gripBgActiveColor:"#dbdde0",labelPadding:8,labelOffset:0,tickWidth:1,tickColor:"#333",tickOffset:25,tickLength:7,minorTickOffset:25,minorTickColor:"#333",minorTickLength:4,currentValuePadding:8,currentValueInset:0}},12343:function(o,a,n){var l=n(71828),f=n(85501),s=n(75067),u=n(98292).name,d=s.steps;function h(g,y,v){function m(k,T){return l.coerce(g,y,s,k,T)}for(var b=f(g,y,{name:"steps",handleItemDefaults:p}),x=0,_=0;_0&&(H=H.transition().duration(N.transition.duration).ease(N.transition.easing)),H.attr("transform",h(q-.5*y.gripWidth,N._dims.currentValueTotalHeight))}}function A(j,N){var E=j._dims;return E.inputAreaStart+y.stepInset+(E.inputAreaLength-2*y.stepInset)*Math.min(1,Math.max(0,N))}function z(j,N){var E=j._dims;return Math.min(1,Math.max(0,(N-y.stepInset-E.inputAreaStart)/(E.inputAreaLength-2*y.stepInset-2*E.inputAreaStart)))}function B(j,N,E){var W=E._dims,G=d.ensureSingle(j,"rect",y.railTouchRectClass,function(L){L.call(O,N,j,E).style("pointer-events","all")});G.attr({width:W.inputAreaLength,height:Math.max(W.inputAreaWidth,y.tickOffset+E.ticklen+W.labelHeight)}).call(s.fill,E.bgcolor).attr("opacity",0),u.setTranslate(G,0,W.currentValueTotalHeight)}function $(j,N){var E=N._dims,W=E.inputAreaLength-2*y.railInset,G=d.ensureSingle(j,"rect",y.railRectClass);G.attr({width:W,height:y.railWidth,rx:y.railRadius,ry:y.railRadius,"shape-rendering":"crispEdges"}).call(s.stroke,N.bordercolor).call(s.fill,N.bgcolor).style("stroke-width",N.borderwidth+"px"),u.setTranslate(G,y.railInset,.5*(E.inputAreaWidth-y.railWidth)+E.currentValueTotalHeight)}o.exports=function(j){var N=j._context.staticPlot,E=j._fullLayout,W=function(te,ee){for(var U=te[y.name],Q=[],Y=0;Y0?[0]:[]);function L(te){te._commandObserver&&(te._commandObserver.remove(),delete te._commandObserver),f.autoMargin(j,_(te))}if(G.enter().append("g").classed(y.containerClassName,!0).style("cursor",N?null:"ew-resize"),G.exit().each(function(){l.select(this).selectAll("g."+y.groupClassName).each(L)}).remove(),W.length!==0){var q=G.selectAll("g."+y.groupClassName).data(W,w);q.enter().append("g").classed(y.groupClassName,!0),q.exit().each(L).remove();for(var H=0;H0||Oe<0){var J={left:[-Me,0],right:[Me,0],top:[0,-Me],bottom:[0,Me]}[P.side];Q.attr("transform",h(J[0],J[1]))}}}return H.call(V),G&&($?H.on(".opacity",null):(A=0,z=!0,H.text(S).on("mouseover.opacity",function(){l.select(this).transition().duration(v.SHOW_PLACEHOLDER).style("opacity",1)}).on("mouseout.opacity",function(){l.select(this).transition().duration(v.HIDE_PLACEHOLDER).style("opacity",0)})),H.call(y.makeEditable,{gd:x}).on("edit",function(U){C!==void 0?u.call("_guiRestyle",x,M,U,C):u.call("_guiRelayout",x,M,U)}).on("cancel",function(){this.text(this.attr("data-unformatted")).call(V)}).on("input",function(U){this.text(U||" ").call(y.positionText,D.x,D.y)})),H.classed("js-placeholder",z),R}}},7163:function(o,a,n){var l=n(41940),f=n(22399),s=n(1426).extendFlat,u=n(30962).overrideAll,d=n(35025),h=n(44467).templatedArray,p=h("button",{visible:{valType:"boolean"},method:{valType:"enumerated",values:["restyle","relayout","animate","update","skip"],dflt:"restyle"},args:{valType:"info_array",freeLength:!0,items:[{valType:"any"},{valType:"any"},{valType:"any"}]},args2:{valType:"info_array",freeLength:!0,items:[{valType:"any"},{valType:"any"},{valType:"any"}]},label:{valType:"string",dflt:""},execute:{valType:"boolean",dflt:!0}});o.exports=u(h("updatemenu",{_arrayAttrRegexps:[/^updatemenus\[(0|[1-9][0-9]+)\]\.buttons/],visible:{valType:"boolean"},type:{valType:"enumerated",values:["dropdown","buttons"],dflt:"dropdown"},direction:{valType:"enumerated",values:["left","right","up","down"],dflt:"down"},active:{valType:"integer",min:-1,dflt:0},showactive:{valType:"boolean",dflt:!0},buttons:p,x:{valType:"number",min:-2,max:3,dflt:-.05},xanchor:{valType:"enumerated",values:["auto","left","center","right"],dflt:"right"},y:{valType:"number",min:-2,max:3,dflt:1},yanchor:{valType:"enumerated",values:["auto","top","middle","bottom"],dflt:"top"},pad:s(d({editType:"arraydraw"}),{}),font:l({}),bgcolor:{valType:"color"},bordercolor:{valType:"color",dflt:f.borderLine},borderwidth:{valType:"number",min:0,dflt:1,editType:"arraydraw"}}),"arraydraw","from-root")},75909:function(o){o.exports={name:"updatemenus",containerClassName:"updatemenu-container",headerGroupClassName:"updatemenu-header-group",headerClassName:"updatemenu-header",headerArrowClassName:"updatemenu-header-arrow",dropdownButtonGroupClassName:"updatemenu-dropdown-button-group",dropdownButtonClassName:"updatemenu-dropdown-button",buttonClassName:"updatemenu-button",itemRectClassName:"updatemenu-item-rect",itemTextClassName:"updatemenu-item-text",menuIndexAttrName:"updatemenu-active-index",autoMarginIdRoot:"updatemenu-",blankHeaderOpts:{label:" "},minWidth:30,minHeight:30,textPadX:24,arrowPadX:16,rx:2,ry:2,textOffsetX:12,textOffsetY:3,arrowOffsetX:4,gapButtonHeader:5,gapButton:2,activeColor:"#F4FAFF",hoverColor:"#F4FAFF",arrowSymbol:{left:"◄",right:"►",up:"▲",down:"▼"}}},64897:function(o,a,n){var l=n(71828),f=n(85501),s=n(7163),u=n(75909).name,d=s.buttons;function h(g,y,v){function m(b,x){return l.coerce(g,y,s,b,x)}m("visible",f(g,y,{name:"buttons",handleItemDefaults:p}).length>0)&&(m("active"),m("direction"),m("type"),m("showactive"),m("x"),m("y"),l.noneOrAll(g,y,["x","y"]),m("xanchor"),m("yanchor"),m("pad.t"),m("pad.r"),m("pad.b"),m("pad.l"),l.coerceFont(m,"font",v.font),m("bgcolor",v.paper_bgcolor),m("bordercolor"),m("borderwidth"))}function p(g,y){function v(m,b){return l.coerce(g,y,d,m,b)}v("visible",g.method==="skip"||Array.isArray(g.args))&&(v("method"),v("args"),v("args2"),v("label"),v("execute"))}o.exports=function(g,y){f(g,y,{name:u,handleItemDefaults:h})}},13689:function(o,a,n){var l=n(39898),f=n(74875),s=n(7901),u=n(91424),d=n(71828),h=n(63893),p=n(44467).arrayEditor,g=n(18783).LINE_SPACING,y=n(75909),v=n(25849);function m(A){return A._index}function b(A,z){return+A.attr(y.menuIndexAttrName)===z._index}function x(A,z,B,$,j,N,E,W){z.active=E,p(A.layout,y.name,z).applyUpdate("active",E),z.type==="buttons"?w(A,$,null,null,z):z.type==="dropdown"&&(j.attr(y.menuIndexAttrName,"-1"),_(A,$,j,N,z),W||w(A,$,j,N,z))}function _(A,z,B,$,j){var N=d.ensureSingle(z,"g",y.headerClassName,function(H){H.style("pointer-events","all")}),E=j._dims,W=j.active,G=j.buttons[W]||y.blankHeaderOpts,L={y:j.pad.t,yPad:0,x:j.pad.l,xPad:0,index:0},q={width:E.headerWidth,height:E.headerHeight};N.call(k,j,G,A).call(R,j,L,q),d.ensureSingle(z,"text",y.headerArrowClassName,function(H){H.attr("text-anchor","end").call(u.font,j.font).text(y.arrowSymbol[j.direction])}).attr({x:E.headerWidth-y.arrowOffsetX+j.pad.l,y:E.headerHeight/2+y.textOffsetY+j.pad.t}),N.on("click",function(){B.call(F,String(b(B,j)?-1:j._index)),w(A,z,B,$,j)}),N.on("mouseover",function(){N.call(C)}),N.on("mouseout",function(){N.call(P,j)}),u.setTranslate(z,E.lx,E.ly)}function w(A,z,B,$,j){B||(B=z).attr("pointer-events","all");var N=function(Q){return+Q.attr(y.menuIndexAttrName)==-1}(B)&&j.type!=="buttons"?[]:j.buttons,E=j.type==="dropdown"?y.dropdownButtonClassName:y.buttonClassName,W=B.selectAll("g."+E).data(d.filterVisible(N)),G=W.enter().append("g").classed(E,!0),L=W.exit();j.type==="dropdown"?(G.attr("opacity","0").transition().attr("opacity","1"),L.transition().attr("opacity","0").remove()):L.remove();var q=0,H=0,V=j._dims,te=["up","down"].indexOf(j.direction)!==-1;j.type==="dropdown"&&(te?H=V.headerHeight+y.gapButtonHeader:q=V.headerWidth+y.gapButtonHeader),j.type==="dropdown"&&j.direction==="up"&&(H=-y.gapButtonHeader+y.gapButton-V.openHeight),j.type==="dropdown"&&j.direction==="left"&&(q=-y.gapButtonHeader+y.gapButton-V.openWidth);var ee={x:V.lx+q+j.pad.l,y:V.ly+H+j.pad.t,yPad:y.gapButton,xPad:y.gapButton,index:0},U={l:ee.x+j.borderwidth,t:ee.y+j.borderwidth};W.each(function(Q,Y){var Z=l.select(this);Z.call(k,j,Q,A).call(R,j,ee),Z.on("click",function(){l.event.defaultPrevented||(Q.execute&&(Q.args2&&j.active===Y?(x(A,j,0,z,B,$,-1),f.executeAPICommand(A,Q.method,Q.args2)):(x(A,j,0,z,B,$,Y),f.executeAPICommand(A,Q.method,Q.args))),A.emit("plotly_buttonclicked",{menu:j,button:Q,active:j.active}))}),Z.on("mouseover",function(){Z.call(C)}),Z.on("mouseout",function(){Z.call(P,j),W.call(S,j)})}),W.call(S,j),te?(U.w=Math.max(V.openWidth,V.headerWidth),U.h=ee.y-U.t):(U.w=ee.x-U.l,U.h=Math.max(V.openHeight,V.headerHeight)),U.direction=j.direction,$&&(W.size()?function(Q,Y,Z,X,re,ie){var le,se,pe,Te=re.direction,Se=Te==="up"||Te==="down",Oe=re._dims,Me=re.active;if(Se)for(se=0,pe=0;pe0?[0]:[]);if(j.enter().append("g").classed(y.containerClassName,!0).style("cursor","pointer"),j.exit().each(function(){l.select(this).selectAll("g."+y.headerGroupClassName).each($)}).remove(),B.length!==0){var N=j.selectAll("g."+y.headerGroupClassName).data(B,m);N.enter().append("g").classed(y.headerGroupClassName,!0);for(var E=d.ensureSingle(j,"g",y.dropdownButtonGroupClassName,function(H){H.style("pointer-events","all")}),W=0;WR,z=d.barLength+2*d.barPad,B=d.barWidth+2*d.barPad,$=k,j=M+S;j+B>m&&(j=m-B);var N=this.container.selectAll("rect.scrollbar-horizontal").data(A?[0]:[]);N.exit().on(".drag",null).remove(),N.enter().append("rect").classed("scrollbar-horizontal",!0).call(f.fill,d.barColor),A?(this.hbar=N.attr({rx:d.barRadius,ry:d.barRadius,x:$,y:j,width:z,height:B}),this._hbarXMin=$+z/2,this._hbarTranslateMax=R-z):(delete this.hbar,delete this._hbarXMin,delete this._hbarTranslateMax);var E=S>F,W=d.barWidth+2*d.barPad,G=d.barLength+2*d.barPad,L=k+T,q=M;L+W>v&&(L=v-W);var H=this.container.selectAll("rect.scrollbar-vertical").data(E?[0]:[]);H.exit().on(".drag",null).remove(),H.enter().append("rect").classed("scrollbar-vertical",!0).call(f.fill,d.barColor),E?(this.vbar=H.attr({rx:d.barRadius,ry:d.barRadius,x:L,y:q,width:W,height:G}),this._vbarYMin=q+G/2,this._vbarTranslateMax=F-G):(delete this.vbar,delete this._vbarYMin,delete this._vbarTranslateMax);var V=this.id,te=b-.5,ee=E?x+W+.5:x+.5,U=_-.5,Q=A?w+B+.5:w+.5,Y=y._topdefs.selectAll("#"+V).data(A||E?[0]:[]);if(Y.exit().remove(),Y.enter().append("clipPath").attr("id",V).append("rect"),A||E?(this._clipRect=Y.select("rect").attr({x:Math.floor(te),y:Math.floor(U),width:Math.ceil(ee)-Math.floor(te),height:Math.ceil(Q)-Math.floor(U)}),this.container.call(s.setClipUrl,V,this.gd),this.bg.attr({x:k,y:M,width:T,height:S})):(this.bg.attr({width:0,height:0}),this.container.on("wheel",null).on(".drag",null).call(s.setClipUrl,null),delete this._clipRect),A||E){var Z=l.behavior.drag().on("dragstart",function(){l.event.sourceEvent.preventDefault()}).on("drag",this._onBoxDrag.bind(this));this.container.on("wheel",null).on("wheel",this._onBoxWheel.bind(this)).on(".drag",null).call(Z);var X=l.behavior.drag().on("dragstart",function(){l.event.sourceEvent.preventDefault(),l.event.sourceEvent.stopPropagation()}).on("drag",this._onBarDrag.bind(this));A&&this.hbar.on(".drag",null).call(X),E&&this.vbar.on(".drag",null).call(X)}this.setTranslate(p,g)},d.prototype.disable=function(){(this.hbar||this.vbar)&&(this.bg.attr({width:0,height:0}),this.container.on("wheel",null).on(".drag",null).call(s.setClipUrl,null),delete this._clipRect),this.hbar&&(this.hbar.on(".drag",null),this.hbar.remove(),delete this.hbar,delete this._hbarXMin,delete this._hbarTranslateMax),this.vbar&&(this.vbar.on(".drag",null),this.vbar.remove(),delete this.vbar,delete this._vbarYMin,delete this._vbarTranslateMax)},d.prototype._onBoxDrag=function(){var h=this.translateX,p=this.translateY;this.hbar&&(h-=l.event.dx),this.vbar&&(p-=l.event.dy),this.setTranslate(h,p)},d.prototype._onBoxWheel=function(){var h=this.translateX,p=this.translateY;this.hbar&&(h+=l.event.deltaY),this.vbar&&(p+=l.event.deltaY),this.setTranslate(h,p)},d.prototype._onBarDrag=function(){var h=this.translateX,p=this.translateY;if(this.hbar){var g=h+this._hbarXMin,y=g+this._hbarTranslateMax;h=(u.constrain(l.event.x,g,y)-g)/(y-g)*(this.position.w-this._box.w)}if(this.vbar){var v=p+this._vbarYMin,m=v+this._vbarTranslateMax;p=(u.constrain(l.event.y,v,m)-v)/(m-v)*(this.position.h-this._box.h)}this.setTranslate(h,p)},d.prototype.setTranslate=function(h,p){var g=this.position.w-this._box.w,y=this.position.h-this._box.h;if(h=u.constrain(h||0,0,g),p=u.constrain(p||0,0,y),this.translateX=h,this.translateY=p,this.container.call(s.setTranslate,this._box.l-this.position.l-h,this._box.t-this.position.t-p),this._clipRect&&this._clipRect.attr({x:Math.floor(this.position.l+h-.5),y:Math.floor(this.position.t+p-.5)}),this.hbar){var v=h/g;this.hbar.call(s.setTranslate,h+v*this._hbarTranslateMax,p)}if(this.vbar){var m=p/y;this.vbar.call(s.setTranslate,h,p+m*this._vbarTranslateMax)}}},18783:function(o){o.exports={FROM_BL:{left:0,center:.5,right:1,bottom:0,middle:.5,top:1},FROM_TL:{left:0,center:.5,right:1,bottom:1,middle:.5,top:0},FROM_BR:{left:1,center:.5,right:0,bottom:0,middle:.5,top:1},LINE_SPACING:1.3,CAP_SHIFT:.7,MID_SHIFT:.35,OPPOSITE_SIDE:{left:"right",right:"left",top:"bottom",bottom:"top"}}},24695:function(o){o.exports={axisRefDescription:function(a,n,l){return["If set to a",a,"axis id (e.g. *"+a+"* or","*"+a+"2*), the `"+a+"` position refers to a",a,"coordinate. If set to *paper*, the `"+a+"`","position refers to the distance from the",n,"of the plotting","area in normalized coordinates where *0* (*1*) corresponds to the",n,"("+l+"). If set to a",a,"axis ID followed by","*domain* (separated by a space), the position behaves like for","*paper*, but refers to the distance in fractions of the domain","length from the",n,"of the domain of that axis: e.g.,","*"+a+"2 domain* refers to the domain of the second",a," axis and a",a,"position of 0.5 refers to the","point between the",n,"and the",l,"of the domain of the","second",a,"axis."].join(" ")}}},31562:function(o){o.exports={FORMAT_LINK:"https://github.com/d3/d3-format/tree/v1.4.5#d3-format",DATE_FORMAT_LINK:"https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format"}},74808:function(o){o.exports={COMPARISON_OPS:["=","!=","<",">=",">","<="],COMPARISON_OPS2:["=","<",">=",">","<="],INTERVAL_OPS:["[]","()","[)","(]","][",")(","](",")["],SET_OPS:["{}","}{"],CONSTRAINT_REDUCTION:{"=":"=","<":"<","<=":"<",">":">",">=":">","[]":"[]","()":"[]","[)":"[]","(]":"[]","][":"][",")(":"][","](":"][",")[":"]["}}},37822:function(o){o.exports={SHOW_PLACEHOLDER:100,HIDE_PLACEHOLDER:1e3,DESELECTDIM:.2}},50606:function(o){o.exports={BADNUM:void 0,FP_SAFE:1e-4*Number.MAX_VALUE,ONEMAXYEAR:316224e5,ONEAVGYEAR:315576e5,ONEMINYEAR:31536e6,ONEMAXQUARTER:79488e5,ONEAVGQUARTER:78894e5,ONEMINQUARTER:76896e5,ONEMAXMONTH:26784e5,ONEAVGMONTH:26298e5,ONEMINMONTH:24192e5,ONEWEEK:6048e5,ONEDAY:864e5,ONEHOUR:36e5,ONEMIN:6e4,ONESEC:1e3,EPOCHJD:24405875e-1,ALMOST_EQUAL:.999999,LOG_CLIP:10,MINUS_SIGN:"−"}},32396:function(o,a){a.CSS_DECLARATIONS=[["image-rendering","optimizeSpeed"],["image-rendering","-moz-crisp-edges"],["image-rendering","-o-crisp-edges"],["image-rendering","-webkit-optimize-contrast"],["image-rendering","optimize-contrast"],["image-rendering","crisp-edges"],["image-rendering","pixelated"]],a.STYLE=a.CSS_DECLARATIONS.map(function(n){return n.join(": ")+"; "}).join("")},77922:function(o,a){a.xmlns="http://www.w3.org/2000/xmlns/",a.svg="http://www.w3.org/2000/svg",a.xlink="http://www.w3.org/1999/xlink",a.svgAttrs={xmlns:a.svg,"xmlns:xlink":a.xlink}},8729:function(o,a,n){a.version=n(11506).version,n(7417),n(98847);for(var l=n(73972),f=a.register=l.register,s=n(10641),u=Object.keys(s),d=0;d",""," ",""," plotly-logomark"," "," "," "," "," "," "," "," "," "," "," "," "," ",""].join("")}}},99863:function(o,a){a.isLeftAnchor=function(n){return n.xanchor==="left"||n.xanchor==="auto"&&n.x<=.3333333333333333},a.isCenterAnchor=function(n){return n.xanchor==="center"||n.xanchor==="auto"&&n.x>.3333333333333333&&n.x<.6666666666666666},a.isRightAnchor=function(n){return n.xanchor==="right"||n.xanchor==="auto"&&n.x>=.6666666666666666},a.isTopAnchor=function(n){return n.yanchor==="top"||n.yanchor==="auto"&&n.y>=.6666666666666666},a.isMiddleAnchor=function(n){return n.yanchor==="middle"||n.yanchor==="auto"&&n.y>.3333333333333333&&n.y<.6666666666666666},a.isBottomAnchor=function(n){return n.yanchor==="bottom"||n.yanchor==="auto"&&n.y<=.3333333333333333}},26348:function(o,a,n){var l=n(64872),f=l.mod,s=l.modHalf,u=Math.PI,d=2*u;function h(v){return Math.abs(v[1]-v[0])>d-1e-14}function p(v,m){return s(m-v,d)}function g(v,m){if(h(m))return!0;var b,x;m[0](x=f(x,d))&&(x+=d);var _=f(v,d),w=_+d;return _>=b&&_<=x||w>=b&&w<=x}function y(v,m,b,x,_,w,k){_=_||0,w=w||0;var T,M,S,C,P,D=h([b,x]);function O(z,B){return[z*Math.cos(B)+_,w-z*Math.sin(B)]}D?(T=0,M=u,S=d):b=_&&v<=w);var _,w},pathArc:function(v,m,b,x,_){return y(null,v,m,b,x,_,0)},pathSector:function(v,m,b,x,_){return y(null,v,m,b,x,_,1)},pathAnnulus:function(v,m,b,x,_,w){return y(v,m,b,x,_,w,1)}}},73627:function(o,a){var n=Array.isArray,l=ArrayBuffer,f=DataView;function s(h){return l.isView(h)&&!(h instanceof f)}function u(h){return n(h)||s(h)}function d(h,p,g){if(u(h)){if(u(h[0])){for(var y=g,v=0;vw.max?x.set(_):x.set(+b)}},integer:{coerceFunction:function(b,x,_,w){b%1||!l(b)||w.min!==void 0&&bw.max?x.set(_):x.set(+b)}},string:{coerceFunction:function(b,x,_,w){if(typeof b!="string"){var k=typeof b=="number";w.strict!==!0&&k?x.set(String(b)):x.set(_)}else w.noBlank&&!b?x.set(_):x.set(b)}},color:{coerceFunction:function(b,x,_){f(b).isValid()?x.set(b):x.set(_)}},colorlist:{coerceFunction:function(b,x,_){Array.isArray(b)&&b.length&&b.every(function(w){return f(w).isValid()})?x.set(b):x.set(_)}},colorscale:{coerceFunction:function(b,x,_){x.set(u.get(b,_))}},angle:{coerceFunction:function(b,x,_){b==="auto"?x.set("auto"):l(b)?x.set(y(+b,360)):x.set(_)}},subplotid:{coerceFunction:function(b,x,_,w){var k=w.regex||g(_);typeof b=="string"&&k.test(b)?x.set(b):x.set(_)},validateFunction:function(b,x){var _=x.dflt;return b===_||typeof b=="string"&&!!g(_).test(b)}},flaglist:{coerceFunction:function(b,x,_,w){if((w.extras||[]).indexOf(b)===-1)if(typeof b=="string"){for(var k=b.split("+"),T=0;T=l&&N<=f?N:g}if(typeof N!="string"&&typeof N!="number")return g;N=String(N);var q=S(E),H=N.charAt(0);!q||H!=="G"&&H!=="g"||(N=N.substr(1),E="");var V=q&&E.substr(0,7)==="chinese",te=N.match(V?T:k);if(!te)return g;var ee=te[1],U=te[3]||"1",Q=Number(te[5]||1),Y=Number(te[7]||0),Z=Number(te[9]||0),X=Number(te[11]||0);if(q){if(ee.length===2)return g;var re;ee=Number(ee);try{var ie=_.getComponentMethod("calendars","getCal")(E);if(V){var le=U.charAt(U.length-1)==="i";U=parseInt(U,10),re=ie.newDate(ee,ie.toMonthIndex(ee,U,le),Q)}else re=ie.newDate(ee,Number(U),Q)}catch{return g}return re?(re.toJD()-x)*y+Y*v+Z*m+X*b:g}ee=ee.length===2?(Number(ee)+2e3-M)%100+M:Number(ee),U-=1;var se=new Date(Date.UTC(2e3,U,Q,Y,Z));return se.setUTCFullYear(ee),se.getUTCMonth()!==U||se.getUTCDate()!==Q?g:se.getTime()+X*b},l=a.MIN_MS=a.dateTime2ms("-9999"),f=a.MAX_MS=a.dateTime2ms("9999-12-31 23:59:59.9999"),a.isDateTime=function(N,E){return a.dateTime2ms(N,E)!==g};var P=90*y,D=3*v,O=5*m;function R(N,E,W,G,L){if((E||W||G||L)&&(N+=" "+C(E,2)+":"+C(W,2),(G||L)&&(N+=":"+C(G,2),L))){for(var q=4;L%10==0;)q-=1,L/=10;N+="."+C(L,q)}return N}a.ms2DateTime=function(N,E,W){if(typeof N!="number"||!(N>=l&&N<=f))return g;E||(E=0);var G,L,q,H,V,te,ee=Math.floor(10*h(N+.05,1)),U=Math.round(N-ee/10);if(S(W)){var Q=Math.floor(U/y)+x,Y=Math.floor(h(N,y));try{G=_.getComponentMethod("calendars","getCal")(W).fromJD(Q).formatDate("yyyy-mm-dd")}catch{G=w("G%Y-%m-%d")(new Date(U))}if(G.charAt(0)==="-")for(;G.length<11;)G="-0"+G.substr(1);else for(;G.length<10;)G="0"+G;L=E=l+y&&N<=f-y))return g;var E=Math.floor(10*h(N+.05,1)),W=new Date(Math.round(N-E/10));return R(s("%Y-%m-%d")(W),W.getHours(),W.getMinutes(),W.getSeconds(),10*W.getUTCMilliseconds()+E)},a.cleanDate=function(N,E,W){if(N===g)return E;if(a.isJSDate(N)||typeof N=="number"&&isFinite(N)){if(S(W))return d.error("JS Dates and milliseconds are incompatible with world calendars",N),E;if(!(N=a.ms2DateTimeLocal(+N))&&E!==void 0)return E}else if(!a.isDateTime(N,W))return d.error("unrecognized date",N),E;return N};var F=/%\d?f/g,A=/%h/g,z={1:"1",2:"1",3:"2",4:"2"};function B(N,E,W,G){N=N.replace(F,function(q){var H=Math.min(+q.charAt(1)||6,6);return(E/1e3%1+2).toFixed(H).substr(2).replace(/0+$/,"")||"0"});var L=new Date(Math.floor(E+.05));if(N=N.replace(A,function(){return z[W("%q")(L)]}),S(G))try{N=_.getComponentMethod("calendars","worldCalFmt")(N,E,G)}catch{return"Invalid"}return W(N)(L)}var $=[59,59.9,59.99,59.999,59.9999];a.formatDate=function(N,E,W,G,L,q){if(L=S(L)&&L,!E)if(W==="y")E=q.year;else if(W==="m")E=q.month;else{if(W!=="d")return function(H,V){var te=h(H+.05,y),ee=C(Math.floor(te/v),2)+":"+C(h(Math.floor(te/m),60),2);if(V!=="M"){u(V)||(V=0);var U=(100+Math.min(h(H/b,60),$[V])).toFixed(V).substr(1);V>0&&(U=U.replace(/0+$/,"").replace(/[\.]$/,"")),ee+=":"+U}return ee}(N,W)+`
-`+B(q.dayMonthYear,N,G,L);E=q.dayMonth+`
-`+q.year}return B(E,N,G,L)};var j=3*y;a.incrementMonth=function(N,E,W){W=S(W)&&W;var G=h(N,y);if(N=Math.round(N-G),W)try{var L=Math.round(N/y)+x,q=_.getComponentMethod("calendars","getCal")(W),H=q.fromJD(L);return E%12?q.add(H,E,"m"):q.add(H,E/12,"y"),(H.toJD()-x)*y+G}catch{d.error("invalid ms "+N+" in calendar "+W)}var V=new Date(N+j);return V.setUTCMonth(V.getUTCMonth()+E)+G-j},a.findExactDates=function(N,E){for(var W,G,L=0,q=0,H=0,V=0,te=S(E)&&_.getComponentMethod("calendars","getCal")(E),ee=0;ee1||D<0||D>1?null:{x:p+w*D,y:g+M*D}}function h(p,g,y,v,m){var b=v*p+m*g;if(b<0)return v*v+m*m;if(b>y){var x=v-p,_=m-g;return x*x+_*_}var w=v*g-m*p;return w*w/y}a.segmentsIntersect=d,a.segmentDistance=function(p,g,y,v,m,b,x,_){if(d(p,g,y,v,m,b,x,_))return 0;var w=y-p,k=v-g,T=x-m,M=_-b,S=w*w+k*k,C=T*T+M*M,P=Math.min(h(w,k,S,m-p,b-g),h(w,k,S,x-p,_-g),h(T,M,C,p-m,g-b),h(T,M,C,y-m,v-b));return Math.sqrt(P)},a.getTextLocation=function(p,g,y,v){if(p===f&&v===s||(l={},f=p,s=v),l[y])return l[y];var m=p.getPointAtLength(u(y-v/2,g)),b=p.getPointAtLength(u(y+v/2,g)),x=Math.atan((b.y-m.y)/(b.x-m.x)),_=p.getPointAtLength(u(y,g)),w={x:(4*_.x+m.x+b.x)/6,y:(4*_.y+m.y+b.y)/6,theta:x};return l[y]=w,w},a.clearLocationCache=function(){f=null},a.getVisibleSegment=function(p,g,y){var v,m,b=g.left,x=g.right,_=g.top,w=g.bottom,k=0,T=p.getTotalLength(),M=T;function S(P){var D=p.getPointAtLength(P);P===0?v=D:P===T&&(m=D);var O=D.xx?D.x-x:0,R=D.y<_?_-D.y:D.y>w?D.y-w:0;return Math.sqrt(O*O+R*R)}for(var C=S(k);C;){if((k+=C+y)>M)return;C=S(k)}for(C=S(M);C;){if(k>(M-=C+y))return;C=S(M)}return{min:k,max:M,len:M-k,total:T,isClosed:k===0&&M===T&&Math.abs(v.x-m.x)<.1&&Math.abs(v.y-m.y)<.1}},a.findPointOnPath=function(p,g,y,v){for(var m,b,x,_=(v=v||{}).pathLength||p.getTotalLength(),w=v.tolerance||.001,k=v.iterationLimit||30,T=p.getPointAtLength(0)[y]>p.getPointAtLength(_)[y]?-1:1,M=0,S=0,C=_;M0?C=m:S=m,M++}return b}},23389:function(o){o.exports=function(a){return a}},39240:function(o){o.exports=function(a,n){if(!n)return a;var l=1/Math.abs(n),f=l>1?(l*a+l*n)/l:a+n,s=String(f).length;if(s>16){var u=String(n).length;if(s>=String(a).length+u){var d=parseFloat(f).toPrecision(12);d.indexOf("e+")===-1&&(f=+d)}}return f}},71828:function(o,a,n){var l=n(39898),f=n(84096).g0,s=n(60721).WU,u=n(92770),d=n(50606),h=d.FP_SAFE,p=-h,g=d.BADNUM,y=o.exports={};y.adjustFormat=function(Y){return!Y||/^\d[.]\df/.test(Y)||/[.]\d%/.test(Y)?Y:Y==="0.f"?"~f":/^\d%/.test(Y)?"~%":/^\ds/.test(Y)?"~s":!/^[~,.0$]/.test(Y)&&/[&fps]/.test(Y)?"~"+Y:Y};var v={};y.warnBadFormat=function(Y){var Z=String(Y);v[Z]||(v[Z]=1,y.warn('encountered bad format: "'+Z+'"'))},y.noFormat=function(Y){return String(Y)},y.numberFormat=function(Y){var Z;try{Z=s(y.adjustFormat(Y))}catch{return y.warnBadFormat(Y),y.noFormat}return Z},y.nestedProperty=n(65487),y.keyedContainer=n(66636),y.relativeAttr=n(6962),y.isPlainObject=n(41965),y.toLogRange=n(58163),y.relinkPrivateKeys=n(51332);var m=n(73627);y.isTypedArray=m.isTypedArray,y.isArrayOrTypedArray=m.isArrayOrTypedArray,y.isArray1D=m.isArray1D,y.ensureArray=m.ensureArray,y.concat=m.concat,y.maxRowLength=m.maxRowLength,y.minRowLength=m.minRowLength;var b=n(64872);y.mod=b.mod,y.modHalf=b.modHalf;var x=n(96554);y.valObjectMeta=x.valObjectMeta,y.coerce=x.coerce,y.coerce2=x.coerce2,y.coerceFont=x.coerceFont,y.coercePattern=x.coercePattern,y.coerceHoverinfo=x.coerceHoverinfo,y.coerceSelectionMarkerOpacity=x.coerceSelectionMarkerOpacity,y.validate=x.validate;var _=n(41631);y.dateTime2ms=_.dateTime2ms,y.isDateTime=_.isDateTime,y.ms2DateTime=_.ms2DateTime,y.ms2DateTimeLocal=_.ms2DateTimeLocal,y.cleanDate=_.cleanDate,y.isJSDate=_.isJSDate,y.formatDate=_.formatDate,y.incrementMonth=_.incrementMonth,y.dateTick0=_.dateTick0,y.dfltRange=_.dfltRange,y.findExactDates=_.findExactDates,y.MIN_MS=_.MIN_MS,y.MAX_MS=_.MAX_MS;var w=n(65888);y.findBin=w.findBin,y.sorterAsc=w.sorterAsc,y.sorterDes=w.sorterDes,y.distinctVals=w.distinctVals,y.roundUp=w.roundUp,y.sort=w.sort,y.findIndexOfMin=w.findIndexOfMin,y.sortObjectKeys=n(78607);var k=n(80038);y.aggNums=k.aggNums,y.len=k.len,y.mean=k.mean,y.median=k.median,y.midRange=k.midRange,y.variance=k.variance,y.stdev=k.stdev,y.interp=k.interp;var T=n(35657);y.init2dArray=T.init2dArray,y.transposeRagged=T.transposeRagged,y.dot=T.dot,y.translationMatrix=T.translationMatrix,y.rotationMatrix=T.rotationMatrix,y.rotationXYMatrix=T.rotationXYMatrix,y.apply3DTransform=T.apply3DTransform,y.apply2DTransform=T.apply2DTransform,y.apply2DTransform2=T.apply2DTransform2,y.convertCssMatrix=T.convertCssMatrix,y.inverseTransformMatrix=T.inverseTransformMatrix;var M=n(26348);y.deg2rad=M.deg2rad,y.rad2deg=M.rad2deg,y.angleDelta=M.angleDelta,y.angleDist=M.angleDist,y.isFullCircle=M.isFullCircle,y.isAngleInsideSector=M.isAngleInsideSector,y.isPtInsideSector=M.isPtInsideSector,y.pathArc=M.pathArc,y.pathSector=M.pathSector,y.pathAnnulus=M.pathAnnulus;var S=n(99863);y.isLeftAnchor=S.isLeftAnchor,y.isCenterAnchor=S.isCenterAnchor,y.isRightAnchor=S.isRightAnchor,y.isTopAnchor=S.isTopAnchor,y.isMiddleAnchor=S.isMiddleAnchor,y.isBottomAnchor=S.isBottomAnchor;var C=n(87642);y.segmentsIntersect=C.segmentsIntersect,y.segmentDistance=C.segmentDistance,y.getTextLocation=C.getTextLocation,y.clearLocationCache=C.clearLocationCache,y.getVisibleSegment=C.getVisibleSegment,y.findPointOnPath=C.findPointOnPath;var P=n(1426);y.extendFlat=P.extendFlat,y.extendDeep=P.extendDeep,y.extendDeepAll=P.extendDeepAll,y.extendDeepNoArrays=P.extendDeepNoArrays;var D=n(47769);y.log=D.log,y.warn=D.warn,y.error=D.error;var O=n(30587);y.counterRegex=O.counter;var R=n(79990);y.throttle=R.throttle,y.throttleDone=R.done,y.clearThrottle=R.clear;var F=n(24401);function A(Y){var Z={};for(var X in Y)for(var re=Y[X],ie=0;ieh||Y=Z)&&u(Y)&&Y>=0&&Y%1==0},y.noop=n(64213),y.identity=n(23389),y.repeat=function(Y,Z){for(var X=new Array(Z),re=0;reX?Math.max(X,Math.min(Z,Y)):Math.max(Z,Math.min(X,Y))},y.bBoxIntersect=function(Y,Z,X){return X=X||0,Y.left<=Z.right+X&&Z.left<=Y.right+X&&Y.top<=Z.bottom+X&&Z.top<=Y.bottom+X},y.simpleMap=function(Y,Z,X,re,ie){for(var le=Y.length,se=new Array(le),pe=0;pe=Math.pow(2,X)?ie>10?(y.warn("randstr failed uniqueness"),Te):Y(Z,X,re,(ie||0)+1):Te},y.OptionControl=function(Y,Z){Y||(Y={}),Z||(Z="opt");var X={optionList:[],_newoption:function(re){re[Z]=Y,X[re.name]=re,X.optionList.push(re)}};return X["_"+Z]=Y,X},y.smooth=function(Y,Z){if((Z=Math.round(Z)||0)<2)return Y;var X,re,ie,le,se=Y.length,pe=2*se,Te=2*Z-1,Se=new Array(Te),Oe=new Array(se);for(X=0;X=pe&&(ie-=pe*Math.floor(ie/pe)),ie<0?ie=-1-ie:ie>=se&&(ie=pe-1-ie),le+=Y[ie]*Se[re];Oe[X]=le}return Oe},y.syncOrAsync=function(Y,Z,X){var re;function ie(){return y.syncOrAsync(Y,Z,X)}for(;Y.length;)if((re=(0,Y.splice(0,1)[0])(Z))&&re.then)return re.then(ie);return X&&X(Z)},y.stripTrailingSlash=function(Y){return Y.substr(-1)==="/"?Y.substr(0,Y.length-1):Y},y.noneOrAll=function(Y,Z,X){if(Y){var re,ie=!1,le=!0;for(re=0;re0?ie:0})},y.fillArray=function(Y,Z,X,re){if(re=re||y.identity,y.isArrayOrTypedArray(Y))for(var ie=0;ie1?ie+se[1]:"";if(le&&(se.length>1||pe.length>4||X))for(;re.test(pe);)pe=pe.replace(re,"$1"+le+"$2");return pe+Te},y.TEMPLATE_STRING_REGEX=/%{([^\s%{}:]*)([:|\|][^}]*)?}/g;var W=/^\w*$/;y.templateString=function(Y,Z){var X={};return Y.replace(y.TEMPLATE_STRING_REGEX,function(re,ie){var le;return W.test(ie)?le=Z[ie]:(X[ie]=X[ie]||y.nestedProperty(Z,ie).get,le=X[ie]()),y.isValidTextValue(le)?le:""})};var G={max:10,count:0,name:"hovertemplate"};y.hovertemplateString=function(){return te.apply(G,arguments)};var L={max:10,count:0,name:"texttemplate"};y.texttemplateString=function(){return te.apply(L,arguments)};var q=/^(\S+)([\*\/])(-?\d+(\.\d+)?)$/,H={max:10,count:0,name:"texttemplate",parseMultDiv:!0};y.texttemplateStringForShapes=function(){return te.apply(H,arguments)};var V=/^[:|\|]/;function te(Y,Z,X){var re=this,ie=arguments;Z||(Z={});var le={};return Y.replace(y.TEMPLATE_STRING_REGEX,function(se,pe,Te){var Se=pe==="_xother"||pe==="_yother",Oe=pe==="_xother_"||pe==="_yother_",Me=pe==="xother_"||pe==="yother_",ce=pe==="xother"||pe==="yother"||Se||Me||Oe,ye=pe;(Se||Oe)&&(ye=ye.substring(1)),(Me||Oe)&&(ye=ye.substring(0,ye.length-1));var J,ne,de,xe=null,ue=null;if(re.parseMultDiv){var ge=function(Ae){var Ee=Ae.match(q);return Ee?{key:Ee[1],op:Ee[2],number:Number(Ee[3])}:{key:Ae,op:null,number:null}}(ye);ye=ge.key,xe=ge.op,ue=ge.number}if(ce){if((J=Z[ye])===void 0)return""}else for(de=3;de=48&&se<=57,Se=pe>=48&&pe<=57;if(Te&&(re=10*re+se-48),Se&&(ie=10*ie+pe-48),!Te||!Se){if(re!==ie)return re-ie;if(se!==pe)return se-pe}}return ie-re};var ee=2e9;y.seedPseudoRandom=function(){ee=2e9},y.pseudoRandom=function(){var Y=ee;return ee=(69069*ee+1)%4294967296,Math.abs(ee-Y)<429496729?y.pseudoRandom():ee/4294967296},y.fillText=function(Y,Z,X){var re=Array.isArray(X)?function(se){X.push(se)}:function(se){X.text=se},ie=y.extractOption(Y,Z,"htx","hovertext");if(y.isValidTextValue(ie))return re(ie);var le=y.extractOption(Y,Z,"tx","text");return y.isValidTextValue(le)?re(le):void 0},y.isValidTextValue=function(Y){return Y||Y===0},y.formatPercent=function(Y,Z){Z=Z||0;for(var X=(Math.round(100*Y*Math.pow(10,Z))*Math.pow(.1,Z)).toFixed(Z)+"%",re=0;re1&&(Se=1):Se=0,y.strTranslate(ie-Se*(X+se),le-Se*(re+pe))+y.strScale(Se)+(Te?"rotate("+Te+(Z?"":" "+X+" "+re)+")":"")},y.setTransormAndDisplay=function(Y,Z){Y.attr("transform",y.getTextTransform(Z)),Y.style("display",Z.scale?null:"none")},y.ensureUniformFontSize=function(Y,Z){var X=y.extendFlat({},Z);return X.size=Math.max(Z.size,Y._fullLayout.uniformtext.minsize||0),X},y.join2=function(Y,Z,X){var re=Y.length;return re>1?Y.slice(0,-1).join(Z)+X+Y[re-1]:Y.join(Z)},y.bigFont=function(Y){return Math.round(1.2*Y)};var U=y.getFirefoxVersion(),Q=U!==null&&U<86;y.getPositionFromD3Event=function(){return Q?[l.event.layerX,l.event.layerY]:[l.event.offsetX,l.event.offsetY]}},41965:function(o){o.exports=function(a){return window&&window.process&&window.process.versions?Object.prototype.toString.call(a)==="[object Object]":Object.prototype.toString.call(a)==="[object Object]"&&Object.getPrototypeOf(a).hasOwnProperty("hasOwnProperty")}},66636:function(o,a,n){var l=n(65487),f=/^\w*$/;o.exports=function(s,u,d,h){var p,g,y;d=d||"name",h=h||"value";var v={};u&&u.length?(y=l(s,u),g=y.get()):g=s,u=u||"";var m={};if(g)for(p=0;p2)return v[w]=2|v[w],x.set(_,null);if(b){for(p=w;p1){var d=["LOG:"];for(u=0;u1){var h=[];for(u=0;u"),"long")}},s.warn=function(){var u;if(l.logging>0){var d=["WARN:"];for(u=0;u0){var h=[];for(u=0;u"),"stick")}},s.error=function(){var u;if(l.logging>0){var d=["ERROR:"];for(u=0;u0){var h=[];for(u=0;u"),"stick")}}},77310:function(o,a,n){var l=n(39898);o.exports=function(f,s,u){var d=f.selectAll("g."+u.replace(/\s/g,".")).data(s,function(p){return p[0].trace.uid});d.exit().remove(),d.enter().append("g").attr("class",u),d.order();var h=f.classed("rangeplot")?"nodeRangePlot3":"node3";return d.each(function(p){p[0][h]=l.select(this)}),d}},35657:function(o,a,n){var l=n(79576);a.init2dArray=function(f,s){for(var u=new Array(f),d=0;dn/2?a-Math.round(a/n)*n:a}}},65487:function(o,a,n){var l=n(92770),f=n(73627).isArrayOrTypedArray;function s(v,m){return function(){var b,x,_,w,k,T=v;for(w=0;w/g),x=0;xg||M===f||Mv||k&&m(w))}:function(w,k){var T=w[0],M=w[1];if(T===f||Tg||M===f||Mv)return!1;var S,C,P,D,O,R=h.length,F=h[0][0],A=h[0][1],z=0;for(S=1;SMath.max(C,F)||M>Math.max(P,A)))if(Mx||Math.abs(l(y,w))>p)return!0;return!1},s.filter=function(u,d){var h=[u[0]],p=0,g=0;function y(v){u.push(v);var m=h.length,b=p;h.splice(g+1);for(var x=b+1;x1&&y(u.pop()),{addPt:y,raw:u,filtered:h}}},45142:function(o,a,n){var l=n(92770),f=n(35791);o.exports=function(s){var u;if(typeof(u=s&&s.hasOwnProperty("userAgent")?s.userAgent:function(){var m;return typeof navigator<"u"&&(m=navigator.userAgent),m&&m.headers&&typeof m.headers["user-agent"]=="string"&&(m=m.headers["user-agent"]),m}())!="string")return!0;var d=f({ua:{headers:{"user-agent":u}},tablet:!0,featureDetect:!1});if(!d){for(var h=u.split(" "),p=1;p-1;g--){var y=h[g];if(y.substr(0,8)==="Version/"){var v=y.substr(8).split(".")[0];if(l(v)&&(v=+v),v>=13)return!0}}}return d}},75138:function(o){o.exports=function(a,n){if(n instanceof RegExp){for(var l=n.toString(),f=0;ff.queueLength&&(u.undoQueue.queue.shift(),u.undoQueue.index--))},startSequence:function(u){u.undoQueue=u.undoQueue||{index:0,queue:[],sequence:!1},u.undoQueue.sequence=!0,u.undoQueue.beginSequence=!0},stopSequence:function(u){u.undoQueue=u.undoQueue||{index:0,queue:[],sequence:!1},u.undoQueue.sequence=!1,u.undoQueue.beginSequence=!1},undo:function(u){var d,h;if(!(u.undoQueue===void 0||isNaN(u.undoQueue.index)||u.undoQueue.index<=0)){for(u.undoQueue.index--,d=u.undoQueue.queue[u.undoQueue.index],u.undoQueue.inSequence=!0,h=0;h=u.undoQueue.queue.length)){for(d=u.undoQueue.queue[u.undoQueue.index],u.undoQueue.inSequence=!0,h=0;hm}function y(v,m){return v>=m}a.findBin=function(v,m,b){if(l(m.start))return b?Math.ceil((v-m.start)/m.size-d)-1:Math.floor((v-m.start)/m.size+d);var x,_,w=0,k=m.length,T=0,M=k>1?(m[k-1]-m[0])/(k-1):1;for(_=M>=0?b?h:p:b?y:g,v+=M*d*(b?-1:1)*(M>=0?1:-1);w90&&f.log("Long binary search..."),w-1},a.sorterAsc=function(v,m){return v-m},a.sorterDes=function(v,m){return m-v},a.distinctVals=function(v){var m,b=v.slice();for(b.sort(a.sorterAsc),m=b.length-1;m>-1&&b[m]===u;m--);for(var x,_=b[m]-b[0]||1,w=_/(m||1)/1e4,k=[],T=0;T<=m;T++){var M=b[T],S=M-x;x===void 0?(k.push(M),x=M):S>w&&(_=Math.min(_,S),k.push(M),x=M)}return{vals:k,minDiff:_}},a.roundUp=function(v,m,b){for(var x,_=0,w=m.length-1,k=0,T=b?0:1,M=b?1:0,S=b?Math.ceil:Math.floor;_0&&(x=1),b&&x)return v.sort(m)}return x?v:v.reverse()},a.findIndexOfMin=function(v,m){m=m||s;for(var b,x=1/0,_=0;_d.length)&&(h=d.length),l(u)||(u=!1),f(d[0])){for(g=new Array(h),p=0;ps.length-1)return s[s.length-1];var d=u%1;return d*s[Math.ceil(u)]+(1-d)*s[Math.floor(u)]}},3883:function(o,a,n){var l=n(32396),f=n(91424),s=n(71828),u=null;o.exports=function(){if(u!==null)return u;u=!1;var d=s.isIE()||s.isSafari()||s.isIOS();if(window.navigator.userAgent&&!d){var h=Array.from(l.CSS_DECLARATIONS).reverse(),p=window.CSS&&window.CSS.supports||window.supportsCSS;if(typeof p=="function")u=h.some(function(v){return p.apply(null,v)});else{var g=f.tester.append("image").attr("style",l.STYLE),y=window.getComputedStyle(g.node()).imageRendering;u=h.some(function(v){var m=v[1];return y===m||y===m.toLowerCase()}),g.remove()}}return u}},63893:function(o,a,n){var l=n(39898),f=n(71828),s=f.strTranslate,u=n(77922),d=n(18783).LINE_SPACING,h=/([^$]*)([$]+[^$]*[$]+)([^$]*)/;a.convertToTspans=function(N,E,W){var G=N.text(),L=!N.attr("data-notex")&&E&&E._context.typesetMath&&typeof MathJax<"u"&&G.match(h),q=l.select(N.node().parentNode);if(!q.empty()){var H=N.attr("class")?N.attr("class").split(" ")[0]:"text";return H+="-math",q.selectAll("svg."+H).remove(),q.selectAll("g."+H+"-group").remove(),N.style("display",null).attr({"data-unformatted":G,"data-math":"N"}),L?(E&&E._promises||[]).push(new Promise(function(te){N.style("display","none");var ee=parseInt(N.node().style.fontSize,10),U={fontSize:ee};(function(Q,Y,Z){var X,re,ie,le,se=parseInt((MathJax.version||"").split(".")[0]);if(se===2||se===3){var pe=function(){var Se="math-output-"+f.randstr({},64),Oe=(le=l.select("body").append("div").attr({id:Se}).style({visibility:"hidden",position:"absolute","font-size":Y.fontSize+"px"}).text(Q.replace(p,"\\lt ").replace(g,"\\gt "))).node();return se===2?MathJax.Hub.Typeset(Oe):MathJax.typeset([Oe])},Te=function(){var Se=le.select(se===2?".MathJax_SVG":".MathJax"),Oe=!Se.empty()&&le.select("svg").node();if(Oe){var Me,ce=Oe.getBoundingClientRect();Me=se===2?l.select("body").select("#MathJax_SVG_glyphs"):Se.select("defs"),Z(Se,Me,ce)}else f.log("There was an error in the tex syntax.",Q),Z();le.remove()};se===2?MathJax.Hub.Queue(function(){return re=f.extendDeepAll({},MathJax.Hub.config),ie=MathJax.Hub.processSectionDelay,MathJax.Hub.processSectionDelay!==void 0&&(MathJax.Hub.processSectionDelay=0),MathJax.Hub.Config({messageStyle:"none",tex2jax:{inlineMath:y},displayAlign:"left"})},function(){if((X=MathJax.Hub.config.menuSettings.renderer)!=="SVG")return MathJax.Hub.setRenderer("SVG")},pe,Te,function(){if(X!=="SVG")return MathJax.Hub.setRenderer(X)},function(){return ie!==void 0&&(MathJax.Hub.processSectionDelay=ie),MathJax.Hub.Config(re)}):se===3&&(re=f.extendDeepAll({},MathJax.config),MathJax.config.tex||(MathJax.config.tex={}),MathJax.config.tex.inlineMath=y,(X=MathJax.config.startup.output)!=="svg"&&(MathJax.config.startup.output="svg"),MathJax.startup.defaultReady(),MathJax.startup.promise.then(function(){pe(),Te(),X!=="svg"&&(MathJax.config.startup.output=X),MathJax.config=re}))}else f.warn("No MathJax version:",MathJax.version)})(L[2],U,function(Q,Y,Z){q.selectAll("svg."+H).remove(),q.selectAll("g."+H+"-group").remove();var X=Q&&Q.select("svg");if(!X||!X.node())return V(),void te();var re=q.append("g").classed(H+"-group",!0).attr({"pointer-events":"none","data-unformatted":G,"data-math":"Y"});re.node().appendChild(X.node()),Y&&Y.node()&&X.node().insertBefore(Y.node().cloneNode(!0),X.node().firstChild);var ie=Z.width,le=Z.height;X.attr({class:H,height:le,preserveAspectRatio:"xMinYMin meet"}).style({overflow:"visible","pointer-events":"none"});var se=N.node().style.fill||"black",pe=X.select("g");pe.attr({fill:se,stroke:se});var Te=pe.node().getBoundingClientRect(),Se=Te.width,Oe=Te.height;(Se>ie||Oe>le)&&(X.style("overflow","hidden"),Se=(Te=X.node().getBoundingClientRect()).width,Oe=Te.height);var Me=+N.attr("x"),ce=+N.attr("y"),ye=-(ee||N.node().getBoundingClientRect().height)/4;if(H[0]==="y")re.attr({transform:"rotate("+[-90,Me,ce]+")"+s(-Se/2,ye-Oe/2)});else if(H[0]==="l")ce=ye-Oe/2;else if(H[0]==="a"&&H.indexOf("atitle")!==0)Me=0,ce=ye;else{var J=N.attr("text-anchor");Me-=Se*(J==="middle"?.5:J==="end"?1:0),ce=ce+ye-Oe/2}X.attr({x:Me,y:ce}),W&&W.call(N,re),te(re)})})):V(),N}function V(){q.empty()||(H=N.attr("class")+"-math",q.select("svg."+H).remove()),N.text("").style("white-space","pre");var te=function(ee,U){U=U.replace(w," ");var Q,Y=!1,Z=[],X=-1;function re(){X++;var ue=document.createElementNS(u.svg,"tspan");l.select(ue).attr({class:"line",dy:X*d+"em"}),ee.appendChild(ue),Q=ue;var ge=Z;if(Z=[{node:ue}],ge.length>1)for(var be=1;be doesnt match end tag <"+ue+">. Pretending it did match.",U),Q=Z[Z.length-1].node}else f.log("Ignoring unexpected end tag "+ue+">.",U)}M.test(U)?re():(Q=ee,Z=[{node:ee}]);for(var pe=U.split(k),Te=0;Te|>|>)/g,y=[["$","$"],["\\(","\\)"]],v={sup:"font-size:70%",sub:"font-size:70%",b:"font-weight:bold",i:"font-style:italic",a:"cursor:pointer",span:"",em:"font-style:italic;font-weight:bold"},m={sub:"0.3em",sup:"-0.6em"},b={sub:"-0.21em",sup:"0.42em"},x="",_=["http:","https:","mailto:","",void 0,":"],w=a.NEWLINES=/(\r\n?|\n)/g,k=/(<[^<>]*>)/,T=/<(\/?)([^ >]*)(\s+(.*))?>/i,M=/
/i;a.BR_TAG_ALL=/
/gi;var S=/(^|[\s"'])style\s*=\s*("([^"]*);?"|'([^']*);?')/i,C=/(^|[\s"'])href\s*=\s*("([^"]*)"|'([^']*)')/i,P=/(^|[\s"'])target\s*=\s*("([^"\s]*)"|'([^'\s]*)')/i,D=/(^|[\s"'])popup\s*=\s*("([\w=,]*)"|'([\w=,]*)')/i;function O(N,E){if(!N)return null;var W=N.match(E),G=W&&(W[3]||W[4]);return G&&z(G)}var R=/(^|;)\s*color:/;a.plainText=function(N,E){for(var W=(E=E||{}).len!==void 0&&E.len!==-1?E.len:1/0,G=E.allowedTags!==void 0?E.allowedTags:["br"],L=N.split(k),q=[],H="",V=0,te=0;te3?q.push(ee.substr(0,Z-3)+"..."):q.push(ee.substr(0,Z));break}H=""}}return q.join("")};var F={mu:"μ",amp:"&",lt:"<",gt:">",nbsp:" ",times:"×",plusmn:"±",deg:"°"},A=/&(#\d+|#x[\da-fA-F]+|[a-z]+);/g;function z(N){return N.replace(A,function(E,W){return(W.charAt(0)==="#"?function(G){if(!(G>1114111)){var L=String.fromCodePoint;if(L)return L(G);var q=String.fromCharCode;return G<=65535?q(G):q(55232+(G>>10),G%1024+56320)}}(W.charAt(1)==="x"?parseInt(W.substr(2),16):parseInt(W.substr(1),10)):F[W])||E})}function B(N){var E=encodeURI(decodeURI(N)),W=document.createElement("a"),G=document.createElement("a");W.href=N,G.href=E;var L=W.protocol,q=G.protocol;return _.indexOf(L)!==-1&&_.indexOf(q)!==-1?E:""}function $(N,E,W){var G,L,q,H=W.horizontalAlign,V=W.verticalAlign||"top",te=N.node().getBoundingClientRect(),ee=E.node().getBoundingClientRect();return L=V==="bottom"?function(){return te.bottom-G.height}:V==="middle"?function(){return te.top+(te.height-G.height)/2}:function(){return te.top},q=H==="right"?function(){return te.right-G.width}:H==="center"?function(){return te.left+(te.width-G.width)/2}:function(){return te.left},function(){G=this.node().getBoundingClientRect();var U=q()-ee.left,Q=L()-ee.top,Y=W.gd||{};if(W.gd){Y._fullLayout._calcInverseTransform(Y);var Z=f.apply3DTransform(Y._fullLayout._invTransform)(U,Q);U=Z[0],Q=Z[1]}return this.style({top:Q+"px",left:U+"px","z-index":1e3}),this}}a.convertEntities=z,a.sanitizeHTML=function(N){N=N.replace(w," ");for(var E=document.createElement("p"),W=E,G=[],L=N.split(k),q=0;qd.ts+s?g():d.timer=setTimeout(function(){g(),d.timer=null},s)},a.done=function(f){var s=n[f];return s&&s.timer?new Promise(function(u){var d=s.onDone;s.onDone=function(){d&&d(),u(),s.onDone=null}}):Promise.resolve()},a.clear=function(f){if(f)l(n[f]),delete n[f];else for(var s in n)a.clear(s)}},58163:function(o,a,n){var l=n(92770);o.exports=function(f,s){if(f>0)return Math.log(f)/Math.LN10;var u=Math.log(Math.min(s[0],s[1]))/Math.LN10;return l(u)||(u=Math.log(Math.max(s[0],s[1]))/Math.LN10-6),u}},37815:function(o){o.exports={moduleType:"locale",name:"en-US",dictionary:{"Click to enter Colorscale title":"Click to enter Colorscale title"},format:{date:"%m/%d/%Y"}}},92177:function(o){o.exports={moduleType:"locale",name:"en",dictionary:{"Click to enter Colorscale title":"Click to enter Colourscale title"},format:{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"],periods:["AM","PM"],dateTime:"%a %b %e %X %Y",date:"%d/%m/%Y",time:"%H:%M:%S",decimal:".",thousands:",",grouping:[3],currency:["$",""],year:"%Y",month:"%b %Y",dayMonth:"%b %-d",dayMonthYear:"%b %-d, %Y"}}},14458:function(o,a,n){var l=n(73972);o.exports=function(f){for(var s,u,d=l.layoutArrayContainers,h=l.layoutArrayRegexes,p=f.split("[")[0],g=0;g0&&u.log("Clearing previous rejected promises from queue."),C._promises=[]},a.cleanLayout=function(C){var P,D;C||(C={}),C.xaxis1&&(C.xaxis||(C.xaxis=C.xaxis1),delete C.xaxis1),C.yaxis1&&(C.yaxis||(C.yaxis=C.yaxis1),delete C.yaxis1),C.scene1&&(C.scene||(C.scene=C.scene1),delete C.scene1);var O=(d.subplotsRegistry.cartesian||{}).attrRegex,R=(d.subplotsRegistry.polar||{}).attrRegex,F=(d.subplotsRegistry.ternary||{}).attrRegex,A=(d.subplotsRegistry.gl3d||{}).attrRegex,z=Object.keys(C);for(P=0;P3?(Z.x=1.02,Z.xanchor="left"):Z.x<-2&&(Z.x=-.02,Z.xanchor="right"),Z.y>3?(Z.y=1.02,Z.yanchor="bottom"):Z.y<-2&&(Z.y=-.02,Z.yanchor="top")),b(C),C.dragmode==="rotate"&&(C.dragmode="orbit"),p.clean(C),C.template&&C.template.layout&&a.cleanLayout(C.template.layout),C},a.cleanData=function(C){for(var P=0;P0)return C.substr(0,P)}a.hasParent=function(C,P){for(var D=M(P);D;){if(D in C)return!0;D=M(D)}return!1};var S=["x","y","z"];a.clearAxisTypes=function(C,P,D){for(var O=0;O1&&s.warn("Full array edits are incompatible with other edits",x);var C=v[""][""];if(p(C))y.set(null);else{if(!Array.isArray(C))return s.warn("Unrecognized full array edit value",x,C),!0;y.set(C)}return!T&&(_(M,S),w(g),!0)}var P,D,O,R,F,A,z,B,$=Object.keys(v).map(Number).sort(u),j=y.get(),N=j||[],E=b(S,x).get(),W=[],G=-1,L=N.length;for(P=0;P<$.length;P++)if(R=v[O=$[P]],F=Object.keys(R),A=R[""],z=h(A),O<0||O>N.length-(z?0:1))s.warn("index out of range",x,O);else if(A!==void 0)F.length>1&&s.warn("Insertion & removal are incompatible with edits to the same index.",x,O),p(A)?W.push(O):z?(A==="add"&&(A={}),N.splice(O,0,A),E&&E.splice(O,0,{})):s.warn("Unrecognized full object edit value",x,O,A),G===-1&&(G=O);else for(D=0;D=0;P--)N.splice(W[P],1),E&&E.splice(W[P],1);if(N.length?j||y.set(N):y.set(null),T)return!1;if(_(M,S),k!==f){var q;if(G===-1)q=$;else{for(L=Math.max(N.length,L),q=[],P=0;P<$.length&&!((O=$[P])>=G);P++)q.push(O);for(P=G;P=ue.data.length||ke<-ue.data.length)throw new Error(be+" must be valid indices for gd.data.");if(ge.indexOf(ke,we+1)>-1||ke>=0&&ge.indexOf(-ue.data.length+ke)>-1||ke<0&&ge.indexOf(ue.data.length+ke)>-1)throw new Error("each index in "+be+" must be unique.")}}function E(ue,ge,be){if(!Array.isArray(ue.data))throw new Error("gd.data must be an array.");if(ge===void 0)throw new Error("currentIndices is a required argument.");if(Array.isArray(ge)||(ge=[ge]),N(ue,ge,"currentIndices"),be===void 0||Array.isArray(be)||(be=[be]),be!==void 0&&N(ue,be,"newIndices"),be!==void 0&&ge.length!==be.length)throw new Error("current and new indices must be of equal length.")}function W(ue,ge,be,we,ke){(function(qe,Ye,at,lt){var ct=u.isPlainObject(lt);if(!Array.isArray(qe.data))throw new Error("gd.data must be an array");if(!u.isPlainObject(Ye))throw new Error("update must be a key:value object");if(at===void 0)throw new Error("indices must be an integer or array of integers");for(var bt in N(qe,at,"indices"),Ye){if(!Array.isArray(Ye[bt])||Ye[bt].length!==at.length)throw new Error("attribute "+bt+" must be an array of length equal to indices array length");if(ct&&(!(bt in lt)||!Array.isArray(lt[bt])||lt[bt].length!==Ye[bt].length))throw new Error("when maxPoints is set as a key:value object it must contain a 1:1 corrispondence with the keys and number of traces in the update object")}})(ue,ge,be,we);for(var Ae=function(qe,Ye,at,lt){var ct,bt,ze,Ne,Qe,it=u.isPlainObject(lt),kt=[];for(var Je in Array.isArray(at)||(at=[at]),at=j(at,qe.data.length-1),Ye)for(var ut=0;ut-1&&be.indexOf("grouptitlefont")===-1?De(be,be.replace("titlefont","title.font")):be.indexOf("titleposition")>-1?De(be,be.replace("titleposition","title.position")):be.indexOf("titleside")>-1?De(be,be.replace("titleside","title.side")):be.indexOf("titleoffset")>-1&&De(be,be.replace("titleoffset","title.offset")):De(be,be.replace("title","title.text"));function De(Re,Ie){ue[Ie]=ue[Re],delete ue[Re]}}function U(ue,ge,be){ue=u.getGraphDiv(ue),P.clearPromiseQueue(ue);var we={};if(typeof ge=="string")we[ge]=be;else{if(!u.isPlainObject(ge))return u.warn("Relayout fail.",ge,be),Promise.reject();we=u.extendFlat({},ge)}Object.keys(we).length&&(ue.changed=!0);var ke=ie(ue,we),Ae=ke.flags;Ae.calc&&(ue.calcdata=void 0);var Ee=[v.previousPromises];Ae.layoutReplot?Ee.push(D.layoutReplot):Object.keys(we).length&&(Q(ue,Ae,ke)||v.supplyDefaults(ue),Ae.legend&&Ee.push(D.doLegend),Ae.layoutstyle&&Ee.push(D.layoutStyles),Ae.axrange&&Y(Ee,ke.rangesAltered),Ae.ticks&&Ee.push(D.doTicksRelayout),Ae.modebar&&Ee.push(D.doModeBar),Ae.camera&&Ee.push(D.doCamera),Ae.colorbars&&Ee.push(D.doColorBars),Ee.push(A)),Ee.push(v.rehover,v.redrag,v.reselect),p.add(ue,U,[ue,ke.undoit],U,[ue,ke.redoit]);var De=u.syncOrAsync(Ee,ue);return De&&De.then||(De=Promise.resolve(ue)),De.then(function(){return ue.emit("plotly_relayout",ke.eventData),ue})}function Q(ue,ge,be){var we,ke,Ae=ue._fullLayout;if(!ge.axrange)return!1;for(var Ee in ge)if(Ee!=="axrange"&&ge[Ee])return!1;var De=function(Ye,at){return u.coerce(we,ke,x,Ye,at)},Re={};for(var Ie in be.rangesAltered){var Be=m.id2name(Ie);if(we=ue.layout[Be],ke=Ae[Be],b(we,ke,De,Re),ke._matchGroup){for(var Ue in ke._matchGroup)if(Ue!==Ie){var qe=Ae[m.id2name(Ue)];qe.autorange=ke.autorange,qe.range=ke.range.slice(),qe._input.range=ke.range.slice()}}}return!0}function Y(ue,ge){var be=ge?function(we){var ke=[];for(var Ae in ge){var Ee=m.getFromId(we,Ae);if(ke.push(Ae),(Ee.ticklabelposition||"").indexOf("inside")!==-1&&Ee._anchorAxis&&ke.push(Ee._anchorAxis._id),Ee._matchGroup)for(var De in Ee._matchGroup)ge[De]||ke.push(De)}return m.draw(we,ke,{skipTitle:!0})}:function(we){return m.draw(we,"redraw")};ue.push(M,D.doAutoRangeAndConstraints,be,D.drawData,D.finalDraw)}var Z=/^[xyz]axis[0-9]*\.range(\[[0|1]\])?$/,X=/^[xyz]axis[0-9]*\.autorange$/,re=/^[xyz]axis[0-9]*\.domain(\[[0|1]\])?$/;function ie(ue,ge){var be,we,ke,Ae=ue.layout,Ee=ue._fullLayout,De=Ee._guiEditing,Re=H(Ee._preGUI,De),Ie=Object.keys(ge),Be=m.list(ue),Ue=u.extendDeepAll({},ge),qe={};for(ee(ge),Ie=Object.keys(ge),we=0;we0&&typeof ut.parts[It]!="string";)It--;var Mt=ut.parts[It],zt=ut.parts[It-1]+"."+Mt,wt=ut.parts.slice(0,It).join("."),ve=d(ue.layout,wt).get(),_e=d(Ee,wt).get(),Ve=ut.get();if(pt!==void 0){bt[Je]=pt,ze[Je]=Mt==="reverse"?pt:q(Ve);var We=y.getLayoutValObject(Ee,ut.parts);if(We&&We.impliedEdits&&pt!==null)for(var Ze in We.impliedEdits)Ne(u.relativeAttr(Je,Ze),We.impliedEdits[Ze]);if(["width","height"].indexOf(Je)!==-1)if(pt){Ne("autosize",null);var Ge=Je==="height"?"width":"height";Ne(Ge,Ee[Ge])}else Ee[Je]=ue._initialAutoSize[Je];else if(Je==="autosize")Ne("width",pt?null:Ee.width),Ne("height",pt?null:Ee.height);else if(zt.match(Z))kt(zt),d(Ee,wt+"._inputRange").set(null);else if(zt.match(X)){kt(zt),d(Ee,wt+"._inputRange").set(null);var Ke=d(Ee,wt).get();Ke._inputDomain&&(Ke._input.domain=Ke._inputDomain.slice())}else zt.match(re)&&d(Ee,wt+"._inputDomain").set(null);if(Mt==="type"){Qe=ve;var nt=_e.type==="linear"&&pt==="log",st=_e.type==="log"&&pt==="linear";if(nt||st){if(Qe&&Qe.range)if(_e.autorange)nt&&(Qe.range=Qe.range[1]>Qe.range[0]?[1,2]:[2,1]);else{var mt=Qe.range[0],tt=Qe.range[1];nt?(mt<=0&&tt<=0&&Ne(wt+".autorange",!0),mt<=0?mt=tt/1e6:tt<=0&&(tt=mt/1e6),Ne(wt+".range[0]",Math.log(mt)/Math.LN10),Ne(wt+".range[1]",Math.log(tt)/Math.LN10)):(Ne(wt+".range[0]",Math.pow(10,mt)),Ne(wt+".range[1]",Math.pow(10,tt)))}else Ne(wt+".autorange",!0);Array.isArray(Ee._subplots.polar)&&Ee._subplots.polar.length&&Ee[ut.parts[0]]&&ut.parts[1]==="radialaxis"&&delete Ee[ut.parts[0]]._subplot.viewInitial["radialaxis.range"],g.getComponentMethod("annotations","convertCoords")(ue,_e,pt,Ne),g.getComponentMethod("images","convertCoords")(ue,_e,pt,Ne)}else Ne(wt+".autorange",!0),Ne(wt+".range",null);d(Ee,wt+"._inputRange").set(null)}else if(Mt.match(R)){var Ft=d(Ee,Je).get(),Vt=(pt||{}).type;Vt&&Vt!=="-"||(Vt="linear"),g.getComponentMethod("annotations","convertCoords")(ue,Ft,Vt,Ne),g.getComponentMethod("images","convertCoords")(ue,Ft,Vt,Ne)}var St=C.containerArrayMatch(Je);if(St){be=St.array,we=St.index;var Nt=St.property,Dt=We||{editType:"calc"};we!==""&&Nt===""&&(C.isAddVal(pt)?ze[Je]=null:C.isRemoveVal(pt)?ze[Je]=(d(Ae,be).get()||[])[we]:u.warn("unrecognized full object value",ge)),O.update(ct,Dt),qe[be]||(qe[be]={});var gt=qe[be][we];gt||(gt=qe[be][we]={}),gt[Nt]=pt,delete ge[Je]}else Mt==="reverse"?(ve.range?ve.range.reverse():(Ne(wt+".autorange",!0),ve.range=[1,0]),_e.autorange?ct.calc=!0:ct.plot=!0):(Je==="dragmode"&&(pt===!1&&Ve!==!1||pt!==!1&&Ve===!1)||Ee._has("scatter-like")&&Ee._has("regl")&&Je==="dragmode"&&(pt==="lasso"||pt==="select")&&Ve!=="lasso"&&Ve!=="select"||Ee._has("gl2d")?ct.plot=!0:We?O.update(ct,We):ct.calc=!0,ut.set(pt))}}for(be in qe)C.applyContainerArrayChanges(ue,Re(Ae,be),qe[be],ct,Re)||(ct.plot=!0);for(var ht in it){var yt=(Qe=m.getFromId(ue,ht))&&Qe._constraintGroup;if(yt)for(var qt in ct.calc=!0,yt)it[qt]||(m.getFromId(ue,qt)._constraintShrinkable=!0)}(le(ue)||ge.height||ge.width)&&(ct.plot=!0);var Et=Ee.shapes;for(we=0;we1;)if(we.pop(),(be=d(ge,we.join(".")+".uirevision").get())!==void 0)return be;return ge.uirevision}function ce(ue,ge){for(var be=0;be=ke.length?ke[0]:ke[Ie]:ke}function De(Ie){return Array.isArray(Ae)?Ie>=Ae.length?Ae[0]:Ae[Ie]:Ae}function Re(Ie,Be){var Ue=0;return function(){if(Ie&&++Ue===Be)return Ie()}}return we._frameWaitingCnt===void 0&&(we._frameWaitingCnt=0),new Promise(function(Ie,Be){function Ue(){ue.emit("plotly_animating"),we._lastFrameAt=-1/0,we._timeToNext=0,we._runningTransitions=0,we._currentFrame=null;var Je=function(){we._animationRaf=window.requestAnimationFrame(Je),Date.now()-we._lastFrameAt>we._timeToNext&&function(){we._currentFrame&&we._currentFrame.onComplete&&we._currentFrame.onComplete();var ut=we._currentFrame=we._frameQueue.shift();if(ut){var pt=ut.name?ut.name.toString():null;ue._fullLayout._currentFrame=pt,we._lastFrameAt=Date.now(),we._timeToNext=ut.frameOpts.duration,v.transition(ue,ut.frame.data,ut.frame.layout,P.coerceTraceIndices(ue,ut.frame.traces),ut.frameOpts,ut.transitionOpts).then(function(){ut.onComplete&&ut.onComplete()}),ue.emit("plotly_animatingframe",{name:pt,frame:ut.frame,animation:{frame:ut.frameOpts,transition:ut.transitionOpts}})}else ue.emit("plotly_animated"),window.cancelAnimationFrame(we._animationRaf),we._animationRaf=null}()};Je()}var qe,Ye,at=0;function lt(Je){return Array.isArray(ke)?at>=ke.length?Je.transitionOpts=ke[at]:Je.transitionOpts=ke[0]:Je.transitionOpts=ke,at++,Je}var ct=[],bt=ge==null,ze=Array.isArray(ge);if(bt||ze||!u.isPlainObject(ge)){if(bt||["string","number"].indexOf(typeof ge)!==-1)for(qe=0;qe0&&itit)&&kt.push(Ye);ct=kt}}ct.length>0?function(Je){if(Je.length!==0){for(var ut=0;ut=0;we--)if(u.isPlainObject(ge[we])){var qe=ge[we].name,Ye=(Re[qe]||Ue[qe]||{}).name,at=ge[we].name,lt=Re[Ye]||Ue[Ye];Ye&&at&&typeof at=="number"&<&&F<5&&(F++,u.warn('addFrames: overwriting frame "'+(Re[Ye]||Ue[Ye]).name+'" with a frame whose name of type "number" also equates to "'+Ye+'". This is valid but may potentially lead to unexpected behavior since all plotly.js frame names are stored internally as strings.'),F===5&&u.warn("addFrames: This API call has yielded too many of these warnings. For the rest of this call, further warnings about numeric frame names will be suppressed.")),Ue[qe]={name:qe},Be.push({frame:v.supplyFrameDefaults(ge[we]),index:be&&be[we]!==void 0&&be[we]!==null?be[we]:Ie+we})}Be.sort(function(Je,ut){return Je.index>ut.index?-1:Je.index=0;we--){if(typeof(ke=Be[we].frame).name=="number"&&u.warn("Warning: addFrames accepts frames with numeric names, but the numbers areimplicitly cast to strings"),!ke.name)for(;Re[ke.name="frame "+ue._transitionData._counter++];);if(Re[ke.name]){for(Ae=0;Ae=0;be--)we=ge[be],Ae.push({type:"delete",index:we}),Ee.unshift({type:"insert",index:we,value:ke[we]});var De=v.modifyFrames,Re=v.modifyFrames,Ie=[ue,Ee],Be=[ue,Ae];return p&&p.add(ue,De,Ie,Re,Be),v.modifyFrames(ue,Ae)},a.addTraces=function ue(ge,be,we){ge=u.getGraphDiv(ge);var ke,Ae,Ee=[],De=a.deleteTraces,Re=ue,Ie=[ge,Ee],Be=[ge,be];for(function(Ue,qe,Ye){var at,lt;if(!Array.isArray(Ue.data))throw new Error("gd.data must be an array.");if(qe===void 0)throw new Error("traces must be defined.");for(Array.isArray(qe)||(qe=[qe]),at=0;at=0&&Be=0&&Be=$.length)return!1;if(R.dimensions===2){if(A++,F.length===A)return R;var j=F[A];if(!S(j))return!1;R=$[B][j]}else R=$[B]}else R=$}}return R}function S(R){return R===Math.round(R)&&R>=0}function C(){var R,F,A={};for(R in y(A,u),l.subplotsRegistry)if((F=l.subplotsRegistry[R]).layoutAttributes)if(Array.isArray(F.attr))for(var z=0;z=j.length)return!1;z=(A=(l.transformsRegistry[j[N].type]||{}).attributes)&&A[F[2]],$=3}else{var E=R._module;if(E||(E=(l.modules[R.type||s.type.dflt]||{})._module),!E)return!1;if(!(z=(A=E.attributes)&&A[B])){var W=E.basePlotModule;W&&W.attributes&&(z=W.attributes[B])}z||(z=s[B])}return M(z,F,$)},a.getLayoutValObject=function(R,F){var A=function(z,B){var $,j,N,E,W=z._basePlotModules;if(W){var G;for($=0;$=v&&(y._input||{})._templateitemname;b&&(m=v);var x,_=g+"["+m+"]";function w(){x={},b&&(x[_]={},x[_][s]=b)}function k(M,S){b?l.nestedProperty(x[_],M).set(S):x[_+"."+M]=S}function T(){var M=x;return w(),M}return w(),{modifyBase:function(M,S){x[M]=S},modifyItem:k,getUpdateObj:T,applyUpdate:function(M,S){M&&k(M,S);var C=T();for(var P in C)l.nestedProperty(p,P).set(C[P])}}}},61549:function(o,a,n){var l=n(39898),f=n(73972),s=n(74875),u=n(71828),d=n(63893),h=n(33306),p=n(7901),g=n(91424),y=n(92998),v=n(64168),m=n(89298),b=n(18783),x=n(99082),_=x.enforce,w=x.clean,k=n(71739).doAutoRange,T="start";function M(O,R,F){for(var A=0;A=O[1]||z[1]<=O[0])&&B[0]R[0])return!0}return!1}function S(O){var R,F,A,z,B,$,j=O._fullLayout,N=j._size,E=N.p,W=m.list(O,"",!0);if(j._paperdiv.style({width:O._context.responsive&&j.autosize&&!O._context._hasZeroWidth&&!O.layout.width?"100%":j.width+"px",height:O._context.responsive&&j.autosize&&!O._context._hasZeroHeight&&!O.layout.height?"100%":j.height+"px"}).selectAll(".main-svg").call(g.setSize,j.width,j.height),O._context.setBackground(O,j.paper_bgcolor),a.drawMainTitle(O),v.manage(O),!j._has("cartesian"))return s.previousPromises(O);function G(Ie,Be,Ue){var qe=Ie._lw/2;return Ie._id.charAt(0)==="x"?Be?Ue==="top"?Be._offset-E-qe:Be._offset+Be._length+E+qe:N.t+N.h*(1-(Ie.position||0))+qe%1:Be?Ue==="right"?Be._offset+Be._length+E+qe:Be._offset-E-qe:N.l+N.w*(Ie.position||0)+qe%1}for(R=0;R.5?"t":"b",ee=G._fullLayout.margin[te],U=0;return L.yref==="paper"?U=q+L.pad.t+L.pad.b:L.yref==="container"&&(U=function(Q,Y,Z,X,re){var ie=0;return Z==="middle"&&(ie+=re/2),Q==="t"?(Z==="top"&&(ie+=re),ie+=X-Y*X):(Z==="bottom"&&(ie+=re),ie+=Y*X),ie}(te,H,V,G._fullLayout.height,q)+L.pad.t+L.pad.b),U>ee?U:0}(O,F,E);W>0&&(function(G,L,q,H){var V="title.automargin",te=G._fullLayout.title,ee=te.y>.5?"t":"b",U={x:te.x,y:te.y,t:0,b:0},Q={};te.yref==="paper"&&function(Y,Z,X,re,ie){var le=Z.yref==="paper"?Y._fullLayout._size.h:Y._fullLayout.height,se=u.isTopAnchor(Z)?re:re-ie,pe=X==="b"?le-se:se;return!(u.isTopAnchor(Z)&&X==="t"||u.isBottomAnchor(Z)&&X==="b")&&peN?D.push({code:"unused",traceType:A,templateCount:j,dataCount:N}):N>j&&D.push({code:"reused",traceType:A,templateCount:j,dataCount:N})}}else D.push({code:"data"});if(function E(W,G){for(var L in W)if(L.charAt(0)!=="_"){var q=W[L],H=x(W,L,G);f(q)?(Array.isArray(W)&&q._template===!1&&q.templateitemname&&D.push({code:"missing",path:H,templateitemname:q.templateitemname}),E(q,H)):Array.isArray(q)&&_(q)&&E(q,H)}}({data:R,layout:O},""),D.length)return D.map(w)}},403:function(o,a,n){var l=n(92770),f=n(72391),s=n(74875),u=n(71828),d=n(25095),h=n(5900),p=n(70942),g=n(11506).version,y={format:{valType:"enumerated",values:["png","jpeg","webp","svg","full-json"],dflt:"png"},width:{valType:"number",min:1},height:{valType:"number",min:1},scale:{valType:"number",min:0,dflt:1},setBackground:{valType:"any",dflt:!1},imageDataOnly:{valType:"boolean",dflt:!1}};o.exports=function(v,m){var b,x,_,w;function k(N){return!(N in m)||u.validate(m[N],y[N])}if(m=m||{},u.isPlainObject(v)?(b=v.data||[],x=v.layout||{},_=v.config||{},w={}):(v=u.getGraphDiv(v),b=u.extendDeep([],v.data),x=u.extendDeep({},v.layout),_=v._context,w=v._fullLayout||{}),!k("width")&&m.width!==null||!k("height")&&m.height!==null)throw new Error("Height and width should be pixel values.");if(!k("format"))throw new Error("Export format is not "+u.join2(y.format.values,", "," or ")+".");var T={};function M(N,E){return u.coerce(m,T,y,N,E)}var S=M("format"),C=M("width"),P=M("height"),D=M("scale"),O=M("setBackground"),R=M("imageDataOnly"),F=document.createElement("div");F.style.position="absolute",F.style.left="-5000px",document.body.appendChild(F);var A=u.extendFlat({},x);C?A.width=C:m.width===null&&l(w.width)&&(A.width=w.width),P?A.height=P:m.height===null&&l(w.height)&&(A.height=w.height);var z=u.extendFlat({},_,{_exportedPlot:!0,staticPlot:!0,setBackground:O}),B=d.getRedrawFunc(F);function $(){return new Promise(function(N){setTimeout(N,d.getDelay(F._fullLayout))})}function j(){return new Promise(function(N,E){var W=h(F,S,D),G=F._fullLayout.width,L=F._fullLayout.height;function q(){f.purge(F),document.body.removeChild(F)}if(S==="full-json"){var H=s.graphJson(F,!1,"keepdata","object",!0,!0);return H.version=g,H=JSON.stringify(H),q(),N(R?H:d.encodeJSON(H))}if(q(),S==="svg")return N(R?W:d.encodeSVG(W));var V=document.createElement("canvas");V.id=u.randstr(),p({format:S,width:G,height:L,scale:D,canvas:V,svg:W,promise:!0}).then(N).catch(E)})}return new Promise(function(N,E){f.newPlot(F,b,A,z).then(B).then($).then(j).then(function(W){N(function(G){return R?G.replace(d.IMAGE_URL_PREFIX,""):G}(W))}).catch(function(W){E(W)})})}},84936:function(o,a,n){var l=n(71828),f=n(74875),s=n(86281),u=n(72075).dfltConfig,d=l.isPlainObject,h=Array.isArray,p=l.isArrayOrTypedArray;function g(k,T,M,S,C,P){P=P||[];for(var D=Object.keys(k),O=0;Oz.length&&S.push(m("unused",C,F.concat(z.length)));var W,G,L,q,H,V=z.length,te=Array.isArray(E);if(te&&(V=Math.min(V,E.length)),B.dimensions===2)for(G=0;Gz[G].length&&S.push(m("unused",C,F.concat(G,z[G].length)));var ee=z[G].length;for(W=0;W<(te?Math.min(ee,E[G].length):ee);W++)L=te?E[G][W]:E,q=A[G][W],H=z[G][W],l.validate(q,L)?H!==q&&H!==+q&&S.push(m("dynamic",C,F.concat(G,W),q,H)):S.push(m("value",C,F.concat(G,W),q))}else S.push(m("array",C,F.concat(G),A[G]));else for(G=0;G1&&P.push(m("object","layout"))),f.supplyDefaults(D);for(var O=D._fullData,R=M.length,F=0;F0&&Math.round(x)===x))return{vals:y};m=x}for(var _=p.calendar,w=v==="start",k=v==="end",T=h[g+"period0"],M=s(T,_)||0,S=[],C=[],P=[],D=y.length,O=0;Oz;)A=u(A,-m,_);for(;A<=z;)A=u(A,m,_);F=u(A,-m,_)}else{for(A=M+(R=Math.round((z-M)/b))*b;A>z;)A-=b;for(;A<=z;)A+=b;F=A-b}S[O]=w?F:k?A:(F+A)/2,C[O]=F,P[O]=A}return{vals:S,starts:C,ends:P}}},89502:function(o){o.exports={xaxis:{valType:"subplotid",dflt:"x",editType:"calc+clearAxisTypes"},yaxis:{valType:"subplotid",dflt:"y",editType:"calc+clearAxisTypes"}}},71739:function(o,a,n){var l=n(39898),f=n(92770),s=n(71828),u=n(50606).FP_SAFE,d=n(73972),h=n(91424),p=n(41675),g=p.getFromId,y=p.isLinked;function v(O,R){var F,A,z=[],B=O._fullLayout,$=b(B,R,0),j=b(B,R,1),N=_(O,R),E=N.min,W=N.max;if(E.length===0||W.length===0)return s.simpleMap(R.range,R.r2l);var G=E[0].val,L=W[0].val;for(F=1;F0&&((Y=le-$(te)-j(ee))>se?Z/Y>pe&&(U=te,Q=ee,pe=Z/Y):Z/le>pe&&(U={val:te.val,nopad:1},Q={val:ee.val,nopad:1},pe=Z/le));if(G===L){var Te=G-1,Se=G+1;if(re)if(G===0)z=[0,1];else{var Oe=(G>0?W:E).reduce(function(ce,ye){return Math.max(ce,j(ye))},0),Me=G/(1-Math.min(.5,Oe/le));z=G>0?[0,Me]:[Me,0]}else z=ie?[Math.max(0,Te),Math.max(1,Se)]:[Te,Se]}else re?(U.val>=0&&(U={val:0,nopad:1}),Q.val<=0&&(Q={val:0,nopad:1})):ie&&(U.val-pe*$(U)<0&&(U={val:0,nopad:1}),Q.val<=0&&(Q={val:1,nopad:1})),pe=(Q.val-U.val-m(R,te.val,ee.val))/(le-$(U)-j(Q)),z=[U.val-pe*$(U),Q.val+pe*j(Q)];return z=D(z,R),R.limitRange&&R.limitRange(),H&&z.reverse(),s.simpleMap(z,R.l2r||Number)}function m(O,R,F){var A=0;if(O.rangebreaks)for(var z=O.locateBreaks(R,F),B=0;B0?F.ppadplus:F.ppadminus)||F.ppad||0),X=Y((O._m>0?F.ppadminus:F.ppadplus)||F.ppad||0),re=Y(F.vpadplus||F.vpad),ie=Y(F.vpadminus||F.vpad);if(!U){if(W=1/0,G=-1/0,ee)for(A=0;A0&&(W=z),z>G&&z-u&&(W=z),z>G&&z=pe;A--)se(A);return{min:L,max:q,opts:F}},concatExtremes:_};var x=3;function _(O,R,F){var A,z,B,$=R._id,j=O._fullData,N=O._fullLayout,E=[],W=[];function G(te,ee){for(A=0;A=F&&(E.extrapad||!$)){j=!1;break}z(R,E.val)&&E.pad<=F&&($||!E.extrapad)&&(O.splice(N,1),N--)}if(j){var W=B&&R===0;O.push({val:R,pad:W?0:F,extrapad:!W&&$})}}function M(O){return f(O)&&Math.abs(O)=R}function P(O,R,F){return R===void 0||F===void 0||(R=O.d2l(R))=N&&(B=N,F=N),$<=N&&($=N,A=N)}}return F=function(E,W){var G=W.autorangeoptions;return G&&G.minallowed!==void 0&&P(W,G.minallowed,G.maxallowed)?G.minallowed:G&&G.clipmin!==void 0&&P(W,G.clipmin,G.clipmax)?Math.max(E,W.d2l(G.clipmin)):E}(F,R),A=function(E,W){var G=W.autorangeoptions;return G&&G.maxallowed!==void 0&&P(W,G.minallowed,G.maxallowed)?G.maxallowed:G&&G.clipmax!==void 0&&P(W,G.clipmin,G.clipmax)?Math.min(E,W.d2l(G.clipmax)):E}(A,R),[F,A]}},23074:function(o){o.exports=function(a,n,l){var f,s;if(l){var u=n==="reversed"||n==="min reversed"||n==="max reversed";f=l[u?1:0],s=l[u?0:1]}var d=a("autorangeoptions.minallowed",s===null?f:void 0),h=a("autorangeoptions.maxallowed",f===null?s:void 0);d===void 0&&a("autorangeoptions.clipmin"),h===void 0&&a("autorangeoptions.clipmax"),a("autorangeoptions.include")}},89298:function(o,a,n){var l=n(39898),f=n(92770),s=n(74875),u=n(73972),d=n(71828),h=d.strTranslate,p=n(63893),g=n(92998),y=n(7901),v=n(91424),m=n(13838),b=n(66287),x=n(50606),_=x.ONEMAXYEAR,w=x.ONEAVGYEAR,k=x.ONEMINYEAR,T=x.ONEMAXQUARTER,M=x.ONEAVGQUARTER,S=x.ONEMINQUARTER,C=x.ONEMAXMONTH,P=x.ONEAVGMONTH,D=x.ONEMINMONTH,O=x.ONEWEEK,R=x.ONEDAY,F=R/2,A=x.ONEHOUR,z=x.ONEMIN,B=x.ONESEC,$=x.MINUS_SIGN,j=x.BADNUM,N={K:"zeroline"},E={K:"gridline",L:"path"},W={K:"minor-gridline",L:"path"},G={K:"tick",L:"path"},L={K:"tick",L:"text"},q={width:["x","r","l","xl","xr"],height:["y","t","b","yt","yb"],right:["r","xr"],left:["l","xl"],top:["t","yt"],bottom:["b","yb"]},H=n(18783),V=H.MID_SHIFT,te=H.CAP_SHIFT,ee=H.LINE_SPACING,U=H.OPPOSITE_SIDE,Q=o.exports={};Q.setConvert=n(21994);var Y=n(4322),Z=n(41675),X=Z.idSort,re=Z.isLinked;Q.id2name=Z.id2name,Q.name2id=Z.name2id,Q.cleanId=Z.cleanId,Q.list=Z.list,Q.listIds=Z.listIds,Q.getFromId=Z.getFromId,Q.getFromTrace=Z.getFromTrace;var ie=n(71739);Q.getAutoRange=ie.getAutoRange,Q.findExtremes=ie.findExtremes;var le=1e-4;function se(ve){var _e=(ve[1]-ve[0])*le;return[ve[0]-_e,ve[1]+_e]}Q.coerceRef=function(ve,_e,Ve,We,Ze,Ge){var Ke=We.charAt(We.length-1),nt=Ve._fullLayout._subplots[Ke+"axis"],st=We+"ref",mt={};return Ze||(Ze=nt[0]||(typeof Ge=="string"?Ge:Ge[0])),Ge||(Ge=Ze),nt=nt.concat(nt.map(function(tt){return tt+" domain"})),mt[st]={valType:"enumerated",values:nt.concat(Ge?typeof Ge=="string"?[Ge]:Ge:[]),dflt:Ze},d.coerce(ve,_e,mt,st)},Q.getRefType=function(ve){return ve===void 0?ve:ve==="paper"?"paper":ve==="pixel"?"pixel":/( domain)$/.test(ve)?"domain":"range"},Q.coercePosition=function(ve,_e,Ve,We,Ze,Ge){var Ke,nt;if(Q.getRefType(We)!=="range")Ke=d.ensureNumber,nt=Ve(Ze,Ge);else{var st=Q.getFromId(_e,We);nt=Ve(Ze,Ge=st.fraction2r(Ge)),Ke=st.cleanPos}ve[Ze]=Ke(nt)},Q.cleanPosition=function(ve,_e,Ve){return(Ve==="paper"||Ve==="pixel"?d.ensureNumber:Q.getFromId(_e,Ve).cleanPos)(ve)},Q.redrawComponents=function(ve,_e){_e=_e||Q.listIds(ve);var Ve=ve._fullLayout;function We(Ze,Ge,Ke,nt){for(var st=u.getComponentMethod(Ze,Ge),mt={},tt=0;tt<_e.length;tt++)for(var Ft=Ve[Q.id2name(_e[tt])][Ke],Vt=0;VtVe&&tt2e-6||((Ve-ve._forceTick0)/ve._minDtick%1+1.000001)%1>2e-6)&&(ve._minDtick=0)):ve._minDtick=0},Q.saveRangeInitial=function(ve,_e){for(var Ve=Q.list(ve,"",!0),We=!1,Ze=0;Ze.3*$t||Lt(qt)||Lt(Et))){var Yt=yt.dtick/2;gt+=gt+Yt.8){var Tt=Number(yt.substr(1));jt.exactYears>.8&&Tt%12==0?gt=Q.tickIncrement(gt,"M6","reverse")+1.5*R:jt.exactMonths>.8?gt=Q.tickIncrement(gt,"M1","reverse")+15.5*R:gt-=F;var Ot=Q.tickIncrement(gt,yt);if(Ot<=qt)return Ot}return gt}(Dt,ve,Nt,nt,Ze)),St=Dt;St<=st;)St=Q.tickIncrement(St,Nt,!1,Ze);return{start:_e.c2r(Dt,0,Ze),end:_e.c2r(St,0,Ze),size:Nt,_dataSpan:st-nt}},Q.prepMinorTicks=function(ve,_e,Ve){if(!_e.minor.dtick){delete ve.dtick;var We,Ze=_e.dtick&&f(_e._tmin);if(Ze){var Ge=Q.tickIncrement(_e._tmin,_e.dtick,!0);We=[_e._tmin,.99*Ge+.01*_e._tmin]}else{var Ke=d.simpleMap(_e.range,_e.r2l);We=[Ke[0],.8*Ke[0]+.2*Ke[1]]}if(ve.range=d.simpleMap(We,_e.l2r),ve._isMinor=!0,Q.prepTicks(ve,Ve),Ze){var nt=f(_e.dtick),st=f(ve.dtick),mt=nt?_e.dtick:+_e.dtick.substring(1),tt=st?ve.dtick:+ve.dtick.substring(1);nt&&st?Oe(mt,tt)?mt===2*O&&tt===2*R&&(ve.dtick=O):mt===2*O&&tt===3*R?ve.dtick=O:mt!==O||(_e._input.minor||{}).nticks?Me(mt/tt,2.5)?ve.dtick=mt/2:ve.dtick=mt:ve.dtick=R:String(_e.dtick).charAt(0)==="M"?st?ve.dtick="M1":Oe(mt,tt)?mt>=12&&tt===2&&(ve.dtick="M3"):ve.dtick=_e.dtick:String(ve.dtick).charAt(0)==="L"?String(_e.dtick).charAt(0)==="L"?Oe(mt,tt)||(ve.dtick=Me(mt/tt,2.5)?_e.dtick/2:_e.dtick):ve.dtick="D1":ve.dtick==="D2"&&+_e.dtick>1&&(ve.dtick=1)}ve.range=_e.range}_e.minor._tick0Init===void 0&&(ve.tick0=_e.tick0)},Q.prepTicks=function(ve,_e){var Ve=d.simpleMap(ve.range,ve.r2l,void 0,void 0,_e);if(ve.tickmode==="auto"||!ve.dtick){var We,Ze=ve.nticks;Ze||(ve.type==="category"||ve.type==="multicategory"?(We=ve.tickfont?d.bigFont(ve.tickfont.size||12):15,Ze=ve._length/We):(We=ve._id.charAt(0)==="y"?40:80,Ze=d.constrain(ve._length/We,4,9)+1),ve._name==="radialaxis"&&(Ze*=2)),ve.minor&&ve.minor.tickmode!=="array"||ve.tickmode==="array"&&(Ze*=100),ve._roughDTick=Math.abs(Ve[1]-Ve[0])/Ze,Q.autoTicks(ve,ve._roughDTick),ve._minDtick>0&&ve.dtick<2*ve._minDtick&&(ve.dtick=ve._minDtick,ve.tick0=ve.l2r(ve._forceTick0))}ve.ticklabelmode==="period"&&function(Ge){var Ke;function nt(){return!(f(Ge.dtick)||Ge.dtick.charAt(0)!=="M")}var st=nt(),mt=Q.getTickFormat(Ge);if(mt){var tt=Ge._dtickInit!==Ge.dtick;/%[fLQsSMX]/.test(mt)||(/%[HI]/.test(mt)?(Ke=A,tt&&!st&&Ge.dtick=(ht?0:1);yt--){var qt=!yt;yt?(ve._dtickInit=ve.dtick,ve._tick0Init=ve.tick0):(ve.minor._dtickInit=ve.minor.dtick,ve.minor._tick0Init=ve.minor.tick0);var Et=yt?ve:d.extendFlat({},ve,ve.minor);if(qt?Q.prepMinorTicks(Et,ve,_e):Q.prepTicks(Et,_e),Et.tickmode!=="array")if(Et.tickmode!=="sync"){var jt=se(st),Tt=jt[0],Ot=jt[1],At=f(Et.dtick),Lt=Ze==="log"&&!(At||Et.dtick.charAt(0)==="L"),Rt=Q.tickFirst(Et,_e);if(yt){if(ve._tmin=Rt,Rt=Ot:Bt<=Ot;Bt=Q.tickIncrement(Bt,Wt,mt,Ge)){if(yt&&$t++,Et.rangebreaks&&!mt){if(Bt=Ft)break}if(Dt.length>Vt||Bt===Xt)break;Xt=Bt;var tn={value:Bt};yt?(Lt&&Bt!==(0|Bt)&&(tn.simpleLabel=!0),Ke>1&&$t%Ke&&(tn.skipLabel=!0),Dt.push(tn)):(tn.minor=!0,gt.push(tn))}}else Dt=[],St=J(ve);else yt?(Dt=[],St=ne(ve)):(gt=[],Nt=ne(ve))}if(ht&&!(ve.minor.ticks==="inside"&&ve.ticks==="outside"||ve.minor.ticks==="outside"&&ve.ticks==="inside")){for(var cn=Dt.map(function(lr){return lr.value}),ln=[],an=0;an0?(oa=ur-1,On=ur):(oa=ur,On=ur);var on,$n=lr[oa].value,Pr=lr[On].value,Ln=Math.abs(Pr-$n),Bn=Ar||Ln,jn=0;Bn>=k?jn=Ln>=k&&Ln<=_?Ln:w:Ar===M&&Bn>=S?jn=Ln>=S&&Ln<=T?Ln:M:Bn>=D?jn=Ln>=D&&Ln<=C?Ln:P:Ar===O&&Bn>=O?jn=O:Bn>=R?jn=R:Ar===F&&Bn>=F?jn=F:Ar===A&&Bn>=A&&(jn=A),jn>=Ln&&(jn=Ln,on=!0);var Un=kr+jn;if(ni.rangebreaks&&jn>0){for(var Lr=0,br=0;br<84;br++){var Mr=(br+.5)/84;ni.maskBreaks(kr*(1-Mr)+Mr*Un)!==j&&Lr++}(jn*=Lr/84)||(lr[ur].drop=!0),on&&Ln>O&&(jn=Ln)}(jn>0||ur===0)&&(lr[ur].periodX=kr+jn/2)}}(Dt,ve,ve._definedDelta),ve.rangebreaks){var Kt=ve._id.charAt(0)==="y",Cn=1;ve.tickmode==="auto"&&(Cn=ve.tickfont?ve.tickfont.size:12);var _n=NaN;for(Ve=Dt.length-1;Ve>-1;Ve--)if(Dt[Ve].drop)Dt.splice(Ve,1);else{Dt[Ve].value=It(Dt[Ve].value,ve);var Pn=ve.c2p(Dt[Ve].value);(Kt?_n>Pn-Cn:_nFt||DnFt&&(xn.periodX=Ft),Dn10||We.substr(5)!=="01-01"?ve._tickround="d":ve._tickround=+_e.substr(1)%12==0?"y":"m";else if(_e>=R&&Ze<=10||_e>=15*R)ve._tickround="d";else if(_e>=z&&Ze<=16||_e>=A)ve._tickround="M";else if(_e>=B&&Ze<=19||_e>=z)ve._tickround="S";else{var Ge=ve.l2r(Ve+_e).replace(/^-/,"").length;ve._tickround=Math.max(Ze,Ge)-20,ve._tickround<0&&(ve._tickround=4)}}else if(f(_e)||_e.charAt(0)==="L"){var Ke=ve.range.map(ve.r2d||Number);f(_e)||(_e=Number(_e.substr(1))),ve._tickround=2-Math.floor(Math.log(_e)/Math.LN10+.01);var nt=Math.max(Math.abs(Ke[0]),Math.abs(Ke[1])),st=Math.floor(Math.log(nt)/Math.LN10+.01),mt=ve.minexponent===void 0?3:ve.minexponent;Math.abs(st)>mt&&(Ie(ve.exponentformat)&&!Be(st)?ve._tickexponent=3*Math.round((st-1)/3):ve._tickexponent=st)}else ve._tickround=null}function De(ve,_e,Ve){var We=ve.tickfont||{};return{x:_e,dx:0,dy:0,text:Ve||"",fontSize:We.size,font:We.family,fontColor:We.color}}Q.autoTicks=function(ve,_e,Ve){var We;function Ze(Ft){return Math.pow(Ft,Math.floor(Math.log(_e)/Math.LN10))}if(ve.type==="date"){ve.tick0=d.dateTick0(ve.calendar,0);var Ge=2*_e;if(Ge>w)_e/=w,We=Ze(10),ve.dtick="M"+12*Ae(_e,We,de);else if(Ge>P)_e/=P,ve.dtick="M"+Ae(_e,1,xe);else if(Ge>R){if(ve.dtick=Ae(_e,R,ve._hasDayOfWeekBreaks?[1,2,7,14]:ge),!Ve){var Ke=Q.getTickFormat(ve),nt=ve.ticklabelmode==="period";nt&&(ve._rawTick0=ve.tick0),/%[uVW]/.test(Ke)?ve.tick0=d.dateTick0(ve.calendar,2):ve.tick0=d.dateTick0(ve.calendar,1),nt&&(ve._dowTick0=ve.tick0)}}else Ge>A?ve.dtick=Ae(_e,A,xe):Ge>z?ve.dtick=Ae(_e,z,ue):Ge>B?ve.dtick=Ae(_e,B,ue):(We=Ze(10),ve.dtick=Ae(_e,We,de))}else if(ve.type==="log"){ve.tick0=0;var st=d.simpleMap(ve.range,ve.r2l);if(ve._isMinor&&(_e*=1.5),_e>.7)ve.dtick=Math.ceil(_e);else if(Math.abs(st[1]-st[0])<1){var mt=1.5*Math.abs((st[1]-st[0])/_e);_e=Math.abs(Math.pow(10,st[1])-Math.pow(10,st[0]))/mt,We=Ze(10),ve.dtick="L"+Ae(_e,We,de)}else ve.dtick=_e>.3?"D2":"D1"}else ve.type==="category"||ve.type==="multicategory"?(ve.tick0=0,ve.dtick=Math.ceil(Math.max(_e,1))):pt(ve)?(ve.tick0=0,We=1,ve.dtick=Ae(_e,We,ke)):(ve.tick0=0,We=Ze(10),ve.dtick=Ae(_e,We,de));if(ve.dtick===0&&(ve.dtick=1),!f(ve.dtick)&&typeof ve.dtick!="string"){var tt=ve.dtick;throw ve.dtick=1,"ax.dtick error: "+String(tt)}},Q.tickIncrement=function(ve,_e,Ve,We){var Ze=Ve?-1:1;if(f(_e))return d.increment(ve,Ze*_e);var Ge=_e.charAt(0),Ke=Ze*Number(_e.substr(1));if(Ge==="M")return d.incrementMonth(ve,Ke,We);if(Ge==="L")return Math.log(Math.pow(10,ve)+Ke)/Math.LN10;if(Ge==="D"){var nt=_e==="D2"?we:be,st=ve+.01*Ze,mt=d.roundUp(d.mod(st,1),nt,Ve);return Math.floor(st)+Math.log(l.round(Math.pow(10,mt),1))/Math.LN10}throw"unrecognized dtick "+String(_e)},Q.tickFirst=function(ve,_e){var Ve=ve.r2l||Number,We=d.simpleMap(ve.range,Ve,void 0,void 0,_e),Ze=We[1] ")}else gt._prevDateHead=Tt,Ot+="
"+Tt;ht.text=Ot}(ve,Ge,Ve,nt):st==="log"?function(gt,ht,yt,qt,Et){var jt=gt.dtick,Tt=ht.x,Ot=gt.tickformat,At=typeof jt=="string"&&jt.charAt(0);if(Et==="never"&&(Et=""),qt&&At!=="L"&&(jt="L3",At="L"),Ot||At==="L")ht.text=Ue(Math.pow(10,Tt),gt,Et,qt);else if(f(jt)||At==="D"&&d.mod(Tt+.01,1)<.1){var Lt=Math.round(Tt),Rt=Math.abs(Lt),$t=gt.exponentformat;$t==="power"||Ie($t)&&Be(Lt)?(ht.text=Lt===0?1:Lt===1?"10":"10"+(Lt>1?"":$)+Rt+"",ht.fontSize*=1.25):($t==="e"||$t==="E")&&Rt>2?ht.text="1"+$t+(Lt>0?"+":$)+Rt:(ht.text=Ue(Math.pow(10,Tt),gt,"","fakehover"),jt==="D1"&>._id.charAt(0)==="y"&&(ht.dy-=ht.fontSize/6))}else{if(At!=="D")throw"unrecognized dtick "+String(jt);ht.text=String(Math.round(Math.pow(10,d.mod(Tt,1)))),ht.fontSize*=.75}if(gt.dtick==="D1"){var Yt=String(ht.text).charAt(0);Yt!=="0"&&Yt!=="1"||(gt._id.charAt(0)==="y"?ht.dx-=ht.fontSize/4:(ht.dy+=ht.fontSize/2,ht.dx+=(gt.range[1]>gt.range[0]?1:-1)*ht.fontSize*(Tt<0?.5:.25)))}}(ve,Ge,0,nt,St):st==="category"?function(gt,ht){var yt=gt._categories[Math.round(ht.x)];yt===void 0&&(yt=""),ht.text=String(yt)}(ve,Ge):st==="multicategory"?function(gt,ht,yt){var qt=Math.round(ht.x),Et=gt._categories[qt]||[],jt=Et[1]===void 0?"":String(Et[1]),Tt=Et[0]===void 0?"":String(Et[0]);yt?ht.text=Tt+" - "+jt:(ht.text=jt,ht.text2=Tt)}(ve,Ge,Ve):pt(ve)?function(gt,ht,yt,qt,Et){if(gt.thetaunit!=="radians"||yt)ht.text=Ue(ht.x,gt,Et,qt);else{var jt=ht.x/180;if(jt===0)ht.text="0";else{var Tt=function(At){function Lt(Xt,Bt){return Math.abs(Xt-Bt)<=1e-6}var Rt=function(Xt){for(var Bt=1;!Lt(Math.round(Xt*Bt)/Bt,Xt);)Bt*=10;return Bt}(At),$t=At*Rt,Yt=Math.abs(function Xt(Bt,Wt){return Lt(Wt,0)?Bt:Xt(Wt,Bt%Wt)}($t,Rt));return[Math.round($t/Yt),Math.round(Rt/Yt)]}(jt);if(Tt[1]>=100)ht.text=Ue(d.deg2rad(ht.x),gt,Et,qt);else{var Ot=ht.x<0;Tt[1]===1?Tt[0]===1?ht.text="π":ht.text=Tt[0]+"π":ht.text=["",Tt[0],"","⁄","",Tt[1],"","π"].join(""),Ot&&(ht.text=$+ht.text)}}}}(ve,Ge,Ve,nt,St):function(gt,ht,yt,qt,Et){Et==="never"?Et="":gt.showexponent==="all"&&Math.abs(ht.x/gt.dtick)<1e-6&&(Et="hide"),ht.text=Ue(ht.x,gt,Et,qt)}(ve,Ge,0,nt,St),We||(ve.tickprefix&&!Vt(ve.showtickprefix)&&(Ge.text=ve.tickprefix+Ge.text),ve.ticksuffix&&!Vt(ve.showticksuffix)&&(Ge.text+=ve.ticksuffix)),ve.labelalias&&ve.labelalias.hasOwnProperty(Ge.text)){var Nt=ve.labelalias[Ge.text];typeof Nt=="string"&&(Ge.text=Nt)}if(ve.tickson==="boundaries"||ve.showdividers){var Dt=function(gt){var ht=ve.l2p(gt);return ht>=0&&ht<=ve._length?gt:null};Ge.xbnd=[Dt(Ge.x-.5),Dt(Ge.x+ve.dtick-.5)]}return Ge},Q.hoverLabelText=function(ve,_e,Ve){Ve&&(ve=d.extendFlat({},ve,{hoverformat:Ve}));var We=Array.isArray(_e)?_e[0]:_e,Ze=Array.isArray(_e)?_e[1]:void 0;if(Ze!==void 0&&Ze!==We)return Q.hoverLabelText(ve,We,Ve)+" - "+Q.hoverLabelText(ve,Ze,Ve);var Ge=ve.type==="log"&&We<=0,Ke=Q.tickText(ve,ve.c2l(Ge?-We:We),"hover").text;return Ge?We===0?"0":$+Ke:Ke};var Re=["f","p","n","μ","m","","k","M","G","T"];function Ie(ve){return ve==="SI"||ve==="B"}function Be(ve){return ve>14||ve<-15}function Ue(ve,_e,Ve,We){var Ze=ve<0,Ge=_e._tickround,Ke=Ve||_e.exponentformat||"B",nt=_e._tickexponent,st=Q.getTickFormat(_e),mt=_e.separatethousands;if(We){var tt={exponentformat:Ke,minexponent:_e.minexponent,dtick:_e.showexponent==="none"?_e.dtick:f(ve)&&Math.abs(ve)||1,range:_e.showexponent==="none"?_e.range.map(_e.r2d):[0,ve||1]};Ee(tt),Ge=(Number(tt._tickround)||0)+4,nt=tt._tickexponent,_e.hoverformat&&(st=_e.hoverformat)}if(st)return _e._numFormat(st)(ve).replace(/-/g,$);var Ft,Vt=Math.pow(10,-Ge)/2;if(Ke==="none"&&(nt=0),(ve=Math.abs(ve))"+Ft+"":Ke==="B"&&nt===9?ve+="B":Ie(Ke)&&(ve+=Re[nt/3+5])),Ze?$+ve:ve}function qe(ve,_e){if(ve){var Ve=Object.keys(q).reduce(function(We,Ze){return _e.indexOf(Ze)!==-1&&q[Ze].forEach(function(Ge){We[Ge]=1}),We},{});Object.keys(ve).forEach(function(We){Ve[We]||(We.length===1?ve[We]=0:delete ve[We])})}}function Ye(ve,_e){for(var Ve=[],We={},Ze=0;Ze<_e.length;Ze++){var Ge=_e[Ze];We[Ge.text2]?We[Ge.text2].push(Ge.x):We[Ge.text2]=[Ge.x]}for(var Ke in We)Ve.push(De(ve,d.interp(We[Ke],.5),Ke));return Ve}function at(ve){return ve.periodX!==void 0?ve.periodX:ve.x}function lt(ve){return[ve.text,ve.x,ve.axInfo,ve.font,ve.fontSize,ve.fontColor].join("_")}function ct(ve){var _e=ve.title.font.size,Ve=(ve.title.text.match(p.BR_TAG_ALL)||[]).length;return ve.title.hasOwnProperty("standoff")?Ve?_e*(te+Ve*ee):_e*te:Ve?_e*(Ve+1)*ee:_e}function bt(ve,_e){var Ve=ve.l2p(_e);return Ve>1&&Ve=Ze.min&&ve=0,ht=tt(Vt,St[1])<=0;return(Nt||gt)&&(Dt||ht)}if(ve.tickformatstops&&ve.tickformatstops.length>0)switch(ve.type){case"date":case"linear":for(_e=0;_e=Ke(Ze)))){Ve=We;break}break;case"log":for(_e=0;_e=0&&Ze.unshift(Ze.splice(mt,1).shift())}});var Ke={false:{left:0,right:0}};return d.syncOrAsync(Ze.map(function(nt){return function(){if(nt){var st=Q.getFromId(ve,nt);Ve||(Ve={}),Ve.axShifts=Ke,Ve.overlayingShiftedAx=Ge;var mt=Q.drawOne(ve,st,Ve);return st._shiftPusher&&wt(st,st._fullDepth||0,Ke,!0),st._r=st.range.slice(),st._rl=d.simpleMap(st._r,st.r2l),mt}}}))},Q.drawOne=function(ve,_e,Ve){var We,Ze,Ge,Ke=(Ve=Ve||{}).axShifts||{},nt=Ve.overlayingShiftedAx||[];_e.setScale();var st=ve._fullLayout,mt=_e._id,tt=mt.charAt(0),Ft=Q.counterLetter(mt),Vt=st._plots[_e._mainSubplot];if(Vt){if(_e._shiftPusher=_e.autoshift||nt.indexOf(_e._id)!==-1||nt.indexOf(_e.overlaying)!==-1,_e._shiftPusher&_e.anchor==="free"){var St=_e.linewidth/2||0;_e.ticks==="inside"&&(St+=_e.ticklen),wt(_e,St,Ke,!0),wt(_e,_e.shift||0,Ke,!1)}Ve.skipTitle===!0&&_e._shift!==void 0||(_e._shift=function(On,on){return On.autoshift?on[On.overlaying][On.side]:On.shift||0}(_e,Ke));var Nt=Vt[tt+"axislayer"],Dt=_e._mainLinePosition,gt=Dt+=_e._shift,ht=_e._mainMirrorPosition,yt=_e._vals=Q.calcTicks(_e),qt=[_e.mirror,gt,ht].join("_");for(We=0;We0?On.bottom-jn:0,Un))));var Lr=0,br=0;if(_e._shiftPusher&&(Lr=Math.max(Un,On.height>0?Ln==="l"?jn-On.left:On.right-jn:0),_e.title.text!==st._dfltTitle[tt]&&(br=(_e._titleStandoff||0)+(_e._titleScoot||0),Ln==="l"&&(br+=ct(_e))),_e._fullDepth=Math.max(Lr,br)),_e.automargin){on={x:0,y:0,r:0,l:0,t:0,b:0};var Mr=[0,1],ja=typeof _e._shift=="number"?_e._shift:0;if(tt==="x"){if(Ln==="b"?on[Ln]=_e._depth:(on[Ln]=_e._depth=Math.max(On.width>0?jn-On.top:0,Un),Mr.reverse()),On.width>0){var _a=On.right-(_e._offset+_e._length);_a>0&&(on.xr=1,on.r=_a);var la=_e._offset-On.left;la>0&&(on.xl=0,on.l=la)}}else if(Ln==="l"?(_e._depth=Math.max(On.height>0?jn-On.left:0,Un),on[Ln]=_e._depth-ja):(_e._depth=Math.max(On.height>0?On.right-jn:0,Un),on[Ln]=_e._depth+ja,Mr.reverse()),On.height>0){var Tn=On.bottom-(_e._offset+_e._length);Tn>0&&(on.yb=0,on.b=Tn);var Dr=_e._offset-On.top;Dr>0&&(on.yt=1,on.t=Dr)}on[Ft]=_e.anchor==="free"?_e.position:_e._anchorAxis.domain[Mr[0]],_e.title.text!==st._dfltTitle[tt]&&(on[Ln]+=ct(_e)+(_e.title.standoff||0)),_e.mirror&&_e.anchor!=="free"&&(($n={x:0,y:0,r:0,l:0,t:0,b:0})[Bn]=_e.linewidth,_e.mirror&&_e.mirror!==!0&&($n[Bn]+=Un),_e.mirror===!0||_e.mirror==="ticks"?$n[Ft]=_e._anchorAxis.domain[Mr[1]]:_e.mirror!=="all"&&_e.mirror!=="allticks"||($n[Ft]=[_e._counterDomainMin,_e._counterDomainMax][Mr[1]]))}kr&&(Pr=u.getComponentMethod("rangeslider","autoMarginOpts")(ve,_e)),typeof _e.automargin=="string"&&(qe(on,_e.automargin),qe($n,_e.automargin)),s.autoMargin(ve,Ne(_e),on),s.autoMargin(ve,Qe(_e),$n),s.autoMargin(ve,it(_e),Pr)}),d.syncOrAsync(Ar)}}function oa(On){var on=mt+(On||"tick");return Et[on]||(Et[on]=function($n,Pr){var Ln,Bn,jn,Un;return $n._selections[Pr].size()?(Ln=1/0,Bn=-1/0,jn=1/0,Un=-1/0,$n._selections[Pr].each(function(){var Lr=ze(this),br=v.bBox(Lr.node().parentNode);Ln=Math.min(Ln,br.top),Bn=Math.max(Bn,br.bottom),jn=Math.min(jn,br.left),Un=Math.max(Un,br.right)})):(Ln=0,Bn=0,jn=0,Un=0),{top:Ln,bottom:Bn,left:jn,right:Un,height:Bn-Ln,width:Un-jn}}(_e,on)),Et[on]}},Q.getTickSigns=function(ve,_e){var Ve=ve._id.charAt(0),We={x:"top",y:"right"}[Ve],Ze=ve.side===We?1:-1,Ge=[-1,1,Ze,-Ze];return(_e?(ve.minor||{}).ticks:ve.ticks)!=="inside"==(Ve==="x")&&(Ge=Ge.map(function(Ke){return-Ke})),ve.side&&Ge.push({l:-1,t:-1,r:1,b:1}[ve.side.charAt(0)]),Ge},Q.makeTransTickFn=function(ve){return ve._id.charAt(0)==="x"?function(_e){return h(ve._offset+ve.l2p(_e.x),0)}:function(_e){return h(0,ve._offset+ve.l2p(_e.x))}},Q.makeTransTickLabelFn=function(ve){var _e=function(Ze){var Ge=Ze.ticklabelposition||"",Ke=function(ht){return Ge.indexOf(ht)!==-1},nt=Ke("top"),st=Ke("left"),mt=Ke("right"),tt=Ke("bottom"),Ft=Ke("inside"),Vt=tt||st||nt||mt;if(!Vt&&!Ft)return[0,0];var St=Ze.side,Nt=Vt?(Ze.tickwidth||0)/2:0,Dt=3,gt=Ze.tickfont?Ze.tickfont.size:12;return(tt||nt)&&(Nt+=gt*te,Dt+=(Ze.linewidth||0)/2),(st||mt)&&(Nt+=(Ze.linewidth||0)/2,Dt+=3),Ft&&St==="top"&&(Dt-=gt*(1-te)),(st||nt)&&(Nt=-Nt),St!=="bottom"&&St!=="right"||(Dt=-Dt),[Vt?Nt:0,Ft?Dt:0]}(ve),Ve=_e[0],We=_e[1];return ve._id.charAt(0)==="x"?function(Ze){return h(Ve+ve._offset+ve.l2p(at(Ze)),We)}:function(Ze){return h(We,Ve+ve._offset+ve.l2p(at(Ze)))}},Q.makeTickPath=function(ve,_e,Ve,We){We||(We={});var Ze=We.minor;if(Ze&&!ve.minor)return"";var Ge=We.len!==void 0?We.len:Ze?ve.minor.ticklen:ve.ticklen,Ke=ve._id.charAt(0),nt=(ve.linewidth||1)/2;return Ke==="x"?"M0,"+(_e+nt*Ve)+"v"+Ge*Ve:"M"+(_e+nt*Ve)+",0h"+Ge*Ve},Q.makeLabelFns=function(ve,_e,Ve){var We=ve.ticklabelposition||"",Ze=function($t){return We.indexOf($t)!==-1},Ge=Ze("top"),Ke=Ze("left"),nt=Ze("right"),st=Ze("bottom")||Ke||Ge||nt,mt=Ze("inside"),tt=We==="inside"&&ve.ticks==="inside"||!mt&&ve.ticks==="outside"&&ve.tickson!=="boundaries",Ft=0,Vt=0,St=tt?ve.ticklen:0;if(mt?St*=-1:st&&(St=0),tt&&(Ft+=St,Ve)){var Nt=d.deg2rad(Ve);Ft=St*Math.cos(Nt)+1,Vt=St*Math.sin(Nt)}ve.showticklabels&&(tt||ve.showline)&&(Ft+=.2*ve.tickfont.size);var Dt,gt,ht,yt,qt,Et={labelStandoff:Ft+=(ve.linewidth||1)/2*(mt?-1:1),labelShift:Vt},jt=0,Tt=ve.side,Ot=ve._id.charAt(0),At=ve.tickangle;if(Ot==="x")yt=(qt=!mt&&Tt==="bottom"||mt&&Tt==="top")?1:-1,mt&&(yt*=-1),Dt=Vt*yt,gt=_e+Ft*yt,ht=qt?1:-.2,Math.abs(At)===90&&(mt?ht+=V:ht=At===-90&&Tt==="bottom"?te:At===90&&Tt==="top"?V:.5,jt=V/2*(At/90)),Et.xFn=function($t){return $t.dx+Dt+jt*$t.fontSize},Et.yFn=function($t){return $t.dy+gt+$t.fontSize*ht},Et.anchorFn=function($t,Yt){if(st){if(Ke)return"end";if(nt)return"start"}return f(Yt)&&Yt!==0&&Yt!==180?Yt*yt<0!==mt?"end":"start":"middle"},Et.heightFn=function($t,Yt,Xt){return Yt<-60||Yt>60?-.5*Xt:ve.side==="top"!==mt?-Xt:0};else if(Ot==="y"){if(yt=(qt=!mt&&Tt==="left"||mt&&Tt==="right")?1:-1,mt&&(yt*=-1),Dt=Ft,gt=Vt*yt,ht=0,mt||Math.abs(At)!==90||(ht=At===-90&&Tt==="left"||At===90&&Tt==="right"?te:.5),mt){var Lt=f(At)?+At:0;if(Lt!==0){var Rt=d.deg2rad(Lt);jt=Math.abs(Math.sin(Rt))*te*yt,ht=0}}Et.xFn=function($t){return $t.dx+_e-(Dt+$t.fontSize*ht)*yt+jt*$t.fontSize},Et.yFn=function($t){return $t.dy+gt+$t.fontSize*V},Et.anchorFn=function($t,Yt){return f(Yt)&&Math.abs(Yt)===90?"middle":qt?"end":"start"},Et.heightFn=function($t,Yt,Xt){return ve.side==="right"&&(Yt*=-1),Yt<-30?-Xt:Yt<30?-.5*Xt:0}}return Et},Q.drawTicks=function(ve,_e,Ve){Ve=Ve||{};var We=_e._id+"tick",Ze=[].concat(_e.minor&&_e.minor.ticks?Ve.vals.filter(function(Ke){return Ke.minor&&!Ke.noTick}):[]).concat(_e.ticks?Ve.vals.filter(function(Ke){return!Ke.minor&&!Ke.noTick}):[]),Ge=Ve.layer.selectAll("path."+We).data(Ze,lt);Ge.exit().remove(),Ge.enter().append("path").classed(We,1).classed("ticks",1).classed("crisp",Ve.crisp!==!1).each(function(Ke){return y.stroke(l.select(this),Ke.minor?_e.minor.tickcolor:_e.tickcolor)}).style("stroke-width",function(Ke){return v.crispRound(ve,Ke.minor?_e.minor.tickwidth:_e.tickwidth,1)+"px"}).attr("d",Ve.path).style("display",null),zt(_e,[G]),Ge.attr("transform",Ve.transFn)},Q.drawGrid=function(ve,_e,Ve){if(Ve=Ve||{},_e.tickmode!=="sync"){var We=_e._id+"grid",Ze=_e.minor&&_e.minor.showgrid,Ge=Ze?Ve.vals.filter(function(ht){return ht.minor}):[],Ke=_e.showgrid?Ve.vals.filter(function(ht){return!ht.minor}):[],nt=Ve.counterAxis;if(nt&&Q.shouldShowZeroLine(ve,_e,nt))for(var st=_e.tickmode==="array",mt=0;mt=0;Nt--){var Dt=Nt?Vt:St;if(Dt){var gt=Dt.selectAll("path."+We).data(Nt?Ke:Ge,lt);gt.exit().remove(),gt.enter().append("path").classed(We,1).classed("crisp",Ve.crisp!==!1),gt.attr("transform",Ve.transFn).attr("d",Ve.path).each(function(ht){return y.stroke(l.select(this),ht.minor?_e.minor.gridcolor:_e.gridcolor||"#ddd")}).style("stroke-dasharray",function(ht){return v.dashStyle(ht.minor?_e.minor.griddash:_e.griddash,ht.minor?_e.minor.gridwidth:_e.gridwidth)}).style("stroke-width",function(ht){return(ht.minor?Ft:_e._gw)+"px"}).style("display",null),typeof Ve.path=="function"&>.attr("d",Ve.path)}}zt(_e,[E,W])}},Q.drawZeroLine=function(ve,_e,Ve){Ve=Ve||Ve;var We=_e._id+"zl",Ze=Q.shouldShowZeroLine(ve,_e,Ve.counterAxis),Ge=Ve.layer.selectAll("path."+We).data(Ze?[{x:0,id:_e._id}]:[]);Ge.exit().remove(),Ge.enter().append("path").classed(We,1).classed("zl",1).classed("crisp",Ve.crisp!==!1).each(function(){Ve.layer.selectAll("path").sort(function(Ke,nt){return X(Ke.id,nt.id)})}),Ge.attr("transform",Ve.transFn).attr("d",Ve.path).call(y.stroke,_e.zerolinecolor||y.defaultLine).style("stroke-width",v.crispRound(ve,_e.zerolinewidth,_e._gw||1)+"px").style("display",null),zt(_e,[N])},Q.drawLabels=function(ve,_e,Ve){Ve=Ve||{};var We=ve._fullLayout,Ze=_e._id,Ge=Ze.charAt(0),Ke=Ve.cls||Ze+"tick",nt=Ve.vals.filter(function(yt){return yt.text}),st=Ve.labelFns,mt=Ve.secondary?0:_e.tickangle,tt=(_e._prevTickAngles||{})[Ke],Ft=Ve.layer.selectAll("g."+Ke).data(_e.showticklabels?nt:[],lt),Vt=[];function St(yt,qt){yt.each(function(Et){var jt=l.select(this),Tt=jt.select(".text-math-group"),Ot=st.anchorFn(Et,qt),At=Ve.transFn.call(jt.node(),Et)+(f(qt)&&+qt!=0?" rotate("+qt+","+st.xFn(Et)+","+(st.yFn(Et)-Et.fontSize/2)+")":""),Lt=p.lineCount(jt),Rt=ee*Et.fontSize,$t=st.heightFn(Et,f(qt)?+qt:0,(Lt-1)*Rt);if($t&&(At+=h(0,$t)),Tt.empty()){var Yt=jt.select("text");Yt.attr({transform:At,"text-anchor":Ot}),Yt.style("opacity",1),_e._adjustTickLabelsOverflow&&_e._adjustTickLabelsOverflow()}else{var Xt=v.bBox(Tt.node()).width*{end:-.5,start:.5}[Ot];Tt.attr("transform",At+h(Xt,0))}})}Ft.enter().append("g").classed(Ke,1).append("text").attr("text-anchor","middle").each(function(yt){var qt=l.select(this),Et=ve._promises.length;qt.call(p.positionText,st.xFn(yt),st.yFn(yt)).call(v.font,yt.font,yt.fontSize,yt.fontColor).text(yt.text).call(p.convertToTspans,ve),ve._promises[Et]?Vt.push(ve._promises.pop().then(function(){St(qt,mt)})):St(qt,mt)}),zt(_e,[L]),Ft.exit().remove(),Ve.repositionOnUpdate&&Ft.each(function(yt){l.select(this).select("text").call(p.positionText,st.xFn(yt),st.yFn(yt))}),_e._adjustTickLabelsOverflow=function(){var yt=_e.ticklabeloverflow;if(yt&&yt!=="allow"){var qt=yt.indexOf("hide")!==-1,Et=_e._id.charAt(0)==="x",jt=0,Tt=Et?ve._fullLayout.width:ve._fullLayout.height;if(yt.indexOf("domain")!==-1){var Ot=d.simpleMap(_e.range,_e.r2l);jt=_e.l2p(Ot[0])+_e._offset,Tt=_e.l2p(Ot[1])+_e._offset}var At=Math.min(jt,Tt),Lt=Math.max(jt,Tt),Rt=_e.side,$t=1/0,Yt=-1/0;for(var Xt in Ft.each(function(tn){var cn=l.select(this);if(cn.select(".text-math-group").empty()){var ln=v.bBox(cn.node()),an=0;Et?(ln.right>Lt||ln.leftLt||ln.top+(_e.tickangle?0:tn.fontSize/4)_e["_visibleLabelMin_"+Ot._id]?Wt.style("display","none"):Lt.K!=="tick"||At||Wt.style("display",null)})})})})},St(Ft,tt+1?tt:mt);var Nt=null;_e._selections&&(_e._selections[Ke]=Ft);var Dt=[function(){return Vt.length&&Promise.all(Vt)}];_e.automargin&&We._redrawFromAutoMarginCount&&tt===90?(Nt=90,Dt.push(function(){St(Ft,tt)})):Dt.push(function(){if(St(Ft,mt),nt.length&&Ge==="x"&&!f(mt)&&(_e.type!=="log"||String(_e.dtick).charAt(0)!=="D")){Nt=0;var yt,qt=0,Et=[];if(Ft.each(function(cn){qt=Math.max(qt,cn.fontSize);var ln=_e.l2p(cn.x),an=ze(this),sn=v.bBox(an.node());Et.push({top:0,bottom:10,height:10,left:ln-sn.width/2,right:ln+sn.width/2+2,width:sn.width+2})}),_e.tickson!=="boundaries"&&!_e.showdividers||Ve.secondary){var jt=nt.length,Tt=Math.abs((nt[jt-1].x-nt[0].x)*_e._m)/(jt-1),Ot=_e.ticklabelposition||"",At=function(cn){return Ot.indexOf(cn)!==-1},Lt=At("top"),Rt=At("left"),$t=At("right"),Yt=At("bottom")||Rt||Lt||$t?(_e.tickwidth||0)+6:0,Xt=Tt<2.5*qt||_e.type==="multicategory"||_e._name==="realaxis";for(yt=0;yt1)for(nt=1;nt2*R}(x,m))return"date";var M=b.autotypenumbers!=="strict";return function(S,C){for(var P=S.length,D=y(P),O=0,R=0,F={},A=0;A2*O}(x,M)?"category":function(S,C){for(var P=S.length,D=0;D
=2){var F,A,z="";if(R.length===2){for(F=0;F<2;F++)if(A=S(R[F])){z=w;break}}var B=O("pattern",z);if(B===w)for(F=0;F<2;F++)(A=S(R[F]))&&(P.bounds[F]=R[F]=A-1);if(B)for(F=0;F<2;F++)switch(A=R[F],B){case w:if(!l(A)||(A=+A)!==Math.floor(A)||A<0||A>=7)return void(P.enabled=!1);P.bounds[F]=R[F]=A;break;case k:if(!l(A)||(A=+A)<0||A>24)return void(P.enabled=!1);P.bounds[F]=R[F]=A}if(D.autorange===!1){var $=D.range;if($[0]<$[1]){if(R[0]<$[0]&&R[1]>$[1])return void(P.enabled=!1)}else if(R[0]>$[0]&&R[1]<$[1])return void(P.enabled=!1)}}else{var j=O("values");if(!j||!j.length)return void(P.enabled=!1);O("dvalue")}}}o.exports=function(C,P,D,O,R){var F,A=O.letter,z=O.font||{},B=O.splomStash||{},$=D("visible",!O.visibleDflt),j=P._template||{},N=P.type||j.type||"-";N==="date"&&(f.getComponentMethod("calendars","handleDefaults")(C,P,"calendar",O.calendar),O.noTicklabelmode||(F=D("ticklabelmode")));var E="";O.noTicklabelposition&&N!=="multicategory"||(E=s.coerce(C,P,{ticklabelposition:{valType:"enumerated",dflt:"outside",values:F==="period"?["outside","inside"]:A==="x"?["outside","inside","outside left","inside left","outside right","inside right"]:["outside","inside","outside top","inside top","outside bottom","inside bottom"]}},"ticklabelposition")),O.noTicklabeloverflow||D("ticklabeloverflow",E.indexOf("inside")!==-1?"hide past domain":N==="category"||N==="multicategory"?"allow":"hide past div"),_(P,R),x(C,P,D,O),m(C,P,D,O),N==="category"||O.noHover||D("hoverformat");var W=D("color"),G=W!==h.color.dflt?W:z.color,L=B.label||R._dfltTitle[A];if(v(C,P,D,N,O),!$)return P;D("title.text",L),s.coerceFont(D,"title.font",{family:z.family,size:s.bigFont(z.size),color:G}),p(C,P,D,N);var q=O.hasMinor;if(q&&(u.newContainer(P,"minor"),p(C,P,D,N,{isMinor:!0})),y(C,P,D,N,O),g(C,P,D,O),q){var H=O.isMinor;O.isMinor=!0,g(C,P,D,O),O.isMinor=H}b(C,P,D,{dfltColor:W,bgColor:O.bgColor,showGrid:O.showGrid,hasMinor:q,attributes:h}),!q||P.minor.ticks||P.minor.showgrid||delete P.minor,(P.showline||P.ticks)&&D("mirror");var V,te=N==="multicategory";if(O.noTickson||N!=="category"&&!te||!P.ticks&&!P.showgrid||(te&&(V="boundaries"),D("tickson",V)==="boundaries"&&delete P.ticklabelposition),te&&D("showdividers")&&(D("dividercolor"),D("dividerwidth")),N==="date")if(d(C,P,{name:"rangebreaks",inclusionAttr:"enabled",handleItemDefaults:T}),P.rangebreaks.length){for(var ee=0;ee
p?1:-1:+(u.substr(1)||1)-+(d.substr(1)||1)},a.ref2id=function(u){return!!/^[xyz]/.test(u)&&u.split(" ")[0]},a.isLinked=function(u,d){return s(d,u._axisMatchGroups)||s(d,u._axisConstraintGroups)}},15258:function(o){o.exports=function(a,n,l,f){if(n.type==="category"){var s,u=a.categoryarray,d=Array.isArray(u)&&u.length>0;d&&(s="array");var h,p=l("categoryorder",s);p==="array"&&(h=l("categoryarray")),d||p!=="array"||(p=n.categoryorder="trace"),p==="trace"?n._initialCategories=[]:p==="array"?n._initialCategories=h.slice():(h=function(g,y){var v,m,b,x=y.dataAttr||g._id.charAt(0),_={};if(y.axData)v=y.axData;else for(v=[],m=0;mS?C.substr(S):P.substr(M))+D:C+P+k*T:D}function _(k,T){for(var M=T._size,S=M.h/M.w,C={},P=Object.keys(k),D=0;Dp*$)||W){for(M=0;MY&&ieU&&(U=ie);R/=(U-ee)/(2*Q),ee=P.l2r(ee),U=P.l2r(U),P.range=P._input.range=H=0?Math.min(ie,.9):1/(1/Math.max(ie,-.3)+3.222))}function H(ie,le,se,pe,Te){return ie.append("path").attr("class","zoombox").style({fill:le>.2?"rgba(0,0,0,0)":"rgba(255,255,255,0)","stroke-width":0}).attr("transform",p(se,pe)).attr("d",Te+"Z")}function V(ie,le,se){return ie.append("path").attr("class","zoombox-corners").style({fill:y.background,stroke:y.defaultLine,"stroke-width":1,opacity:0}).attr("transform",p(le,se)).attr("d","M0,0Z")}function te(ie,le,se,pe,Te,Se){ie.attr("d",pe+"M"+se.l+","+se.t+"v"+se.h+"h"+se.w+"v-"+se.h+"h-"+se.w+"Z"),ee(ie,le,Te,Se)}function ee(ie,le,se,pe){se||(ie.transition().style("fill",pe>.2?"rgba(0,0,0,0.4)":"rgba(255,255,255,0.3)").duration(200),le.transition().style("opacity",1).duration(200))}function U(ie){l.select(ie).selectAll(".zoombox,.js-zoombox-backdrop,.js-zoombox-menu,.zoombox-corners").remove()}function Q(ie){j&&ie.data&&ie._context.showTips&&(f.notifier(f._(ie,"Double-click to zoom back out"),"long"),j=!1)}function Y(ie){var le=Math.floor(Math.min(ie.b-ie.t,ie.r-ie.l,$)/2);return"M"+(ie.l-3.5)+","+(ie.t-.5+le)+"h3v"+-le+"h"+le+"v-3h-"+(le+3)+"ZM"+(ie.r+3.5)+","+(ie.t-.5+le)+"h-3v"+-le+"h"+-le+"v-3h"+(le+3)+"ZM"+(ie.r+3.5)+","+(ie.b+.5-le)+"h-3v"+le+"h"+-le+"v3h"+(le+3)+"ZM"+(ie.l-3.5)+","+(ie.b+.5-le)+"h3v"+le+"h"+le+"v3h-"+(le+3)+"Z"}function Z(ie,le,se,pe,Te){for(var Se,Oe,Me,ce,ye=!1,J={},ne={},de=(Te||{}).xaHash,xe=(Te||{}).yaHash,ue=0;ue=0)At._fullLayout._deactivateShape(At);else{var Lt=At._fullLayout.clickmode;if(U(At),Tt!==2||Ne||gt(),ze)Lt.indexOf("select")>-1&&F(Ot,At,de,xe,le.id,We),Lt.indexOf("event")>-1&&m.click(At,Ot,le.id);else if(Tt===1&&Ne){var Rt=Oe?ye:ce,$t=Oe==="s"||Me==="w"?0:1,Yt=Rt._name+".range["+$t+"]",Xt=function(tn,cn){var ln,an=tn.range[cn],sn=Math.abs(an-tn.range[1-cn]);return tn.type==="date"?an:tn.type==="log"?(ln=Math.ceil(Math.max(0,-Math.log(sn)/Math.LN10))+3,s("."+ln+"g")(Math.pow(10,an))):(ln=Math.floor(Math.log(Math.abs(an))/Math.LN10)-Math.floor(Math.log(sn)/Math.LN10)+4,s("."+String(ln)+"g")(an))}(Rt,$t),Bt="left",Wt="middle";if(Rt.fixedrange)return;Oe?(Wt=Oe==="n"?"top":"bottom",Rt.side==="right"&&(Bt="right")):Me==="e"&&(Bt="right"),At._context.showAxisRangeEntryBoxes&&l.select(kt).call(g.makeEditable,{gd:At,immediate:!0,background:At._fullLayout.paper_bgcolor,text:String(Xt),fill:Rt.tickfont?Rt.tickfont.color:"#444",horizontalAlign:Bt,verticalAlign:Wt}).on("edit",function(tn){var cn=Rt.d2r(tn);cn!==void 0&&h.call("_guiRelayout",At,Yt,cn)})}}}function Ke(Tt,Ot){if(ie._transitioningWithDuration)return!1;var At=Math.max(0,Math.min(be,lt*Tt+Je)),Lt=Math.max(0,Math.min(we,ct*Ot+ut)),Rt=Math.abs(At-Je),$t=Math.abs(Lt-ut);function Yt(){wt="",pt.r=pt.l,pt.t=pt.b,_e.attr("d","M0,0Z")}if(pt.l=Math.min(Je,At),pt.r=Math.max(Je,At),pt.t=Math.min(ut,Lt),pt.b=Math.max(ut,Lt),ke.isSubplotConstrained)Rt>$||$t>$?(wt="xy",Rt/be>$t/we?($t=Rt*we/be,ut>Lt?pt.t=ut-$t:pt.b=ut+$t):(Rt=$t*be/we,Je>At?pt.l=Je-Rt:pt.r=Je+Rt),_e.attr("d",Y(pt))):Yt();else if(Ae.isSubplotConstrained)if(Rt>$||$t>$){wt="xy";var Xt=Math.min(pt.l/be,(we-pt.b)/we),Bt=Math.max(pt.r/be,(we-pt.t)/we);pt.l=Xt*be,pt.r=Bt*be,pt.b=(1-Xt)*we,pt.t=(1-Bt)*we,_e.attr("d",Y(pt))}else Yt();else!De||$t0){var Wt;if(Ae.isSubplotConstrained||!Ee&&De.length===1){for(Wt=0;Wt1&&(Lt.maxallowed!==void 0&&Ie===(Lt.range[0]1&&(Rt.maxallowed!==void 0&&Be===(Rt.range[0]P[1]-.000244140625&&(u.domain=g),f.noneOrAll(s.domain,u.domain,g),u.tickmode==="sync"&&(u.tickmode="auto")}return d("layer"),u}},89426:function(o,a,n){var l=n(59652);o.exports=function(f,s,u,d,h){h||(h={});var p=h.tickSuffixDflt,g=l(f);u("tickprefix")&&u("showtickprefix",g),u("ticksuffix",p)&&u("showticksuffix",g)}},23608:function(o,a,n){var l=n(23074);o.exports=function(f,s,u,d){var h=s._template||{},p=s.type||h.type||"-";u("minallowed"),u("maxallowed");var g,y=u("range"),v=s.getAutorangeDflt(y,d),m=u("autorange",v);!y||(y[0]!==null||y[1]!==null)&&(y[0]!==null&&y[1]!==null||m!=="reversed"&&m!==!0)&&(y[0]===null||m!=="min"&&m!=="max reversed")&&(y[1]===null||m!=="max"&&m!=="min reversed")||(y=void 0,delete s.range,s.autorange=!0,g=!0),g||(m=u("autorange",v=s.getAutorangeDflt(y,d))),m&&(l(u,m,y),p!=="linear"&&p!=="-"||u("rangemode")),s.cleanRange()}},42449:function(o,a,n){var l=n(18783).FROM_BL;o.exports=function(f,s,u){u===void 0&&(u=l[f.constraintoward||"center"]);var d=[f.r2l(f.range[0]),f.r2l(f.range[1])],h=d[0]+(d[1]-d[0])*u;f.range=f._input.range=[f.l2r(h+(d[0]-h)*s),f.l2r(h+(d[1]-h)*s)],f.setScale()}},21994:function(o,a,n){var l=n(39898),f=n(84096).g0,s=n(71828),u=s.numberFormat,d=n(92770),h=s.cleanNumber,p=s.ms2DateTime,g=s.dateTime2ms,y=s.ensureNumber,v=s.isArrayOrTypedArray,m=n(50606),b=m.FP_SAFE,x=m.BADNUM,_=m.LOG_CLIP,w=m.ONEWEEK,k=m.ONEDAY,T=m.ONEHOUR,M=m.ONEMIN,S=m.ONESEC,C=n(41675),P=n(85555),D=P.HOUR_PATTERN,O=P.WEEKDAY_PATTERN;function R(A){return Math.pow(10,A)}function F(A){return A!=null}o.exports=function(A,z){z=z||{};var B=A._id||"x",$=B.charAt(0);function j(Z,X){if(Z>0)return Math.log(Z)/Math.LN10;if(Z<=0&&X&&A.range&&A.range.length===2){var re=A.range[0],ie=A.range[1];return .5*(re+ie-2*_*Math.abs(re-ie))}return x}function N(Z,X,re,ie){if((ie||{}).msUTC&&d(Z))return+Z;var le=g(Z,re||A.calendar);if(le===x){if(!d(Z))return x;Z=+Z;var se=Math.floor(10*s.mod(Z+.05,1)),pe=Math.round(Z-se/10);le=g(new Date(pe))+se/10}return le}function E(Z,X,re){return p(Z,X,re||A.calendar)}function W(Z){return A._categories[Math.round(Z)]}function G(Z){if(F(Z)){if(A._categoriesMap===void 0&&(A._categoriesMap={}),A._categoriesMap[Z]!==void 0)return A._categoriesMap[Z];A._categories.push(typeof Z=="number"?String(Z):Z);var X=A._categories.length-1;return A._categoriesMap[Z]=X,X}return x}function L(Z){if(A._categoriesMap)return A._categoriesMap[Z]}function q(Z){var X=L(Z);return X!==void 0?X:d(Z)?+Z:void 0}function H(Z){return d(Z)?+Z:L(Z)}function V(Z,X,re){return l.round(re+X*Z,2)}function te(Z,X,re){return(Z-re)/X}var ee=function(Z){return d(Z)?V(Z,A._m,A._b):x},U=function(Z){return te(Z,A._m,A._b)};if(A.rangebreaks){var Q=$==="y";ee=function(Z){if(!d(Z))return x;var X=A._rangebreaks.length;if(!X)return V(Z,A._m,A._b);var re=Q;A.range[0]>A.range[1]&&(re=!re);for(var ie=re?-1:1,le=ie*Z,se=0,pe=0;peSe)){se=le<(Te+Se)/2?pe:pe+1;break}se=pe+1}var Oe=A._B[se]||0;return isFinite(Oe)?V(Z,A._m2,Oe):0},U=function(Z){var X=A._rangebreaks.length;if(!X)return te(Z,A._m,A._b);for(var re=0,ie=0;ieA._rangebreaks[ie].pmax&&(re=ie+1);return te(Z,A._m2,A._B[re])}}A.c2l=A.type==="log"?j:y,A.l2c=A.type==="log"?R:y,A.l2p=ee,A.p2l=U,A.c2p=A.type==="log"?function(Z,X){return ee(j(Z,X))}:ee,A.p2c=A.type==="log"?function(Z){return R(U(Z))}:U,["linear","-"].indexOf(A.type)!==-1?(A.d2r=A.r2d=A.d2c=A.r2c=A.d2l=A.r2l=h,A.c2d=A.c2r=A.l2d=A.l2r=y,A.d2p=A.r2p=function(Z){return A.l2p(h(Z))},A.p2d=A.p2r=U,A.cleanPos=y):A.type==="log"?(A.d2r=A.d2l=function(Z,X){return j(h(Z),X)},A.r2d=A.r2c=function(Z){return R(h(Z))},A.d2c=A.r2l=h,A.c2d=A.l2r=y,A.c2r=j,A.l2d=R,A.d2p=function(Z,X){return A.l2p(A.d2r(Z,X))},A.p2d=function(Z){return R(U(Z))},A.r2p=function(Z){return A.l2p(h(Z))},A.p2r=U,A.cleanPos=y):A.type==="date"?(A.d2r=A.r2d=s.identity,A.d2c=A.r2c=A.d2l=A.r2l=N,A.c2d=A.c2r=A.l2d=A.l2r=E,A.d2p=A.r2p=function(Z,X,re){return A.l2p(N(Z,0,re))},A.p2d=A.p2r=function(Z,X,re){return E(U(Z),X,re)},A.cleanPos=function(Z){return s.cleanDate(Z,x,A.calendar)}):A.type==="category"?(A.d2c=A.d2l=G,A.r2d=A.c2d=A.l2d=W,A.d2r=A.d2l_noadd=q,A.r2c=function(Z){var X=H(Z);return X!==void 0?X:A.fraction2r(.5)},A.l2r=A.c2r=y,A.r2l=H,A.d2p=function(Z){return A.l2p(A.r2c(Z))},A.p2d=function(Z){return W(U(Z))},A.r2p=A.d2p,A.p2r=U,A.cleanPos=function(Z){return typeof Z=="string"&&Z!==""?Z:y(Z)}):A.type==="multicategory"&&(A.r2d=A.c2d=A.l2d=W,A.d2r=A.d2l_noadd=q,A.r2c=function(Z){var X=q(Z);return X!==void 0?X:A.fraction2r(.5)},A.r2c_just_indices=L,A.l2r=A.c2r=y,A.r2l=q,A.d2p=function(Z){return A.l2p(A.r2c(Z))},A.p2d=function(Z){return W(U(Z))},A.r2p=A.d2p,A.p2r=U,A.cleanPos=function(Z){return Array.isArray(Z)||typeof Z=="string"&&Z!==""?Z:y(Z)},A.setupMultiCategory=function(Z){var X,re,ie=A._traceIndices,le=A._matchGroup;if(le&&A._categories.length===0){for(var se in le)if(se!==B){var pe=z[C.id2name(se)];ie=ie.concat(pe._traceIndices)}}var Te=[[0,{}],[0,{}]],Se=[];for(X=0;Xpe[1]&&(ie[se?0:1]=re)}},A.cleanRange=function(Z,X){A._cleanRange(Z,X),A.limitRange(Z)},A._cleanRange=function(Z,X){X||(X={}),Z||(Z="range");var re,ie,le=s.nestedProperty(A,Z).get();if(ie=(ie=A.type==="date"?s.dfltRange(A.calendar):$==="y"?P.DFLTRANGEY:A._name==="realaxis"?[0,1]:X.dfltRange||P.DFLTRANGEX).slice(),A.rangemode!=="tozero"&&A.rangemode!=="nonnegative"||(ie[0]=0),le&&le.length===2){var se=le[0]===null,pe=le[1]===null;for(A.type!=="date"||A.autorange||(le[0]=s.cleanDate(le[0],x,A.calendar),le[1]=s.cleanDate(le[1],x,A.calendar)),re=0;re<2;re++)if(A.type==="date"){if(!s.isDateTime(le[re],A.calendar)){A[Z]=ie;break}if(A.r2l(le[0])===A.r2l(le[1])){var Te=s.constrain(A.r2l(le[0]),s.MIN_MS+1e3,s.MAX_MS-1e3);le[0]=A.l2r(Te-1e3),le[1]=A.l2r(Te+1e3);break}}else{if(!d(le[re])){if(se||pe||!d(le[1-re])){A[Z]=ie;break}le[re]=le[1-re]*(re?10:.1)}if(le[re]<-b?le[re]=-b:le[re]>b&&(le[re]=b),le[0]===le[1]){var Se=Math.max(1,Math.abs(1e-6*le[0]));le[0]-=Se,le[1]+=Se}}}else s.nestedProperty(A,Z).set(ie)},A.setScale=function(Z){var X=z._size;if(A.overlaying){var re=C.getFromId({_fullLayout:z},A.overlaying);A.domain=re.domain}var ie=Z&&A._r?"_r":"range",le=A.calendar;A.cleanRange(ie);var se,pe,Te=A.r2l(A[ie][0],le),Se=A.r2l(A[ie][1],le),Oe=$==="y";if(Oe?(A._offset=X.t+(1-A.domain[1])*X.h,A._length=X.h*(A.domain[1]-A.domain[0]),A._m=A._length/(Te-Se),A._b=-A._m*Se):(A._offset=X.l+A.domain[0]*X.w,A._length=X.w*(A.domain[1]-A.domain[0]),A._m=A._length/(Se-Te),A._b=-A._m*Te),A._rangebreaks=[],A._lBreaks=0,A._m2=0,A._B=[],A.rangebreaks&&(A._rangebreaks=A.locateBreaks(Math.min(Te,Se),Math.max(Te,Se)),A._rangebreaks.length)){for(se=0;seSe&&(Me=!Me),Me&&A._rangebreaks.reverse();var ce=Me?-1:1;for(A._m2=ce*A._length/(Math.abs(Se-Te)-A._lBreaks),A._B.push(-A._m2*(Oe?Se:Te)),se=0;seie&&(ie+=7,leie&&(ie+=24,le=re&&le=re&&Z=Ae.min&&(geAe.max&&(Ae.max=be),we=!1)}we&&pe.push({min:ge,max:be})}};for(re=0;reg.duration?(function(){for(var D={},O=0;O rect").call(u.setTranslate,0,0).call(u.setScale,1,1),M.plot.call(u.setTranslate,S._offset,C._offset).call(u.setScale,1,1);var P=M.plot.selectAll(".scatterlayer .trace");P.selectAll(".point").call(u.setPointGroupScale,1,1),P.selectAll(".textpoint").call(u.setTextPointsScale,1,1),P.call(u.hideOutsideRangePoints,M)}function T(M,S){var C=M.plotinfo,P=C.xaxis,D=C.yaxis,O=P._length,R=D._length,F=!!M.xr1,A=!!M.yr1,z=[];if(F){var B=s.simpleMap(M.xr0,P.r2l),$=s.simpleMap(M.xr1,P.r2l),j=B[1]-B[0],N=$[1]-$[0];z[0]=(B[0]*(1-S)+S*$[0]-B[0])/(B[1]-B[0])*O,z[2]=O*(1-S+S*N/j),P.range[0]=P.l2r(B[0]*(1-S)+S*$[0]),P.range[1]=P.l2r(B[1]*(1-S)+S*$[1])}else z[0]=0,z[2]=O;if(A){var E=s.simpleMap(M.yr0,D.r2l),W=s.simpleMap(M.yr1,D.r2l),G=E[1]-E[0],L=W[1]-W[0];z[1]=(E[1]*(1-S)+S*W[1]-E[1])/(E[0]-E[1])*R,z[3]=R*(1-S+S*L/G),D.range[0]=P.l2r(E[0]*(1-S)+S*W[0]),D.range[1]=D.l2r(E[1]*(1-S)+S*W[1])}else z[1]=0,z[3]=R;d.drawOne(h,P,{skipTitle:!0}),d.drawOne(h,D,{skipTitle:!0}),d.redrawComponents(h,[P._id,D._id]);var q=F?O/z[2]:1,H=A?R/z[3]:1,V=F?z[0]:0,te=A?z[1]:0,ee=F?z[0]/z[2]*O:0,U=A?z[1]/z[3]*R:0,Q=P._offset-ee,Y=D._offset-U;C.clipRect.call(u.setTranslate,V,te).call(u.setScale,1/q,1/H),C.plot.call(u.setTranslate,Q,Y).call(u.setScale,q,H),u.setPointGroupScale(C.zoomScalePts,1/q,1/H),u.setTextPointsScale(C.zoomScaleTxt,1/q,1/H)}d.redrawComponents(h)}},951:function(o,a,n){var l=n(73972).traceIs,f=n(4322);function s(d){return{v:"x",h:"y"}[d.orientation||"v"]}function u(d,h){var p=s(d),g=l(d,"box-violin"),y=l(d._fullInput||{},"candlestick");return g&&!y&&h===p&&d[p]===void 0&&d[p+"0"]===void 0}o.exports=function(d,h,p,g){p("autotypenumbers",g.autotypenumbersDflt),p("type",(g.splomStash||{}).type)==="-"&&(function(y,v){if(y.type==="-"){var m,b=y._id,x=b.charAt(0);b.indexOf("scene")!==-1&&(b=x);var _=function(D,O,R){for(var F=0;F0&&(A["_"+R+"axes"]||{})[O]||(A[R+"axis"]||R)===O&&(u(A,R)||(A[R]||[]).length||A[R+"0"]))return A}}(v,b,x);if(_)if(_.type!=="histogram"||x!=={v:"y",h:"x"}[_.orientation||"v"]){var w=x+"calendar",k=_[w],T={noMultiCategory:!l(_,"cartesian")||l(_,"noMultiCategory")};if(_.type==="box"&&_._hasPreCompStats&&x==={h:"x",v:"y"}[_.orientation||"v"]&&(T.noMultiCategory=!0),T.autotypenumbers=y.autotypenumbers,u(_,x)){var M=s(_),S=[];for(m=0;m0?".":"")+m;f.isPlainObject(b)?h(b,g,x,v+1):g(x,m,b)}})}a.manageCommandObserver=function(p,g,y,v){var m={},b=!0;g&&g._commandObserver&&(m=g._commandObserver),m.cache||(m.cache={}),m.lookupTable={};var x=a.hasSimpleAPICommandBindings(p,y,m.lookupTable);if(g&&g._commandObserver){if(x)return m;if(g._commandObserver.remove)return g._commandObserver.remove(),g._commandObserver=null,m}if(x){s(p,x,m.cache),m.check=function(){if(b){var k=s(p,x,m.cache);return k.changed&&v&&m.lookupTable[k.value]!==void 0&&(m.disable(),Promise.resolve(v({value:k.value,type:x.type,prop:x.prop,traces:x.traces,index:m.lookupTable[k.value]})).then(m.enable,m.enable)),k.changed}};for(var _=["plotly_relayout","plotly_redraw","plotly_restyle","plotly_update","plotly_animatingframe","plotly_afterplot"],w=0;w<_.length;w++)p._internalOn(_[w],m.check);m.remove=function(){for(var k=0;k<_.length;k++)p._removeInternalListener(_[k],m.check)}}else f.log("Unable to automatically bind plot updates to API command"),m.lookupTable={},m.remove=function(){};return m.disable=function(){b=!1},m.enable=function(){b=!0},g&&(g._commandObserver=m),m},a.hasSimpleAPICommandBindings=function(p,g,y){var v,m,b=g.length;for(v=0;v=q.width-20?(te["text-anchor"]="start",te.x=5):(te["text-anchor"]="end",te.x=q._paper.attr("width")-7),H.attr(te);var ee=H.select(".js-link-to-tool"),U=H.select(".js-link-spacer"),Q=H.select(".js-sourcelinks");L._context.showSources&&L._context.showSources(L),L._context.showLink&&function(Y,Z){Z.text("");var X=Z.append("a").attr({"xlink:xlink:href":"#",class:"link--impt link--embedview","font-weight":"bold"}).text(Y._context.linkText+" »");if(Y._context.sendData)X.on("click",function(){S.sendDataToCloud(Y)});else{var re=window.location.pathname.split("/"),ie=window.location.search;X.attr({"xlink:xlink:show":"new","xlink:xlink:href":"/"+re[2].split(".")[0]+"/"+re[1]+ie})}}(L,ee),U.text(ee.text()&&Q.text()?" - ":"")}},S.sendDataToCloud=function(L){var q=(window.PLOTLYENV||{}).BASE_URL||L._context.plotlyServerURL;if(q){L.emit("plotly_beforeexport");var H=l.select(L).append("div").attr("id","hiddenform").style("display","none"),V=H.append("form").attr({action:q+"/external",method:"post",target:"_blank"});return V.append("input").attr({type:"text",name:"data"}).node().value=S.graphJson(L,!1,"keepdata"),V.node().submit(),H.remove(),L.emit("plotly_afterexport"),!1}};var D=["days","shortDays","months","shortMonths","periods","dateTime","date","time","decimal","thousands","grouping","currency"],O=["year","month","dayMonth","dayMonthYear"];function R(L,q){var H=L._context.locale;H||(H="en-US");var V=!1,te={};function ee(re){for(var ie=!0,le=0;le1&&J.length>1){for(d.getComponentMethod("grid","sizeDefaults")(U,ee),te=0;te15&&J.length>15&&ee.shapes.length===0&&ee.images.length===0,S.linkSubplots(Y,ee,Q,V),S.cleanPlot(Y,ee,Q,V);var ge=!(!V._has||!V._has("gl2d")),be=!(!ee._has||!ee._has("gl2d")),we=!(!V._has||!V._has("cartesian"))||ge,ke=!(!ee._has||!ee._has("cartesian"))||be;we&&!ke?V._bgLayer.remove():ke&&!we&&(ee._shouldCreateBgLayer=!0),V._zoomlayer&&!L._dragging&&b({_fullLayout:V}),function(Re,Ie){var Be,Ue=[];Ie.meta&&(Be=Ie._meta={meta:Ie.meta,layout:{meta:Ie.meta}});for(var qe=0;qe0){var Z=1-2*U;V=Math.round(Z*V),te=Math.round(Z*te)}}var X=S.layoutAttributes.width.min,re=S.layoutAttributes.height.min;V1,le=!q.height&&Math.abs(H.height-te)>1;(le||ie)&&(ie&&(H.width=V),le&&(H.height=te)),L._initialAutoSize||(L._initialAutoSize={width:V,height:te}),S.sanitizeMargins(H)},S.supplyLayoutModuleDefaults=function(L,q,H,V){var te,ee,U,Q=d.componentsRegistry,Y=q._basePlotModules,Z=d.subplotsRegistry.cartesian;for(te in Q)(U=Q[te]).includeBasePlot&&U.includeBasePlot(L,q);for(var X in Y.length||Y.push(Z),q._has("cartesian")&&(d.getComponentMethod("grid","contentDefaults")(L,q),Z.finalizeSubplots(L,q)),q._subplots)q._subplots[X].sort(g.subplotSort);for(ee=0;ee1&&(H.l/=Te,H.r/=Te)}if(ie){var Se=(H.t+H.b)/ie;Se>1&&(H.t/=Se,H.b/=Se)}var Oe=H.xl!==void 0?H.xl:H.x,Me=H.xr!==void 0?H.xr:H.x,ce=H.yt!==void 0?H.yt:H.y,ye=H.yb!==void 0?H.yb:H.y;le[q]={l:{val:Oe,size:H.l+pe},r:{val:Me,size:H.r+pe},b:{val:ye,size:H.b+pe},t:{val:ce,size:H.t+pe}},se[q]=1}else delete le[q],delete se[q];if(!V._replotting)return S.doAutoMargin(L)}},S.doAutoMargin=function(L){var q=L._fullLayout,H=q.width,V=q.height;q._size||(q._size={}),$(q);var te=q._size,ee=q.margin,U={t:0,b:0,l:0,r:0},Q=g.extendFlat({},te),Y=ee.l,Z=ee.r,X=ee.t,re=ee.b,ie=q._pushmargin,le=q._pushmarginIds,se=q.minreducedwidth,pe=q.minreducedheight;if(ee.autoexpand!==!1){for(var Te in ie)le[Te]||delete ie[Te];var Se=L._fullLayout._reservedMargin;for(var Oe in Se)for(var Me in Se[Oe]){var ce=Se[Oe][Me];U[Me]=Math.max(U[Me],ce)}for(var ye in ie.base={l:{val:0,size:Y},r:{val:1,size:Z},t:{val:1,size:X},b:{val:0,size:re}},U){var J=0;for(var ne in ie)ne!=="base"&&u(ie[ne][ye].size)&&(J=ie[ne][ye].size>J?ie[ne][ye].size:J);var de=Math.max(0,ee[ye]-J);U[ye]=Math.max(0,U[ye]-de)}for(var xe in ie){var ue=ie[xe].l||{},ge=ie[xe].b||{},be=ue.val,we=ue.size,ke=ge.val,Ae=ge.size,Ee=H-U.r-U.l,De=V-U.t-U.b;for(var Re in ie){if(u(we)&&ie[Re].r){var Ie=ie[Re].r.val,Be=ie[Re].r.size;if(Ie>be){var Ue=(we*Ie+(Be-Ee)*be)/(Ie-be),qe=(Be*(1-be)+(we-Ee)*(1-Ie))/(Ie-be);Ue+qe>Y+Z&&(Y=Ue,Z=qe)}}if(u(Ae)&&ie[Re].t){var Ye=ie[Re].t.val,at=ie[Re].t.size;if(Ye>ke){var lt=(Ae*Ye+(at-De)*ke)/(Ye-ke),ct=(at*(1-ke)+(Ae-De)*(1-Ye))/(Ye-ke);lt+ct>re+X&&(re=lt,X=ct)}}}}}var bt=g.constrain(H-ee.l-ee.r,2,se),ze=g.constrain(V-ee.t-ee.b,2,pe),Ne=Math.max(0,H-bt),Qe=Math.max(0,V-ze);if(Ne){var it=(Y+Z)/Ne;it>1&&(Y/=it,Z/=it)}if(Qe){var kt=(re+X)/Qe;kt>1&&(re/=kt,X/=kt)}if(te.l=Math.round(Y)+U.l,te.r=Math.round(Z)+U.r,te.t=Math.round(X)+U.t,te.b=Math.round(re)+U.b,te.p=Math.round(ee.pad),te.w=Math.round(H)-te.l-te.r,te.h=Math.round(V)-te.t-te.b,!q._replotting&&(S.didMarginChange(Q,te)||function(ut){if("_redrawFromAutoMarginCount"in ut._fullLayout)return!1;var pt=m.list(ut,"",!0);for(var It in pt)if(pt[It].autoshift||pt[It].shift)return!0;return!1}(L))){"_redrawFromAutoMarginCount"in q?q._redrawFromAutoMarginCount++:q._redrawFromAutoMarginCount=1;var Je=3*(1+Object.keys(le).length);if(q._redrawFromAutoMarginCount0&&(L._transitioningWithDuration=!0),L._transitionData._interruptCallbacks.push(function(){V=!0}),H.redraw&&L._transitionData._interruptCallbacks.push(function(){return d.call("redraw",L)}),L._transitionData._interruptCallbacks.push(function(){L.emit("plotly_transitioninterrupted",[])});var Q=0,Y=0;function Z(){return Q++,function(){var X;Y++,V||Y!==Q||(X=U,L._transitionData&&(function(re){if(re)for(;re.length;)re.shift()}(L._transitionData._interruptCallbacks),Promise.resolve().then(function(){if(H.redraw)return d.call("redraw",L)}).then(function(){L._transitioning=!1,L._transitioningWithDuration=!1,L.emit("plotly_transitioned",[])}).then(X)))}}H.runFn(Z),setTimeout(Z())})}],ee=g.syncOrAsync(te,L);return ee&&ee.then||(ee=Promise.resolve()),ee.then(function(){return L})}S.didMarginChange=function(L,q){for(var H=0;H1)return!0}return!1},S.graphJson=function(L,q,H,V,te,ee){(te&&q&&!L._fullData||te&&!q&&!L._fullLayout)&&S.supplyDefaults(L);var U=te?L._fullData:L.data,Q=te?L._fullLayout:L.layout,Y=(L._transitionData||{})._frames;function Z(ie,le){if(typeof ie=="function")return le?"_function_":null;if(g.isPlainObject(ie)){var se,pe={};return Object.keys(ie).sort().forEach(function(Te){if(["_","["].indexOf(Te.charAt(0))===-1)if(typeof ie[Te]!="function"){if(H==="keepdata"){if(Te.substr(Te.length-3)==="src")return}else if(H==="keepstream"){if(typeof(se=ie[Te+"src"])=="string"&&se.indexOf(":")>0&&!g.isPlainObject(ie.stream))return}else if(H!=="keepall"&&typeof(se=ie[Te+"src"])=="string"&&se.indexOf(":")>0)return;pe[Te]=Z(ie[Te],le)}else le&&(pe[Te]="_function")}),pe}return Array.isArray(ie)?ie.map(function(Te){return Z(Te,le)}):g.isTypedArray(ie)?g.simpleMap(ie,g.identity):g.isJSDate(ie)?g.ms2DateTimeLocal(+ie):ie}var X={data:(U||[]).map(function(ie){var le=Z(ie);return q&&delete le.fit,le})};if(!q&&(X.layout=Z(Q),te)){var re=Q._size;X.layout.computed={margin:{b:re.b,l:re.l,r:re.r,t:re.t}}}return Y&&(X.frames=Z(Y)),ee&&(X.config=Z(L._context,!0)),V==="object"?X:JSON.stringify(X)},S.modifyFrames=function(L,q){var H,V,te,ee=L._transitionData._frames,U=L._transitionData._frameHash;for(H=0;H=0;ee--)if(ye[ee].enabled){H._indexToPoints=ye[ee]._indexToPoints;break}V&&V.calc&&(ce=V.calc(L,H))}Array.isArray(ce)&&ce[0]||(ce=[{x:v,y:v}]),ce[0].t||(ce[0].t={}),ce[0].trace=H,Z[Oe]=ce}}for(W(U,Q,Y),te=0;te0){for(var h=[],p=0;p=D&&(R.min=0,F.min=0,A.min=0,_.aaxis&&delete _.aaxis.min,_.baxis&&delete _.baxis.min,_.caxis&&delete _.caxis.min)}function x(_,w,k,T){var M=v[w._name];function S(F,A){return s.coerce(_,w,M,F,A)}S("uirevision",T.uirevision),w.type="linear";var C=S("color"),P=C!==M.color.dflt?C:k.font.color,D=w._name.charAt(0).toUpperCase(),O="Component "+D,R=S("title.text",O);w._hovertitle=R===O?R:D,s.coerceFont(S,"title.font",{family:k.font.family,size:s.bigFont(k.font.size),color:P}),S("min"),g(_,w,S,"linear"),h(_,w,S,"linear"),d(_,w,S,"linear"),p(_,w,S,{outerTicks:!0}),S("showticklabels")&&(s.coerceFont(S,"tickfont",{family:k.font.family,size:k.font.size,color:P}),S("tickangle"),S("tickformat")),y(_,w,S,{dfltColor:C,bgColor:k.bgColor,blend:60,showLine:!0,showGrid:!0,noZeroLine:!0,attributes:M}),S("hoverformat"),S("layer")}o.exports=function(_,w,k){u(_,w,k,{type:"ternary",attributes:v,handleDefaults:b,font:w.font,paper_bgcolor:w.paper_bgcolor})}},64380:function(o,a,n){var l=n(39898),f=n(84267),s=n(73972),u=n(71828),d=u.strTranslate,h=u._,p=n(7901),g=n(91424),y=n(21994),v=n(1426).extendFlat,m=n(74875),b=n(89298),x=n(28569),_=n(30211),w=n(64505),k=w.freeMode,T=w.rectMode,M=n(92998),S=n(47322).prepSelect,C=n(47322).selectOnClick,P=n(47322).clearOutline,D=n(47322).clearSelectionsCache,O=n(85555);function R(W,G){this.id=W.id,this.graphDiv=W.graphDiv,this.init(G),this.makeFramework(G),this.aTickLayout=null,this.bTickLayout=null,this.cTickLayout=null}o.exports=R;var F=R.prototype;F.init=function(W){this.container=W._ternarylayer,this.defs=W._defs,this.layoutId=W._uid,this.traceHash={},this.layers={}},F.plot=function(W,G){var L=this,q=G[L.id],H=G._size;L._hasClipOnAxisFalse=!1;for(var V=0;VA*le?H=(V=le)*A:V=(H=ie)/A,te=X*H/ie,ee=re*V/le,L=G.l+G.w*Y-H/2,q=G.t+G.h*(1-Z)-V/2,U.x0=L,U.y0=q,U.w=H,U.h=V,U.sum=se,U.xaxis={type:"linear",range:[pe+2*Se-se,se-pe-2*Te],domain:[Y-te/2,Y+te/2],_id:"x"},y(U.xaxis,U.graphDiv._fullLayout),U.xaxis.setScale(),U.xaxis.isPtWithinRange=function(be){return be.a>=U.aaxis.range[0]&&be.a<=U.aaxis.range[1]&&be.b>=U.baxis.range[1]&&be.b<=U.baxis.range[0]&&be.c>=U.caxis.range[1]&&be.c<=U.caxis.range[0]},U.yaxis={type:"linear",range:[pe,se-Te-Se],domain:[Z-ee/2,Z+ee/2],_id:"y"},y(U.yaxis,U.graphDiv._fullLayout),U.yaxis.setScale(),U.yaxis.isPtWithinRange=function(){return!0};var Oe=U.yaxis.domain[0],Me=U.aaxis=v({},W.aaxis,{range:[pe,se-Te-Se],side:"left",tickangle:(+W.aaxis.tickangle||0)-30,domain:[Oe,Oe+ee*A],anchor:"free",position:0,_id:"y",_length:H});y(Me,U.graphDiv._fullLayout),Me.setScale();var ce=U.baxis=v({},W.baxis,{range:[se-pe-Se,Te],side:"bottom",domain:U.xaxis.domain,anchor:"free",position:0,_id:"x",_length:H});y(ce,U.graphDiv._fullLayout),ce.setScale();var ye=U.caxis=v({},W.caxis,{range:[se-pe-Te,Se],side:"right",tickangle:(+W.caxis.tickangle||0)+30,domain:[Oe,Oe+ee*A],anchor:"free",position:0,_id:"y",_length:H});y(ye,U.graphDiv._fullLayout),ye.setScale();var J="M"+L+","+(q+V)+"h"+H+"l-"+H/2+",-"+V+"Z";U.clipDef.select("path").attr("d",J),U.layers.plotbg.select("path").attr("d",J);var ne="M0,"+V+"h"+H+"l-"+H/2+",-"+V+"Z";U.clipDefRelative.select("path").attr("d",ne);var de=d(L,q);U.plotContainer.selectAll(".scatterlayer,.maplayer").attr("transform",de),U.clipDefRelative.select("path").attr("transform",null);var xe=d(L-ce._offset,q+V);U.layers.baxis.attr("transform",xe),U.layers.bgrid.attr("transform",xe);var ue=d(L+H/2,q)+"rotate(30)"+d(0,-Me._offset);U.layers.aaxis.attr("transform",ue),U.layers.agrid.attr("transform",ue);var ge=d(L+H/2,q)+"rotate(-30)"+d(0,-ye._offset);U.layers.caxis.attr("transform",ge),U.layers.cgrid.attr("transform",ge),U.drawAxes(!0),U.layers.aline.select("path").attr("d",Me.showline?"M"+L+","+(q+V)+"l"+H/2+",-"+V:"M0,0").call(p.stroke,Me.linecolor||"#000").style("stroke-width",(Me.linewidth||0)+"px"),U.layers.bline.select("path").attr("d",ce.showline?"M"+L+","+(q+V)+"h"+H:"M0,0").call(p.stroke,ce.linecolor||"#000").style("stroke-width",(ce.linewidth||0)+"px"),U.layers.cline.select("path").attr("d",ye.showline?"M"+(L+H/2)+","+q+"l"+H/2+","+V:"M0,0").call(p.stroke,ye.linecolor||"#000").style("stroke-width",(ye.linewidth||0)+"px"),U.graphDiv._context.staticPlot||U.initInteractions(),g.setClipUrl(U.layers.frontplot,U._hasClipOnAxisFalse?null:U.clipId,U.graphDiv)},F.drawAxes=function(W){var G=this,L=G.graphDiv,q=G.id.substr(7)+"title",H=G.layers,V=G.aaxis,te=G.baxis,ee=G.caxis;if(G.drawAx(V),G.drawAx(te),G.drawAx(ee),W){var U=Math.max(V.showticklabels?V.tickfont.size/2:0,(ee.showticklabels?.75*ee.tickfont.size:0)+(ee.ticks==="outside"?.87*ee.ticklen:0)),Q=(te.showticklabels?te.tickfont.size:0)+(te.ticks==="outside"?te.ticklen:0)+3;H["a-title"]=M.draw(L,"a"+q,{propContainer:V,propName:G.id+".aaxis.title",placeholder:h(L,"Click to enter Component A title"),attributes:{x:G.x0+G.w/2,y:G.y0-V.title.font.size/3-U,"text-anchor":"middle"}}),H["b-title"]=M.draw(L,"b"+q,{propContainer:te,propName:G.id+".baxis.title",placeholder:h(L,"Click to enter Component B title"),attributes:{x:G.x0-Q,y:G.y0+G.h+.83*te.title.font.size+Q,"text-anchor":"middle"}}),H["c-title"]=M.draw(L,"c"+q,{propContainer:ee,propName:G.id+".caxis.title",placeholder:h(L,"Click to enter Component C title"),attributes:{x:G.x0+G.w+Q,y:G.y0+G.h+.83*ee.title.font.size+Q,"text-anchor":"middle"}})}},F.drawAx=function(W){var G,L=this,q=L.graphDiv,H=W._name,V=H.charAt(0),te=W._id,ee=L.layers[H],U=V+"tickLayout",Q=(G=W).ticks+String(G.ticklen)+String(G.showticklabels);L[U]!==Q&&(ee.selectAll("."+te+"tick").remove(),L[U]=Q),W.setScale();var Y=b.calcTicks(W),Z=b.clipEnds(W,Y),X=b.makeTransTickFn(W),re=b.getTickSigns(W)[2],ie=u.deg2rad(30),le=re*(W.linewidth||1)/2,se=re*W.ticklen,pe=L.w,Te=L.h,Se=V==="b"?"M0,"+le+"l"+Math.sin(ie)*se+","+Math.cos(ie)*se:"M"+le+",0l"+Math.cos(ie)*se+","+-Math.sin(ie)*se,Oe={a:"M0,0l"+Te+",-"+pe/2,b:"M0,0l-"+pe/2+",-"+Te,c:"M0,0l-"+Te+","+pe/2}[V];b.drawTicks(q,W,{vals:W.ticks==="inside"?Z:Y,layer:ee,path:Se,transFn:X,crisp:!1}),b.drawGrid(q,W,{vals:Z,layer:L.layers[V+"grid"],path:Oe,transFn:X,crisp:!1}),b.drawLabels(q,W,{vals:Y,layer:ee,transFn:X,labelFns:b.makeLabelFns(W,0,30)})};var z=O.MINZOOM/2+.87,B="m-0.87,.5h"+z+"v3h-"+(z+5.2)+"l"+(z/2+2.6)+",-"+(.87*z+4.5)+"l2.6,1.5l-"+z/2+","+.87*z+"Z",$="m0.87,.5h-"+z+"v3h"+(z+5.2)+"l-"+(z/2+2.6)+",-"+(.87*z+4.5)+"l-2.6,1.5l"+z/2+","+.87*z+"Z",j="m0,1l"+z/2+","+.87*z+"l2.6,-1.5l-"+(z/2+2.6)+",-"+(.87*z+4.5)+"l-"+(z/2+2.6)+","+(.87*z+4.5)+"l2.6,1.5l"+z/2+",-"+.87*z+"Z",N=!0;function E(W){l.select(W).selectAll(".zoombox,.js-zoombox-backdrop,.js-zoombox-menu,.zoombox-corners").remove()}F.clearOutline=function(){D(this.dragOptions),P(this.dragOptions.gd)},F.initInteractions=function(){var W,G,L,q,H,V,te,ee,U,Q,Y,Z,X=this,re=X.layers.plotbg.select("path").node(),ie=X.graphDiv,le=ie._fullLayout._zoomlayer;function se(ne){var de={};return de[X.id+".aaxis.min"]=ne.a,de[X.id+".baxis.min"]=ne.b,de[X.id+".caxis.min"]=ne.c,de}function pe(ne,de){var xe=ie._fullLayout.clickmode;E(ie),ne===2&&(ie.emit("plotly_doubleclick",null),s.call("_guiRelayout",ie,se({a:0,b:0,c:0}))),xe.indexOf("select")>-1&&ne===1&&C(de,ie,[X.xaxis],[X.yaxis],X.id,X.dragOptions),xe.indexOf("event")>-1&&_.click(ie,de,X.id)}function Te(ne,de){return 1-de/X.h}function Se(ne,de){return 1-(ne+(X.h-de)/Math.sqrt(3))/X.w}function Oe(ne,de){return(ne-(X.h-de)/Math.sqrt(3))/X.w}function Me(ne,de){var xe=L+ne*W,ue=q+de*G,ge=Math.max(0,Math.min(1,Te(0,q),Te(0,ue))),be=Math.max(0,Math.min(1,Se(L,q),Se(xe,ue))),we=Math.max(0,Math.min(1,Oe(L,q),Oe(xe,ue))),ke=(ge/2+we)*X.w,Ae=(1-ge/2-be)*X.w,Ee=(ke+Ae)/2,De=Ae-ke,Re=(1-ge)*X.h,Ie=Re-De/A;De.2?"rgba(0,0,0,0.4)":"rgba(255,255,255,0.3)").duration(200),Z.transition().style("opacity",1).duration(200),Q=!0),ie.emit("plotly_relayouting",se(te))}function ce(){E(ie),te!==H&&(s.call("_guiRelayout",ie,se(te)),N&&ie.data&&ie._context.showTips&&(u.notifier(h(ie,"Double-click to zoom back out"),"long"),N=!1))}function ye(ne,de){var xe=ne/X.xaxis._m,ue=de/X.yaxis._m,ge=[(te={a:H.a-ue,b:H.b+(xe+ue)/2,c:H.c-(xe-ue)/2}).a,te.b,te.c].sort(u.sorterAsc),be=ge.indexOf(te.a),we=ge.indexOf(te.b),ke=ge.indexOf(te.c);ge[0]<0&&(ge[1]+ge[0]/2<0?(ge[2]+=ge[0]+ge[1],ge[0]=ge[1]=0):(ge[2]+=ge[0]/2,ge[1]+=ge[0]/2,ge[0]=0),te={a:ge[be],b:ge[we],c:ge[ke]},de=(H.a-te.a)*X.yaxis._m,ne=(H.c-te.c-H.b+te.b)*X.xaxis._m);var Ae=d(X.x0+ne,X.y0+de);X.plotContainer.selectAll(".scatterlayer,.maplayer").attr("transform",Ae);var Ee=d(-ne,-de);X.clipDefRelative.select("path").attr("transform",Ee),X.aaxis.range=[te.a,X.sum-te.b-te.c],X.baxis.range=[X.sum-te.a-te.c,te.b],X.caxis.range=[X.sum-te.a-te.b,te.c],X.drawAxes(!1),X._hasClipOnAxisFalse&&X.plotContainer.select(".scatterlayer").selectAll(".trace").call(g.hideOutsideRangePoints,X),ie.emit("plotly_relayouting",se(te))}function J(){s.call("_guiRelayout",ie,se(te))}this.dragOptions={element:re,gd:ie,plotinfo:{id:X.id,domain:ie._fullLayout[X.id].domain,xaxis:X.xaxis,yaxis:X.yaxis},subplot:X.id,prepFn:function(ne,de,xe){X.dragOptions.xaxes=[X.xaxis],X.dragOptions.yaxes=[X.yaxis],W=ie._fullLayout._invScaleX,G=ie._fullLayout._invScaleY;var ue=X.dragOptions.dragmode=ie._fullLayout.dragmode;k(ue)?X.dragOptions.minDrag=1:X.dragOptions.minDrag=void 0,ue==="zoom"?(X.dragOptions.moveFn=Me,X.dragOptions.clickFn=pe,X.dragOptions.doneFn=ce,function(ge,be,we){var ke=re.getBoundingClientRect();L=be-ke.left,q=we-ke.top,ie._fullLayout._calcInverseTransform(ie);var Ae=ie._fullLayout._invTransform,Ee=u.apply3DTransform(Ae)(L,q);L=Ee[0],q=Ee[1],H={a:X.aaxis.range[0],b:X.baxis.range[1],c:X.caxis.range[1]},te=H,V=X.aaxis.range[1]-H.a,ee=f(X.graphDiv._fullLayout[X.id].bgcolor).getLuminance(),U="M0,"+X.h+"L"+X.w/2+", 0L"+X.w+","+X.h+"Z",Q=!1,Y=le.append("path").attr("class","zoombox").attr("transform",d(X.x0,X.y0)).style({fill:ee>.2?"rgba(0,0,0,0)":"rgba(255,255,255,0)","stroke-width":0}).attr("d",U),Z=le.append("path").attr("class","zoombox-corners").attr("transform",d(X.x0,X.y0)).style({fill:p.background,stroke:p.defaultLine,"stroke-width":1,opacity:0}).attr("d","M0,0Z"),X.clearOutline(ie)}(0,de,xe)):ue==="pan"?(X.dragOptions.moveFn=ye,X.dragOptions.clickFn=pe,X.dragOptions.doneFn=J,H={a:X.aaxis.range[0],b:X.baxis.range[1],c:X.caxis.range[1]},te=H,X.clearOutline(ie)):(T(ue)||k(ue))&&S(ne,de,xe,X.dragOptions,ue)}},re.onmousemove=function(ne){_.hover(ie,ne,X.id),ie._fullLayout._lasthover=re,ie._fullLayout._hoversubplot=X.id},re.onmouseout=function(ne){ie._dragging||x.unhover(ie,ne)},x.init(this.dragOptions)}},73972:function(o,a,n){var l=n(47769),f=n(64213),s=n(75138),u=n(41965),d=n(24401).addStyleRule,h=n(1426),p=n(9012),g=n(10820),y=h.extendFlat,v=h.extendDeepAll;function m(C){var P=C.name,D=C.categories,O=C.meta;if(a.modules[P])l.log("Type "+P+" already registered");else{a.subplotsRegistry[C.basePlotModule.name]||function(N){var E=N.name;if(a.subplotsRegistry[E])l.log("Plot type "+E+" already registered.");else for(var W in w(N),a.subplotsRegistry[E]=N,a.componentsRegistry)M(W,N.name)}(C.basePlotModule);for(var R={},F=0;F-1&&(x[w[g]].title={text:""});for(g=0;g")!==-1?"":F.html(z).text()});return F.remove(),A}(O)).replace(/&(?!\w+;|\#[0-9]+;| \#x[0-9A-F]+;)/g,"&")).replace(g,"'"),f.isIE()&&(O=(O=(O=O.replace(/"/gi,"'")).replace(/(\('#)([^']*)('\))/gi,'("#$2")')).replace(/(\\')/gi,'"')),O}},75341:function(o,a,n){var l=n(71828);o.exports=function(f,s){for(var u=0;uA+R||!l(F))}for(var B=0;Bg))return d}return h!==void 0?h:u.dflt},a.coerceColor=function(u,d,h){return f(d).isValid()?d:h!==void 0?h:u.dflt},a.coerceEnumerated=function(u,d,h){return u.coerceNumber&&(d=+d),u.values.indexOf(d)!==-1?d:h!==void 0?h:u.dflt},a.getValue=function(u,d){var h;return Array.isArray(u)?d0?se+=pe:k<0&&(se-=pe)}return se}function ee(le){var se=k,pe=le.b,Te=te(le);return l.inbox(pe-se,Te-se,z+(Te-se)/(Te-pe)-1)}var U=v[T+"a"],Q=v[M+"a"];P=Math.abs(U.r2c(U.range[1])-U.r2c(U.range[0]));var Y=l.getDistanceFunction(x,S,C,function(le){return(S(le)+C(le))/2});if(l.getClosest(D,Y,v),v.index!==!1&&D[v.index].p!==p){j||(L=function(le){return Math.min(N(le),le.p-R.bargroupwidth/2)},q=function(le){return Math.max(E(le),le.p+R.bargroupwidth/2)});var Z=D[v.index],X=O.base?Z.b+Z.s:Z.s;v[M+"0"]=v[M+"1"]=Q.c2p(Z[M],!0),v[M+"LabelVal"]=X;var re=R.extents[R.extents.round(Z.p)];v[T+"0"]=U.c2p(F?L(Z):re[0],!0),v[T+"1"]=U.c2p(F?q(Z):re[1],!0);var ie=Z.orig_p!==void 0;return v[T+"LabelVal"]=ie?Z.orig_p:Z.p,v.labelLabel=h(U,v[T+"LabelVal"],O[T+"hoverformat"]),v.valueLabel=h(Q,v[M+"LabelVal"],O[M+"hoverformat"]),v.baseLabel=h(Q,Z.b,O[M+"hoverformat"]),v.spikeDistance=(function(le){var se=k,pe=le.b,Te=te(le);return l.inbox(pe-se,Te-se,B+(Te-se)/(Te-pe)-1)}(Z)+function(le){return H(N(le),E(le),B)}(Z))/2,v[T+"Spike"]=U.c2p(Z.p,!0),u(Z,O,v),v.hovertemplate=O.hovertemplate,v}}function y(v,m){var b=m.mcc||v.marker.color,x=m.mlcc||v.marker.line.color,_=d(v,m);return s.opacity(b)?b:s.opacity(x)&&_?x:void 0}o.exports={hoverPoints:function(v,m,b,x,_){var w=g(v,m,b,x,_);if(w){var k=w.cd,T=k[0].trace,M=k[w.index];return w.color=y(T,M),f.getComponentMethod("errorbars","hoverInfo")(M,T,w),[w]}},hoverOnBars:g,getTraceColor:y}},60822:function(o,a,n){o.exports={attributes:n(1486),layoutAttributes:n(43641),supplyDefaults:n(90769).supplyDefaults,crossTraceDefaults:n(90769).crossTraceDefaults,supplyLayoutDefaults:n(13957),calc:n(92290),crossTraceCalc:n(11661).crossTraceCalc,colorbar:n(4898),arraysToCalcdata:n(75341),plot:n(17295).plot,style:n(16688).style,styleOnSelect:n(16688).styleOnSelect,hoverPoints:n(95423).hoverPoints,eventData:n(58065),selectPoints:n(81974),moduleType:"trace",name:"bar",basePlotModule:n(93612),categories:["bar-like","cartesian","svg","bar","oriented","errorBarsOK","showLegend","zoomScale"],animatable:!0,meta:{}}},43641:function(o){o.exports={barmode:{valType:"enumerated",values:["stack","group","overlay","relative"],dflt:"group",editType:"calc"},barnorm:{valType:"enumerated",values:["","fraction","percent"],dflt:"",editType:"calc"},bargap:{valType:"number",min:0,max:1,editType:"calc"},bargroupgap:{valType:"number",min:0,max:1,dflt:0,editType:"calc"}}},13957:function(o,a,n){var l=n(73972),f=n(89298),s=n(71828),u=n(43641);o.exports=function(d,h,p){function g(T,M){return s.coerce(d,h,u,T,M)}for(var y=!1,v=!1,m=!1,b={},x=g("barmode"),_=0;_0}function F(B){return B==="auto"?0:B}function A(B,$){var j=Math.PI/180*$,N=Math.abs(Math.sin(j)),E=Math.abs(Math.cos(j));return{x:B.width*E+B.height*N,y:B.width*N+B.height*E}}function z(B,$,j,N,E,W){var G=!!W.isHorizontal,L=!!W.constrained,q=W.angle||0,H=W.anchor||"end",V=H==="end",te=H==="start",ee=((W.leftToRight||0)+1)/2,U=1-ee,Q=E.width,Y=E.height,Z=Math.abs($-B),X=Math.abs(N-j),re=Z>2*S&&X>2*S?S:0;Z-=2*re,X-=2*re;var ie=F(q);q!=="auto"||Q<=Z&&Y<=X||!(Q>Z||Y>X)||(Q>X||Y>Z)&&Q.01?we:function(De,Re,Ie){return Ie&&De===Re?De:Math.abs(De-Re)>=2?we(De):De>Re?Math.ceil(De):Math.floor(De)};ne=ke(ne,de,re),de=ke(de,ne,re),xe=ke(xe,ue,!re),ue=ke(ue,xe,!re)}var Ae=O(s.ensureSingle(ye,"path"),q,E,W);if(Ae.style("vector-effect",H?"none":"non-scaling-stroke").attr("d",isNaN((de-ne)*(ue-xe))||ge&&B._context.staticPlot?"M0,0Z":"M"+ne+","+xe+"V"+ue+"H"+de+"V"+xe+"Z").call(h.setClipUrl,$.layerClipId,B),!q.uniformtext.mode&&ie){var Ee=h.makePointStyleFns(U);h.singlePointStyle(Se,Ae,U,Ee,B)}(function(De,Re,Ie,Be,Ue,qe,Ye,at,lt,ct,bt){var ze,Ne=Re.xaxis,Qe=Re.yaxis,it=De._fullLayout;function kt(Dt,gt,ht){return s.ensureSingle(Dt,"text").text(gt).attr({class:"bartext bartext-"+ze,"text-anchor":"middle","data-notex":1}).call(h.font,ht).call(u.convertToTspans,De)}var Je=Be[0].trace,ut=Je.orientation==="h",pt=function(Dt,gt,ht,yt,qt){var Et,jt=gt[0].trace;return Et=jt.texttemplate?function(Tt,Ot,At,Lt,Rt){var $t=Ot[0].trace,Yt=s.castOption($t,At,"texttemplate");if(!Yt)return"";var Xt,Bt,Wt,tn,cn=$t.type==="histogram",ln=$t.type==="waterfall",an=$t.type==="funnel",sn=$t.orientation==="h";function Zt(xn){return g(tn,tn.c2l(xn),!0).text}sn?(Xt="y",Bt=Rt,Wt="x",tn=Lt):(Xt="x",Bt=Lt,Wt="y",tn=Rt);var pn,nn=Ot[At],Kt={};Kt.label=nn.p,Kt.labelLabel=Kt[Xt+"Label"]=(pn=nn.p,g(Bt,Bt.c2l(pn),!0).text);var Cn=s.castOption($t,nn.i,"text");(Cn===0||Cn)&&(Kt.text=Cn),Kt.value=nn.s,Kt.valueLabel=Kt[Wt+"Label"]=Zt(nn.s);var _n={};M(_n,$t,nn.i),(cn||_n.x===void 0)&&(_n.x=sn?Kt.value:Kt.label),(cn||_n.y===void 0)&&(_n.y=sn?Kt.label:Kt.value),(cn||_n.xLabel===void 0)&&(_n.xLabel=sn?Kt.valueLabel:Kt.labelLabel),(cn||_n.yLabel===void 0)&&(_n.yLabel=sn?Kt.labelLabel:Kt.valueLabel),ln&&(Kt.delta=+nn.rawS||nn.s,Kt.deltaLabel=Zt(Kt.delta),Kt.final=nn.v,Kt.finalLabel=Zt(Kt.final),Kt.initial=Kt.final-Kt.delta,Kt.initialLabel=Zt(Kt.initial)),an&&(Kt.value=nn.s,Kt.valueLabel=Zt(Kt.value),Kt.percentInitial=nn.begR,Kt.percentInitialLabel=s.formatPercent(nn.begR),Kt.percentPrevious=nn.difR,Kt.percentPreviousLabel=s.formatPercent(nn.difR),Kt.percentTotal=nn.sumR,Kt.percenTotalLabel=s.formatPercent(nn.sumR));var Pn=s.castOption($t,nn.i,"customdata");return Pn&&(Kt.customdata=Pn),s.texttemplateString(Yt,Kt,Tt._d3locale,_n,Kt,$t._meta||{})}(Dt,gt,ht,yt,qt):jt.textinfo?function(Tt,Ot,At,Lt){var Rt=Tt[0].trace,$t=Rt.orientation==="h",Yt=Rt.type==="waterfall",Xt=Rt.type==="funnel";function Bt(Pn){return g($t?At:Lt,+Pn,!0).text}var Wt,tn,cn=Rt.textinfo,ln=Tt[Ot],an=cn.split("+"),sn=[],Zt=function(Pn){return an.indexOf(Pn)!==-1};if(Zt("label")&&sn.push((tn=Tt[Ot].p,g($t?Lt:At,tn,!0).text)),Zt("text")&&((Wt=s.castOption(Rt,ln.i,"text"))===0||Wt)&&sn.push(Wt),Yt){var pn=+ln.rawS||ln.s,nn=ln.v,Kt=nn-pn;Zt("initial")&&sn.push(Bt(Kt)),Zt("delta")&&sn.push(Bt(pn)),Zt("final")&&sn.push(Bt(nn))}if(Xt){Zt("value")&&sn.push(Bt(ln.s));var Cn=0;Zt("percent initial")&&Cn++,Zt("percent previous")&&Cn++,Zt("percent total")&&Cn++;var _n=Cn>1;Zt("percent initial")&&(Wt=s.formatPercent(ln.begR),_n&&(Wt+=" of initial"),sn.push(Wt)),Zt("percent previous")&&(Wt=s.formatPercent(ln.difR),_n&&(Wt+=" of previous"),sn.push(Wt)),Zt("percent total")&&(Wt=s.formatPercent(ln.sumR),_n&&(Wt+=" of total"),sn.push(Wt))}return sn.join("
")}(gt,ht,yt,qt):x.getValue(jt.text,ht),x.coerceString(k,Et)}(it,Be,Ue,Ne,Qe);ze=function(Dt,gt){var ht=x.getValue(Dt.textposition,gt);return x.coerceEnumerated(T,ht)}(Je,Ue);var It=ct.mode==="stack"||ct.mode==="relative",Mt=Be[Ue],zt=!It||Mt._outmost;if(pt&&ze!=="none"&&(!Mt.isBlank&&qe!==Ye&&at!==lt||ze!=="auto"&&ze!=="inside")){var wt=it.font,ve=b.getBarColor(Be[Ue],Je),_e=b.getInsideTextFont(Je,Ue,wt,ve),Ve=b.getOutsideTextFont(Je,Ue,wt),We=Ie.datum();ut?Ne.type==="log"&&We.s0<=0&&(qe=Ne.range[0]0&&nt>0&&(Ke<=mt&&nt<=tt||Ke<=tt&&nt<=mt||(ut?mt>=Ke*(tt/nt):tt>=nt*(mt/Ke)))?ze="inside":(ze="outside",Ze.remove(),Ze=null)):ze="inside"),!Ze){var Ft=(Ze=kt(Ie,pt,st=s.ensureUniformFontSize(De,ze==="outside"?Ve:_e))).attr("transform");if(Ze.attr("transform",""),Ke=(Ge=h.bBox(Ze.node())).width,nt=Ge.height,Ze.attr("transform",Ft),Ke<=0||nt<=0)return void Ze.remove()}var Vt,St=Je.textangle;Vt=ze==="outside"?function(Dt,gt,ht,yt,qt,Et){var jt,Tt=!!Et.isHorizontal,Ot=!!Et.constrained,At=Et.angle||0,Lt=qt.width,Rt=qt.height,$t=Math.abs(gt-Dt),Yt=Math.abs(yt-ht);jt=Tt?Yt>2*S?S:0:$t>2*S?S:0;var Xt=1;Ot&&(Xt=Tt?Math.min(1,Yt/Rt):Math.min(1,$t/Lt));var Bt=F(At),Wt=A(qt,Bt),tn=(Tt?Wt.x:Wt.y)/2,cn=(qt.left+qt.right)/2,ln=(qt.top+qt.bottom)/2,an=(Dt+gt)/2,sn=(ht+yt)/2,Zt=0,pn=0,nn=Tt?D(gt,Dt):D(ht,yt);return Tt?(an=gt-nn*jt,Zt=nn*tn):(sn=yt+nn*jt,pn=-nn*tn),{textX:cn,textY:ln,targetX:an,targetY:sn,anchorX:Zt,anchorY:pn,scale:Xt,rotate:Bt}}(qe,Ye,at,lt,Ge,{isHorizontal:ut,constrained:Je.constraintext==="both"||Je.constraintext==="outside",angle:St}):z(qe,Ye,at,lt,Ge,{isHorizontal:ut,constrained:Je.constraintext==="both"||Je.constraintext==="inside",angle:St,anchor:Je.insidetextanchor}),Vt.fontSize=st.size,v(Je.type==="histogram"?"bar":Je.type,Vt,it),Mt.transform=Vt;var Nt=O(Ze,it,ct,bt);s.setTransormAndDisplay(Nt,Vt)}else Ie.select("text").remove()})(B,$,ye,te,Oe,ne,de,xe,ue,E,W),$.layerClipId&&h.hideOutsideRangePoint(Se,ye.select("text"),G,L,U.xcalendar,U.ycalendar)});var Te=U.cliponaxis===!1;h.setClipUrl(ee,Te?null:$.layerClipId,B)});p.getComponentMethod("errorbars","plot")(B,V,$,E)},toMoveInsideBar:z}},81974:function(o){function a(n,l,f,s,u){var d=l.c2p(s?n.s0:n.p0,!0),h=l.c2p(s?n.s1:n.p1,!0),p=f.c2p(s?n.p0:n.s0,!0),g=f.c2p(s?n.p1:n.s1,!0);return u?[(d+h)/2,(p+g)/2]:s?[h,(p+g)/2]:[(d+h)/2,g]}o.exports=function(n,l){var f,s=n.cd,u=n.xaxis,d=n.yaxis,h=s[0].trace,p=h.type==="funnel",g=h.orientation==="h",y=[];if(l===!1)for(f=0;f1||O.bargap===0&&O.bargroupgap===0&&!R[0].trace.marker.line.width)&&l.select(this).attr("shape-rendering","crispEdges")}),P.selectAll("g.points").each(function(R){b(l.select(this),R[0].trace,C)}),d.getComponentMethod("errorbars","style")(P)},styleTextPoints:x,styleOnSelect:function(C,P,D){var O=P[0].trace;O.selectedpoints?function(R,F,A){s.selectedPointStyle(R.selectAll("path"),F),function(z,B,$){z.each(function(j){var N,E=l.select(this);if(j.selected){N=u.ensureUniformFontSize($,_(E,j,B,$));var W=B.selected.textfont&&B.selected.textfont.color;W&&(N.color=W),s.font(E,N)}else s.selectedTextStyle(E,B)})}(R.selectAll("text"),F,A)}(D,O,C):(b(D,O,C),d.getComponentMethod("errorbars","style")(D))},getInsideTextFont:k,getOutsideTextFont:T,getBarColor:S,resizeText:h}},98340:function(o,a,n){var l=n(7901),f=n(52075).hasColorscale,s=n(1586),u=n(71828).coercePattern;o.exports=function(d,h,p,g,y){var v=p("marker.color",g),m=f(d,"marker");m&&s(d,h,y,p,{prefix:"marker.",cLetter:"c"}),p("marker.line.color",l.defaultLine),f(d,"marker.line")&&s(d,h,y,p,{prefix:"marker.line.",cLetter:"c"}),p("marker.line.width"),p("marker.opacity"),u(p,"marker.pattern",v,m),p("selected.marker.color"),p("unselected.marker.color")}},72597:function(o,a,n){var l=n(39898),f=n(71828);function s(u){return"_"+u+"Text_minsize"}o.exports={recordMinTextSize:function(u,d,h){if(h.uniformtext.mode){var p=s(u),g=h.uniformtext.minsize,y=d.scale*d.fontSize;d.hide=y g.point"}d.selectAll(y).each(function(m){var b=m.transform;if(b){b.scale=v&&b.hide?0:g/b.fontSize;var x=l.select(this).select("text");f.setTransormAndDisplay(x,b)}})}}}},53522:function(o,a,n){var l=n(82196),f=n(1486),s=n(22399),u=n(12663).axisHoverFormat,d=n(5386).fF,h=n(1426).extendFlat,p=l.marker,g=p.line;o.exports={y:{valType:"data_array",editType:"calc+clearAxisTypes"},x:{valType:"data_array",editType:"calc+clearAxisTypes"},x0:{valType:"any",editType:"calc+clearAxisTypes"},y0:{valType:"any",editType:"calc+clearAxisTypes"},dx:{valType:"number",editType:"calc"},dy:{valType:"number",editType:"calc"},xperiod:l.xperiod,yperiod:l.yperiod,xperiod0:l.xperiod0,yperiod0:l.yperiod0,xperiodalignment:l.xperiodalignment,yperiodalignment:l.yperiodalignment,xhoverformat:u("x"),yhoverformat:u("y"),name:{valType:"string",editType:"calc+clearAxisTypes"},q1:{valType:"data_array",editType:"calc+clearAxisTypes"},median:{valType:"data_array",editType:"calc+clearAxisTypes"},q3:{valType:"data_array",editType:"calc+clearAxisTypes"},lowerfence:{valType:"data_array",editType:"calc"},upperfence:{valType:"data_array",editType:"calc"},notched:{valType:"boolean",editType:"calc"},notchwidth:{valType:"number",min:0,max:.5,dflt:.25,editType:"calc"},notchspan:{valType:"data_array",editType:"calc"},boxpoints:{valType:"enumerated",values:["all","outliers","suspectedoutliers",!1],editType:"calc"},jitter:{valType:"number",min:0,max:1,editType:"calc"},pointpos:{valType:"number",min:-2,max:2,editType:"calc"},sdmultiple:{valType:"number",min:0,editType:"calc",dflt:1},sizemode:{valType:"enumerated",values:["quartiles","sd"],editType:"calc",dflt:"quartiles"},boxmean:{valType:"enumerated",values:[!0,"sd",!1],editType:"calc"},mean:{valType:"data_array",editType:"calc"},sd:{valType:"data_array",editType:"calc"},orientation:{valType:"enumerated",values:["v","h"],editType:"calc+clearAxisTypes"},quartilemethod:{valType:"enumerated",values:["linear","exclusive","inclusive"],dflt:"linear",editType:"calc"},width:{valType:"number",min:0,dflt:0,editType:"calc"},marker:{outliercolor:{valType:"color",dflt:"rgba(0, 0, 0, 0)",editType:"style"},symbol:h({},p.symbol,{arrayOk:!1,editType:"plot"}),opacity:h({},p.opacity,{arrayOk:!1,dflt:1,editType:"style"}),angle:h({},p.angle,{arrayOk:!1,editType:"calc"}),size:h({},p.size,{arrayOk:!1,editType:"calc"}),color:h({},p.color,{arrayOk:!1,editType:"style"}),line:{color:h({},g.color,{arrayOk:!1,dflt:s.defaultLine,editType:"style"}),width:h({},g.width,{arrayOk:!1,dflt:0,editType:"style"}),outliercolor:{valType:"color",editType:"style"},outlierwidth:{valType:"number",min:0,dflt:1,editType:"style"},editType:"style"},editType:"plot"},line:{color:{valType:"color",editType:"style"},width:{valType:"number",min:0,dflt:2,editType:"style"},editType:"plot"},fillcolor:l.fillcolor,whiskerwidth:{valType:"number",min:0,max:1,dflt:.5,editType:"calc"},showwhiskers:{valType:"boolean",editType:"calc"},offsetgroup:f.offsetgroup,alignmentgroup:f.alignmentgroup,selected:{marker:l.selected.marker,editType:"style"},unselected:{marker:l.unselected.marker,editType:"style"},text:h({},l.text,{}),hovertext:h({},l.hovertext,{}),hovertemplate:d({}),hoveron:{valType:"flaglist",flags:["boxes","points"],dflt:"boxes+points",editType:"style"}}},48518:function(o,a,n){var l=n(92770),f=n(89298),s=n(42973),u=n(71828),d=n(50606).BADNUM,h=u._;o.exports=function(k,T){var M,S,C,P,D,O,R,F=k._fullLayout,A=f.getFromId(k,T.xaxis||"x"),z=f.getFromId(k,T.yaxis||"y"),B=[],$=T.type==="violin"?"_numViolins":"_numBoxes";T.orientation==="h"?(C=A,P="x",D=z,O="y",R=!!T.yperiodalignment):(C=z,P="y",D=A,O="x",R=!!T.xperiodalignment);var j,N,E,W,G,L,q=function(Re,Ie,Be,Ue){var qe,Ye=Ie+"0"in Re;if(Ie in Re||Ye&&"d"+Ie in Re){var at=Be.makeCalcdata(Re,Ie);return[s(Re,Be,Ie,at).vals,at]}qe=Ye?Re[Ie+"0"]:"name"in Re&&(Be.type==="category"||l(Re.name)&&["linear","log"].indexOf(Be.type)!==-1||u.isDateTime(Re.name)&&Be.type==="date")?Re.name:Ue;for(var lt=Be.type==="multicategory"?Be.r2c_just_indices(qe):Be.d2c(qe,0,Re[Ie+"calendar"]),ct=Re._length,bt=new Array(ct),ze=0;zej.uf};if(T._hasPreCompStats){var Y=T[P],Z=function(Re){return C.d2c((T[Re]||[])[M])},X=1/0,re=-1/0;for(M=0;M=j.q1&&j.q3>=j.med){var le=Z("lowerfence");j.lf=le!==d&&le<=j.q1?le:m(j,E,W);var se=Z("upperfence");j.uf=se!==d&&se>=j.q3?se:b(j,E,W);var pe=Z("mean");j.mean=pe!==d?pe:W?u.mean(E,W):(j.q1+j.q3)/2;var Te=Z("sd");j.sd=pe!==d&&Te>=0?Te:W?u.stdev(E,W,j.mean):j.q3-j.q1,j.lo=x(j),j.uo=_(j);var Se=Z("notchspan");Se=Se!==d&&Se>0?Se:w(j,W),j.ln=j.med-Se,j.un=j.med+Se;var Oe=j.lf,Me=j.uf;T.boxpoints&&E.length&&(Oe=Math.min(Oe,E[0]),Me=Math.max(Me,E[W-1])),T.notched&&(Oe=Math.min(Oe,j.ln),Me=Math.max(Me,j.un)),j.min=Oe,j.max=Me}else{var ce;u.warn(["Invalid input - make sure that q1 <= median <= q3","q1 = "+j.q1,"median = "+j.med,"q3 = "+j.q3].join(`
-`)),ce=j.med!==d?j.med:j.q1!==d?j.q3!==d?(j.q1+j.q3)/2:j.q1:j.q3!==d?j.q3:0,j.med=ce,j.q1=j.q3=ce,j.lf=j.uf=ce,j.mean=j.sd=ce,j.ln=j.un=ce,j.min=j.max=ce}X=Math.min(X,j.min),re=Math.max(re,j.max),j.pts2=N.filter(Q),B.push(j)}}T._extremes[C._id]=f.findExtremes(C,[X,re],{padded:!0})}else{var ye=C.makeCalcdata(T,P),J=function(Re,Ie){for(var Be=Re.length,Ue=new Array(Be+1),qe=0;qe=0&&xe0){var Ae,Ee;(j={}).pos=j[O]=ee[M],N=j.pts=de[M].sort(y),W=(E=j[P]=N.map(v)).length,j.min=E[0],j.max=E[W-1],j.mean=u.mean(E,W),j.sd=u.stdev(E,W,j.mean)*T.sdmultiple,j.med=u.interp(E,.5),W%2&&(we||ke)?(we?(Ae=E.slice(0,W/2),Ee=E.slice(W/2+1)):ke&&(Ae=E.slice(0,W/2+1),Ee=E.slice(W/2)),j.q1=u.interp(Ae,.5),j.q3=u.interp(Ee,.5)):(j.q1=u.interp(E,.25),j.q3=u.interp(E,.75)),j.lf=m(j,E,W),j.uf=b(j,E,W),j.lo=x(j),j.uo=_(j);var De=w(j,W);j.ln=j.med-De,j.un=j.med+De,ue=Math.min(ue,j.ln),ge=Math.max(ge,j.un),j.pts2=N.filter(Q),B.push(j)}T._extremes[C._id]=f.findExtremes(C,T.notched?ye.concat([ue,ge]):ye,{padded:!0})}return function(Re,Ie){if(u.isArrayOrTypedArray(Ie.selectedpoints))for(var Be=0;Be0?(B[0].t={num:F[$],dPos:U,posLetter:O,valLetter:P,labels:{med:h(k,"median:"),min:h(k,"min:"),q1:h(k,"q1:"),q3:h(k,"q3:"),max:h(k,"max:"),mean:T.boxmean==="sd"||T.sizemode==="sd"?h(k,"mean ± σ:").replace("σ",T.sdmultiple===1?"σ":T.sdmultiple+"σ"):h(k,"mean:"),lf:h(k,"lower fence:"),uf:h(k,"upper fence:")}},F[$]++,B):[{t:{empty:!0}}]};var p={text:"tx",hovertext:"htx"};function g(k,T,M){for(var S in p)u.isArrayOrTypedArray(T[S])&&(Array.isArray(M)?u.isArrayOrTypedArray(T[S][M[0]])&&(k[p[S]]=T[S][M[0]][M[1]]):k[p[S]]=T[S][M])}function y(k,T){return k.v-T.v}function v(k){return k.v}function m(k,T,M){return M===0?k.q1:Math.min(k.q1,T[Math.min(u.findBin(2.5*k.q1-1.5*k.q3,T,!0)+1,M-1)])}function b(k,T,M){return M===0?k.q3:Math.max(k.q3,T[Math.max(u.findBin(2.5*k.q3-1.5*k.q1,T),0)])}function x(k){return 4*k.q1-3*k.q3}function _(k){return 4*k.q3-3*k.q1}function w(k,T){return T===0?0:1.57*(k.q3-k.q1)/Math.sqrt(T)}},37188:function(o,a,n){var l=n(89298),f=n(71828),s=n(99082).getAxisGroup,u=["v","h"];function d(h,p,g,y){var v,m,b,x=p.calcdata,_=p._fullLayout,w=y._id,k=w.charAt(0),T=[],M=0;for(v=0;v1,O=1-_[h+"gap"],R=1-_[h+"groupgap"];for(v=0;v0){var ie=N.pointpos,le=N.jitter,se=N.marker.size/2,pe=0;ie+le>=0&&((pe=X*(ie+le))>$?(re=!0,Y=se,U=pe):pe>te&&(Y=se,U=$)),pe<=$&&(U=$);var Te=0;ie-le<=0&&((Te=-X*(ie-le))>j?(re=!0,Z=se,Q=Te):Te>ee&&(Z=se,Q=j)),Te<=j&&(Q=j)}else U=$,Q=j;var Se=new Array(b.length);for(m=0;m0?(D="v",O=F>0?Math.min(z,A):Math.min(A)):F>0?(D="h",O=Math.min(z)):O=0;if(O){m._length=O;var W=b("orientation",D);m._hasPreCompStats?W==="v"&&F===0?(b("x0",0),b("dx",1)):W==="h"&&R===0&&(b("y0",0),b("dy",1)):W==="v"&&F===0?b("x0"):W==="h"&&R===0&&b("y0"),f.getComponentMethod("calendars","handleTraceDefaults")(v,m,["x","y"],x)}else m.visible=!1}function y(v,m,b,x){var _=x.prefix,w=l.coerce2(v,m,p,"marker.outliercolor"),k=b("marker.line.outliercolor"),T="outliers";m._hasPreCompStats?T="all":(w||k)&&(T="suspectedoutliers");var M=b(_+"points",T);M?(b("jitter",M==="all"?.3:0),b("pointpos",M==="all"?-1.5:0),b("marker.symbol"),b("marker.opacity"),b("marker.size"),b("marker.angle"),b("marker.color",m.line.color),b("marker.line.color"),b("marker.line.width"),M==="suspectedoutliers"&&(b("marker.line.outliercolor",m.marker.color),b("marker.line.outlierwidth")),b("selected.marker.color"),b("unselected.marker.color"),b("selected.marker.size"),b("unselected.marker.size"),b("text"),b("hovertext")):delete m.marker;var S=b("hoveron");S!=="all"&&S.indexOf("points")===-1||b("hovertemplate"),l.coerceSelectionMarkerOpacity(m,b)}o.exports={supplyDefaults:function(v,m,b,x){function _(O,R){return l.coerce(v,m,p,O,R)}if(g(v,m,_,x),m.visible!==!1){u(v,m,x,_),_("xhoverformat"),_("yhoverformat");var w=m._hasPreCompStats;w&&(_("lowerfence"),_("upperfence")),_("line.color",(v.marker||{}).color||b),_("line.width"),_("fillcolor",s.addOpacity(m.line.color,.5));var k=!1;if(w){var T=_("mean"),M=_("sd");T&&T.length&&(k=!0,M&&M.length&&(k="sd"))}_("whiskerwidth");var S,C=_("sizemode");C==="quartiles"&&(S=_("boxmean",k)),_("showwhiskers",C==="quartiles"),C!=="sd"&&S!=="sd"||_("sdmultiple"),_("width"),_("quartilemethod");var P=!1;if(w){var D=_("notchspan");D&&D.length&&(P=!0)}else l.validate(v.notchwidth,p.notchwidth)&&(P=!0);_("notched",P)&&_("notchwidth"),y(v,m,_,{prefix:"box"})}},crossTraceDefaults:function(v,m){var b,x;function _(T){return l.coerce(x._input,x,p,T)}for(var w=0;wM.lo&&(E.so=!0)}return P});T.enter().append("path").classed("point",!0),T.exit().remove(),T.call(s.translatePoints,m,b)}function h(p,g,y,v){var m,b,x=g.val,_=g.pos,w=!!_.rangebreaks,k=v.bPos,T=v.bPosPxOffset||0,M=y.boxmean||(y.meanline||{}).visible;Array.isArray(v.bdPos)?(m=v.bdPos[0],b=v.bdPos[1]):(m=v.bdPos,b=v.bdPos);var S=p.selectAll("path.mean").data(y.type==="box"&&y.boxmean||y.type==="violin"&&y.box.visible&&y.meanline.visible?f.identity:[]);S.enter().append("path").attr("class","mean").style({fill:"none","vector-effect":"non-scaling-stroke"}),S.exit().remove(),S.each(function(C){var P=_.c2l(C.pos+k,!0),D=_.l2p(P-m)+T,O=_.l2p(P+b)+T,R=w?(D+O)/2:_.l2p(P)+T,F=x.c2p(C.mean,!0),A=x.c2p(C.mean-C.sd,!0),z=x.c2p(C.mean+C.sd,!0);y.orientation==="h"?l.select(this).attr("d","M"+F+","+D+"V"+O+(M==="sd"?"m0,0L"+A+","+R+"L"+F+","+D+"L"+z+","+R+"Z":"")):l.select(this).attr("d","M"+D+","+F+"H"+O+(M==="sd"?"m0,0L"+R+","+A+"L"+D+","+F+"L"+R+","+z+"Z":""))})}o.exports={plot:function(p,g,y,v){var m=p._context.staticPlot,b=g.xaxis,x=g.yaxis;f.makeTraceGroups(v,y,"trace boxes").each(function(_){var w,k,T=l.select(this),M=_[0],S=M.t,C=M.trace;S.wdPos=S.bdPos*C.whiskerwidth,C.visible!==!0||S.empty?T.remove():(C.orientation==="h"?(w=x,k=b):(w=b,k=x),u(T,{pos:w,val:k},C,S,m),d(T,{x:b,y:x},C,S),h(T,{pos:w,val:k},C,S))})},plotBoxAndWhiskers:u,plotPoints:d,plotBoxMean:h}},24626:function(o){o.exports=function(a,n){var l,f,s=a.cd,u=a.xaxis,d=a.yaxis,h=[];if(n===!1)for(l=0;ld.level||d.starts.length&&u===d.level)}break;case"constraint":if(f.prefixBoundary=!1,f.edgepaths.length)return;var h=f.x.length,p=f.y.length,g=-1/0,y=1/0;for(l=0;l":b>g&&(f.prefixBoundary=!0);break;case"<":(bg||f.starts.length&&m===y)&&(f.prefixBoundary=!0);break;case"][":v=Math.min(b[0],b[1]),m=Math.max(b[0],b[1]),vg&&(f.prefixBoundary=!0)}}}},90654:function(o,a,n){var l=n(21081),f=n(86068),s=n(53572);o.exports={min:"zmin",max:"zmax",calc:function(u,d,h){var p=d.contours,g=d.line,y=p.size||1,v=p.coloring,m=f(d,{isColorbar:!0});if(v==="heatmap"){var b=l.extractOpts(d);h._fillgradient=b.reversescale?l.flipScale(b.colorscale):b.colorscale,h._zrange=[b.min,b.max]}else v==="fill"&&(h._fillcolor=m);h._line={color:v==="lines"?m:g.color,width:p.showlines!==!1?g.width:0,dash:g.dash},h._levels={start:p.start,end:s(p),size:y}}}},36914:function(o){o.exports={BOTTOMSTART:[1,9,13,104,713],TOPSTART:[4,6,7,104,713],LEFTSTART:[8,12,14,208,1114],RIGHTSTART:[2,3,11,208,1114],NEWDELTA:[null,[-1,0],[0,-1],[-1,0],[1,0],null,[0,-1],[-1,0],[0,1],[0,1],null,[0,1],[1,0],[1,0],[0,-1]],CHOOSESADDLE:{104:[4,1],208:[2,8],713:[7,13],1114:[11,14]},SADDLEREMAINDER:{1:4,2:8,4:1,7:13,8:2,11:14,13:7,14:11},LABELDISTANCE:2,LABELINCREASE:10,LABELMIN:3,LABELMAX:10,LABELOPTIMIZER:{EDGECOST:1,ANGLECOST:1,NEIGHBORCOST:5,SAMELEVELFACTOR:10,SAMELEVELDISTANCE:5,MAXCOST:100,INITIALSEARCHPOINTS:10,ITERATIONS:5}}},83179:function(o,a,n){var l=n(92770),f=n(14523),s=n(7901),u=s.addOpacity,d=s.opacity,h=n(74808),p=h.CONSTRAINT_REDUCTION,g=h.COMPARISON_OPS2;o.exports=function(y,v,m,b,x,_){var w,k,T,M=v.contours,S=m("contours.operation");M._operation=p[S],function(C,P){var D;g.indexOf(P.operation)===-1?(C("contours.value",[0,1]),Array.isArray(P.value)?P.value.length>2?P.value=P.value.slice(2):P.length===0?P.value=[0,1]:P.length<2?(D=parseFloat(P.value[0]),P.value=[D,D+1]):P.value=[parseFloat(P.value[0]),parseFloat(P.value[1])]:l(P.value)&&(D=parseFloat(P.value),P.value=[D,D+1])):(C("contours.value",0),l(P.value)||(Array.isArray(P.value)?P.value=parseFloat(P.value[0]):P.value=0))}(m,M),S==="="?w=M.showlines=!0:(w=m("contours.showlines"),T=m("fillcolor",u((y.line||{}).color||x,.5))),w&&(k=m("line.color",T&&d(T)?u(v.fillcolor,1):x),m("line.width",2),m("line.dash")),m("line.smoothing"),f(m,b,k,_)}},64237:function(o,a,n){var l=n(74808),f=n(92770);function s(h,p){var g,y=Array.isArray(p);function v(m){return f(m)?+m:null}return l.COMPARISON_OPS2.indexOf(h)!==-1?g=v(y?p[0]:p):l.INTERVAL_OPS.indexOf(h)!==-1?g=y?[v(p[0]),v(p[1])]:[v(p),v(p)]:l.SET_OPS.indexOf(h)!==-1&&(g=y?p.map(v):[v(p)]),g}function u(h){return function(p){p=s(h,p);var g=Math.min(p[0],p[1]),y=Math.max(p[0],p[1]);return{start:g,end:y,size:y-g}}}function d(h){return function(p){return{start:p=s(h,p),end:1/0,size:1/0}}}o.exports={"[]":u("[]"),"][":u("]["),">":d(">"),"<":d("<"),"=":d("=")}},67217:function(o){o.exports=function(a,n,l,f){var s=f("contours.start"),u=f("contours.end"),d=s===!1||u===!1,h=l("contours.size");!(d?n.autocontour=!0:l("autocontour",!1))&&h||l("ncontours")}},84857:function(o,a,n){var l=n(71828);function f(s){return l.extendFlat({},s,{edgepaths:l.extendDeep([],s.edgepaths),paths:l.extendDeep([],s.paths),starts:l.extendDeep([],s.starts)})}o.exports=function(s,u){var d,h,p,g=function(m){return m.reverse()},y=function(m){return m};switch(u){case"=":case"<":return s;case">":for(s.length!==1&&l.warn("Contour data invalid for the specified inequality operation."),h=s[0],d=0;d1e3){l.warn("Too many contours, clipping at 1000",u);break}return y}},53572:function(o){o.exports=function(a){return a.end+a.size/1e6}},81696:function(o,a,n){var l=n(71828),f=n(36914);function s(h,p,g,y){return Math.abs(h[0]-p[0])20&&re?X===208||X===1114?le=ie[0]===0?1:-1:se=ie[1]===0?1:-1:f.BOTTOMSTART.indexOf(X)!==-1?se=1:f.LEFTSTART.indexOf(X)!==-1?le=1:f.TOPSTART.indexOf(X)!==-1?se=-1:le=-1,[le,se]}(x,g,p),w=[d(h,p,[-_[0],-_[1]])],k=h.z.length,T=h.z[0].length,M=p.slice(),S=_.slice();for(m=0;m<1e4;m++){if(x>20?(x=f.CHOOSESADDLE[x][(_[0]||_[1])<0?0:1],h.crossings[b]=f.SADDLEREMAINDER[x]):delete h.crossings[b],!(_=f.NEWDELTA[x])){l.log("Found bad marching index:",x,p,h.level);break}w.push(d(h,p,_)),p[0]+=_[0],p[1]+=_[1],b=p.join(","),s(w[w.length-1],w[w.length-2],y,v)&&w.pop();var C=_[0]&&(p[0]<0||p[0]>T-2)||_[1]&&(p[1]<0||p[1]>k-2);if(p[0]===M[0]&&p[1]===M[1]&&_[0]===S[0]&&_[1]===S[1]||g&&C)break;x=h.crossings[b]}m===1e4&&l.log("Infinite loop in contour?");var P,D,O,R,F,A,z,B,$,j,N,E,W,G,L,q=s(w[0],w[w.length-1],y,v),H=0,V=.2*h.smoothing,te=[],ee=0;for(m=1;m=ee;m--)if((P=te[m])=ee&&P+te[D]B&&$--,h.edgepaths[$]=N.concat(w,j));break}Z||(h.edgepaths[B]=w.concat(j))}for(B=0;B=S)&&(h<=M&&(h=M),p>=S&&(p=S),y=Math.floor((p-h)/g)+1,v=0),x=0;xM&&(k.unshift(M),T.unshift(T[0])),k[k.length-1]s?0:1)+(u[0][1]>s?0:2)+(u[1][1]>s?0:4)+(u[1][0]>s?0:8);return d===5||d===10?s>(u[0][0]+u[0][1]+u[1][0]+u[1][1])/4?d===5?713:1114:d===5?104:208:d===15?0:d}o.exports=function(s){var u,d,h,p,g,y,v,m,b,x=s[0].z,_=x.length,w=x[0].length,k=_===2||w===2;for(d=0;d<_-1;d++)for(p=[],d===0&&(p=p.concat(l.BOTTOMSTART)),d===_-2&&(p=p.concat(l.TOPSTART)),u=0;u=0&&(D=L,R=F):Math.abs(P[1]-D[1])<.01?Math.abs(P[1]-L[1])<.01&&(L[0]-P[0])*(D[0]-L[0])>=0&&(D=L,R=F):f.log("endpt to newendpt is not vert. or horz.",P,D,L)}if(P=D,R>=0)break;B+="L"+D}if(R===S.edgepaths.length){f.log("unclosed perimeter path");break}$=R,(N=j.indexOf($)===-1)&&($=j[0],B+="Z")}for($=0;$D.center?D.right-F:F-D.left)/(B+Math.abs(Math.sin(z)*R)),N=(A>D.middle?D.bottom-A:A-D.top)/(Math.abs($)+Math.cos(z)*R);if(j<1||N<1)return 1/0;var E=w.EDGECOST*(1/(j-1)+1/(N-1));E+=w.ANGLECOST*z*z;for(var W=F-B,G=A-$,L=F+B,q=A+$,H=0;H2*w.MAXCOST)break;N&&(F/=2),A=(R=z-F/2)+1.5*F}if(j<=w.MAXCOST)return B},a.addLabelData=function(S,C,P,D){var O=C.fontSize,R=C.width+O/3,F=Math.max(0,C.height-O/3),A=S.x,z=S.y,B=S.theta,$=Math.sin(B),j=Math.cos(B),N=function(W,G){return[A+W*j-G*$,z+W*$+G*j]},E=[N(-R/2,-F/2),N(-R/2,F/2),N(R/2,F/2),N(R/2,-F/2)];P.push({text:C.text,x:A,y:z,dy:C.dy,theta:B,level:C.level,width:R,height:F}),D.push(E)},a.drawLabels=function(S,C,P,D,O){var R=S.selectAll("text").data(C,function(z){return z.text+","+z.x+","+z.y+","+z.theta});if(R.exit().remove(),R.enter().append("text").attr({"data-notex":1,"text-anchor":"middle"}).each(function(z){var B=z.x+Math.sin(z.theta)*z.dy,$=z.y-Math.cos(z.theta)*z.dy;l.select(this).text(z.text).attr({x:B,y:$,transform:"rotate("+180*z.theta/Math.PI+" "+B+" "+$+")"}).call(d.convertToTspans,P)}),O){for(var F="",A=0;Ah.end&&(h.start=h.end=(h.start+h.end)/2),u._input.contours||(u._input.contours={}),f.extendFlat(u._input.contours,{start:h.start,end:h.end,size:h.size}),u._input.autocontour=!0}else if(h.type!=="constraint"){var v,m=h.start,b=h.end,x=u._input.contours;m>b&&(h.start=x.start=b,b=h.end=x.end=m,m=h.start),h.size>0||(v=m===b?1:s(m,b,u.ncontours).dtick,x.size=h.size=v)}}},84426:function(o,a,n){var l=n(39898),f=n(91424),s=n(70035),u=n(86068);o.exports=function(d){var h=l.select(d).selectAll("g.contour");h.style("opacity",function(p){return p[0].trace.opacity}),h.each(function(p){var g=l.select(this),y=p[0].trace,v=y.contours,m=y.line,b=v.size||1,x=v.start,_=v.type==="constraint",w=!_&&v.coloring==="lines",k=!_&&v.coloring==="fill",T=w||k?u(y):null;g.selectAll("g.contourlevel").each(function(C){l.select(this).selectAll("path").call(f.lineGroupStyle,m.width,w?T(C.level):m.color,m.dash)});var M=v.labelfont;if(g.selectAll("g.contourlabels text").each(function(C){f.font(l.select(this),{family:M.family,size:M.size,color:M.color||(w?T(C.level):m.color)})}),_)g.selectAll("g.contourfill path").style("fill",y.fillcolor);else if(k){var S;g.selectAll("g.contourfill path").style("fill",function(C){return S===void 0&&(S=C.level),T(C.level+.5*b)}),S===void 0&&(S=x),g.selectAll("g.contourbg path").style("fill",T(S-.5*b))}}),s(d)}},8724:function(o,a,n){var l=n(1586),f=n(14523);o.exports=function(s,u,d,h,p){var g,y=d("contours.coloring"),v="";y==="fill"&&(g=d("contours.showlines")),g!==!1&&(y!=="lines"&&(v=d("line.color","#000")),d("line.width",.5),d("line.dash")),y!=="none"&&(s.showlegend!==!0&&(u.showlegend=!1),u._dfltShowLegend=!1,l(s,u,h,d,{prefix:"",cLetter:"z"})),d("line.smoothing"),f(d,h,v,p)}},21606:function(o,a,n){var l=n(82196),f=n(9012),s=n(41940),u=n(12663).axisHoverFormat,d=n(5386).fF,h=n(5386).si,p=n(50693),g=n(1426).extendFlat;o.exports=g({z:{valType:"data_array",editType:"calc"},x:g({},l.x,{impliedEdits:{xtype:"array"}}),x0:g({},l.x0,{impliedEdits:{xtype:"scaled"}}),dx:g({},l.dx,{impliedEdits:{xtype:"scaled"}}),y:g({},l.y,{impliedEdits:{ytype:"array"}}),y0:g({},l.y0,{impliedEdits:{ytype:"scaled"}}),dy:g({},l.dy,{impliedEdits:{ytype:"scaled"}}),xperiod:g({},l.xperiod,{impliedEdits:{xtype:"scaled"}}),yperiod:g({},l.yperiod,{impliedEdits:{ytype:"scaled"}}),xperiod0:g({},l.xperiod0,{impliedEdits:{xtype:"scaled"}}),yperiod0:g({},l.yperiod0,{impliedEdits:{ytype:"scaled"}}),xperiodalignment:g({},l.xperiodalignment,{impliedEdits:{xtype:"scaled"}}),yperiodalignment:g({},l.yperiodalignment,{impliedEdits:{ytype:"scaled"}}),text:{valType:"data_array",editType:"calc"},hovertext:{valType:"data_array",editType:"calc"},transpose:{valType:"boolean",dflt:!1,editType:"calc"},xtype:{valType:"enumerated",values:["array","scaled"],editType:"calc+clearAxisTypes"},ytype:{valType:"enumerated",values:["array","scaled"],editType:"calc+clearAxisTypes"},zsmooth:{valType:"enumerated",values:["fast","best",!1],dflt:!1,editType:"calc"},hoverongaps:{valType:"boolean",dflt:!0,editType:"none"},connectgaps:{valType:"boolean",editType:"calc"},xgap:{valType:"number",dflt:0,min:0,editType:"plot"},ygap:{valType:"number",dflt:0,min:0,editType:"plot"},xhoverformat:u("x"),yhoverformat:u("y"),zhoverformat:u("z",1),hovertemplate:d(),texttemplate:h({arrayOk:!1,editType:"plot"},{keys:["x","y","z","text"]}),textfont:s({editType:"plot",autoSize:!0,autoColor:!0,colorEditType:"style"}),showlegend:g({},f.showlegend,{dflt:!1})},{transforms:void 0},p("",{cLetter:"z",autoColorDflt:!1}))},90757:function(o,a,n){var l=n(73972),f=n(71828),s=n(89298),u=n(42973),d=n(17562),h=n(78803),p=n(68296),g=n(4742),y=n(824),v=n(43907),m=n(70769),b=n(50606).BADNUM;function x(_){for(var w=[],k=_.length,T=0;T1){var Z=(Y[Y.length-1]-Y[0])/(Y.length-1),X=Math.abs(Z/100);for(F=0;FX)return!1}return!0}(z.rangebreaks||B.rangebreaks)&&(R=function(Y,Z,X){for(var re=[],ie=-1,le=0;le=0;p--)(g=((b[[(u=(h=x[p])[0])-1,d=h[1]]]||k)[2]+(b[[u+1,d]]||k)[2]+(b[[u,d-1]]||k)[2]+(b[[u,d+1]]||k)[2])/20)&&(y[h]=[u,d,g],x.splice(p,1),v=!0);if(!v)throw"findEmpties iterated with no new neighbors";for(h in y)b[h]=y[h],m.push(y[h])}return m.sort(function(M,S){return S[2]-M[2]})}},46248:function(o,a,n){var l=n(30211),f=n(71828),s=n(89298),u=n(21081).extractOpts;o.exports=function(d,h,p,g,y){y||(y={});var v,m,b,x,_=y.isContour,w=d.cd[0],k=w.trace,T=d.xa,M=d.ya,S=w.x,C=w.y,P=w.z,D=w.xCenter,O=w.yCenter,R=w.zmask,F=k.zhoverformat,A=S,z=C;if(d.index!==!1){try{b=Math.round(d.index[1]),x=Math.round(d.index[0])}catch{return void f.error("Error hovering on heatmap, pointNumber must be [row,col], found:",d.index)}if(b<0||b>=P[0].length||x<0||x>P.length)return}else{if(l.inbox(h-S[0],h-S[S.length-1],0)>0||l.inbox(p-C[0],p-C[C.length-1],0)>0)return;if(_){var B;for(A=[2*S[0]-S[1]],B=1;B