0===(r?D>E:Dn?function(e){return e<=0}:function(e){return e>=0};e.c2g=function(r){var n=e.c2l(r)-t;return(s(n)?n:0)+o},e.g2c=function(r){return e.l2c(r+t-o)},e.g2p=function(e){return e*a},e.c2p=function(t){return e.g2p(e.c2g(t))}}}(e,t);break;case"angularaxis":!function(e,t){var r=e.type;if("linear"===r){var i=e.d2c,s=e.c2d;e.d2c=function(e,t){return function(e,t){return"degrees"===t?a(e):e}(i(e),t)},e.c2d=function(e,t){return s(function(e,t){return"degrees"===t?o(e):e}(e,t))}}e.makeCalcdata=function(t,i){var a,o,s=t[i],l=t._length,u=function(r){return e.d2c(r,t.thetaunit)};if(s){if(n.isTypedArray(s)&&"linear"===r){if(l===s.length)return s;if(s.subarray)return s.subarray(0,l)}for(a=new Array(l),o=0;o0?1:0}function r(e){var t=e[0],r=e[1];if(!isFinite(t)||!isFinite(r))return[1,0];var n=(t+1)*(t+1)+r*r;return[(t*t+r*r-1)/n,2*r/n]}function n(e,t){var r=t[0],n=t[1];return[r*e.radius+e.cx,-n*e.radius+e.cy]}function i(e,t){return t*e.radius}e.exports={smith:r,reactanceArc:function(e,t,a,o){var s=n(e,r([a,t])),l=s[0],u=s[1],c=n(e,r([o,t])),f=c[0],d=c[1];if(0===t)return["M"+l+","+u,"L"+f+","+d].join(" ");var p=i(e,1/Math.abs(t));return["M"+l+","+u,"A"+p+","+p+" 0 0,"+(t<0?1:0)+" "+f+","+d].join(" ")},resistanceArc:function(e,a,o,s){var l=i(e,1/(a+1)),u=n(e,r([a,o])),c=u[0],f=u[1],d=n(e,r([a,s])),p=d[0],h=d[1];if(t(o)!==t(s)){var v=n(e,r([a,0]));return["M"+c+","+f,"A"+l+","+l+" 0 0,"+(00){for(var n=[],i=0;i=c&&(d.min=0,h.min=0,m.min=0,e.aaxis&&delete e.aaxis.min,e.baxis&&delete e.baxis.min,e.caxis&&delete e.caxis.min)}function v(e,t,r,n){var i=d[t._name];function o(r,n){return a.coerce(e,t,i,r,n)}o("uirevision",n.uirevision),t.type="linear";var p=o("color"),h=p!==i.color.dflt?p:r.font.color,v=t._name.charAt(0).toUpperCase(),m="Component "+v,g=o("title.text",m);t._hovertitle=g===m?g:v,a.coerceFont(o,"title.font",{family:r.font.family,size:a.bigFont(r.font.size),color:h}),o("min"),c(e,t,o,"linear"),l(e,t,o,"linear"),s(e,t,o,"linear"),u(e,t,o,{outerTicks:!0}),o("showticklabels")&&(a.coerceFont(o,"tickfont",{family:r.font.family,size:r.font.size,color:h}),o("tickangle"),o("tickformat")),f(e,t,o,{dfltColor:p,bgColor:r.bgColor,blend:60,showLine:!0,showGrid:!0,noZeroLine:!0,attributes:i}),o("hoverformat"),o("layer")}e.exports=function(e,t,r){o(e,t,r,{type:"ternary",attributes:d,handleDefaults:h,font:t.font,paper_bgcolor:t.paper_bgcolor})}},64380:function(e,t,r){"use strict";var n=r(39898),i=r(84267),a=r(73972),o=r(71828),s=o.strTranslate,l=o._,u=r(7901),c=r(91424),f=r(21994),d=r(1426).extendFlat,p=r(74875),h=r(89298),v=r(28569),m=r(30211),g=r(64505),y=g.freeMode,x=g.rectMode,b=r(92998),_=r(47322).prepSelect,w=r(47322).selectOnClick,k=r(47322).clearOutline,T=r(47322).clearSelectionsCache,M=r(85555);function S(e,t){this.id=e.id,this.graphDiv=e.graphDiv,this.init(t),this.makeFramework(t),this.aTickLayout=null,this.bTickLayout=null,this.cTickLayout=null}e.exports=S;var A=S.prototype;A.init=function(e){this.container=e._ternarylayer,this.defs=e._defs,this.layoutId=e._uid,this.traceHash={},this.layers={}},A.plot=function(e,t){var r=this,n=t[r.id],i=t._size;r._hasClipOnAxisFalse=!1;for(var a=0;aC*b?i=(a=b)*C:a=(i=x)/C,o=g*i/x,l=y*a/b,r=t.l+t.w*v-i/2,n=t.t+t.h*(1-m)-a/2,p.x0=r,p.y0=n,p.w=i,p.h=a,p.sum=_,p.xaxis={type:"linear",range:[w+2*T-_,_-w-2*k],domain:[v-o/2,v+o/2],_id:"x"},f(p.xaxis,p.graphDiv._fullLayout),p.xaxis.setScale(),p.xaxis.isPtWithinRange=function(e){return e.a>=p.aaxis.range[0]&&e.a<=p.aaxis.range[1]&&e.b>=p.baxis.range[1]&&e.b<=p.baxis.range[0]&&e.c>=p.caxis.range[1]&&e.c<=p.caxis.range[0]},p.yaxis={type:"linear",range:[w,_-k-T],domain:[m-l/2,m+l/2],_id:"y"},f(p.yaxis,p.graphDiv._fullLayout),p.yaxis.setScale(),p.yaxis.isPtWithinRange=function(){return!0};var M=p.yaxis.domain[0],S=p.aaxis=d({},e.aaxis,{range:[w,_-k-T],side:"left",tickangle:(+e.aaxis.tickangle||0)-30,domain:[M,M+l*C],anchor:"free",position:0,_id:"y",_length:i});f(S,p.graphDiv._fullLayout),S.setScale();var A=p.baxis=d({},e.baxis,{range:[_-w-T,k],side:"bottom",domain:p.xaxis.domain,anchor:"free",position:0,_id:"x",_length:i});f(A,p.graphDiv._fullLayout),A.setScale();var E=p.caxis=d({},e.caxis,{range:[_-w-k,T],side:"right",tickangle:(+e.caxis.tickangle||0)+30,domain:[M,M+l*C],anchor:"free",position:0,_id:"y",_length:i});f(E,p.graphDiv._fullLayout),E.setScale();var P="M"+r+","+(n+a)+"h"+i+"l-"+i/2+",-"+a+"Z";p.clipDef.select("path").attr("d",P),p.layers.plotbg.select("path").attr("d",P);var L="M0,"+a+"h"+i+"l-"+i/2+",-"+a+"Z";p.clipDefRelative.select("path").attr("d",L);var I=s(r,n);p.plotContainer.selectAll(".scatterlayer,.maplayer").attr("transform",I),p.clipDefRelative.select("path").attr("transform",null);var R=s(r-A._offset,n+a);p.layers.baxis.attr("transform",R),p.layers.bgrid.attr("transform",R);var O=s(r+i/2,n)+"rotate(30)"+s(0,-S._offset);p.layers.aaxis.attr("transform",O),p.layers.agrid.attr("transform",O);var D=s(r+i/2,n)+"rotate(-30)"+s(0,-E._offset);p.layers.caxis.attr("transform",D),p.layers.cgrid.attr("transform",D),p.drawAxes(!0),p.layers.aline.select("path").attr("d",S.showline?"M"+r+","+(n+a)+"l"+i/2+",-"+a:"M0,0").call(u.stroke,S.linecolor||"#000").style("stroke-width",(S.linewidth||0)+"px"),p.layers.bline.select("path").attr("d",A.showline?"M"+r+","+(n+a)+"h"+i:"M0,0").call(u.stroke,A.linecolor||"#000").style("stroke-width",(A.linewidth||0)+"px"),p.layers.cline.select("path").attr("d",E.showline?"M"+(r+i/2)+","+n+"l"+i/2+","+a:"M0,0").call(u.stroke,E.linecolor||"#000").style("stroke-width",(E.linewidth||0)+"px"),p.graphDiv._context.staticPlot||p.initInteractions(),c.setClipUrl(p.layers.frontplot,p._hasClipOnAxisFalse?null:p.clipId,p.graphDiv)},A.drawAxes=function(e){var t=this,r=t.graphDiv,n=t.id.substr(7)+"title",i=t.layers,a=t.aaxis,o=t.baxis,s=t.caxis;if(t.drawAx(a),t.drawAx(o),t.drawAx(s),e){var u=Math.max(a.showticklabels?a.tickfont.size/2:0,(s.showticklabels?.75*s.tickfont.size:0)+("outside"===s.ticks?.87*s.ticklen:0)),c=(o.showticklabels?o.tickfont.size:0)+("outside"===o.ticks?o.ticklen:0)+3;i["a-title"]=b.draw(r,"a"+n,{propContainer:a,propName:t.id+".aaxis.title",placeholder:l(r,"Click to enter Component A title"),attributes:{x:t.x0+t.w/2,y:t.y0-a.title.font.size/3-u,"text-anchor":"middle"}}),i["b-title"]=b.draw(r,"b"+n,{propContainer:o,propName:t.id+".baxis.title",placeholder:l(r,"Click to enter Component B title"),attributes:{x:t.x0-c,y:t.y0+t.h+.83*o.title.font.size+c,"text-anchor":"middle"}}),i["c-title"]=b.draw(r,"c"+n,{propContainer:s,propName:t.id+".caxis.title",placeholder:l(r,"Click to enter Component C title"),attributes:{x:t.x0+t.w+c,y:t.y0+t.h+.83*s.title.font.size+c,"text-anchor":"middle"}})}},A.drawAx=function(e){var t,r=this,n=r.graphDiv,i=e._name,a=i.charAt(0),s=e._id,l=r.layers[i],u=a+"tickLayout",c=(t=e).ticks+String(t.ticklen)+String(t.showticklabels);r[u]!==c&&(l.selectAll("."+s+"tick").remove(),r[u]=c),e.setScale();var f=h.calcTicks(e),d=h.clipEnds(e,f),p=h.makeTransTickFn(e),v=h.getTickSigns(e)[2],m=o.deg2rad(30),g=v*(e.linewidth||1)/2,y=v*e.ticklen,x=r.w,b=r.h,_="b"===a?"M0,"+g+"l"+Math.sin(m)*y+","+Math.cos(m)*y:"M"+g+",0l"+Math.cos(m)*y+","+-Math.sin(m)*y,w={a:"M0,0l"+b+",-"+x/2,b:"M0,0l-"+x/2+",-"+b,c:"M0,0l-"+b+","+x/2}[a];h.drawTicks(n,e,{vals:"inside"===e.ticks?d:f,layer:l,path:_,transFn:p,crisp:!1}),h.drawGrid(n,e,{vals:d,layer:r.layers[a+"grid"],path:w,transFn:p,crisp:!1}),h.drawLabels(n,e,{vals:f,layer:l,transFn:p,labelFns:h.makeLabelFns(e,0,30)})};var E=M.MINZOOM/2+.87,P="m-0.87,.5h"+E+"v3h-"+(E+5.2)+"l"+(E/2+2.6)+",-"+(.87*E+4.5)+"l2.6,1.5l-"+E/2+","+.87*E+"Z",L="m0.87,.5h-"+E+"v3h"+(E+5.2)+"l-"+(E/2+2.6)+",-"+(.87*E+4.5)+"l-2.6,1.5l"+E/2+","+.87*E+"Z",I="m0,1l"+E/2+","+.87*E+"l2.6,-1.5l-"+(E/2+2.6)+",-"+(.87*E+4.5)+"l-"+(E/2+2.6)+","+(.87*E+4.5)+"l2.6,1.5l"+E/2+",-"+.87*E+"Z",R=!0;function O(e){n.select(e).selectAll(".zoombox,.js-zoombox-backdrop,.js-zoombox-menu,.zoombox-corners").remove()}A.clearOutline=function(){T(this.dragOptions),k(this.dragOptions.gd)},A.initInteractions=function(){var e,t,r,n,f,d,p,h,g,b,k,T,S=this,A=S.layers.plotbg.select("path").node(),E=S.graphDiv,D=E._fullLayout._zoomlayer;function z(e){var t={};return t[S.id+".aaxis.min"]=e.a,t[S.id+".baxis.min"]=e.b,t[S.id+".caxis.min"]=e.c,t}function F(e,t){var r=E._fullLayout.clickmode;O(E),2===e&&(E.emit("plotly_doubleclick",null),a.call("_guiRelayout",E,z({a:0,b:0,c:0}))),r.indexOf("select")>-1&&1===e&&w(t,E,[S.xaxis],[S.yaxis],S.id,S.dragOptions),r.indexOf("event")>-1&&m.click(E,t,S.id)}function j(e,t){return 1-t/S.h}function N(e,t){return 1-(e+(S.h-t)/Math.sqrt(3))/S.w}function Z(e,t){return(e-(S.h-t)/Math.sqrt(3))/S.w}function B(i,a){var o=r+i*e,s=n+a*t,l=Math.max(0,Math.min(1,j(0,n),j(0,s))),u=Math.max(0,Math.min(1,N(r,n),N(o,s))),c=Math.max(0,Math.min(1,Z(r,n),Z(o,s))),v=(l/2+c)*S.w,m=(1-l/2-u)*S.w,y=(v+m)/2,x=m-v,_=(1-l)*S.h,w=_-x/C;x.2?"rgba(0,0,0,0.4)":"rgba(255,255,255,0.3)").duration(200),T.transition().style("opacity",1).duration(200),b=!0),E.emit("plotly_relayouting",z(p))}function V(){O(E),p!==f&&(a.call("_guiRelayout",E,z(p)),R&&E.data&&E._context.showTips&&(o.notifier(l(E,"Double-click to zoom back out"),"long"),R=!1))}function U(e,t){var r=e/S.xaxis._m,n=t/S.yaxis._m,i=[(p={a:f.a-n,b:f.b+(r+n)/2,c:f.c-(r-n)/2}).a,p.b,p.c].sort(o.sorterAsc),a=i.indexOf(p.a),l=i.indexOf(p.b),u=i.indexOf(p.c);i[0]<0&&(i[1]+i[0]/2<0?(i[2]+=i[0]+i[1],i[0]=i[1]=0):(i[2]+=i[0]/2,i[1]+=i[0]/2,i[0]=0),p={a:i[a],b:i[l],c:i[u]},t=(f.a-p.a)*S.yaxis._m,e=(f.c-p.c-f.b+p.b)*S.xaxis._m);var d=s(S.x0+e,S.y0+t);S.plotContainer.selectAll(".scatterlayer,.maplayer").attr("transform",d);var h=s(-e,-t);S.clipDefRelative.select("path").attr("transform",h),S.aaxis.range=[p.a,S.sum-p.b-p.c],S.baxis.range=[S.sum-p.a-p.c,p.b],S.caxis.range=[S.sum-p.a-p.b,p.c],S.drawAxes(!1),S._hasClipOnAxisFalse&&S.plotContainer.select(".scatterlayer").selectAll(".trace").call(c.hideOutsideRangePoints,S),E.emit("plotly_relayouting",z(p))}function H(){a.call("_guiRelayout",E,z(p))}this.dragOptions={element:A,gd:E,plotinfo:{id:S.id,domain:E._fullLayout[S.id].domain,xaxis:S.xaxis,yaxis:S.yaxis},subplot:S.id,prepFn:function(a,l,c){S.dragOptions.xaxes=[S.xaxis],S.dragOptions.yaxes=[S.yaxis],e=E._fullLayout._invScaleX,t=E._fullLayout._invScaleY;var v=S.dragOptions.dragmode=E._fullLayout.dragmode;y(v)?S.dragOptions.minDrag=1:S.dragOptions.minDrag=void 0,"zoom"===v?(S.dragOptions.moveFn=B,S.dragOptions.clickFn=F,S.dragOptions.doneFn=V,function(e,t,a){var l=A.getBoundingClientRect();r=t-l.left,n=a-l.top,E._fullLayout._calcInverseTransform(E);var c=E._fullLayout._invTransform,v=o.apply3DTransform(c)(r,n);r=v[0],n=v[1],f={a:S.aaxis.range[0],b:S.baxis.range[1],c:S.caxis.range[1]},p=f,d=S.aaxis.range[1]-f.a,h=i(S.graphDiv._fullLayout[S.id].bgcolor).getLuminance(),g="M0,"+S.h+"L"+S.w/2+", 0L"+S.w+","+S.h+"Z",b=!1,k=D.append("path").attr("class","zoombox").attr("transform",s(S.x0,S.y0)).style({fill:h>.2?"rgba(0,0,0,0)":"rgba(255,255,255,0)","stroke-width":0}).attr("d",g),T=D.append("path").attr("class","zoombox-corners").attr("transform",s(S.x0,S.y0)).style({fill:u.background,stroke:u.defaultLine,"stroke-width":1,opacity:0}).attr("d","M0,0Z"),S.clearOutline(E)}(0,l,c)):"pan"===v?(S.dragOptions.moveFn=U,S.dragOptions.clickFn=F,S.dragOptions.doneFn=H,f={a:S.aaxis.range[0],b:S.baxis.range[1],c:S.caxis.range[1]},p=f,S.clearOutline(E)):(x(v)||y(v))&&_(a,l,c,S.dragOptions,v)}},A.onmousemove=function(e){m.hover(E,e,S.id),E._fullLayout._lasthover=A,E._fullLayout._hoversubplot=S.id},A.onmouseout=function(e){E._dragging||v.unhover(E,e)},v.init(this.dragOptions)}},73972:function(e,t,r){"use strict";var n=r(47769),i=r(64213),a=r(75138),o=r(41965),s=r(24401).addStyleRule,l=r(1426),u=r(9012),c=r(10820),f=l.extendFlat,d=l.extendDeepAll;function p(e){var r=e.name,i=e.categories,a=e.meta;if(t.modules[r])n.log("Type "+r+" already registered");else{t.subplotsRegistry[e.basePlotModule.name]||function(e){var r=e.name;if(t.subplotsRegistry[r])n.log("Plot type "+r+" already registered.");else for(var i in g(e),t.subplotsRegistry[r]=e,t.componentsRegistry)b(i,e.name)}(e.basePlotModule);for(var o={},l=0;l-1&&(f[p[r]].title={text:""});for(r=0;r")?"":t.html(e).text()}));return t.remove(),r}(w)).replace(/&(?!\w+;|\#[0-9]+;| \#x[0-9A-F]+;)/g,"&")).replace(c,"'"),i.isIE()&&(w=(w=(w=w.replace(/"/gi,"'")).replace(/(\('#)([^']*)('\))/gi,'("#$2")')).replace(/(\\')/gi,'"')),w}},75341:function(e,t,r){"use strict";var n=r(71828);e.exports=function(e,t){for(var r=0;rf+u||!n(c))}for(var p=0;pa))return t}return void 0!==r?r:e.dflt},t.coerceColor=function(e,t,r){return i(t).isValid()?t:void 0!==r?r:e.dflt},t.coerceEnumerated=function(e,t,r){return e.coerceNumber&&(t=+t),-1!==e.values.indexOf(t)?t:void 0!==r?r:e.dflt},t.getValue=function(e,t){var r;return Array.isArray(e)?t0?t+=r:c<0&&(t-=r)}return t}function O(e){var t=c,r=e.b,i=R(e);return n.inbox(r-t,i-t,_+(i-t)/(i-r)-1)}var D=e[f+"a"],z=e[d+"a"];v=Math.abs(D.r2c(D.range[1])-D.r2c(D.range[0]));var F=n.getDistanceFunction(i,p,h,(function(e){return(p(e)+h(e))/2}));if(n.getClosest(m,F,e),!1!==e.index&&m[e.index].p!==u){T||(E=function(e){return Math.min(M(e),e.p-y.bargroupwidth/2)},P=function(e){return Math.max(S(e),e.p+y.bargroupwidth/2)});var j=m[e.index],N=g.base?j.b+j.s:j.s;e[d+"0"]=e[d+"1"]=z.c2p(j[d],!0),e[d+"LabelVal"]=N;var Z=y.extents[y.extents.round(j.p)];e[f+"0"]=D.c2p(x?E(j):Z[0],!0),e[f+"1"]=D.c2p(x?P(j):Z[1],!0);var B=void 0!==j.orig_p;return e[f+"LabelVal"]=B?j.orig_p:j.p,e.labelLabel=l(D,e[f+"LabelVal"],g[f+"hoverformat"]),e.valueLabel=l(z,e[d+"LabelVal"],g[d+"hoverformat"]),e.baseLabel=l(z,j.b,g[d+"hoverformat"]),e.spikeDistance=(function(e){var t=c,r=e.b,i=R(e);return n.inbox(r-t,i-t,w+(i-t)/(i-r)-1)}(j)+function(e){return L(M(e),S(e),w)}(j))/2,e[f+"Spike"]=D.c2p(j.p,!0),o(j,g,e),e.hovertemplate=g.hovertemplate,e}}function f(e,t){var r=t.mcc||e.marker.color,n=t.mlcc||e.marker.line.color,i=s(e,t);return a.opacity(r)?r:a.opacity(n)&&i?n:void 0}e.exports={hoverPoints:function(e,t,r,n,a){var o=c(e,t,r,n,a);if(o){var s=o.cd,l=s[0].trace,u=s[o.index];return o.color=f(l,u),i.getComponentMethod("errorbars","hoverInfo")(u,l,o),[o]}},hoverOnBars:c,getTraceColor:f}},60822:function(e,t,r){"use strict";e.exports={attributes:r(1486),layoutAttributes:r(43641),supplyDefaults:r(90769).supplyDefaults,crossTraceDefaults:r(90769).crossTraceDefaults,supplyLayoutDefaults:r(13957),calc:r(92290),crossTraceCalc:r(11661).crossTraceCalc,colorbar:r(4898),arraysToCalcdata:r(75341),plot:r(17295).plot,style:r(16688).style,styleOnSelect:r(16688).styleOnSelect,hoverPoints:r(95423).hoverPoints,eventData:r(58065),selectPoints:r(81974),moduleType:"trace",name:"bar",basePlotModule:r(93612),categories:["bar-like","cartesian","svg","bar","oriented","errorBarsOK","showLegend","zoomScale"],animatable:!0,meta:{}}},43641:function(e){"use strict";e.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(e,t,r){"use strict";var n=r(73972),i=r(89298),a=r(71828),o=r(43641);e.exports=function(e,t,r){function s(r,n){return a.coerce(e,t,o,r,n)}for(var l=!1,u=!1,c=!1,f={},d=s("barmode"),p=0;p0}function A(e){return"auto"===e?0:e}function C(e,t){var r=Math.PI/180*t,n=Math.abs(Math.sin(r)),i=Math.abs(Math.cos(r));return{x:e.width*i+e.height*n,y:e.width*n+e.height*i}}function E(e,t,r,n,i,a){var o=!!a.isHorizontal,s=!!a.constrained,l=a.angle||0,u=a.anchor||"end",c="end"===u,f="start"===u,d=((a.leftToRight||0)+1)/2,p=1-d,h=i.width,v=i.height,m=Math.abs(t-e),g=Math.abs(n-r),y=m>2*_&&g>2*_?_:0;m-=2*y,g-=2*y;var x=A(l);"auto"!==l||h<=m&&v<=g||!(h>m||v>g)||(h>g||v>m)&&h.01?W:function(e,t,r){return r&&e===t?e:Math.abs(e-t)>=2?W(e):e>t?Math.ceil(e):Math.floor(e)};N=G(N,Z,z),Z=G(Z,N,z),B=G(B,V,!z),V=G(V,B,!z)}var q=M(a.ensureSingle(R,"path"),L,m,g);if(q.style("vector-effect",I?"none":"non-scaling-stroke").attr("d",isNaN((Z-N)*(V-B))||U&&e._context.staticPlot?"M0,0Z":"M"+N+","+B+"V"+V+"H"+Z+"V"+B+"Z").call(l.setClipUrl,t.layerClipId,e),!L.uniformtext.mode&&F){var Y=l.makePointStyleFns(f);l.singlePointStyle(u,q,f,Y,e)}!function(e,t,r,n,i,s,u,f,p,m,g){var w,k=t.xaxis,S=t.yaxis,P=e._fullLayout;function L(t,r,n){return a.ensureSingle(t,"text").text(r).attr({class:"bartext bartext-"+w,"text-anchor":"middle","data-notex":1}).call(l.font,n).call(o.convertToTspans,e)}var I=n[0].trace,R="h"===I.orientation,O=function(e,t,r,n,i){var o,s=t[0].trace,l=s.texttemplate;return o=l?function(e,t,r,n,i){var o=t[0].trace,s=a.castOption(o,r,"texttemplate");if(!s)return"";var l,u,f,d,p="histogram"===o.type,h="waterfall"===o.type,v="funnel"===o.type,m="h"===o.orientation;function g(e){return c(u,u.c2l(e),!0).text}function y(e){return c(d,d.c2l(e),!0).text}m?(l="y",u=i,f="x",d=n):(l="x",u=n,f="y",d=i);var x=t[r],_={};_.label=x.p,_.labelLabel=_[l+"Label"]=g(x.p);var w=a.castOption(o,x.i,"text");(0===w||w)&&(_.text=w),_.value=x.s,_.valueLabel=_[f+"Label"]=y(x.s);var k={};b(k,o,x.i),(p||void 0===k.x)&&(k.x=m?_.value:_.label),(p||void 0===k.y)&&(k.y=m?_.label:_.value),(p||void 0===k.xLabel)&&(k.xLabel=m?_.valueLabel:_.labelLabel),(p||void 0===k.yLabel)&&(k.yLabel=m?_.labelLabel:_.valueLabel),h&&(_.delta=+x.rawS||x.s,_.deltaLabel=y(_.delta),_.final=x.v,_.finalLabel=y(_.final),_.initial=_.final-_.delta,_.initialLabel=y(_.initial)),v&&(_.value=x.s,_.valueLabel=y(_.value),_.percentInitial=x.begR,_.percentInitialLabel=a.formatPercent(x.begR),_.percentPrevious=x.difR,_.percentPreviousLabel=a.formatPercent(x.difR),_.percentTotal=x.sumR,_.percenTotalLabel=a.formatPercent(x.sumR));var T=a.castOption(o,x.i,"customdata");return T&&(_.customdata=T),a.texttemplateString(s,_,e._d3locale,k,_,o._meta||{})}(e,t,r,n,i):s.textinfo?function(e,t,r,n){var i=e[0].trace,o="h"===i.orientation,s="waterfall"===i.type,l="funnel"===i.type;function u(e){return c(o?n:r,e,!0).text}function f(e){return c(o?r:n,+e,!0).text}var d,p=i.textinfo,h=e[t],v=p.split("+"),m=[],g=function(e){return-1!==v.indexOf(e)};if(g("label")&&m.push(u(e[t].p)),g("text")&&(0===(d=a.castOption(i,h.i,"text"))||d)&&m.push(d),s){var y=+h.rawS||h.s,x=h.v,b=x-y;g("initial")&&m.push(f(b)),g("delta")&&m.push(f(y)),g("final")&&m.push(f(x))}if(l){g("value")&&m.push(f(h.s));var _=0;g("percent initial")&&_++,g("percent previous")&&_++,g("percent total")&&_++;var w=_>1;g("percent initial")&&(d=a.formatPercent(h.begR),w&&(d+=" of initial"),m.push(d)),g("percent previous")&&(d=a.formatPercent(h.difR),w&&(d+=" of previous"),m.push(d)),g("percent total")&&(d=a.formatPercent(h.sumR),w&&(d+=" of total"),m.push(d))}return m.join("
")}(t,r,n,i):v.getValue(s.text,r),v.coerceString(y,o)}(P,n,i,k,S);w=function(e,t){var r=v.getValue(e.textposition,t);return v.coerceEnumerated(x,r)}(I,i);var D="stack"===m.mode||"relative"===m.mode,z=n[i],F=!D||z._outmost;if(O&&"none"!==w&&(!z.isBlank&&s!==u&&f!==p||"auto"!==w&&"inside"!==w)){var j=P.font,N=h.getBarColor(n[i],I),Z=h.getInsideTextFont(I,i,j,N),B=h.getOutsideTextFont(I,i,j),V=r.datum();R?"log"===k.type&&V.s0<=0&&(s=k.range[0]0&&G>0&&(W<=Y&&G<=X||W<=X&&G<=Y||(R?Y>=W*(X/G):X>=G*(Y/W)))?w="inside":(w="outside",U.remove(),U=null)):w="inside"),!U){var K=(U=L(r,O,q=a.ensureUniformFontSize(e,"outside"===w?B:Z))).attr("transform");if(U.attr("transform",""),W=(H=l.bBox(U.node())).width,G=H.height,U.attr("transform",K),W<=0||G<=0)return void U.remove()}var $,J=I.textangle;$="outside"===w?function(e,t,r,n,i,a){var o,s=!!a.isHorizontal,l=!!a.constrained,u=a.angle||0,c=i.width,f=i.height,d=Math.abs(t-e),p=Math.abs(n-r);o=s?p>2*_?_:0:d>2*_?_:0;var h=1;l&&(h=s?Math.min(1,p/f):Math.min(1,d/c));var v=A(u),m=C(i,v),g=(s?m.x:m.y)/2,y=(i.left+i.right)/2,x=(i.top+i.bottom)/2,b=(e+t)/2,w=(r+n)/2,k=0,M=0,S=s?T(t,e):T(r,n);return s?(b=t-S*o,k=S*g):(w=n+S*o,M=-S*g),{textX:y,textY:x,targetX:b,targetY:w,anchorX:k,anchorY:M,scale:h,rotate:v}}(s,u,f,p,H,{isHorizontal:R,constrained:"both"===I.constraintext||"outside"===I.constraintext,angle:J}):E(s,u,f,p,H,{isHorizontal:R,constrained:"both"===I.constraintext||"inside"===I.constraintext,angle:J,anchor:I.insidetextanchor}),$.fontSize=q.size,d("histogram"===I.type?"bar":I.type,$,P),z.transform=$;var Q=M(U,P,m,g);a.setTransormAndDisplay(Q,$)}else r.select("text").remove()}(e,t,R,r,p,N,Z,B,V,m,g),t.layerClipId&&l.hideOutsideRangePoint(u,R.select("text"),w,P,f.xcalendar,f.ycalendar)}));var B=!1===f.cliponaxis;l.setClipUrl(u,B?null:t.layerClipId,e)}));u.getComponentMethod("errorbars","plot")(e,R,t,m)},toMoveInsideBar:E}},81974:function(e){"use strict";function t(e,t,r,n,i){var a=t.c2p(n?e.s0:e.p0,!0),o=t.c2p(n?e.s1:e.p1,!0),s=r.c2p(n?e.p0:e.s0,!0),l=r.c2p(n?e.p1:e.s1,!0);return i?[(a+o)/2,(s+l)/2]:n?[o,(s+l)/2]:[(a+o)/2,l]}e.exports=function(e,r){var n,i=e.cd,a=e.xaxis,o=e.yaxis,s=i[0].trace,l="funnel"===s.type,u="h"===s.orientation,c=[];if(!1===r)for(n=0;n1||0===i.bargap&&0===i.bargroupgap&&!e[0].trace.marker.line.width)&&n.select(this).attr("shape-rendering","crispEdges")})),t.selectAll("g.points").each((function(t){h(n.select(this),t[0].trace,e)})),s.getComponentMethod("errorbars","style")(t)},styleTextPoints:v,styleOnSelect:function(e,t,r){var i=t[0].trace;i.selectedpoints?function(e,t,r){a.selectedPointStyle(e.selectAll("path"),t),function(e,t,r){e.each((function(e){var i,s=n.select(this);if(e.selected){i=o.ensureUniformFontSize(r,m(s,e,t,r));var l=t.selected.textfont&&t.selected.textfont.color;l&&(i.color=l),a.font(s,i)}else a.selectedTextStyle(s,t)}))}(e.selectAll("text"),t,r)}(r,i,e):(h(r,i,e),s.getComponentMethod("errorbars","style")(r))},getInsideTextFont:y,getOutsideTextFont:x,getBarColor:_,resizeText:l}},98340:function(e,t,r){"use strict";var n=r(7901),i=r(52075).hasColorscale,a=r(1586),o=r(71828).coercePattern;e.exports=function(e,t,r,s,l){var u=r("marker.color",s),c=i(e,"marker");c&&a(e,t,l,r,{prefix:"marker.",cLetter:"c"}),r("marker.line.color",n.defaultLine),i(e,"marker.line")&&a(e,t,l,r,{prefix:"marker.line.",cLetter:"c"}),r("marker.line.width"),r("marker.opacity"),o(r,"marker.pattern",u,c),r("selected.marker.color"),r("unselected.marker.color")}},72597:function(e,t,r){"use strict";var n=r(39898),i=r(71828);function a(e){return"_"+e+"Text_minsize"}e.exports={recordMinTextSize:function(e,t,r){if(r.uniformtext.mode){var n=a(e),i=r.uniformtext.minsize,o=t.scale*t.fontSize;t.hide=o g.point"}t.selectAll(s).each((function(e){var t=e.transform;if(t){t.scale=l&&t.hide?0:o/t.fontSize;var r=n.select(this).select("text");i.setTransormAndDisplay(r,t)}}))}}}},55023:function(e,t,r){"use strict";var n=r(5386).fF,i=r(1426).extendFlat,a=r(81245),o=r(1486);e.exports={r:a.r,theta:a.theta,r0:a.r0,dr:a.dr,theta0:a.theta0,dtheta:a.dtheta,thetaunit:a.thetaunit,base:i({},o.base,{}),offset:i({},o.offset,{}),width:i({},o.width,{}),text:i({},o.text,{}),hovertext:i({},o.hovertext,{}),marker:o.marker,hoverinfo:a.hoverinfo,hovertemplate:n(),selected:o.selected,unselected:o.unselected}},74692:function(e,t,r){"use strict";var n=r(52075).hasColorscale,i=r(78803),a=r(75341),o=r(11661).setGroupPositions,s=r(66279),l=r(73972).traceIs,u=r(71828).extendFlat;e.exports={calc:function(e,t){for(var r=e._fullLayout,o=t.subplot,l=r[o].radialaxis,u=r[o].angularaxis,c=l.makeCalcdata(t,"r"),f=u.makeCalcdata(t,"theta"),d=t._length,p=new Array(d),h=c,v=f,m=0;md.range[1]&&(x+=Math.PI),n.getClosest(u,(function(e){return v(y,x,[e.rp0,e.rp1],[e.thetag0,e.thetag1],h)?m+Math.min(1,Math.abs(e.thetag1-e.thetag0)/g)-1+(e.rp1-y)/(e.rp1-e.rp0)-1:1/0}),e),!1!==e.index){var b=u[e.index];e.x0=e.x1=b.ct[0],e.y0=e.y1=b.ct[1];var _=i.extendFlat({},b,{r:b.s,theta:b.p});return o(b,c,e),s(_,c,f,e),e.hovertemplate=c.hovertemplate,e.color=a(c,b),e.xLabelVal=e.yLabelVal=void 0,b.s<0&&(e.idealAlign="left"),[e]}}},23381:function(e,t,r){"use strict";e.exports={moduleType:"trace",name:"barpolar",basePlotModule:r(23580),categories:["polar","bar","showLegend"],attributes:r(55023),layoutAttributes:r(40151),supplyDefaults:r(6135),supplyLayoutDefaults:r(19860),calc:r(74692).calc,crossTraceCalc:r(74692).crossTraceCalc,plot:r(60173),colorbar:r(4898),formatLabels:r(98608),style:r(16688).style,styleOnSelect:r(16688).styleOnSelect,hoverPoints:r(27379),selectPoints:r(81974),meta:{}}},40151:function(e){"use strict";e.exports={barmode:{valType:"enumerated",values:["stack","overlay"],dflt:"stack",editType:"calc"},bargap:{valType:"number",dflt:.1,min:0,max:1,editType:"calc"}}},19860:function(e,t,r){"use strict";var n=r(71828),i=r(40151);e.exports=function(e,t,r){var a,o={};function s(r,o){return n.coerce(e[a]||{},t[a],i,r,o)}for(var l=0;l0?(u=o,c=l):(u=l,c=o);var f=[s.findEnclosingVertexAngles(u,e.vangles)[0],(u+c)/2,s.findEnclosingVertexAngles(c,e.vangles)[1]];return s.pathPolygonAnnulus(n,i,u,c,f,t,r)}:function(e,n,i,o){return a.pathAnnulus(e,n,i,o,t,r)}}(t),h=t.layers.frontplot.select("g.barlayer");a.makeTraceGroups(h,r,"trace bars").each((function(){var r=n.select(this),s=a.ensureSingle(r,"g","points").selectAll("g.point").data(a.identity);s.enter().append("g").style("vector-effect",l?"none":"non-scaling-stroke").style("stroke-miterlimit",2).classed("point",!0),s.exit().remove(),s.each((function(e){var t,r=n.select(this),o=e.rp0=f.c2p(e.s0),s=e.rp1=f.c2p(e.s1),l=e.thetag0=d.c2g(e.p0),h=e.thetag1=d.c2g(e.p1);if(i(o)&&i(s)&&i(l)&&i(h)&&o!==s&&l!==h){var v=f.c2g(e.s1),m=(l+h)/2;e.ct=[u.c2p(v*Math.cos(m)),c.c2p(v*Math.sin(m))],t=p(o,s,l,h)}else t="M0,0Z";a.ensureSingle(r,"path").attr("d",t)})),o.setClipUrl(r,t._hasClipOnAxisFalse?t.clipIds.forTraces:null,e)}))}},53522:function(e,t,r){"use strict";var n=r(82196),i=r(1486),a=r(22399),o=r(12663).axisHoverFormat,s=r(5386).fF,l=r(1426).extendFlat,u=n.marker,c=u.line;e.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:n.xperiod,yperiod:n.yperiod,xperiod0:n.xperiod0,yperiod0:n.yperiod0,xperiodalignment:n.xperiodalignment,yperiodalignment:n.yperiodalignment,xhoverformat:o("x"),yhoverformat:o("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:l({},u.symbol,{arrayOk:!1,editType:"plot"}),opacity:l({},u.opacity,{arrayOk:!1,dflt:1,editType:"style"}),angle:l({},u.angle,{arrayOk:!1,editType:"calc"}),size:l({},u.size,{arrayOk:!1,editType:"calc"}),color:l({},u.color,{arrayOk:!1,editType:"style"}),line:{color:l({},c.color,{arrayOk:!1,dflt:a.defaultLine,editType:"style"}),width:l({},c.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:n.fillcolor,whiskerwidth:{valType:"number",min:0,max:1,dflt:.5,editType:"calc"},showwhiskers:{valType:"boolean",editType:"calc"},offsetgroup:i.offsetgroup,alignmentgroup:i.alignmentgroup,selected:{marker:n.selected.marker,editType:"style"},unselected:{marker:n.unselected.marker,editType:"style"},text:l({},n.text,{}),hovertext:l({},n.hovertext,{}),hovertemplate:s({}),hoveron:{valType:"flaglist",flags:["boxes","points"],dflt:"boxes+points",editType:"style"}}},48518:function(e,t,r){"use strict";var n=r(92770),i=r(89298),a=r(42973),o=r(71828),s=r(50606).BADNUM,l=o._;e.exports=function(e,t){var r,u,y,x,b,_,w,k=e._fullLayout,T=i.getFromId(e,t.xaxis||"x"),M=i.getFromId(e,t.yaxis||"y"),S=[],A="violin"===t.type?"_numViolins":"_numBoxes";"h"===t.orientation?(y=T,x="x",b=M,_="y",w=!!t.yperiodalignment):(y=M,x="y",b=T,_="x",w=!!t.xperiodalignment);var C,E,P,L,I,R,O=function(e,t,r,i){var s,l=t in e,u=t+"0"in e,c="d"+t in e;if(l||u&&c){var f=r.makeCalcdata(e,t);return[a(e,r,t,f).vals,f]}s=u?e[t+"0"]:"name"in e&&("category"===r.type||n(e.name)&&-1!==["linear","log"].indexOf(r.type)||o.isDateTime(e.name)&&"date"===r.type)?e.name:i;for(var d="multicategory"===r.type?r.r2c_just_indices(s):r.d2c(s,0,e[t+"calendar"]),p=e._length,h=new Array(p),v=0;vC.uf};if(t._hasPreCompStats){var B=t[x],V=function(e){return y.d2c((t[e]||[])[r])},U=1/0,H=-1/0;for(r=0;r=C.q1&&C.q3>=C.med){var G=V("lowerfence");C.lf=G!==s&&G<=C.q1?G:p(C,P,L);var q=V("upperfence");C.uf=q!==s&&q>=C.q3?q:h(C,P,L);var Y=V("mean");C.mean=Y!==s?Y:L?o.mean(P,L):(C.q1+C.q3)/2;var X=V("sd");C.sd=Y!==s&&X>=0?X:L?o.stdev(P,L,C.mean):C.q3-C.q1,C.lo=v(C),C.uo=m(C);var K=V("notchspan");K=K!==s&&K>0?K:g(C,L),C.ln=C.med-K,C.un=C.med+K;var $=C.lf,J=C.uf;t.boxpoints&&P.length&&($=Math.min($,P[0]),J=Math.max(J,P[L-1])),t.notched&&($=Math.min($,C.ln),J=Math.max(J,C.un)),C.min=$,C.max=J}else{var Q;o.warn(["Invalid input - make sure that q1 <= median <= q3","q1 = "+C.q1,"median = "+C.med,"q3 = "+C.q3].join("\n")),Q=C.med!==s?C.med:C.q1!==s?C.q3!==s?(C.q1+C.q3)/2:C.q1:C.q3!==s?C.q3:0,C.med=Q,C.q1=C.q3=Q,C.lf=C.uf=Q,C.mean=C.sd=Q,C.ln=C.un=Q,C.min=C.max=Q}U=Math.min(U,C.min),H=Math.max(H,C.max),C.pts2=E.filter(Z),S.push(C)}}t._extremes[y._id]=i.findExtremes(y,[U,H],{padded:!0})}else{var ee=y.makeCalcdata(t,x),te=function(e,t){for(var r=e.length,n=new Array(r+1),i=0;i=0&&ie0){var ce,fe;(C={}).pos=C[_]=j[r],E=C.pts=ne[r].sort(f),L=(P=C[x]=E.map(d)).length,C.min=P[0],C.max=P[L-1],C.mean=o.mean(P,L),C.sd=o.stdev(P,L,C.mean)*t.sdmultiple,C.med=o.interp(P,.5),L%2&&(le||ue)?(le?(ce=P.slice(0,L/2),fe=P.slice(L/2+1)):ue&&(ce=P.slice(0,L/2+1),fe=P.slice(L/2)),C.q1=o.interp(ce,.5),C.q3=o.interp(fe,.5)):(C.q1=o.interp(P,.25),C.q3=o.interp(P,.75)),C.lf=p(C,P,L),C.uf=h(C,P,L),C.lo=v(C),C.uo=m(C);var de=g(C,L);C.ln=C.med-de,C.un=C.med+de,ae=Math.min(ae,C.ln),oe=Math.max(oe,C.un),C.pts2=E.filter(Z),S.push(C)}t._extremes[y._id]=i.findExtremes(y,t.notched?ee.concat([ae,oe]):ee,{padded:!0})}return function(e,t){if(o.isArrayOrTypedArray(t.selectedpoints))for(var r=0;r0?(S[0].t={num:k[A],dPos:N,posLetter:_,valLetter:x,labels:{med:l(e,"median:"),min:l(e,"min:"),q1:l(e,"q1:"),q3:l(e,"q3:"),max:l(e,"max:"),mean:"sd"===t.boxmean||"sd"===t.sizemode?l(e,"mean \xb1 \u03c3:").replace("\u03c3",1===t.sdmultiple?"\u03c3":t.sdmultiple+"\u03c3"):l(e,"mean:"),lf:l(e,"lower fence:"),uf:l(e,"upper fence:")}},k[A]++,S):[{t:{empty:!0}}]};var u={text:"tx",hovertext:"htx"};function c(e,t,r){for(var n in u)o.isArrayOrTypedArray(t[n])&&(Array.isArray(r)?o.isArrayOrTypedArray(t[n][r[0]])&&(e[u[n]]=t[n][r[0]][r[1]]):e[u[n]]=t[n][r])}function f(e,t){return e.v-t.v}function d(e){return e.v}function p(e,t,r){return 0===r?e.q1:Math.min(e.q1,t[Math.min(o.findBin(2.5*e.q1-1.5*e.q3,t,!0)+1,r-1)])}function h(e,t,r){return 0===r?e.q3:Math.max(e.q3,t[Math.max(o.findBin(2.5*e.q3-1.5*e.q1,t),0)])}function v(e){return 4*e.q1-3*e.q3}function m(e){return 4*e.q3-3*e.q1}function g(e,t){return 0===t?0:1.57*(e.q3-e.q1)/Math.sqrt(t)}},37188:function(e,t,r){"use strict";var n=r(89298),i=r(71828),a=r(99082).getAxisGroup,o=["v","h"];function s(e,t,r,o){var s,l,u,c=t.calcdata,f=t._fullLayout,d=o._id,p=d.charAt(0),h=[],v=0;for(s=0;s1,b=1-f[e+"gap"],_=1-f[e+"groupgap"];for(s=0;s0){var H=C.pointpos,W=C.jitter,G=C.marker.size/2,q=0;H+W>=0&&((q=V*(H+W))>S?(U=!0,Z=G,j=q):q>z&&(Z=G,j=S)),q<=S&&(j=S);var Y=0;H-W<=0&&((Y=-V*(H-W))>A?(U=!0,B=G,N=Y):Y>F&&(B=G,N=A)),Y<=A&&(N=A)}else j=S,N=A;var X=new Array(u.length);for(l=0;l0?(m="v",g=x>0?Math.min(_,b):Math.min(b)):x>0?(m="h",g=Math.min(_)):g=0;if(g){t._length=g;var A=r("orientation",m);t._hasPreCompStats?"v"===A&&0===x?(r("x0",0),r("dx",1)):"h"===A&&0===y&&(r("y0",0),r("dy",1)):"v"===A&&0===x?r("x0"):"h"===A&&0===y&&r("y0"),i.getComponentMethod("calendars","handleTraceDefaults")(e,t,["x","y"],a)}else t.visible=!1}function f(e,t,r,i){var a=i.prefix,o=n.coerce2(e,t,u,"marker.outliercolor"),s=r("marker.line.outliercolor"),l="outliers";t._hasPreCompStats?l="all":(o||s)&&(l="suspectedoutliers");var c=r(a+"points",l);c?(r("jitter","all"===c?.3:0),r("pointpos","all"===c?-1.5:0),r("marker.symbol"),r("marker.opacity"),r("marker.size"),r("marker.angle"),r("marker.color",t.line.color),r("marker.line.color"),r("marker.line.width"),"suspectedoutliers"===c&&(r("marker.line.outliercolor",t.marker.color),r("marker.line.outlierwidth")),r("selected.marker.color"),r("unselected.marker.color"),r("selected.marker.size"),r("unselected.marker.size"),r("text"),r("hovertext")):delete t.marker;var f=r("hoveron");"all"!==f&&-1===f.indexOf("points")||r("hovertemplate"),n.coerceSelectionMarkerOpacity(t,r)}e.exports={supplyDefaults:function(e,t,r,i){function s(r,i){return n.coerce(e,t,u,r,i)}if(c(e,t,s,i),!1!==t.visible){o(e,t,i,s),s("xhoverformat"),s("yhoverformat");var l=t._hasPreCompStats;l&&(s("lowerfence"),s("upperfence")),s("line.color",(e.marker||{}).color||r),s("line.width"),s("fillcolor",a.addOpacity(t.line.color,.5));var d=!1;if(l){var p=s("mean"),h=s("sd");p&&p.length&&(d=!0,h&&h.length&&(d="sd"))}s("whiskerwidth");var v,m=s("sizemode");"quartiles"===m&&(v=s("boxmean",d)),s("showwhiskers","quartiles"===m),"sd"!==m&&"sd"!==v||s("sdmultiple"),s("width"),s("quartilemethod");var g=!1;if(l){var y=s("notchspan");y&&y.length&&(g=!0)}else n.validate(e.notchwidth,u.notchwidth)&&(g=!0);s("notched",g)&&s("notchwidth"),f(e,t,s,{prefix:"box"})}},crossTraceDefaults:function(e,t){var r,i;function a(e){return n.coerce(i._input,i,u,e)}for(var o=0;oe.lo&&(_.so=!0)}return a}));h.enter().append("path").classed("point",!0),h.exit().remove(),h.call(a.translatePoints,l,u)}function c(e,t,r,a){var o,s,l=t.val,u=t.pos,c=!!u.rangebreaks,f=a.bPos,d=a.bPosPxOffset||0,p=r.boxmean||(r.meanline||{}).visible;Array.isArray(a.bdPos)?(o=a.bdPos[0],s=a.bdPos[1]):(o=a.bdPos,s=a.bdPos);var h=e.selectAll("path.mean").data("box"===r.type&&r.boxmean||"violin"===r.type&&r.box.visible&&r.meanline.visible?i.identity:[]);h.enter().append("path").attr("class","mean").style({fill:"none","vector-effect":"non-scaling-stroke"}),h.exit().remove(),h.each((function(e){var t=u.c2l(e.pos+f,!0),i=u.l2p(t-o)+d,a=u.l2p(t+s)+d,h=c?(i+a)/2:u.l2p(t)+d,v=l.c2p(e.mean,!0),m=l.c2p(e.mean-e.sd,!0),g=l.c2p(e.mean+e.sd,!0);"h"===r.orientation?n.select(this).attr("d","M"+v+","+i+"V"+a+("sd"===p?"m0,0L"+m+","+h+"L"+v+","+i+"L"+g+","+h+"Z":"")):n.select(this).attr("d","M"+i+","+v+"H"+a+("sd"===p?"m0,0L"+h+","+m+"L"+i+","+v+"L"+h+","+g+"Z":""))}))}e.exports={plot:function(e,t,r,a){var o=e._context.staticPlot,s=t.xaxis,f=t.yaxis;i.makeTraceGroups(a,r,"trace boxes").each((function(e){var t,r,i=n.select(this),a=e[0],d=a.t,p=a.trace;d.wdPos=d.bdPos*p.whiskerwidth,!0!==p.visible||d.empty?i.remove():("h"===p.orientation?(t=f,r=s):(t=s,r=f),l(i,{pos:t,val:r},p,d,o),u(i,{x:s,y:f},p,d),c(i,{pos:t,val:r},p,d))}))},plotBoxAndWhiskers:l,plotPoints:u,plotBoxMean:c}},24626:function(e){"use strict";e.exports=function(e,t){var r,n,i=e.cd,a=e.xaxis,o=e.yaxis,s=[];if(!1===t)for(r=0;r=10)return null;for(var r=1/0,a=-1/0,o=e.length,s=0;s0?Math.floor:Math.ceil,I=E>0?Math.ceil:Math.floor,R=E>0?Math.min:Math.max,O=E>0?Math.max:Math.min,D=L(A+P),z=I(C-P),F=[[f=S(A)]];for(a=D;a*E=0;i--)a[c-i]=e[f][i],o[c-i]=t[f][i];for(s.push({x:a,y:o,bicubic:l}),i=f,a=[],o=[];i>=0;i--)a[f-i]=e[i][0],o[f-i]=t[i][0];return s.push({x:a,y:o,bicubic:u}),s}},20347:function(e,t,r){"use strict";var n=r(89298),i=r(1426).extendFlat;e.exports=function(e,t,r){var a,o,s,l,u,c,f,d,p,h,v,m,g,y,x=e["_"+t],b=e[t+"axis"],_=b._gridlines=[],w=b._minorgridlines=[],k=b._boundarylines=[],T=e["_"+r],M=e[r+"axis"];"array"===b.tickmode&&(b.tickvals=x.slice());var S=e._xctrl,A=e._yctrl,C=S[0].length,E=S.length,P=e._a.length,L=e._b.length;n.prepTicks(b),"array"===b.tickmode&&delete b.tickvals;var I=b.smoothing?3:1;function R(n){var i,a,o,s,l,u,c,f,p,h,v,m,g=[],y=[],x={};if("b"===t)for(a=e.b2j(n),o=Math.floor(Math.max(0,Math.min(L-2,a))),s=a-o,x.length=L,x.crossLength=P,x.xy=function(t){return e.evalxy([],t,a)},x.dxy=function(t,r){return e.dxydi([],t,o,r,s)},i=0;i0&&(p=e.dxydi([],i-1,o,0,s),g.push(l[0]+p[0]/3),y.push(l[1]+p[1]/3),h=e.dxydi([],i-1,o,1,s),g.push(f[0]-h[0]/3),y.push(f[1]-h[1]/3)),g.push(f[0]),y.push(f[1]),l=f;else for(i=e.a2i(n),u=Math.floor(Math.max(0,Math.min(P-2,i))),c=i-u,x.length=P,x.crossLength=L,x.xy=function(t){return e.evalxy([],i,t)},x.dxy=function(t,r){return e.dxydj([],u,t,c,r)},a=0;a0&&(v=e.dxydj([],u,a-1,c,0),g.push(l[0]+v[0]/3),y.push(l[1]+v[1]/3),m=e.dxydj([],u,a-1,c,1),g.push(f[0]-m[0]/3),y.push(f[1]-m[1]/3)),g.push(f[0]),y.push(f[1]),l=f;return x.axisLetter=t,x.axis=b,x.crossAxis=M,x.value=n,x.constvar=r,x.index=d,x.x=g,x.y=y,x.smoothing=M.smoothing,x}function O(n){var i,a,o,s,l,u=[],c=[],f={};if(f.length=x.length,f.crossLength=T.length,"b"===t)for(o=Math.max(0,Math.min(L-2,n)),l=Math.min(1,Math.max(0,n-o)),f.xy=function(t){return e.evalxy([],t,n)},f.dxy=function(t,r){return e.dxydi([],t,o,r,l)},i=0;ix.length-1||_.push(i(O(o),{color:b.gridcolor,width:b.gridwidth,dash:b.griddash}));for(d=c;dx.length-1)&&!(v<0||v>x.length-1))for(m=x[s],g=x[v],a=0;ax[x.length-1]||w.push(i(R(h),{color:b.minorgridcolor,width:b.minorgridwidth,dash:b.minorgriddash}));b.startline&&k.push(i(O(0),{color:b.startlinecolor,width:b.startlinewidth})),b.endline&&k.push(i(O(x.length-1),{color:b.endlinecolor,width:b.endlinewidth}))}else{for(l=5e-15,c=(u=[Math.floor((x[x.length-1]-b.tick0)/b.dtick*(1+l)),Math.ceil((x[0]-b.tick0)/b.dtick/(1+l))].sort((function(e,t){return e-t})))[0],f=u[1],d=c;d<=f;d++)p=b.tick0+b.dtick*d,_.push(i(R(p),{color:b.gridcolor,width:b.gridwidth,dash:b.griddash}));for(d=c-1;dx[x.length-1]||w.push(i(R(h),{color:b.minorgridcolor,width:b.minorgridwidth,dash:b.minorgriddash}));b.startline&&k.push(i(R(x[0]),{color:b.startlinecolor,width:b.startlinewidth})),b.endline&&k.push(i(R(x[x.length-1]),{color:b.endlinecolor,width:b.endlinewidth}))}}},83311:function(e,t,r){"use strict";var n=r(89298),i=r(1426).extendFlat;e.exports=function(e,t){var r,a,o,s=t._labels=[],l=t._gridlines;for(r=0;r