@jrc03c/make-key 0.0.14 → 0.0.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin.js +1 -1
- package/dist/make-key.js +7 -7
- package/moon.yml +52 -0
- package/package.json +6 -12
package/bin.js
CHANGED
package/dist/make-key.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(()=>{var
|
|
1
|
+
(()=>{var qr=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var c=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var X=c((Ry,yr)=>{var dc=new Function(`
|
|
2
2
|
try {
|
|
3
3
|
return this === window
|
|
4
4
|
} catch(e) {}
|
|
@@ -8,13 +8,13 @@
|
|
|
8
8
|
} catch(e) {}
|
|
9
9
|
|
|
10
10
|
return false
|
|
11
|
-
`),ct=class extends Error{constructor(t){
|
|
11
|
+
`),ct=class extends Error{constructor(t){dc()?super(t):super(`
|
|
12
12
|
|
|
13
13
|
\x1B[31m`+t+`
|
|
14
|
-
\x1B[0m`)}};yn.exports=ct});var h=c((Cy,bn)=>{var mc=X();bn.exports=function(e,t){if(!e)throw new mc(t)}});var b=c((ky,Nn)=>{function dc(e){return e===null||typeof e>"u"}Nn.exports=dc});var wn=c((Jy,vn)=>{vn.exports=[Array,ArrayBuffer,BigInt64Array,BigUint64Array,Float32Array,Float64Array,Int16Array,Int32Array,Int8Array,Uint16Array,Uint32Array,Uint8Array,Uint8ClampedArray]});var m=c((Yy,On)=>{var pc=b(),Sn=wn(),gc=Sn.map(e=>e.name);function qc(e){try{return e instanceof Array?!0:pc(e.constructor)?!1:Sn.indexOf(e.constructor)>-1||gc.indexOf(e.constructor.name)>-1}catch{return!1}}On.exports=qc});var q=c(($y,xn)=>{function yc(e){try{return!!e._symbol&&e._symbol===Symbol.for("@jrc03c/js-math-tools/dataframe")}catch{return!1}}xn.exports=yc});var D=c((Ry,Tn)=>{function bc(e){return typeof e=="function"}Tn.exports=bc});var p=c((Ly,_n)=>{function Nc(e){return typeof e=="number"&&!isNaN(e)}_n.exports=Nc});var C=c((Ky,Dn)=>{var vc=m(),wc=b();function Sc(e){return typeof e=="object"&&!wc(e)&&!vc(e)}Dn.exports=Sc});var g=c((Vy,An)=>{function Oc(e){try{return!!e._symbol&&e._symbol===Symbol.for("@jrc03c/js-math-tools/series")}catch{return!1}}An.exports=Oc});var oe=c((Gy,En)=>{var xc=h(),Fn=m(),Tc=q(),_c=D(),lt=p(),jn=C(),Dc=g();function ft(e,t){if(Tc(e)){let i=ft(e.values,t);return i.length>0&<(i[0])&&i[0]>=0&&i[0]<e.index.length&&(i[0]=e.index[i[0]]),i.length>1&<(i[1])&&i[1]>=0&&i[1]<e.columns.length&&(i[1]=e.columns[i[1]]),i}if(Dc(e)){let i=ft(e.values,t);return i.length>0&<(i[0])&&i[0]>=0&&i[0]<e.index.length&&(i[0]=e.index[i[0]]),i}if(xc(jn(e)||Fn(e),"You must pass (1) an object, array, Series, or DataFrame and (2) a function or value into the `indexOf` function!"),!_c(t)){let i=t;t=o=>o===i}function n(i,o,u){if(u=u||[],u.indexOf(i)>-1)return null;if(jn(i)){u.push(i);let a=Object.keys(i).concat(Object.getOwnPropertySymbols(i));for(let l=0;l<a.length;l++){let f=a[l],d=i[f];if(o(d))return[f];let y=n(d,o,u);if(y&&y.length>0)return[f].concat(y)}}else if(Fn(i)){u.push(i);for(let a=0;a<i.length;a++){let l=i[a];if(o(l))return[a];let f=n(l,o,u);if(f&&f.length>0)return[a].concat(f)}}else if(o(i))return[];return null}function s(i){try{return t(i)}catch{return!1}}let r=n(e,s);return r&&r.length>0?r:null}En.exports=ft});var B=c((Wy,Bn)=>{var Ac=oe(),In=m(),Mn=q(),Un=g();function ue(e){function t(n){if(typeof n=="object"){if(n===null)return null;if(In(n))return n instanceof Array?n.map(r=>ue(r)):n.slice();if(Un(n)){let r=n.copy();return r.values=ue(r.values),r}if(Mn(n)){let r=n.copy();return r.values=ue(n.values),r}if(n instanceof Date)return new Date(n.getTime());n=ht(n);let s={};return Object.keys(n).concat(Object.getOwnPropertySymbols(n)).forEach(r=>{s[r]=ue(n[r])}),s}else return n}return t(ht(e))}function ht(e){function t(r,i,o){if(i=i||[],o=o||"",i.indexOf(r)>-1){let u=o.split("/").slice(o.startsWith("/")?1:0);if(u.some((l,f)=>{let d=u.slice(0,u.length-f-1),y=n;return d.forEach(T=>{y=y[T]}),y===r}))return`<reference to "${n===r?"/":"/"+Ac(n,r).join("/")}">`}return typeof r=="object"?r===null?null:(i.push(r),In(r)?typeof r.constructor<"u"&&r.constructor.name!=="Array"?r.slice():r.map((u,a)=>t(u,i,o+"/"+a)):(Object.keys(r).concat(Object.getOwnPropertySymbols(r)).forEach(u=>{r[u]=t(r[u],i,o+"/"+u.toString())}),r)):r}let n=e,s=t(n);if(Mn(e)){let r=e.copy();r._values=s.values,r._columns=s.columns,r._index=s.index,s=r}if(Un(e)){let r=e.copy();r.name=s.name,r._values=s.values,r._index=s.index,s=r}return s}Bn.exports={copy:ue,decycle:ht}});var S=c((Hy,Cn)=>{var Fc=h(),Pn=m(),jc=q(),Ec=g();function zn(e){if(jc(e)||Ec(e))return zn(e.values);Fc(Pn(e),"The `flatten` function only works on arrays, Series, and DataFrames!");function t(n){let s=[];return n.forEach(r=>{Pn(r)?s=s.concat(t(r)):s.push(r)}),s}return t(e)}Cn.exports=zn});var ae=c((Xy,kn)=>{function Ic(e){return e instanceof Date&&e.toString()!=="Invalid Date"}kn.exports=Ic});var I=c((Qy,$n)=>{var{decycle:Jn}=B(),Yn=m(),mt=ae();function Mc(e,t){function n(s,r){let i=typeof s;if(i!==typeof r)return!1;if(i==="undefined")return!0;if(i==="boolean"||i==="symbol")return s===r;if(i==="number"||i==="bigint")return s.toString()==="NaN"&&r.toString()==="NaN"?!0:s===r;if(i==="string"||i==="function")return s===r;if(i==="object"){if(s===null||r===null)return s===null&&r===null;{if(mt(s))return mt(r)?s.getTime()===r.getTime():!1;if(mt(r)||Yn(s)!==Yn(r))return!1;let u=Object.keys(s).concat(Object.getOwnPropertySymbols(s)),a=Object.keys(r).concat(Object.getOwnPropertySymbols(r));if(u.length!==a.length)return!1;for(let l=0;l<u.length;l++){let f=u[l];if(!n(s[f],r[f]))return!1}return!0}}}try{return n(e,t)}catch{return n(Jn(e),Jn(t))}}$n.exports=Mc});var M=c((Zy,Vn)=>{var Uc=h(),Bc=S(),Pc=m(),Rn=q(),zc=D(),Ln=g(),Cc=b();function ce(e){let t="abcdefg1234567890",n="";for(;n.length<e;)n+=t[parseInt(Math.random()*t.length)];return n}var kc=ce(256),Jc=ce(256),Yc=ce(256),$c=ce(256),Rc=ce(256);function Kn(e){if(Rn(e)||Ln(e))return Kn(e.values);Uc(Pc(e),"The `set` function only works on arrays, Series, and DataFrames!");let t=[],n={};return Bc(e).forEach(s=>{let r=typeof s=="object"&&s===null?kc:Cc(s)?Jc:zc(s)?s.toString():typeof s=="symbol"?s.toString()+" - "+Rc:s===1/0?Yc:s===-1/0?$c:Rn(s)?s.toJSONString():Ln(s)?JSON.stringify(s.toObject()):JSON.stringify(s);n[r]||t.push(s),n[r]=!0}),t}Vn.exports=Kn});var le=c((eb,Hn)=>{var Lc=h(),dt=S(),Gn=m(),Kc=q(),Wn=I(),Vc=D(),Gc=g(),Wc=M();function xe(e,t){if(Kc(e)||Gc(e))return arguments.length>1?xe(e.values,t):xe(e.values,e.values);if(Lc(Gn(e),"The first argument to the `count` function must be an array, Series, or DataFrame!"),Vc(t))return dt(e).filter(n=>t(n)).length;if(Gn(t)){let n=dt(e);return Wc(t).map(s=>({value:s,count:n.filter(r=>Wn(r,s)).length}))}else return arguments.length>1?dt(e).filter(n=>Wn(n,t)).length:xe(e,e)}Hn.exports=xe});var fe=c((tb,Qn)=>{var Hc=h(),Xn=m(),Xc=q(),Qc=g();function pt(e){if(Xc(e)||Qc(e))return pt(e.values);Hc(Xn(e),"The `isJagged` function only works on arrays, Series, and DataFrames!");let t=0,n=null;for(let s=0;s<e.length;s++)if(Xn(e[s])){if(t++,pt(e[s]))return!0;if(n===null)n=e[s].length;else if(e[s].length!==n)return!0}return t>0&&t<e.length}Qn.exports=pt});var Te=c((nb,tr)=>{var Zc=h(),Zn=m(),el=q(),tl=g();function er(e){if(el(e)||tl(e))return er(e.values);Zc(Zn(e),"The `isNested` function only works on arrays, Series, and DataFrames!");for(let t=0;t<e.length;t++)if(Zn(e[t]))return!0;return!1}tr.exports=er});var k=c((rb,rr)=>{var W=h(),nl=m(),rl=Te(),sl=p(),il=b(),Q="You must pass a natural number or a one-dimensional array of natural numbers into the `ndarray` function!";function nr(e){W(!il(e),Q),nl(e)||(e=[e]),W(!rl(e),Q),W(e.length>0,Q);let t=e[0];if(W(sl(t),Q),W(parseInt(t)===t,Q),W(t>=0,Q),W(t!==1/0,"We can't create an array containing an infinite number of values!"),e.length===1){let n=[];for(let s=0;s<t;s++)n.push(void 0);return n}else{let n=[];for(let s=0;s<t;s++)n.push(nr(e.slice(1)));return n}}rr.exports=nr});var he=c((sb,sr)=>{var ol=h(),ul=m(),al=q(),cl=g();function gt(e){if(al(e)||cl(e)){let n=e.copy();return n.values=gt(n.values),n.index=gt(n.index),n}ol(ul(e),"The `reverse` function only works on arrays, Series, and DataFrames!");let t=[];for(let n=e.length-1;n>=0;n--)t.push(e[n]);return t}sr.exports=gt});var j=c((ib,ir)=>{var qt=h(),yt=p(),bt=b(),ll=he();function fl(e,t,n=1){qt(!bt(e)&&!bt(t)&&!bt(n),"You must pass two numbers and optionally a step value to the `range` function!"),qt(yt(e)&&yt(t)&&yt(n),"You must pass two numbers and optionally a step value to the `range` function!"),qt(n>0,"The step value must be greater than 0! (NOTE: The step value is a magnitude; it does not indicate direction.)");let s=!1;if(e>t){s=!0;let i=e;e=t+n,t=i+n}let r=[];for(let i=e;i<t;i+=n)r.push(i);return s&&(r=ll(r)),r}ir.exports=fl});var v=c((ob,cr)=>{var hl=h(),or=m(),ml=q(),dl=I(),pl=g(),gl=b();function ur(e){if(!or(e))return;let t=[e.length],n=0,s=e.map(r=>{let i=ur(r);return gl(i)?i:(n++,i.length===1?i[0]:i)});return n>0?n===e.length&&s.slice(0,-1).every((i,o)=>dl(i,s[o+1]))?t.concat(s[0]):(t.push(s),t):t}function ar(e){return ml(e)||pl(e)?ar(e.values):(hl(or(e),"The `shape` function only works on arrays, Series, and DataFrames!"),ur(e))}cr.exports=ar});var pr=c((ub,dr)=>{var lr=h(),ql=m(),yl=q(),bl=fe(),Nl=g(),vl=b(),fr=X(),_e=k(),hr=j(),wl=M(),Sl=v();function mr(e,t,n){if(vl(n)&&(n=0),lr(n===0||n===1||n==="vertical"||n==="horizontal",'The only valid axis values for use when appending data to a DataFrame are 0, 1, "vertical", and "horizontal". Note that 0 == "horizontal" and 1 == "vertical".'),ql(t)){lr(!bl(t),"The array of data you're trying to append to this DataFrame is jagged!");let s=Sl(t);if(s.length===1)if(n===0){let r=e.copy();r._values.push(t);let i=Math.max(e.shape[1],s[0]);for(r._values.forEach(o=>{for(;o.length<i;)o.push(void 0)});r._index.length<r._values.length;)r._index.push("row"+r._index.length);for(;r._columns.length<i;)r._columns.push("col"+r._columns.length);return r}else{let r=Math.max(e.shape[0],s[0]),i=e.copy();for(hr(0,r).forEach(o=>{o>=i._values.length&&i._values.push(_e(e.shape[1])),i._values[o].push(t[o])});i._index.length<i._values.length;)i._index.push("row"+i._index.length);for(;i._columns.length<i._values[0].length;)i._columns.push("col"+i._columns.length);return i}else if(s.length===2)if(n===0){let r=Math.max(...t.map(o=>o.length).concat([e.shape[1]])),i=e.copy();for(i._values=i._values.concat(t).map(o=>{for(;o.length<r;)o.push(void 0);return o});i._index.length<i._values.length;)i._index.push("row"+i._index.length);for(;i._columns.length<r;)i._columns.push("col"+i._columns.length);return i}else{let r=Math.max(...t.map(u=>u.length))+e.shape[1],i=Math.max(e.shape[0],s[0]),o=e.copy();for(hr(0,i).forEach(u=>{for(u>=o._values.length&&o._values.push(_e(e.shape[1])),o._values[u]=o._values[u].concat(t[u]);o._values[u].length<r;)o._values[u].push(void 0)});o._index.length<o._values.length;)o._index.push("row"+o._index.length);for(;o._columns.length<r;)o._columns.push("col"+o._columns.length);return o}else throw new fr("Only 1- and 2-dimensional arrays can be appended to a DataFrame!")}else if(Nl(t)){let s=mr(e,t.values,n);return n===0?s.index[s.index.length-1]=s.index.indexOf(t.name)>-1?t.name+" (2)":t.name:s.columns[s.columns.length-1]=s.columns.indexOf(t.name)>-1?t.name+" (2)":t.name,s}else if(yl(t))if(n===0){let s=e.copy(),r=wl(s._columns.concat(t._columns)).length;for(s._values.forEach(i=>{for(;i.length<r;)i.push(void 0)}),t.apply(i=>{let o=i.copy(),u=[];s._columns.forEach(a=>{let l=o._index.indexOf(a);l>-1?(u.push(o._values[l]),o._values.splice(l,1),o._index.splice(l,1)):u.push(void 0)}),s._values.push(u.concat(o._values))},1),s._columns=s._columns.concat(t._columns.filter(i=>s._columns.indexOf(i)<0));s._index.length<s._values.length;){let i="row"+s._index.length;s._index.push(i+(e._index.indexOf(i)>-1?" (2)":""))}return s}else{let s=e.copy();return s._index.forEach((r,i)=>{let o=t._index.indexOf(r);o>-1?s._values[i]=s._values[i].concat(t._values[o]):s._values[i]=s._values[i].concat(_e(t.shape[1]))}),t._index.forEach((r,i)=>{s._index.indexOf(r)<0&&(s._index.push(r),s._values.push(_e(s._columns.length).concat(t._values[i])))}),s._columns=s._columns.concat(t._columns.map(r=>r+(s._columns.indexOf(r)>-1?" (2)":""))),s}else throw new fr("Only 1- or 2-dimensional arrays, Series, and DataFrames can be appended to a DataFrame!")}dr.exports=mr});var Nr=c((ab,br)=>{var gr=h(),qr=m(),Ol=D(),yr=b();function xl(e,t,n,s,r){if(r=r||0,gr(Ol(s),"The first parameter to the `apply` method must be a function."),gr(r===0||r===1,"The second parameter to the `apply` method (the `axis`) must be 0 or 1."),r===0){let i={},o;if(n.columns.forEach((u,a)=>{let l=new t(n.values.map(d=>d[a]));l.name=u,l.index=n.index;let f=s(l,a,n);f instanceof t?i[u]=f.values:i[u]=f,yr(o)&&(o=f instanceof t||qr(f))}),o){let u=new e(i);return u.index=n.index,u}else{let u=new t(n.columns.map(a=>i[a]));return u.index=n.columns,u}}else if(r===1){let i,o=n.values.map((u,a)=>{let l=new t(u);l.name=n.index[a],l.index=n.columns;let f=s(l,a,n);return yr(i)&&(i=f instanceof t||qr(f)),f instanceof t?f.values:f});if(i){let u=new e(o);return u.index=n.index,u.columns=n.columns,u}else{let u=new t(o);return u.index=n.index,u}}}br.exports=xl});var A=c((cb,vr)=>{function Tl(e){return typeof e=="string"}vr.exports=Tl});var Or=c((lb,Sr)=>{var wr=h(),_l=m(),Dl=fe(),Al=C(),Fl=A(),jl=b(),El=X(),Il=v();function Ml(e,t,n,s,r){let i=u=>u instanceof e,o=u=>u instanceof t;if(jl(r)){if(i(s))return n.append(s,1);if(o(s))return n.append(s,1);if(Al(s)){let u=Math.max(...Object.keys(s).concat(Object.getOwnPropertySymbols(s)).map(a=>s[a].length));return Object.keys(s).concat(Object.getOwnPropertySymbols(s)).forEach(a=>{for(;s[a].length<u;)s[a].push(void 0)}),n.append(new e(s),1)}else throw new El("You must pass a DataFrame, Series, or object into the `assign` method!")}else{wr(Fl(s),"If passing two arguments into the `assign` method, then the first argument must be a string name!"),wr(_l(r)&&!Dl(r)&&Il(r).length===1,"If passing two arguments into the `assign` method, then the second argument must be a 1-dimensional array!");let u=n.append(r,1);return u.columns[u.columns.length-1]=s,u}}Sr.exports=Ml});var Tr=c((fb,xr)=>{var{copy:Ul}=B();function Bl(e,t){if(t.isEmpty)return new e;let n=new e(Ul(t.values));return n.columns=t.columns.slice(),n.index=t.index.slice(),n}xr.exports=Bl});var Ir=c((hb,Er)=>{var De=h(),_r=m(),Dr=p(),Ar=A(),Fr=b(),jr=v();function Pl(e,t,n,s,r){Fr(s)&&(s=[]),Fr(r)&&(r=[]),(Ar(s)||Dr(s))&&(s=[s]),(Ar(r)||Dr(r))&&(r=[r]),De(_r(s),"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings."),De(_r(r),"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings."),De(jr(s).length===1,"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings."),De(jr(r).length===1,"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings.");let i,o;n.index.forEach((a,l)=>{s.indexOf(a)<0&&s.indexOf(l)<0&&(i||(i=[]),i.push(a))}),n.columns.forEach((a,l)=>{r.indexOf(a)<0&&r.indexOf(l)<0&&(o||(o=[]),o.push(a))});let u=n.get(i,o);if(u instanceof t){let a=new e;a=a.assign(u),n.index.indexOf(u.name)>-1&&(a=a.transpose()),u=a}return u}Er.exports=Pl});var me=c((mb,Mr)=>{var zl=p();function Cl(e){return zl(e)&&parseInt(e)===e}function kl(e){return Cl(e)&&e>=0}Mr.exports=kl});var Br=c((db,Ur)=>{var Nt=h(),Jl=A(),Ae=b(),Yl=me(),$l=v();function Rl(e,t,n,s,r,i){s=s||0,Nt(s===0||s===1,"The first parameter of the `dropMissing` method (the `axis`) must be 0 or 1."),i=i||0,Nt(Yl(i),"The third parameter of the `dropMissing` method (the `threshold`) should be a whole number (meaning that data should be dropped if it contains more than `threshold` null values)."),r=i>0?"none":r||"any",Nt(r==="any"||r==="all"||r==="none","The second parameter of the `dropMissing` method (the `condition` parameter, which indicates the condition under which data should be dropped) should be 'any' or 'all' (meaning that if 'any' of the data contains null values, then it should be dropped; or that if 'all' of the data contains null values, then it should be dropped).");function o(l){if(i>0){let f=0;for(let d=0;d<l.length;d++){let y=l[d];if(Ae(y)&&f++,f>=i)return[]}}else if(r==="any")for(let f=0;f<l.length;f++){let d=l[f];if(Ae(d))return[]}else if(r==="all"){for(let f=0;f<l.length;f++){let d=l[f];if(!Ae(d))return l}return[]}return l}let u=n.copy(),a=Math.random().toString();if(s===0){u=u.assign(a,u.index);let l=u.values.map(o).filter(d=>d.length>0);if($l(l).length<2)return new e;u.values=l;let f=u.get(null,a);if(Ae(f))return new e;Jl(f)&&(f=[f]),f instanceof t&&(f=f.values),u.index=f,u=u.drop(null,a)}else if(s===1){let l={};if(u.columns.forEach((d,y)=>{let T=u.values.map(_=>_[y]),G=o(T);G.length>0&&(l[d]=G)}),Object.keys(l).length+Object.getOwnPropertySymbols(l).length===0)return new e;let f=new e(l);return f.index=u.index,f}return u}Ur.exports=Rl});var vt=c((pb,zr)=>{var Ll=h(),Kl=m(),Vl=q(),Gl=p(),Wl=g();function Pr(e){if(Vl(e)||Wl(e))return e.dropNaN(...Object.values(arguments).slice(1));Ll(Kl(e),"The `dropNaN` function only works on arrays, Series, and DataFrames!");let t=[];return e.forEach(n=>{try{return t.push(Pr(n))}catch{if(Gl(n))return t.push(n)}}),t}zr.exports=Pr});var kr=c((gb,Cr)=>{var wt=h(),Hl=vt(),Xl=me();function Ql(e,t,n,s,r){n=n||0,wt(n===0||n===1,"The first parameter of the `dropNaN` method (the `axis`) must be 0 or 1."),r=r||0,wt(Xl(r),"The third parameter of the `dropNaN` method (the `threshold`) should be a whole number (meaning that data should be dropped if it contains more than `threshold` NaN values)."),s=r>0?"none":s||"any",wt(s==="any"||s==="all"||s==="none","The second parameter of the `dropNaN` method (the `condition` parameter, which indicates the condition under which data should be dropped) should be 'any' or 'all' (meaning that if 'any' of the data contains NaN values, then it should be dropped; or that if 'all' of the data contains NaN values, then it should be dropped).");function i(u){let a=Hl(u);return r>0?u.length-a.length<r:s==="any"?a.length===u.length:s==="all"?a.length>0:!0}let o=t.copy();if(n===0){let u=o.index.filter(a=>{let l=o.get(a,null).values;return i(l)});return u.length>0?o.get(u,null):new e}else if(n===1){let u=o.columns.filter(a=>{let l=o.get(null,a).values;return i(l)});return u.length>0?o.get(null,u):new e}return o}Cr.exports=Ql});var Rr=c((qb,$r)=>{var Jr=h(),de=S(),Zl=D(),ef=b();function Yr(e){let t={};return de(e).forEach((n,s)=>{t[n]=s}),t}function Z(e){return Object.keys(e).concat(Object.getOwnPropertySymbols(e)).sort((t,n)=>e[t]-e[n])}function tf(e,t,n,s,r){Jr(Zl(s),"The `filter` method takes a single parameter: a function that is used to filter the values."),ef(r)&&(r=0),Jr(r===0||r===1,"The `axis` parameter to the `filter` method must be 0 or 1.");let i=n.copy();if(i.isEmpty)return i;let o=Yr(i.index),u=Yr(i.columns);if(r===0){let a=i.values.filter((l,f)=>{let d=new t(l);d.name=n.index[f],d.index=n.columns;let y=s(d,f,n);return y||delete o[i.index[f]],y});if(de(a).length===0)return new e;if(a.length===1){let l=new t(de(a));return l.name=Z(o)[0],l.index=Z(u),l}i.values=a,i.index=Z(o)}else if(r===1){i=i.transpose();let a=i.values.filter((l,f)=>{let d=new t(l);d.name=n.columns[f],d.index=n.index;let y=s(d,f,n);return y||delete u[i.index[f]],y});if(de(a).length===0)return new e;if(a.length===1){let l=new t(de(a));return l.name=Z(u)[0],l.index=Z(o),l}i.values=a,i.index=Z(u),i=i.transpose()}return i}$r.exports=tf});var Vr=c((yb,Kr)=>{var E=h(),Fe=p(),je=A(),Lr=b(),nf=M();function rf(e,t,n){(je(t)||Fe(t))&&(t=[t]),(je(n)||Fe(n))&&(n=[n]);let s=nf((t||[]).concat(n||[]).map(r=>typeof r));return E(s.length<=2,"Only whole numbers and/or strings are allowed in `get` arrays!"),s.length===1&&E(s[0]==="string"||s[0]==="number","Only whole numbers and/or strings are allowed in `get` arrays!"),s.length===2&&(E(s.indexOf("string")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!"),E(s.indexOf("number")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!")),Lr(t)||(t=t.map(r=>{if(je(r))return E(e.index.indexOf(r)>-1,`Row "${r}" does not exist!`),r;if(Fe(r))return E(r>=0,`Index ${r} is out of bounds!`),E(parseInt(r)===r,"Row numbers must be integers!"),E(r<e.index.length,`Index ${r} is out of bounds!`),e.index[r]})),Lr(n)||(n=n.map(r=>{if(je(r))return E(e.columns.indexOf(r)>-1,`Column "${r}" does not exist!`),r;if(Fe(r))return E(r>=0,`Column ${r} is out of bounds!`),E(parseInt(r)===r,"Column numbers must be integers!"),E(r<e.columns.length,`Column ${r} is out of bounds!`),e.columns[r]})),e.getSubsetByNames(t,n)}Kr.exports=rf});var J=c((bb,Wr)=>{var Gr=h(),sf=m(),of=q(),uf=D(),af=g(),cf=b();function lf(e,t){try{return e<t?-1:e>t?1:0}catch{return e=typeof e=="object"&&e!==null?JSON.stringify(e):e.toString(),t=typeof t=="object"&&t!==null?JSON.stringify(t):t.toString(),e<t?-1:e>t?1:0}}function ff(e,t){if(cf(t)&&(t=lf),of(e)||af(e))return e.sort(...Object.values(arguments).slice(1));Gr(sf(e),"The `sort` function only works on arrays, Series, and DataFrames!"),Gr(uf(t),"The second parameter of the `sort` function must be a comparison function!");let n=e.slice();return n.sort(t),n}Wr.exports=ff});var Zr=c((Nb,Qr)=>{var Hr=h(),Xr=A(),hf=b(),mf=M(),df=J();function pf(e){let t=e.toLowerCase(),n="";for(let r=0;r<t.length;r++){let i=t[r];i.match(/[a-z0-9]/g)?n+=i:n+=" "}let s=n.split(" ").filter(r=>r.length>0);return s[0]+s.slice(1).map(r=>r[0].toUpperCase()+r.substring(1)).join("")}function gf(e,t,n){hf(n)?n=t.columns:Xr(n)&&(n=[n]);let s={};n.forEach(i=>{Hr(Xr(i),"You must pass either a string or a one-dimensional array of strings into the `getDummies` (AKA `oneHotEncode`) method!");let o=t.columns.indexOf(i);Hr(o>-1,`The given DataFrame does not have a column called "${i}"!`);let u=t.values.map(l=>l[o]),a=df(mf(u));u.forEach(l=>{a.forEach(f=>{let d=i+"_"+pf(f.toString());s[d]||(s[d]=[]),l===f?s[d].push(1):s[d].push(0)})})});let r=new e(s);return r.index=t.index,r}Qr.exports=gf});var us=c((vb,os)=>{var Y=h(),es=m(),ts=p(),ns=b(),rs=me(),ss=j(),is=v();function qf(e,t,n){let s=e.shape;ns(t)&&(t=ss(0,s[0])),ns(n)&&(n=ss(0,s[1])),ts(t)&&(t=[t]),ts(n)&&(n=[n]),Y(es(t)&&es(n),"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),Y(is(t).length===1&&is(n).length===1,"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),Y(t.length>0,"The `rowIndices` array must contain at least one index."),Y(n.length>0,"The `colIndices` array must contain at least one index."),t.forEach(o=>{Y(rs(o),"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),Y(o<e.index.length,`The row index ${o} is out of bounds.`)}),n.forEach(o=>{Y(rs(o),"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),Y(o<e.columns.length,`The column index ${o} is out of bounds.`)});let r=t.map(o=>e.index[o]),i=n.map(o=>e.columns[o]);return e.getSubsetByNames(r,i)}os.exports=qf});var hs=c((wb,fs)=>{var $=h(),St=S(),as=m(),Ee=A(),cs=b(),ls=v();function yf(e,t,n,s,r){cs(s)&&(s=n.index),cs(r)&&(r=n.columns),Ee(s)&&(s=[s]),Ee(r)&&(r=[r]),$(as(s)&&as(r),"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),$(ls(s).length===1&&ls(r).length===1,"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),$(s.length>0,"The `rows` array must contain at least one row name."),$(r.length>0,"The `cols` array must contain at least one column name."),s.forEach(u=>{$(Ee(u),"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),$(n.index.indexOf(u)>-1,`The row name "${u}" does not exist in the list of rows.`)}),r.forEach(u=>{$(Ee(u),"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),$(n.columns.indexOf(u)>-1,`The column name "${u}" does not exist in the list of columns.`)});let i=s.map(u=>r.map(a=>n.values[n.index.indexOf(u)][n.columns.indexOf(a)]));if(s.length===1&&r.length===1)return St(i)[0];if(s.length===1){let u=new t(St(i));return u.name=s[0],u.index=r,u}if(r.length===1){let u=new t(St(i));return u.name=r[0],u.index=s,u}let o=new e(i);return o.columns=r,o.index=s,o}fs.exports=yf});var ds=c((Sb,ms)=>{var bf=A(),pe=j();function Nf(e,t,n){function s(y,T){return bf(y)&&y.length>T?y.substring(0,T-3)+"...":y}if(n.isEmpty)return console.table({}),console.log("Shape:",[0,0],`
|
|
15
|
-
`),
|
|
16
|
-
`),n}ms.exports=Nf});var Ie=c((Ob,ps)=>{var vf=h(),wf=p();function Sf(e,t){vf(wf(e),"The `leftPad` function only works on numbers!");let n=e.toString();for(;n.length<t;)n="0"+n;return n}ps.exports=Sf});var qs=c((xb,gs)=>{var Of=Ie(),xf=j();function Tf(e,t){let n=t?e:e.copy();return n.index=xf(0,e.shape[0]).map(s=>"row"+Of(s,(n.index.length-1).toString().length)),n}gs.exports=Tf});var ge=c((Tb,bs)=>{var _f=h(),Df=S(),Af=m(),Ff=q(),jf=g();function ys(e){if(Ff(e)||jf(e))return ys(e.values);_f(Af(e),"The `product` function only works on arrays, Series, and DataFrames!");try{return e.length===0?NaN:Df(e).reduce((t,n)=>t*n,1)}catch{return NaN}}bs.exports=ys});var Me=c((_b,Ss)=>{var qe=h(),Ns=S(),vs=m(),Ef=q(),ws=p(),If=g(),Mf=ge(),Uf=v();function Ot(e,t){if(Ef(e)||If(e))return Ot(e.values,t);if(qe(vs(e),"The first argument passed into the `reshape` function must be an array!"),ws(t)&&(t=[t]),qe(vs(t),"The second argument passed into the `reshape` function must be a whole number or a one-dimensional array of whole numbers!"),qe(Uf(t).length===1,"The first argument passed into the `reshape` function must be a whole number or a one-dimensional array of whole numbers!"),t.forEach(i=>{qe(ws(i)&&parseInt(i)===i&&i>0,"The first argument passed into the `reshape` function must be a whole number or a one-dimensional array of whole numbers!")}),t.length===0)return Ns(e);let n=Ns(e);if(t.length===1&&t[0]===n.length)return n;qe(Mf(t)===n.length,"The new shape doesn't match the number of values available in `x` (the first argument passed into the `reshape` function)!");let s=[],r=parseInt(n.length/t[0]);for(let i=0;i<t[0];i++){let o=n.slice(i*r,(i+1)*r);s.push(Ot(o,t.slice(1)))}return s}Ss.exports=Ot});var ee=c((Db,Fs)=>{var{copy:Ts}=B(),Bf=h(),Pf=m(),zf=p(),_s=b(),Cf=k(),kf=ge(),Jf=Me(),Ds=Math.pow(2,64),w=[];As(parseInt(Math.random()*Ds));function Yf(e,t){e=x(e);function n(){e+=x("0x9e3779b97f4a7c15");let r=Ts(e);return r=(r^r>>BigInt(30))*x("0xbf58476d1ce4e5b9"),r=(r^r>>BigInt(27))*x("0x94d049bb133111eb"),r^r>>BigInt(31)}let s=[];for(let r=0;r<t;r++)s.push(n());return s}function x(e){return BigInt.asUintN(64,BigInt(e))}function Os(e,t){return e=x(e),t=BigInt(t),x(x(e<<t)|x(e>>x(BigInt(64)-t)))}function As(e){if(_s(e))return Ts(w);{Bf(zf(e),"If passing a value into the `seed` function, then that value must be an integer!");let t=Yf(parseInt(e),4);w[0]=t[0],w[1]=t[1],w[2]=t[2],w[3]=t[3]}}function xs(){let e=x(Os(w[0]+w[3],23)+w[0]),t=x(w[1]<<BigInt(17));return w[2]=x(w[2]^w[0]),w[3]=x(w[3]^w[1]),w[1]=x(w[1]^w[2]),w[0]=x(w[0]^w[3]),w[2]=x(w[2]^t),w[3]=Os(w[3],45),parseInt(e)/Ds}function $f(e){return _s(e)?xs():(Pf(e)||(e=[e]),Jf(Cf(kf(e)).map(xs),e))}Fs.exports={random:$f,seed:As}});var Ue=c((Ab,js)=>{var{random:Rf}=ee(),Lf=h(),Kf=m(),Vf=q(),Gf=g();function Wf(e){if(Vf(e)||Gf(e))return e.shuffle(...Object.values(arguments).slice(1));Lf(Kf(e),"The `shuffle` function only works on arrays, Series, and DataFrames!");let t=[],n=e.slice();for(let s=0;s<e.length;s++){let r=parseInt(Rf()*n.length);t.push(n.splice(r,1)[0])}return t}js.exports=Wf});var Ms=c((Fb,Is)=>{var Hf=h(),Xf=b(),Es=Ue();function Qf(e,t){return Xf(t)&&(t=0),Hf(t===0||t===1,"The `axis` parameter to the `shuffle` must be 0, 1, or undefined."),e.get(t===0?Es(e.index):null,t===1?Es(e.columns):null)}Is.exports=Qf});var Be=c((jb,Us)=>{function Zf(e){return typeof e=="boolean"}Us.exports=Zf});var ks=c((Eb,Cs)=>{var{random:eh}=ee(),F=h(),th=S(),Bs=m(),xt=Be(),zs=D(),Pe=p(),te=A(),Tt=b(),nh=j(),Ps=v(),_t=J();function rh(e,t,n){return zs(t)?sh(e,t,n):ih(e,t,n)}function sh(e,t,n){if(n=Tt(n)?0:n,F(zs(t),"When sorting a DataFrame using a function, the first argument to the `sort` method must be a function!"),F(Pe(n),"When sorting a DataFrame using a function, the second argument to the `sort` method must be null, undefined, 0, or 1 to indicate the axis along which the data should be sorted! An axis of 0 means that the rows will be sorted relative to each other, whereas an axis of 1 means that the columns will be sorted relative to each other."),n===0){let s=_t(e.index,(r,i)=>t(e.get(r,null),e.get(i,null)));return e.get(s,null)}else{let s=_t(e.columns,(r,i)=>t(e.get(null,r),e.get(null,i)));return e.get(null,s)}}function ih(e,t,n){let s=e.copy(),r=eh().toString();return s=s.assign(r,s.index),Tt(t)&&(t=[r],n=[!0]),(Pe(t)||te(t))&&(t=[t],(xt(n)||te(n))&&(n=[n])),F(Bs(t),"The first parameter of the `sort` method must be (1) a string or index representing a column name or index, respectively; (2) a 1-dimensional array of strings and/or indices; or (3) null."),F(Ps(t).length===1,"The first parameter of the `sort` method must be (1) a string or index representing a column name or index, respectively; (2) a 1-dimensional array of strings and/or indices; or (3) null."),Tt(n)&&(n=nh(0,t.length).map(()=>!0)),F(Bs(n),"The second parameter of the `sort` method must be (1) a string or boolean representing the sort direction ('ascending' / 'descending', or true / false); (2) a 1-dimensional array of strings and/or booleans; or (3) null."),F(Ps(n).length===1,"The second parameter of the `sort` method must be (1) a string or boolean representing the sort direction ('ascending' / 'descending', or true / false); (2) a 1-dimensional array of strings and/or booleans; or (3) null."),F(t.length===n.length,"The arrays passed into the `sort` method must be equal in length."),t=t.map(i=>{if(F(te(i)||Pe(i),"Column references can either be column names (as strings) or column indices (as whole numbers)."),te(i)){let o=s.columns.indexOf(i);return F(o>-1,`The column "${i}" does not exist!`),o}if(Pe(i))return F(parseInt(i)===i,"Column indices must be whole numbers!"),F(i>=0,`The column index ${i} is out of bounds!`),F(i<s.columns.length,`The index ${i} is out of bounds!`),i}),n=n.map(i=>{if(F(te(i)||xt(i),"Direction references can either be strings ('ascending' or 'descending') or booleans (true or false)."),te(i)){let o=i.trim().toLowerCase();return F(o==="ascending"||o==="descending","Direction references can either be strings ('ascending' or 'descending') or booleans (true or false)."),o==="ascending"}if(xt(i))return i}),s.values=_t(s.values,(i,o)=>{let u=0;for(;i[t[u]]===o[t[u]]&&u<t.length;)u++;let a=n[u];if(i[t[u]]===o[t[u]])return 0;if(i[t[u]]<o[t[u]])return a?-1:1;if(i[t[u]]>o[t[u]])return a?1:-1}),s.index=th(s.get(null,r).values),s=s.dropColumns(r),s}Cs.exports=rh});var Dt=c((Ib,Js)=>{function oh(e,t){return JSON.stringify(e.toObject(t))}Js.exports=oh});var Ys=c((Mb,Ft)=>{var At=X(),uh=Dt();function ah(e,t,n){let s=uh(e,n),r=!1,i=!1,o,u;try{let a=t;if(t.includes("/")){let f=t.split("/");a=f[f.length-1]}let l=document.createElement("a");l.href=`data:application/json;charset=utf-8,${encodeURIComponent(s)}`,l.download=a,l.dispatchEvent(new MouseEvent("click")),r=!0}catch(a){o=a}try{let a=qn("fs"),l=qn("path");a.writeFileSync(l.resolve(t),s,"utf8"),i=!0}catch(a){u=a}if(!r&&!i)throw typeof window<"u"?new At(o):typeof Ft<"u"?new At(u):new At("I don't know what's going wrong, but it doesn't seem like you're in Node or the browser, and we couldn't download and/or write the file to disk!");return e}Ft.exports=ah});var Rs=c((Ub,$s)=>{var ch=h(),lh=b();function fh(e,t){lh(t)?t=0:ch(t===0||t===1,"The axis parameter of the `toObject` method must be undefined, 0, or 1. An axis of 0 indicates that the returned object should be organized first by rows and then by columns. An axis of 1 indicates that the returned object should be organized first by columns and then by rows.");let n={};return t===0?e.index.forEach((s,r)=>{let i={};e.columns.forEach((o,u)=>{i[o]=e.values[r][u]}),n[s]=i}):e.columns.forEach((s,r)=>{let i={};e.index.forEach((o,u)=>{i[o]=e.values[u][r]}),n[s]=i}),n}$s.exports=fh});var H=c((Bb,Vs)=>{var Ls=h(),hh=m(),mh=q(),dh=g(),ph=k(),Ks=he(),gh=v();function qh(e){if(mh(e)||dh(e))return e.transpose();Ls(hh(e),"The `transpose` function only works on arrays, Series, and DataFrames!");let t=gh(e);if(Ls(t.length<=2,"I'm not smart enough to know how to transpose arrays that have more than 2 dimensions. Sorry for the inconvenience! Please only pass 1- or 2-dimensional arrays into the `transpose` function!"),t.length===1)return Ks(e);if(t.length===2){let n=ph(Ks(t));for(let s=0;s<t[0];s++)for(let r=0;r<t[1];r++)n[r][s]=e[s][r];return n}}Vs.exports=qh});var Xs=c((Pb,Hs)=>{var Gs=h(),yh=m(),bh=q(),Nh=Te(),vh=g(),wh=v();function Ws(e,t,n){if(vh(n))return new e(t.values.concat(n.values));if(yh(n)){let s=wh(n);Gs(s.length===1&&!Nh(s),"Only vectors can be appended to Series!");let r=t.copy();return n.forEach((i,o)=>{r._values.push(i),r._index.push("item"+(t.values.length+o))}),r}return Gs(!bh(n),"DataFrames cannot be appended to Series!"),Ws(t,[n])}Hs.exports=Ws});var Zs=c((zb,Qs)=>{var Sh=h(),Oh=D();function xh(e,t){Sh(Oh(t),"The parameter to the `apply` method must be a function.");let n=e.copy();return n._values=n._values.map((s,r)=>t(s,r)),n}Qs.exports=xh});var ti=c((Cb,ei)=>{var Th=b();function _h(e){let t=e.copy(),n=[];return t._values=t.values.filter((s,r)=>Th(s)?!1:(n.push(t.index[r]),!0)),t._index=n,t}ei.exports=_h});var ri=c((kb,ni)=>{var Dh=p();function Ah(e,t){let n=[],s=[];t.values.forEach((i,o)=>{Dh(i)&&(s.push(i),n.push(t.index[o]))});let r=new e(s);return r.name=t.name,r.index=n,r}ni.exports=Ah});var ii=c((Jb,si)=>{var{copy:Fh}=B();function jh(e,t,n){let s=t.copy(),r=Fh(s.index),i=[],o=s.values.filter((u,a)=>{let l=n(u,a,s.values);return l||i.push(s.index[a]),l});return i.forEach(u=>{r.splice(r.indexOf(u),1)}),o.length===0?(s=new e,s.name=t.name,s):(s.values=o,s.index=r,s)}si.exports=jh});var ui=c((Yb,oi)=>{var R=h(),Eh=p(),Ih=A(),Mh=b(),Uh=M();function Bh(e,t){(Ih(t)||Eh(t))&&(t=[t]);let n=Uh((t||[]).map(s=>typeof s));return R(n.length<=2,"Only whole numbers and/or strings are allowed in `get` arrays!"),n.length===1&&R(n[0]==="string"||n[0]==="number","Only whole numbers and/or strings are allowed in `get` arrays!"),n.length===2&&(R(n.indexOf("string")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!"),R(n.indexOf("number")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!")),Mh(t)||(t=t.map(s=>{if(typeof s=="string")return R(e.index.indexOf(s)>-1,`Index "${s}" does not exist!`),s;if(typeof s=="number")return R(s>=0,`Index ${s} is out of bounds!`),R(parseInt(s)===s,"Indices must be integers!"),R(s<e.index.length,`Index ${s} is out of bounds!`),e.index[s]})),e.getSubsetByNames(t)}oi.exports=Bh});var ci=c(($b,ai)=>{var ye=h(),Ph=m(),zh=b(),Ch=me(),kh=j(),Jh=v();function Yh(e,t){let n=e.shape;zh(t)&&(t=kh(0,n[0])),ye(Ph(t),"The `indices` array must be 1-dimensional array of whole numbers."),ye(Jh(t).length===1,"The `indices` array must be a 1-dimensional array of whole numbers."),ye(t.length>0,"The `indices` array must contain at least one index."),t.forEach(r=>{ye(Ch(r),"The `indices` array must be a 1-dimensional array of whole numbers."),ye(r<e.index.length,`The row index ${r} is out of bounds.`)});let s=t.map(r=>e.index[r]);return e.getSubsetByNames(s)}ai.exports=Yh});var fi=c((Rb,li)=>{var be=h(),$h=m(),Rh=A(),Lh=b(),Kh=v();function Vh(e,t,n){Lh(n)&&(n=t.index),be($h(n),"The `indices` array must be a 1-dimensional array of strings."),be(Kh(n).length===1,"The `indices` array must be a 1-dimensional array of strings."),be(n.length>0,"The `indices` array must contain at least one index name."),n.forEach(i=>{be(Rh(i),"The `indices` array must contain only strings."),be(t.index.indexOf(i)>-1,`The name "${i}" does not exist in the index.`)});let s=n.map(i=>t.values[t.index.indexOf(i)]);if(s.length===1)return s[0];let r=new e(s);return r.index=n,r.name=t.name,r}li.exports=Vh});var di=c((Lb,mi)=>{var{copy:Gh}=B(),hi=j();function Wh(e){let t=e.copy(),n=typeof window>"u"?20:10;if(t.index.length>n){t=t.get(hi(0,n/2).concat(hi(t.index.length-n/2,t.index.length)));let r=Gh(t.index);r.splice(parseInt(r.length/2),0,"..."),t.values.push("..."),t.index.push("..."),t=t.get(r)}let s={};return t.values.forEach((r,i)=>{let o={};o[t.name]=r,s[t.index[i]]=o}),console.table(s),console.log("Shape:",e.shape,`
|
|
17
|
-
`),e}mi.exports=Wh});var gi=c((Kb,pi)=>{var Hh=Ue();function Xh(e){let t=e.copy();return t.get(Hh(t.index))}pi.exports=Xh});var yi=c((Vb,qi)=>{var Qh=h(),Zh=D(),em=b(),tm=J(),nm=H();function rm(e,t,n){n=n||((a,l)=>a<l?-1:1),Qh(em(n)||Zh(n),"You must pass undefined, null, or a comparison function as the second argument to the `sort` method!");let s=nm([t.values,t.index]),r=tm(s,(a,l)=>n(a[0],l[0])),i=[],o=[];r.forEach(a=>{i.push(a[0]),o.push(a[1])});let u=new e;return u._values=i,u._index=o,u.name=t.name,u}qi.exports=rm});var vi=c((Gb,Ni)=>{var sm=J(),bi=H();function im(e,t){let n=bi([t.values,t.index]);n=bi(sm(n,(r,i)=>{if(r[1]===i[1])return 0;if(r[1]<i[1])return-1;if(r[1]>i[1])return 1}));let s=new e(n[0]);return s.index=n[1],s.name=t.name,s}Ni.exports=im});var Si=c((Wb,wi)=>{function om(e){let t={};return t[e.name]={},e.index.forEach((n,s)=>{t[e.name][n]=e.values[s]}),t}wi.exports=om});var Di=c((Hb,_i)=>{var{copy:ze}=B(),P=h(),jt=m(),um=A(),am=b(),Oi=Ie(),xi=j(),Ce=he(),cm=Xs(),lm=Zs(),fm=ti(),hm=ri(),mm=ii(),dm=ui(),pm=ci(),gm=fi(),qm=di(),ym=gi(),bm=yi(),Nm=vi(),vm=Si(),Ne=v(),wm=H(),Ti=Symbol.for("@jrc03c/js-math-tools/series");_i.exports=function(e){class t{static[Symbol.hasInstance](s){try{return!!s._symbol&&s._symbol===Ti}catch{return!1}}constructor(s){let r=this;if(r.name="data",Object.defineProperty(r,"_symbol",{configurable:!1,enumerable:!1,writable:!1,value:Ti}),Object.defineProperty(r,"_values",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(r,"values",{configurable:!0,enumerable:!0,get(){return r._values},set(i){P(jt(i),"The new values must be a 1-dimensional array!");let o=Ne(i);P(o.length===1,"The new array of values must be 1-dimensional!"),o[0]<r._index.length?r._index=r._index.slice(0,o[0]):o[0]>r._index.length&&(r._index=r._index.concat(xi(r._index.length,o[0]).map(u=>"item"+Oi(u,(i.length-1).toString().length)))),r._values=i}}),Object.defineProperty(r,"_index",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(r,"index",{configurable:!0,enumerable:!0,get(){return r._index},set(i){P(jt(i),"The new index must be a 1-dimensional array of strings!"),P(i.length===r.shape[0],"The new index must be the same length as the old index!"),P(Ne(i).length===1,"The new index must be a 1-dimensional array of strings!"),i.forEach(o=>{P(um(o),"All of the row names must be strings!")}),r._index=i}}),s){if(s instanceof t)r.name=s.name,r.values=ze(s.values),r.index=ze(s.index);else if(jt(s)){let i=Ne(s);P(i.length===1,"When passing an array into the constructor of a Series, the array must be 1-dimensional!"),r.values=s}else if(s instanceof Object){let i=Object.keys(s).concat(Object.getOwnPropertySymbols(s)).map(a=>a.toString());P(i.length===1,"When passing an object into the constructor of a Series, the object must have only 1 key-value pair, where the key is the name of the data and the value is the 1-dimensional array of values!");let o=i[0],u=s[o];P(Ne(u).length===1,"When passing an object into the constructor of a Series, the object must have only 1 key-value pair, where the key is the name of the data and the value is the 1-dimensional array of values!"),r.name=o,r.values=u.slice()}}}get shape(){return Ne(this.values)}get length(){return this.shape[0]}get isEmpty(){return this.values.filter(r=>!am(r)).length===0}clear(){let r=this.copy();return r.values.forEach((i,o)=>{r.values[o]=void 0}),r}get(s){return dm(this,s)}getSubsetByNames(s){return gm(t,this,s)}getSubsetByIndices(s){return pm(this,s)}loc(s){return this.getSubsetByNames(s)}iloc(s){return this.getSubsetByIndices(s)}reverse(){let s=this,r=new t(Ce(s.values));return r.index=Ce(s.index),r.name=s.name,r}resetIndex(){let s=this,r=s.copy();return r.index=xi(0,s.shape[0]).map(i=>"item"+Oi(i,(r.index.length-1).toString().length)),r}copy(){let s=this,r=new t;return r._values=ze(s.values),r._index=ze(s.index),r.name=s.name,r}append(s){return cm(t,this,s)}apply(s){return lm(this,s)}concat(s){return this.append(s)}dropMissing(s,r){return fm(this,s,r)}dropNaN(){return hm(t,this)}toObject(){return vm(this)}print(){return qm(this)}shuffle(){return ym(this)}sort(s){return bm(t,this,s)}sortByIndex(){return Nm(t,this)}filter(s){return mm(t,this,s)}toDataFrame(){let s=this,r=new e(wm([s.values]));return r.columns=[s.name],r.index=s.index,r}transpose(){let r=this.copy();return r.values=Ce(r.values),r.index=Ce(r.index),r}getDummies(){return this.toDataFrame().getDummies()}oneHotEncode(){return this.getDummies()}}return t}});var we=c((Xb,Mi)=>{var{copy:Et}=B(),U=h(),Ai=le(),Sm=pr(),Om=Nr(),xm=Or(),Tm=Tr(),_m=Ir(),Dm=Br(),Am=kr(),Fm=Rr(),jm=Vr(),Fi=Zr(),Em=us(),Im=hs(),Mm=ds(),Um=qs(),Bm=Ms(),Pm=ks(),zm=Ys(),Cm=Dt(),km=Rs(),Jm=S(),ve=m(),Ym=C(),ji=b(),It=Ie(),$m=k(),Mt=j(),ne=v(),Ei=H(),Ii=Symbol.for("@jrc03c/js-math-tools/dataframe");function ke(e){let t="abcdefghijklmnopqrstuvwxyz1234567890",n="";for(let s=0;s<e;s++)n+=t[parseInt(Math.random()*t.length)];return n}var O=class{static[Symbol.hasInstance](t){try{return!!t._symbol&&t._symbol===Ii}catch{return!1}}constructor(t){let n=this;if(Object.defineProperty(n,"_symbol",{configurable:!1,enumerable:!1,writable:!1,value:Ii}),Object.defineProperty(n,"_values",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(n,"values",{configurable:!0,enumerable:!0,get(){return n._values.length===0||!ji(n._values[0])&&n._values[0].length===0?[[]]:n._values},set(s){U(ve(s),"The new values must be a 2-dimensional array!");let r=ne(s);U(r.length===2,"The new array of values must be 2-dimensional!"),r[0]<n._index.length?n._index=n._index.slice(0,r[0]):r[0]>n._index.length&&(n._index=n._index.concat(Mt(n._index.length,r[0]).map(i=>"row"+It(i,(r[0]-1).toString().length)))),r[1]<n._columns.length?n._columns=n._columns.slice(0,r[1]):r[1]>n._columns.length&&(n._columns=n._columns.concat(Mt(n._columns.length,r[1]).map(i=>"col"+It(i,(r[1]-1).toString().length)))),n._values=s}}),Object.defineProperty(n,"_columns",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(n,"columns",{configurable:!0,enumerable:!0,get(){return n._columns},set(s){U(ve(s),"The new columns list must be a 1-dimensional array of strings!"),U(n.isEmpty||s.length===n.shape[1],"The new columns list must be the same length as the old columns list!"),U(ne(s).length===1,"The new columns list must be a 1-dimensional array of strings!"),s=s.map(i=>(typeof i!="string"&&(i=JSON.stringify(i)||i.toString()),i.trim().length===0?"untitled_"+ke(8):i.trim()));let r=(()=>{let i=Ai(s),o={};return i.forEach(u=>{o[u.value]=u.count}),o})();s=s.map(i=>r[i]>1?i+"_"+ke(8):i),n._columns=s}}),Object.defineProperty(n,"_index",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(n,"index",{configurable:!0,enumerable:!0,get(){return n._index},set(s){U(ve(s),"The new index must be a 1-dimensional array of strings!"),U(n.isEmpty||s.length===n.shape[0],"The new index must be the same length as the old index!"),U(ne(s).length===1,"The new index must be a 1-dimensional array of strings!"),s=s.map(i=>(typeof i!="string"&&(i=JSON.stringify(i)||i.toString()),i.trim().length===0?"untitled_"+ke(8):i.trim()));let r=(()=>{let i=Ai(s),o={};return i.forEach(u=>{o[u.value]=u.count}),o})();s=s.map(i=>r[i]>1?i+"_"+ke(8):i),n._index=s}}),U(ji(t)||Ym(t)||ve(t),"The `data` passed into the constructor of a DataFrame must be either (1) an object where the key-value pairs are (respectively) column names and 1-dimensional arrays of values, or (2) a 2-dimensional array of values."),t)if(t instanceof O)n.values=Et(t.values),n.columns=Et(t.columns),n.index=Et(t.index);else if(ve(t)){let s=ne(t);U(s.length===2,"The `data` array passed into the constructor of a DataFrame must be 2-dimensional!"),n.values=t}else{n._columns=Object.keys(t).concat(Object.getOwnPropertySymbols(t)).map(i=>i.toString());let s=[];n._columns.forEach(i=>{let o=t[i];s.push(o)}),n._values=Ei(s);let r=ne(n.values);n._index=Mt(0,r[0]).map(i=>"row"+It(i,(r[0]-1).toString().length))}}get shape(){return ne(this.values)}get length(){return this.shape[0]}get width(){return this.shape[1]}get rows(){return this.index}set rows(t){let n=this;n.index=t}get isEmpty(){return Jm(this.values).length===0}clear(){let t=this,n=new O($m(t.shape));return n.columns=t.columns.slice(),n.index=t.index.slice(),n}get(t,n){let s=this;if(arguments.length===0)return s;if(arguments.length===1)try{return s.get(null,t)}catch{return s.get(t,null)}return jm(s,t,n)}getSubsetByNames(t,n){return Im(O,L,this,t,n)}getSubsetByIndices(t,n){return Em(this,t,n)}getDummies(t){return Fi(O,this,t)}oneHotEncode(t){return Fi(O,this,t)}transpose(){let t=this,n=new O(Ei(t.values));return n.columns=t.index.slice(),n.index=t.columns.slice(),n}get T(){return this.transpose()}resetIndex(t){return Um(this,t)}copy(){return Tm(O,this)}assign(t,n){return xm(O,L,this,t,n)}apply(t,n){return Om(O,L,this,t,n)}dropMissing(t,n,s){return Dm(O,L,this,t,n,s)}dropNaN(t,n,s){return Am(O,this,t,n,s)}drop(t,n){return _m(O,L,this,t,n)}dropColumns(t){return this.drop(null,t)}dropRows(t){return this.drop(t,null)}toObject(t){return km(this,t)}toJSONString(t){return Cm(this,t)}saveAsJSON(t,n){return zm(this,t,n)}print(){return Mm(O,L,this)}sort(t,n){return Pm(this,t,n)}sortByIndex(){return this.sort()}filter(t,n){return Fm(O,L,this,t,n)}shuffle(t){return Bm(this,t)}append(t,n){return Sm(this,t,n)}concat(t,n){return this.append(t,n)}join(t,n){return this.append(t,n)}toString(){return JSON.stringify(this)}},L=Di()(O);Mi.exports={DataFrame:O,Series:L}});var re=c((Qb,Bi)=>{var Rm=h(),Lm=S(),Km=m(),Vm=q(),Gm=g();function Ui(e){if(Vm(e)||Gm(e))return Ui(e.values);Rm(Km(e),"The `max` function only works on arrays, Series, and DataFrames!");try{return Math.max(...Lm(e))}catch{return NaN}}Bi.exports=Ui});var N=c((Zb,Ji)=>{var{DataFrame:Pi,Series:zi}=we(),Ci=h(),Se=m(),Ut=q(),ki=I(),Wm=D(),Bt=g(),Hm=re(),Xm=j(),Je=v();function Qm(e){return Se(e)||Bt(e)||Ut(e)}function Zm(e){return Ci(Wm(e),"You must pass a function into the `vectorize` function!"),function t(){let n,s,r=[],i=[],o=Object.keys(arguments).filter(u=>{let a=arguments[u];return Se(a)?!0:Bt(a)?(n=!0,r.push(a),!0):Ut(a)?(s=!0,i.push(a),!0):!1}).map(u=>arguments[u]);if(o.slice(0,-1).forEach((u,a)=>{Ci(ki(Se(u)?Je(u):u.shape,Se(o[a+1])?Je(o[a+1]):o[a+1].shape),`When passing multiple arrays into the \`${e.name}\` function, all of the arrays must have the same shape!`)}),o.length>0){let u=Hm(o.map(l=>l.length?l.length:l.values.length)),a=Xm(0,u).map(l=>{let f=Object.keys(arguments).map(d=>{if(Qm(arguments[d])){if(Se(arguments[d]))return arguments[d][l];if(Bt(arguments[d]))return arguments[d].values[l];if(Ut(arguments[d]))return arguments[d].values[l]}else return arguments[d]});return t(...f)});if(s)try{if(i.length===1&&ki(Je(i[0]),Je(a))){let l=new Pi(a);return l.index=i[0].index.slice(),l.columns=i[0].columns.slice(),l}else return new Pi(a)}catch{return a}if(n)try{if(r.length===1&&r[0].length===a.length){let l=new zi(a);return l.name=r[0].name,l.index=r[0].index.slice(),l}else return new zi(a)}catch{return a}return a}else return e(...arguments)}}Ji.exports=Zm});var Ye=c((eN,Yi)=>{var ed=p(),td=N();function nd(e){try{return ed(e)?Math.abs(e):NaN}catch{return NaN}}Yi.exports=td(nd)});var $e=c((tN,$i)=>{var rd=p(),sd=N();function id(){try{let e=0,t=Object.values(arguments);for(let n=0;n<t.length;n++){if(!rd(t[n]))return NaN;e+=t[n]}return e}catch{return NaN}}$i.exports=sd(id)});var Oe=c((nN,Ri)=>{var od=N();function ud(e,t){try{return t(e)}catch{return NaN}}Ri.exports=od(ud)});var Ki=c((rN,Li)=>{var ad=p(),cd=N();function ld(e){try{return ad(e)?Math.acos(e):NaN}catch{return NaN}}Li.exports=cd(ld)});var Gi=c((sN,Vi)=>{var fd=p(),hd=N();function md(e){try{return fd(e)?Math.asin(e):NaN}catch{return NaN}}Vi.exports=hd(md)});var Hi=c((iN,Wi)=>{var dd=p(),pd=N();function gd(e){try{return dd(e)?Math.atan(e):NaN}catch{return NaN}}Wi.exports=pd(gd)});var Qi=c((oN,Xi)=>{var qd=h(),yd=oe(),bd=m(),Nd=q(),vd=g(),wd=re();function Pt(e){if(Nd(e)){let t=Pt(e.values);return[e.index[t[0]],e.columns[t[1]]]}if(vd(e)){let t=Pt(e.values);return[e.index[t]]}qd(bd(e),"The `argmax` function only works on arrays, Series, and DataFrames!");try{let t=yd(e,wd(e));return t?t.length===0?void 0:t.length===1?t[0]:t:void 0}catch{return}}Xi.exports=Pt});var Re=c((uN,eo)=>{var Sd=h(),Od=S(),xd=m(),Td=q(),_d=g();function Zi(e){if(Td(e)||_d(e))return Zi(e.values);Sd(xd(e),"The `min` function only works on arrays, Series, and DataFrames!");try{return Math.min(...Od(e))}catch{return NaN}}eo.exports=Zi});var no=c((aN,to)=>{var Dd=h(),Ad=oe(),Fd=m(),jd=q(),Ed=g(),Id=Re();function zt(e){if(jd(e)){let t=zt(e.values);return[e.index[t[0]],e.columns[t[1]]]}if(Ed(e)){let t=zt(e.values);return[e.index[t]]}Dd(Fd(e),"The `argmin` function only works on arrays, Series, and DataFrames!");try{let t=Ad(e,Id(e));return t?t.length===0?void 0:t.length===1?t[0]:t:void 0}catch{return}}to.exports=zt});var Yt=c((cN,io)=>{var ro=m(),Ct=Be(),Md=q(),kt=ae(),Ud=I(),so=p(),Bd=C(),Pd=g(),Jt=b();function z(e,t){if(Md(e)||Pd(e))return e.apply(n=>z(n,t));if(ro(e))return e.map(n=>z(n,t));if(t==="null")return null;if(t==="number"){if(Jt(e))return NaN;let n=z(e,"boolean");if(Ct(n))return n?1:0;try{JSON.parse(e)}catch{let i=z(e,"date");if(kt(i))return i.getTime()}let s=parseFloat(e);return isNaN(s)?NaN:s}if(t==="boolean"){if(Ct(e))return e;if(so(e))return e===0?!1:e===1?!0:null;try{let n=(typeof e=="object"?e.toString()==="null"?"false":JSON.stringify(e):e.toString()).trim().toLowerCase();return n==="true"||n==="yes"||n==="y"?!0:n==="false"||n==="no"||n==="n"?!1:null}catch{return null}}if(t==="date"){if(kt(e))return e;if(Jt(e))return null;let n=parseFloat(e);if(!isNaN(n)){let r=new Date(e);return kt(r)?r:null}let s=Date.parse(e);return isNaN(s)?null:new Date(s)}if(t==="object"){if(Bd(e))return e;let n=z(e,"boolean");if(Ct(n))return null;try{let r=z(e,"number");if(so(r))return JSON.parse(e),null}catch{}let s=z(e,"date");if(s)return s;try{let r=JSON.parse(e);return ro(r)?r.map(i=>z(i,t)):r}catch{return null}}if(t==="string")return Jt(e)?Ud(e,void 0)?"undefined":"null":e instanceof Date?e.toJSON():(()=>typeof e=="object"?e===null?"null":JSON.stringify(e):e.toString())()}io.exports=z});var uo=c((lN,oo)=>{var zd=p(),Cd=N();function kd(e){try{return zd(e)?Math.ceil(e):NaN}catch{return NaN}}oo.exports=Cd(kd)});var lo=c((fN,co)=>{var Jd=Ye(),ao=p(),Yd=b(),$d=N();function Rd(e,t){try{if(!ao(e))return NaN;if(Yd(t))t=1e-10;else if(!ao(t))return NaN;return Jd(e)<t?0:e}catch{return NaN}}co.exports=$d(Rd)});var ho=c((hN,fo)=>{var $t=p(),Ld=N();function Kd(e,t,n){try{return $t(e)?$t(t)?$t(n)?e<t?t:e>n?n:e:NaN:NaN:NaN}catch{return NaN}}fo.exports=Ld(Kd)});var po=c((mN,mo)=>{var Rt=h(),Vd=S(),Gd=m(),Wd=q(),Hd=p(),Xd=g();function Lt(e,t){if(Wd(e)||Xd(e))return Lt(e.values,t);if(Rt(Gd(e),"The `combinations` function only works on arrays, Series, and DataFrames!"),Rt(Hd(t),"`r` must be a whole number!"),e=Vd(e),t>e.length)return[e];if(t<=0)return[[]];if(Rt(t===parseInt(t),"`r` must be a whole number!"),e.length<2)return e;let n=[];return e.forEach((s,r)=>{let i=e.slice(r+1);if(i.length<t-1)return;Lt(i,t-1).forEach(u=>{n.push([s].concat(u))})}),n}mo.exports=Lt});var Le=c((dN,qo)=>{var Qd=h(),Zd=S(),ep=m(),tp=q(),np=g();function go(e){if(tp(e)||np(e))return go(e.values);Qd(ep(e),"The `mean` function only works on arrays, Series, and DataFrames!");try{let t=Zd(e),n=0;return t.forEach(s=>{n+=s}),n/t.length}catch{return NaN}}qo.exports=go});var Vt=c((pN,So)=>{var yo=h(),bo=m(),Ke=p(),No=g(),vo=Le(),wo=v();function Kt(e,t){if(No(e))return Kt(e.values,t);if(No(t))return Kt(e,t.values);yo(bo(e)&&bo(t)&&wo(e).length===1&&wo(t).length===1,"The `covariance` function only works on 1-dimensional arrays and Series!"),yo(e.length===t.length,"The two arrays or Series passed into the `covariance` function must have the same length!");try{let n=vo(e),s=vo(t);if(!Ke(n)||!Ke(s))return NaN;let r=Math.max(e.length,t.length),i=0;for(let o=0;o<r;o++){if(!Ke(e[o]))return NaN;if(!Ke(t[o]))return NaN;i+=(e[o]-n)*(t[o]-s)}return i/e.length}catch{return NaN}}So.exports=Kt});var Ve=c((gN,Oo)=>{var rp=p(),sp=N();function ip(e){try{return rp(e)?Math.sqrt(e):NaN}catch{return NaN}}Oo.exports=sp(ip)});var Gt=c((qN,To)=>{var op=h(),up=S(),ap=m(),cp=q(),lp=p(),fp=g(),hp=Le();function xo(e){if(cp(e)||fp(e))return xo(e.values);op(ap(e),"The `variance` function only works on arrays, Series, and DataFrames!");try{let t=up(e),n=hp(t),s=0;for(let r=0;r<t.length;r++){if(!lp(t[r]))return NaN;s+=(t[r]-n)*(t[r]-n)}return s/t.length}catch{return NaN}}To.exports=xo});var Ge=c((yN,Do)=>{var mp=h(),dp=m(),pp=q(),gp=g(),qp=Ve(),yp=Gt();function _o(e){if(pp(e)||gp(e))return _o(e.values);mp(dp(e),"The `std` function only works on arrays, Series, and DataFrames!");try{return qp(yp(e))}catch{return NaN}}Do.exports=_o});var Uo=c((bN,Mo)=>{var Ao=h(),bp=Vt(),Fo=m(),jo=g(),Eo=v(),Io=Ge();function Wt(e,t){if(jo(e))return Wt(e.values,t);if(jo(t))return Wt(e,t.values);Ao(Fo(e)&&Fo(t)&&Eo(e).length===1&&Eo(t).length===1,"The `correl` function only works on 1-dimensional arrays and Series!"),Ao(e.length===t.length,"The two arrays or Series passed into the `correl` function must have the same length!");try{return bp(e,t)/(Io(e)*Io(t))}catch{return NaN}}Mo.exports=Wt});var Po=c((NN,Bo)=>{var Np=p(),vp=N();function wp(e){try{return Np(e)?Math.cos(e):NaN}catch{return NaN}}Bo.exports=vp(wp)});var Co=c((vN,zo)=>{zo.exports=Object.freeze({boolean:"boolean",date:"date",null:"null",number:"number",object:"object",string:"string"})});var Lo=c((wN,Ro)=>{var Sp=h(),ko=m(),Jo=q(),Op=I(),Yo=g(),$o=M();function Ht(e,t){if(Jo(e)||Yo(e))return Ht(e.values,t);if(Jo(t)||Yo(t))return Ht(e,t.values);Sp(ko(e)&&ko(t),"The `diff` function only works on arrays, Series, and DataFrames!");let n=$o(e),s=$o(t),r=[];return n.forEach(i=>{s.findIndex(o=>Op(o,i))<0&&r.push(i)}),r}Ro.exports=Ht});var We=c((SN,Vo)=>{var Ko=p(),xp=N();function Tp(e,t){try{return Ko(e)?Ko(t)?Math.pow(e,t):NaN:NaN}catch{return NaN}}Vo.exports=xp(Tp)});var Xt=c((ON,Go)=>{var _p=p(),Dp=N();function Ap(){try{let e=Object.values(arguments);if(e.length===0)return NaN;let t=1;for(let n=0;n<e.length;n++){if(!_p(e[n]))return NaN;t*=e[n]}return t}catch{return NaN}}Go.exports=Dp(Ap)});var se=c((xN,Wo)=>{var Fp=Xt();function jp(){return Fp(...arguments)}Wo.exports=jp});var Qt=c((TN,Ho)=>{var Ep=$e(),Ip=se();function Mp(e,t){return Ep(e,Ip(t,-1))}Ho.exports=Mp});var He=c((_N,Qo)=>{var Up=h(),Bp=S(),Pp=m(),zp=q(),Cp=g();function Xo(e){if(zp(e)||Cp(e))return Xo(e.values);Up(Pp(e),"The `sum` function only works on arrays, Series, and DataFrames!");try{return e.length===0?NaN:Bp(e).reduce((t,n)=>t+n,0)}catch{return NaN}}Qo.exports=Xo});var iu=c((DN,su)=>{var kp=Ye(),Jp=h(),Zo=m(),eu=q(),Yp=I(),tu=p(),nu=g(),$p=We(),ru=v(),Rp=Ve(),Lp=Qt(),Kp=He();function Zt(e,t){if(tu(e)&&tu(t))return kp(e-t);if(eu(e)||nu(e))return Zt(e.values,t);if(eu(t)||nu(t))return Zt(e,t.values);Zo(e)&&Zo(t)&&Jp(Yp(ru(e),ru(t)),"If passing two arrays, Series, or DataFrames into the `distance` function, then those objects must have the same shape!");try{return Rp(Kp($p(Lp(e,t),2)))}catch{return NaN}}su.exports=Zt});var uu=c((AN,ou)=>{var Vp=We(),Gp=se();function Wp(e,t){return Gp(e,Vp(t,-1))}ou.exports=Wp});var tn=c((FN,mu)=>{var{DataFrame:au,Series:cu}=we(),Xe=h(),lu=S(),fu=m(),en=q(),Hp=p(),Qe=g(),Xp=se(),Ze=v(),Qp=He(),hu=H();function K(e,t){if(en(e)){let r=K(e.values,t);if(Ze(r).length===1){let i=new cu(r);return i.name=Qe(t)?t.name:i.name,i.index=e.index.slice(),i}else{let i=new au(r);return i.index=e.index.slice(),en(t)&&(i.columns=t.columns.slice()),i}}if(en(t)){let r=K(e,t.values);if(Ze(r).length===1){let i=new cu(r);return i.name=Qe(e)?e.name:i.name,i.index=t.columns.slice(),i}else{let i=new au(r);return i.columns=t.columns.slice(),i}}if(Qe(e))return K(e.values,t);if(Qe(t))return K(e,t.values);Xe(fu(e)&&fu(t),"The `dot` function only works on arrays, Series, and DataFrames!"),lu(e).concat(lu(t)).forEach(r=>{Xe(Hp(r),"One of the arrays you passed into the `dot` function contains non-numerical values!")});let n=Ze(e),s=Ze(t);if(Xe(n.length<=2&&s.length<=2,"I'm not smart enough to know how to get the dot-product of arrays that have more than 2 dimensions. Sorry for the inconvenience! Please only pass 1- or 2-dimensional arrays into the `dot` function!"),Xe(n[n.length-1]===s[0],`There's a dimension misalignment in the two arrays you passed into the \`dot\` function. (${n[n.length-1]} !== ${s[0]})`),n.length===1&&s.length===1)return Qp(Xp(e,t));if(n.length===1&&s.length===2)return hu(t).map(r=>K(e,r));if(n.length===2&&s.length===1)return e.map(r=>K(r,t));if(n.length===2&&s.length===2){let r=hu(t),i=[];for(let o=0;o<e.length;o++){let u=[];for(let a=0;a<r.length;a++)u.push(K(e[o],r[a]));i.push(u)}return i}}mu.exports=K});var nn=c((jN,pu)=>{var Zp=h(),eg=m(),tg=q(),ng=g(),rg=b();function du(e){if(tg(e)||ng(e))return e.dropMissing(...Object.values(arguments).slice(1));Zp(eg(e),"The `dropMissing` function only works on arrays, Series, and DataFrames!");let t=[];return e.forEach(n=>{try{return t.push(du(n))}catch{rg(n)||t.push(n)}}),t}pu.exports=du});var Su=c((EN,wu)=>{var gu=h(),qu=m(),yu=q(),sg=I(),bu=g(),Nu=b(),vu=v();function et(e,t){if(yu(e)||bu(e))return et(e.values,t);if(yu(t)||bu(t))return et(e,t.values);gu(qu(e)&&qu(t),"The `dropMissingPairwise` function only works on arrays, Series, and DataFrames!"),gu(sg(vu(e),vu(t)),"The two arrays, Series, and/or DataFrames passed into the `dropMissingPairwise` function must have the same shape!");let n=[],s=[];for(let r=0;r<e.length;r++)try{let[i,o]=et(e[r],t[r]);n.push(i),s.push(o)}catch{!Nu(e[r])&&!Nu(t[r])&&(n.push(e[r]),s.push(t[r]))}return[n,s]}wu.exports=et});var ju=c((IN,Fu)=>{var Ou=h(),xu=m(),Tu=q(),ig=I(),_u=p(),Du=g(),Au=v();function tt(e,t){if(Tu(e)||Du(e))return tt(e.values,t);if(Tu(t)||Du(t))return tt(e,t.values);Ou(xu(e)&&xu(t),"The `dropNaNPairwise` only works on arrays, Series, and DataFrames!"),Ou(ig(Au(e),Au(t)),"The two arrays, Series, and/or DataFrames passed into the `dropNaNPairwise` must have the same shape!");let n=[],s=[];for(let r=0;r<e.length;r++)try{let[i,o]=tt(e[r],t[r]);n.push(i),s.push(o)}catch{_u(e[r])&&_u(t[r])&&(n.push(e[r]),s.push(t[r]))}return[n,s]}Fu.exports=tt});var Iu=c((MN,Eu)=>{var og=nn();function ug(e){return og(e)}Eu.exports=ug});var Uu=c((UN,Mu)=>{var ag=p(),cg=N();function lg(e){try{return ag(e)?Math.exp(e):NaN}catch{return NaN}}Mu.exports=cg(lg)});var zu=c((BN,Pu)=>{var fg=N();function Bu(e){try{return e!==parseInt(e)?NaN:e<=1?1:e*Bu(e-1)}catch{return NaN}}Pu.exports=fg(Bu)});var Yu=c((PN,Ju)=>{var hg=h(),mg=S(),Cu=m(),dg=q(),pg=D(),ku=C(),gg=g();function rn(e,t){if(dg(e))return rn(mg(e.values),t);if(gg(e))return rn(e.values,t);if(hg(ku(e)||Cu(e),"You must pass (1) an object, array, Series, or DataFrame and (2) a function or value into the `find` function!"),!pg(t)){let r=t;t=i=>i===r}function n(r,i,o){if(o=o||[],o.indexOf(r)>-1)return null;if(ku(r)){o.push(r);let u=Object.keys(r).concat(Object.getOwnPropertySymbols(r));for(let a=0;a<u.length;a++){let l=u[a],f=r[l];if(i(f))return f;let d=n(f,i,o);if(d)return d}}else if(Cu(r)){o.push(r);for(let u=0;u<r.length;u++){let a=r[u];if(i(a))return a;let l=n(a,i,o);if(l)return l}}else if(i(r))return r;return null}function s(r){try{return t(r)}catch{return!1}}return n(e,s)}Ju.exports=rn});var Ku=c((zN,Lu)=>{var qg=h(),yg=S(),$u=m(),bg=q(),Ng=D(),Ru=C(),vg=g();function sn(e,t){if(bg(e))return sn(yg(e.values),t);if(vg(e))return sn(e.values,t);if(qg(Ru(e)||$u(e),"You must pass (1) an object, array, Series, or DataFrame and (2) a function or value into the `findAll` function!"),!Ng(t)){let i=t;t=o=>o===i}function n(i,o,u){if(u=u||[],u.indexOf(i)>-1)return null;if(Ru(i)){u.push(i);let a=Object.keys(i).concat(Object.getOwnPropertySymbols(i)),l=[];for(let f=0;f<a.length;f++){let d=a[f],y=i[d],T=!1;o(y)&&(l.push(y),T=!0);let G=n(y,o,u);G&&G.length>0&&G.slice(T?1:0).forEach(_=>l.push(_))}return l}else if($u(i)){u.push(i);let a=[];for(let l=0;l<i.length;l++){let f=i[l],d=!1;o(f)&&(a.push(f),d=!0);let y=n(f,o,u);y&&y.length>0&&y.slice(d?1:0).forEach(T=>a.push(T))}return a}else if(o(i))return[i];return null}function s(i){try{return t(i)}catch{return!1}}let r=n(e,s);return r&&r.length>0?r:null}Lu.exports=sn});var Gu=c((CN,Vu)=>{var wg=p(),Sg=N();function Og(e){try{if(e==="Infinity")return 1/0;if(e==="-Infinity")return-1/0;let t=JSON.parse(e);return wg(t)?t:NaN}catch{return NaN}}Vu.exports=Sg(Og)});var Hu=c((kN,Wu)=>{var xg=p(),Tg=N();function _g(e){try{return xg(e)?Math.floor(e):NaN}catch{return NaN}}Wu.exports=Tg(_g)});var on=c((JN,Xu)=>{var Dg=p(),Ag=ge(),Fg=Me();function jg(e){Dg(e)&&(e=[e]);let t=[],n=Ag(e);for(let s=0;s<n;s++)t.push(0);return Fg(t,e)}Xu.exports=jg});var Zu=c((YN,Qu)=>{var nt=h(),Eg=p(),Ig=b(),Mg=on();function Ug(e){nt(!Ig(e),"You must pass an integer greater than 0 (representing the size) into the `identity` function!"),nt(Eg(e),"You must pass an integer greater than 0 (representing the size) into the `identity` function!"),nt(parseInt(e)===e,"You must pass an integer greater than 0 (representing the size) into the `identity` function!"),nt(e>0,"You must pass an integer greater than 0 (representing the size) into the `identity` function!");let t=Mg([e,e]);for(let n=0;n<e;n++)t[n][n]=1;return t}Qu.exports=Ug});var ta=c(($N,ea)=>{ea.exports=["true","false","yes","no"]});var ra=c((RN,na)=>{na.exports=["null","none","nan","na","n/a","","undefined"]});var aa=c((LN,ua)=>{var Bg=Oe(),Pg=h(),zg=ta(),Cg=Yt(),kg=le(),ia=S(),un=m(),Jg=q(),sa=ae(),oa=p(),Yg=g(),$g=A(),Rg=ra();function rt(e){return e.type==="number"&&(typeof e.value<"u"?e.isInteger=parseInt(e.value)===e.value:e.isInteger=ia(e.values).every(t=>oa(t)?parseInt(t)===t:!0)),e}function st(e){if(Jg(e)){let r=e.copy(),i=st(e.values);return r.values=i.values,rt({type:i.type,values:r})}if(Yg(e)){let r=e.copy(),i=st(e.values);return r.values=i.values,rt({type:i.type,values:r})}if(!un(e)){let r=st([e]);return r.value=r.values[0],delete r.values,rt(r)}Pg(un(e),"The `inferType` function only works on arrays, Series, and DataFrames!");let t=ia(e).map(r=>{if(r===void 0)return"null";try{if(typeof r=="object"){let u=new Date(r.getTime());if(sa(u))return"date"}}catch{}$g(r)||(r=JSON.stringify(r));let o=r.toLowerCase().trim();if(Rg.indexOf(o)>-1)return"null";if(zg.indexOf(o)>-1)return"boolean";try{let u=JSON.parse(r);return oa(u)?"number":typeof u=="object"?un(u)?"string":"object":"string"}catch{let a=new Date(r);return sa(a)?"date":"string"}}),s=kg(t).sort((r,i)=>i.count-r.count)[0].value;return rt({type:s,values:Bg(e,r=>Cg(r,s))})}ua.exports=st});var la=c((KN,ca)=>{var Lg=p(),Kg=N();function Vg(e){try{let t=JSON.parse(e);return Lg(t)?parseInt(t):NaN}catch{return NaN}}ca.exports=Kg(Vg)});var ha=c((VN,fa)=>{var Gg=h(),Wg=m(),Hg=q(),Xg=I(),Qg=g(),an=M();function Zg(){let e=Object.values(arguments).map(n=>Hg(n)||Qg(n)?an(n.values):(Gg(Wg(n),"The `intersect` function only works on arrays, Series, and DataFrames!"),an(n)));return an(e).filter(n=>e.every(s=>s.findIndex(r=>Xg(r,n))>-1))}fa.exports=Zg});var ga=c((GN,pa)=>{var ma=$e(),V=h(),eq=tn(),tq=S(),nq=m(),rq=q(),cn=p(),da=se(),sq=v();function it(e){if(rq(e)){let n=e.copy();return n.values=it(n.values),n}V(nq(e),"The `inverse` function only works on square 2-dimensional arrays or DataFrames!"),tq(e).forEach(n=>V(cn(n),"The array passed into the `inverse` function must contain only numbers!"));let t=sq(e);if(V(t.length===2,"The array passed into the `inverse` function must be exactly two-dimensional and square!"),V(t[0]===t[1],"The array passed into the `inverse` function must be exactly two-dimensional and square!"),V(t[0]>=0,"The array passed into the `inverse` function must be exactly two-dimensional and square!"),t[0]===0)return e;if(t[0]===1)return V(e[0][0]!==0,"This matrix cannot be inverted!"),1/e[0][0];if(t[0]===2){let n=e[0][0],s=e[0][1],r=e[1][0],i=e[1][1],o=n*i-s*r;V(o!==0,"This matrix cannot be inverted!");let u=[[i,-s],[-r,n]];return da(u,1/o)}else if(t[0]>1){let n=(s,r)=>cn(s)||cn(r)?da(s,r):eq(s,r);for(let s=1;s<t[0]-1;s++)try{let r=e.slice(0,s).map(_=>_.slice(0,s)),i=e.slice(0,s).map(_=>_.slice(s,t[0])),o=e.slice(s,t[0]).map(_=>_.slice(0,s)),u=e.slice(s,t[0]).map(_=>_.slice(s,t[0])),a=it(r),l=it(ma(u,n(-1,n(n(o,a),i)))),f=ma(a,n(n(n(n(a,i),l),o),a)),d=n(-1,n(n(a,i),l)),y=n(-1,n(n(l,o),a)),T=l;return f.map((_,at)=>_.concat(d[at])).concat(y.map((_,at)=>_.concat(T[at])))}catch{}V(!1,"This matrix cannot be inverted!")}}pa.exports=it});var ya=c((WN,qa)=>{var iq=new Function(`
|
|
14
|
+
\x1B[0m`)}};yr.exports=ct});var h=c((Yy,br)=>{var pc=X();br.exports=function(e,t){if(!e)throw new pc(t)}});var b=c((Ly,Nr)=>{function gc(e){return e===null||typeof e>"u"}Nr.exports=gc});var wr=c((Ky,vr)=>{vr.exports=[Array,ArrayBuffer,BigInt64Array,BigUint64Array,Float32Array,Float64Array,Int16Array,Int32Array,Int8Array,Uint16Array,Uint32Array,Uint8Array,Uint8ClampedArray]});var m=c((Vy,Or)=>{var qc=b(),Sr=wr(),yc=Sr.map(e=>e.name);function bc(e){try{return e instanceof Array?!0:qc(e.constructor)?!1:Sr.indexOf(e.constructor)>-1||yc.indexOf(e.constructor.name)>-1}catch{return!1}}Or.exports=bc});var q=c((Gy,xr)=>{function Nc(e){try{return!!e._symbol&&e._symbol===Symbol.for("@jrc03c/js-math-tools/dataframe")}catch{return!1}}xr.exports=Nc});var D=c((Wy,Tr)=>{function vc(e){return typeof e=="function"}Tr.exports=vc});var p=c((Hy,_r)=>{function wc(e){return typeof e=="number"&&!isNaN(e)}_r.exports=wc});var z=c((Xy,Dr)=>{var Sc=m(),Oc=b();function xc(e){return typeof e=="object"&&!Oc(e)&&!Sc(e)}Dr.exports=xc});var g=c((Qy,Fr)=>{function Tc(e){try{return!!e._symbol&&e._symbol===Symbol.for("@jrc03c/js-math-tools/series")}catch{return!1}}Fr.exports=Tc});var oe=c((Zy,Er)=>{var _c=h(),Ar=m(),Dc=q(),Fc=D(),lt=p(),jr=z(),Ac=g();function ft(e,t){if(Dc(e)){let i=ft(e.values,t);return i.length>0&<(i[0])&&i[0]>=0&&i[0]<e.index.length&&(i[0]=e.index[i[0]]),i.length>1&<(i[1])&&i[1]>=0&&i[1]<e.columns.length&&(i[1]=e.columns[i[1]]),i}if(Ac(e)){let i=ft(e.values,t);return i.length>0&<(i[0])&&i[0]>=0&&i[0]<e.index.length&&(i[0]=e.index[i[0]]),i}if(_c(jr(e)||Ar(e),"You must pass (1) an object, array, Series, or DataFrame and (2) a function or value into the `indexOf` function!"),!Fc(t)){let i=t;t=o=>o===i}function r(i,o,u){if(u=u||[],u.indexOf(i)>-1)return null;if(jr(i)){u.push(i);let a=Object.keys(i).concat(Object.getOwnPropertySymbols(i));for(let l=0;l<a.length;l++){let f=a[l],d=i[f];if(o(d))return[f];let y=r(d,o,u);if(y&&y.length>0)return[f].concat(y)}}else if(Ar(i)){u.push(i);for(let a=0;a<i.length;a++){let l=i[a];if(o(l))return[a];let f=r(l,o,u);if(f&&f.length>0)return[a].concat(f)}}else if(o(i))return[];return null}function n(i){try{return t(i)}catch{return!1}}let s=r(e,n);return s&&s.length>0?s:null}Er.exports=ft});var B=c((eb,Br)=>{var jc=oe(),Ir=m(),Mr=q(),Ur=g();function ue(e){function t(r){if(typeof r=="object"){if(r===null)return null;if(Ir(r))return r instanceof Array?r.map(s=>ue(s)):r.slice();if(Ur(r)){let s=r.copy();return s.values=ue(s.values),s}if(Mr(r)){let s=r.copy();return s.values=ue(r.values),s}if(r instanceof Date)return new Date(r.getTime());r=ht(r);let n={};return Object.keys(r).concat(Object.getOwnPropertySymbols(r)).forEach(s=>{n[s]=ue(r[s])}),n}else return r}return t(ht(e))}function ht(e){function t(s,i,o){if(i=i||[],o=o||"",i.indexOf(s)>-1){let u=o.split("/").slice(o.startsWith("/")?1:0);if(u.some((l,f)=>{let d=u.slice(0,u.length-f-1),y=r;return d.forEach(T=>{y=y[T]}),y===s}))return`<reference to "${r===s?"/":"/"+jc(r,s).join("/")}">`}return typeof s=="object"?s===null?null:(i.push(s),Ir(s)?typeof s.constructor<"u"&&s.constructor.name!=="Array"?s.slice():s.map((u,a)=>t(u,i,o+"/"+a)):(Object.keys(s).concat(Object.getOwnPropertySymbols(s)).forEach(u=>{s[u]=t(s[u],i,o+"/"+u.toString())}),s)):s}let r=e,n=t(r);if(Mr(e)){let s=e.copy();s._values=n.values,s._columns=n.columns,s._index=n.index,n=s}if(Ur(e)){let s=e.copy();s.name=n.name,s._values=n.values,s._index=n.index,n=s}return n}Br.exports={copy:ue,decycle:ht}});var S=c((tb,zr)=>{var Ec=h(),Cr=m(),Ic=q(),Mc=g();function Pr(e){if(Ic(e)||Mc(e))return Pr(e.values);Ec(Cr(e),"The `flatten` function only works on arrays, Series, and DataFrames!");function t(r){let n=[];return r.forEach(s=>{Cr(s)?n=n.concat(t(s)):n.push(s)}),n}return t(e)}zr.exports=Pr});var ae=c((rb,kr)=>{function Uc(e){return e instanceof Date&&e.toString()!=="Invalid Date"}kr.exports=Uc});var U=c((nb,Rr)=>{var{decycle:Jr}=B(),$r=m(),mt=ae();function Bc(e,t){function r(n,s){let i=typeof n;if(i!==typeof s)return!1;if(i==="undefined")return!0;if(i==="boolean"||i==="symbol")return n===s;if(i==="number"||i==="bigint")return n.toString()==="NaN"&&s.toString()==="NaN"?!0:n===s;if(i==="string"||i==="function")return n===s;if(i==="object"){if(n===null||s===null)return n===null&&s===null;{if(mt(n))return mt(s)?n.getTime()===s.getTime():!1;if(mt(s))return!1;if(n instanceof RegExp&&s instanceof RegExp)return n.toString()===s.toString();if($r(n)!==$r(s))return!1;let u=Object.keys(n).concat(Object.getOwnPropertySymbols(n)),a=Object.keys(s).concat(Object.getOwnPropertySymbols(s));if(u.length!==a.length)return!1;for(let l=0;l<u.length;l++){let f=u[l];if(!r(n[f],s[f]))return!1}return!0}}}try{return r(e,t)}catch{return r(Jr(e),Jr(t))}}Rr.exports=Bc});var E=c((sb,Vr)=>{var Cc=h(),Pc=S(),zc=m(),Yr=q(),kc=D(),Lr=g(),Jc=b();function ce(e){let t="abcdefg1234567890",r="";for(;r.length<e;)r+=t[parseInt(Math.random()*t.length)];return r}var $c=ce(256),Rc=ce(256),Yc=ce(256),Lc=ce(256),Kc=ce(256);function Kr(e){if(Yr(e)||Lr(e))return Kr(e.values);Cc(zc(e),"The `set` function only works on arrays, Series, and DataFrames!");let t=[],r={};return Pc(e).forEach(n=>{let s=typeof n=="object"&&n===null?$c:Jc(n)?Rc:kc(n)?n.toString():typeof n=="symbol"?n.toString()+" - "+Kc:n===1/0?Yc:n===-1/0?Lc:Yr(n)?n.toJSONString():Lr(n)?JSON.stringify(n.toObject()):JSON.stringify(n);r[s]||t.push(n),r[s]=!0}),t}Vr.exports=Kr});var le=c((ib,Hr)=>{var Vc=h(),dt=S(),Gr=m(),Gc=q(),Wr=U(),Wc=D(),Hc=g(),Xc=E();function xe(e,t){if(Gc(e)||Hc(e))return arguments.length>1?xe(e.values,t):xe(e.values,e.values);if(Vc(Gr(e),"The first argument to the `count` function must be an array, Series, or DataFrame!"),Wc(t))return dt(e).filter(r=>t(r)).length;if(Gr(t)){let r=dt(e);return Xc(t).map(n=>({value:n,count:r.filter(s=>Wr(s,n)).length}))}else return arguments.length>1?dt(e).filter(r=>Wr(r,t)).length:xe(e,e)}Hr.exports=xe});var fe=c((ob,Qr)=>{var Qc=h(),Xr=m(),Zc=q(),el=g();function pt(e){if(Zc(e)||el(e))return pt(e.values);Qc(Xr(e),"The `isJagged` function only works on arrays, Series, and DataFrames!");let t=0,r=null;for(let n=0;n<e.length;n++)if(Xr(e[n])){if(t++,pt(e[n]))return!0;if(r===null)r=e[n].length;else if(e[n].length!==r)return!0}return t>0&&t<e.length}Qr.exports=pt});var Te=c((ub,tn)=>{var tl=h(),Zr=m(),rl=q(),nl=g();function en(e){if(rl(e)||nl(e))return en(e.values);tl(Zr(e),"The `isNested` function only works on arrays, Series, and DataFrames!");for(let t=0;t<e.length;t++)if(Zr(e[t]))return!0;return!1}tn.exports=en});var k=c((ab,nn)=>{var W=h(),sl=m(),il=Te(),ol=p(),ul=b(),Q="You must pass a natural number or a one-dimensional array of natural numbers into the `ndarray` function!";function rn(e){W(!ul(e),Q),sl(e)||(e=[e]),W(!il(e),Q),W(e.length>0,Q);let t=e[0];if(W(ol(t),Q),W(parseInt(t)===t,Q),W(t>=0,Q),W(t!==1/0,"We can't create an array containing an infinite number of values!"),e.length===1){let r=[];for(let n=0;n<t;n++)r.push(void 0);return r}else{let r=[];for(let n=0;n<t;n++)r.push(rn(e.slice(1)));return r}}nn.exports=rn});var he=c((cb,sn)=>{var al=h(),cl=m(),ll=q(),fl=g();function gt(e){if(ll(e)||fl(e)){let r=e.copy();return r.values=gt(r.values),r.index=gt(r.index),r}al(cl(e),"The `reverse` function only works on arrays, Series, and DataFrames!");let t=[];for(let r=e.length-1;r>=0;r--)t.push(e[r]);return t}sn.exports=gt});var j=c((lb,on)=>{var qt=h(),yt=p(),bt=b(),hl=he();function ml(e,t,r=1){qt(!bt(e)&&!bt(t)&&!bt(r),"You must pass two numbers and optionally a step value to the `range` function!"),qt(yt(e)&&yt(t)&&yt(r),"You must pass two numbers and optionally a step value to the `range` function!"),qt(r>0,"The step value must be greater than 0! (NOTE: The step value is a magnitude; it does not indicate direction.)");let n=!1;if(e>t){n=!0;let i=e;e=t+r,t=i+r}let s=[];for(let i=e;i<t;i+=r)s.push(i);return n&&(s=hl(s)),s}on.exports=ml});var v=c((fb,ln)=>{var dl=h(),un=m(),pl=q(),gl=U(),ql=g(),yl=b();function an(e){if(!un(e))return;let t=[e.length],r=0,n=e.map(s=>{let i=an(s);return yl(i)?i:(r++,i.length===1?i[0]:i)});return r>0?r===e.length&&n.slice(0,-1).every((i,o)=>gl(i,n[o+1]))?t.concat(n[0]):(t.push(n),t):t}function cn(e){return pl(e)||ql(e)?cn(e.values):(dl(un(e),"The `shape` function only works on arrays, Series, and DataFrames!"),an(e))}ln.exports=cn});var gn=c((hb,pn)=>{var fn=h(),bl=m(),Nl=q(),vl=fe(),wl=g(),Sl=b(),hn=X(),_e=k(),mn=j(),Ol=E(),xl=v();function dn(e,t,r){if(Sl(r)&&(r=0),fn(r===0||r===1||r==="vertical"||r==="horizontal",'The only valid axis values for use when appending data to a DataFrame are 0, 1, "vertical", and "horizontal". Note that 0 == "horizontal" and 1 == "vertical".'),bl(t)){fn(!vl(t),"The array of data you're trying to append to this DataFrame is jagged!");let n=xl(t);if(n.length===1)if(r===0){let s=e.copy();s._values.push(t);let i=Math.max(e.shape[1],n[0]);for(s._values.forEach(o=>{for(;o.length<i;)o.push(void 0)});s._index.length<s._values.length;)s._index.push("row"+s._index.length);for(;s._columns.length<i;)s._columns.push("col"+s._columns.length);return s}else{let s=Math.max(e.shape[0],n[0]),i=e.copy();for(mn(0,s).forEach(o=>{o>=i._values.length&&i._values.push(_e(e.shape[1])),i._values[o].push(t[o])});i._index.length<i._values.length;)i._index.push("row"+i._index.length);for(;i._columns.length<i._values[0].length;)i._columns.push("col"+i._columns.length);return i}else if(n.length===2)if(r===0){let s=Math.max(...t.map(o=>o.length).concat([e.shape[1]])),i=e.copy();for(i._values=i._values.concat(t).map(o=>{for(;o.length<s;)o.push(void 0);return o});i._index.length<i._values.length;)i._index.push("row"+i._index.length);for(;i._columns.length<s;)i._columns.push("col"+i._columns.length);return i}else{let s=Math.max(...t.map(u=>u.length))+e.shape[1],i=Math.max(e.shape[0],n[0]),o=e.copy();for(mn(0,i).forEach(u=>{for(u>=o._values.length&&o._values.push(_e(e.shape[1])),o._values[u]=o._values[u].concat(t[u]);o._values[u].length<s;)o._values[u].push(void 0)});o._index.length<o._values.length;)o._index.push("row"+o._index.length);for(;o._columns.length<s;)o._columns.push("col"+o._columns.length);return o}else throw new hn("Only 1- and 2-dimensional arrays can be appended to a DataFrame!")}else if(wl(t)){let n=dn(e,t.values,r);return r===0?n.index[n.index.length-1]=n.index.indexOf(t.name)>-1?t.name+" (2)":t.name:n.columns[n.columns.length-1]=n.columns.indexOf(t.name)>-1?t.name+" (2)":t.name,n}else if(Nl(t))if(r===0){let n=e.copy(),s=Ol(n._columns.concat(t._columns)).length;for(n._values.forEach(i=>{for(;i.length<s;)i.push(void 0)}),t.apply(i=>{let o=i.copy(),u=[];n._columns.forEach(a=>{let l=o._index.indexOf(a);l>-1?(u.push(o._values[l]),o._values.splice(l,1),o._index.splice(l,1)):u.push(void 0)}),n._values.push(u.concat(o._values))},1),n._columns=n._columns.concat(t._columns.filter(i=>n._columns.indexOf(i)<0));n._index.length<n._values.length;){let i="row"+n._index.length;n._index.push(i+(e._index.indexOf(i)>-1?" (2)":""))}return n}else{let n=e.copy();return n._index.forEach((s,i)=>{let o=t._index.indexOf(s);o>-1?n._values[i]=n._values[i].concat(t._values[o]):n._values[i]=n._values[i].concat(_e(t.shape[1]))}),t._index.forEach((s,i)=>{n._index.indexOf(s)<0&&(n._index.push(s),n._values.push(_e(n._columns.length).concat(t._values[i])))}),n._columns=n._columns.concat(t._columns.map(s=>s+(n._columns.indexOf(s)>-1?" (2)":""))),n}else throw new hn("Only 1- or 2-dimensional arrays, Series, and DataFrames can be appended to a DataFrame!")}pn.exports=dn});var vn=c((mb,Nn)=>{var qn=h(),yn=m(),Tl=D(),bn=b();function _l(e,t,r,n,s){if(s=s||0,qn(Tl(n),"The first parameter to the `apply` method must be a function."),qn(s===0||s===1,"The second parameter to the `apply` method (the `axis`) must be 0 or 1."),s===0){let i={},o;if(r.columns.forEach((u,a)=>{let l=new t(r.values.map(d=>d[a]));l.name=u,l.index=r.index;let f=n(l,a,r);f instanceof t?i[u]=f.values:i[u]=f,bn(o)&&(o=f instanceof t||yn(f))}),o){let u=new e(i);return u.index=r.index,u}else{let u=new t(r.columns.map(a=>i[a]));return u.index=r.columns,u}}else if(s===1){let i,o=r.values.map((u,a)=>{let l=new t(u);l.name=r.index[a],l.index=r.columns;let f=n(l,a,r);return bn(i)&&(i=f instanceof t||yn(f)),f instanceof t?f.values:f});if(i){let u=new e(o);return u.index=r.index,u.columns=r.columns,u}else{let u=new t(o);return u.index=r.index,u}}}Nn.exports=_l});var F=c((db,wn)=>{function Dl(e){return typeof e=="string"}wn.exports=Dl});var xn=c((pb,On)=>{var Sn=h(),Fl=m(),Al=fe(),jl=z(),El=F(),Il=b(),Ml=X(),Ul=v();function Bl(e,t,r,n,s){let i=u=>u instanceof e,o=u=>u instanceof t;if(Il(s)){if(i(n))return r.append(n,1);if(o(n))return r.append(n,1);if(jl(n)){let u=Math.max(...Object.keys(n).concat(Object.getOwnPropertySymbols(n)).map(a=>n[a].length));return Object.keys(n).concat(Object.getOwnPropertySymbols(n)).forEach(a=>{for(;n[a].length<u;)n[a].push(void 0)}),r.append(new e(n),1)}else throw new Ml("You must pass a DataFrame, Series, or object into the `assign` method!")}else{Sn(El(n),"If passing two arguments into the `assign` method, then the first argument must be a string name!"),Sn(Fl(s)&&!Al(s)&&Ul(s).length===1,"If passing two arguments into the `assign` method, then the second argument must be a 1-dimensional array!");let u=r.append(s,1);return u.columns[u.columns.length-1]=n,u}}On.exports=Bl});var _n=c((gb,Tn)=>{var{copy:Cl}=B();function Pl(e,t){if(t.isEmpty)return new e;let r=new e(Cl(t.values));return r.columns=t.columns.slice(),r.index=t.index.slice(),r}Tn.exports=Pl});var Mn=c((qb,In)=>{var De=h(),Dn=m(),Fn=p(),An=F(),jn=b(),En=v();function zl(e,t,r,n,s){jn(n)&&(n=[]),jn(s)&&(s=[]),(An(n)||Fn(n))&&(n=[n]),(An(s)||Fn(s))&&(s=[s]),De(Dn(n),"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings."),De(Dn(s),"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings."),De(En(n).length===1,"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings."),De(En(s).length===1,"The `drop` method only works on 1-dimensional arrays of numerical indices and/or strings.");let i,o;r.index.forEach((a,l)=>{n.indexOf(a)<0&&n.indexOf(l)<0&&(i||(i=[]),i.push(a))}),r.columns.forEach((a,l)=>{s.indexOf(a)<0&&s.indexOf(l)<0&&(o||(o=[]),o.push(a))});let u=r.get(i,o);if(u instanceof t){let a=new e;a=a.assign(u),r.index.indexOf(u.name)>-1&&(a=a.transpose()),u=a}return u}In.exports=zl});var me=c((yb,Un)=>{var kl=p();function Jl(e){return kl(e)&&parseInt(e)===e}function $l(e){return Jl(e)&&e>=0}Un.exports=$l});var Cn=c((bb,Bn)=>{var Nt=h(),Rl=F(),Fe=b(),Yl=me(),Ll=v();function Kl(e,t,r,n,s,i){n=n||0,Nt(n===0||n===1,"The first parameter of the `dropMissing` method (the `axis`) must be 0 or 1."),i=i||0,Nt(Yl(i),"The third parameter of the `dropMissing` method (the `threshold`) should be a whole number (meaning that data should be dropped if it contains more than `threshold` null values)."),s=i>0?"none":s||"any",Nt(s==="any"||s==="all"||s==="none","The second parameter of the `dropMissing` method (the `condition` parameter, which indicates the condition under which data should be dropped) should be 'any' or 'all' (meaning that if 'any' of the data contains null values, then it should be dropped; or that if 'all' of the data contains null values, then it should be dropped).");function o(l){if(i>0){let f=0;for(let d=0;d<l.length;d++){let y=l[d];if(Fe(y)&&f++,f>=i)return[]}}else if(s==="any")for(let f=0;f<l.length;f++){let d=l[f];if(Fe(d))return[]}else if(s==="all"){for(let f=0;f<l.length;f++){let d=l[f];if(!Fe(d))return l}return[]}return l}let u=r.copy(),a=Math.random().toString();if(n===0){u=u.assign(a,u.index);let l=u.values.map(o).filter(d=>d.length>0);if(Ll(l).length<2)return new e;u.values=l;let f=u.get(null,a);if(Fe(f))return new e;Rl(f)&&(f=[f]),f instanceof t&&(f=f.values),u.index=f,u=u.drop(null,a)}else if(n===1){let l={};if(u.columns.forEach((d,y)=>{let T=u.values.map(_=>_[y]),G=o(T);G.length>0&&(l[d]=G)}),Object.keys(l).length+Object.getOwnPropertySymbols(l).length===0)return new e;let f=new e(l);return f.index=u.index,f}return u}Bn.exports=Kl});var vt=c((Nb,zn)=>{var Vl=h(),Gl=m(),Wl=q(),Hl=p(),Xl=g();function Pn(e){if(Wl(e)||Xl(e))return e.dropNaN(...Object.values(arguments).slice(1));Vl(Gl(e),"The `dropNaN` function only works on arrays, Series, and DataFrames!");let t=[];return e.forEach(r=>{try{return t.push(Pn(r))}catch{if(Hl(r))return t.push(r)}}),t}zn.exports=Pn});var Jn=c((vb,kn)=>{var wt=h(),Ql=vt(),Zl=me();function ef(e,t,r,n,s){r=r||0,wt(r===0||r===1,"The first parameter of the `dropNaN` method (the `axis`) must be 0 or 1."),s=s||0,wt(Zl(s),"The third parameter of the `dropNaN` method (the `threshold`) should be a whole number (meaning that data should be dropped if it contains more than `threshold` NaN values)."),n=s>0?"none":n||"any",wt(n==="any"||n==="all"||n==="none","The second parameter of the `dropNaN` method (the `condition` parameter, which indicates the condition under which data should be dropped) should be 'any' or 'all' (meaning that if 'any' of the data contains NaN values, then it should be dropped; or that if 'all' of the data contains NaN values, then it should be dropped).");function i(u){let a=Ql(u);return s>0?u.length-a.length<s:n==="any"?a.length===u.length:n==="all"?a.length>0:!0}let o=t.copy();if(r===0){let u=o.index.filter(a=>{let l=o.get(a,null).values;return i(l)});return u.length>0?o.get(u,null):new e}else if(r===1){let u=o.columns.filter(a=>{let l=o.get(null,a).values;return i(l)});return u.length>0?o.get(null,u):new e}return o}kn.exports=ef});var Ln=c((wb,Yn)=>{var $n=h(),de=S(),tf=D(),rf=b();function Rn(e){let t={};return de(e).forEach((r,n)=>{t[r]=n}),t}function Z(e){return Object.keys(e).concat(Object.getOwnPropertySymbols(e)).sort((t,r)=>e[t]-e[r])}function nf(e,t,r,n,s){$n(tf(n),"The `filter` method takes a single parameter: a function that is used to filter the values."),rf(s)&&(s=0),$n(s===0||s===1,"The `axis` parameter to the `filter` method must be 0 or 1.");let i=r.copy();if(i.isEmpty)return i;let o=Rn(i.index),u=Rn(i.columns);if(s===0){let a=i.values.filter((l,f)=>{let d=new t(l);d.name=r.index[f],d.index=r.columns;let y=n(d,f,r);return y||delete o[i.index[f]],y});if(de(a).length===0)return new e;if(a.length===1){let l=new t(de(a));return l.name=Z(o)[0],l.index=Z(u),l}i.values=a,i.index=Z(o)}else if(s===1){i=i.transpose();let a=i.values.filter((l,f)=>{let d=new t(l);d.name=r.columns[f],d.index=r.index;let y=n(d,f,r);return y||delete u[i.index[f]],y});if(de(a).length===0)return new e;if(a.length===1){let l=new t(de(a));return l.name=Z(u)[0],l.index=Z(o),l}i.values=a,i.index=Z(u),i=i.transpose()}return i}Yn.exports=nf});var Gn=c((Sb,Vn)=>{var I=h(),Ae=p(),je=F(),Kn=b(),sf=E();function of(e,t,r){(je(t)||Ae(t))&&(t=[t]),(je(r)||Ae(r))&&(r=[r]);let n=sf((t||[]).concat(r||[]).map(s=>typeof s));return I(n.length<=2,"Only whole numbers and/or strings are allowed in `get` arrays!"),n.length===1&&I(n[0]==="string"||n[0]==="number","Only whole numbers and/or strings are allowed in `get` arrays!"),n.length===2&&(I(n.indexOf("string")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!"),I(n.indexOf("number")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!")),Kn(t)||(t=t.map(s=>{if(je(s))return I(e.index.indexOf(s)>-1,`Row "${s}" does not exist!`),s;if(Ae(s))return I(s>=0,`Index ${s} is out of bounds!`),I(parseInt(s)===s,"Row numbers must be integers!"),I(s<e.index.length,`Index ${s} is out of bounds!`),e.index[s]})),Kn(r)||(r=r.map(s=>{if(je(s))return I(e.columns.indexOf(s)>-1,`Column "${s}" does not exist!`),s;if(Ae(s))return I(s>=0,`Column ${s} is out of bounds!`),I(parseInt(s)===s,"Column numbers must be integers!"),I(s<e.columns.length,`Column ${s} is out of bounds!`),e.columns[s]})),e.getSubsetByNames(t,r)}Vn.exports=of});var J=c((Ob,Hn)=>{var Wn=h(),uf=m(),af=q(),cf=D(),lf=g(),ff=b();function hf(e,t){try{return e<t?-1:e>t?1:0}catch{return e=typeof e=="object"&&e!==null?JSON.stringify(e):e.toString(),t=typeof t=="object"&&t!==null?JSON.stringify(t):t.toString(),e<t?-1:e>t?1:0}}function mf(e,t){if(ff(t)&&(t=hf),af(e)||lf(e))return e.sort(...Object.values(arguments).slice(1));Wn(uf(e),"The `sort` function only works on arrays, Series, and DataFrames!"),Wn(cf(t),"The second parameter of the `sort` function must be a comparison function!");let r=e.slice();return r.sort(t),r}Hn.exports=mf});var es=c((xb,Zn)=>{var Xn=h(),Qn=F(),df=b(),pf=E(),gf=J();function qf(e){let t=e.toLowerCase(),r="";for(let s=0;s<t.length;s++){let i=t[s];i.match(/[a-z0-9]/g)?r+=i:r+=" "}let n=r.split(" ").filter(s=>s.length>0);return n[0]+n.slice(1).map(s=>s[0].toUpperCase()+s.substring(1)).join("")}function yf(e,t,r){df(r)?r=t.columns:Qn(r)&&(r=[r]);let n={};r.forEach(i=>{Xn(Qn(i),"You must pass either a string or a one-dimensional array of strings into the `getDummies` (AKA `oneHotEncode`) method!");let o=t.columns.indexOf(i);Xn(o>-1,`The given DataFrame does not have a column called "${i}"!`);let u=t.values.map(l=>l[o]),a=gf(pf(u));u.forEach(l=>{a.forEach(f=>{let d=i+"_"+qf(f.toString());n[d]||(n[d]=[]),l===f?n[d].push(1):n[d].push(0)})})});let s=new e(n);return s.index=t.index,s}Zn.exports=yf});var as=c((Tb,us)=>{var $=h(),ts=m(),rs=p(),ns=b(),ss=me(),is=j(),os=v();function bf(e,t,r){let n=e.shape;ns(t)&&(t=is(0,n[0])),ns(r)&&(r=is(0,n[1])),rs(t)&&(t=[t]),rs(r)&&(r=[r]),$(ts(t)&&ts(r),"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),$(os(t).length===1&&os(r).length===1,"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),$(t.length>0,"The `rowIndices` array must contain at least one index."),$(r.length>0,"The `colIndices` array must contain at least one index."),t.forEach(o=>{$(ss(o),"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),$(o<e.index.length,`The row index ${o} is out of bounds.`)}),r.forEach(o=>{$(ss(o),"The `rowIndices` and `colIndices` parameters must be 1-dimensional arrays of whole numbers."),$(o<e.columns.length,`The column index ${o} is out of bounds.`)});let s=t.map(o=>e.index[o]),i=r.map(o=>e.columns[o]);return e.getSubsetByNames(s,i)}us.exports=bf});var ms=c((_b,hs)=>{var R=h(),St=S(),cs=m(),Ee=F(),ls=b(),fs=v();function Nf(e,t,r,n,s){ls(n)&&(n=r.index),ls(s)&&(s=r.columns),Ee(n)&&(n=[n]),Ee(s)&&(s=[s]),R(cs(n)&&cs(s),"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),R(fs(n).length===1&&fs(s).length===1,"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),R(n.length>0,"The `rows` array must contain at least one row name."),R(s.length>0,"The `cols` array must contain at least one column name."),n.forEach(u=>{R(Ee(u),"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),R(r.index.indexOf(u)>-1,`The row name "${u}" does not exist in the list of rows.`)}),s.forEach(u=>{R(Ee(u),"The `rows` and `cols` parameters must be 1-dimensional arrays of strings."),R(r.columns.indexOf(u)>-1,`The column name "${u}" does not exist in the list of columns.`)});let i=n.map(u=>s.map(a=>r.values[r.index.indexOf(u)][r.columns.indexOf(a)]));if(n.length===1&&s.length===1)return St(i)[0];if(n.length===1){let u=new t(St(i));return u.name=n[0],u.index=s,u}if(s.length===1){let u=new t(St(i));return u.name=s[0],u.index=n,u}let o=new e(i);return o.columns=s,o.index=n,o}hs.exports=Nf});var ps=c((Db,ds)=>{var vf=F(),pe=j();function wf(e,t,r){function n(y,T){return vf(y)&&y.length>T?y.substring(0,T-3)+"...":y}if(r.isEmpty)return console.table({}),console.log("Shape:",[0,0],`
|
|
15
|
+
`),r;let s=typeof window>"u"?20:10,i=parseInt(s/2),o=typeof process>"u"?10:Math.floor(process.stdout.columns/24)-1,u=parseInt(o/2),a=s>r.index.length?null:pe(0,i).concat(pe(r.index.length-i,r.index.length)),l=o>r.columns.length?null:pe(0,u).concat(pe(r.columns.length-u,r.columns.length)),f=r.get(a,l);f instanceof t&&(r.shape[0]===1?(f=new e([f.values]),f.index=r.index,f.columns=new t(r.columns).get(l).values):r.shape[1]===1&&(f=new e([f.values]).transpose(),f.index=new t(r.index).get(a).values,f.columns=r.columns)),s<=r.index.length&&(f._index.splice(i,0,"..."),f._values.splice(i,0,pe(0,f.columns.length).map(()=>"..."))),o<=r.columns.length&&(f._columns.splice(u,0,"..."),f._values=f._values.map(y=>(y.splice(u,0,"..."),y)));let d=28;return f instanceof t?(f.values=f.values.map(y=>n(y,d)),f.name=n(f.name,d),f.index=f.index.map(y=>n(y,d))):(f.values=f.values.map(y=>y.map(T=>n(T,d))),f.columns=f.columns.map(y=>n(y,d)),f.index=f.index.map(y=>n(y,d))),console.table(f.toDetailedObject()),console.log("Shape:",r.shape,`
|
|
16
|
+
`),r}ds.exports=wf});var Ie=c((Fb,gs)=>{var Sf=h(),Of=p();function xf(e,t){Sf(Of(e),"The `leftPad` function only works on numbers!");let r=e.toString();for(;r.length<t;)r="0"+r;return r}gs.exports=xf});var ys=c((Ab,qs)=>{var Tf=Ie(),_f=j();function Df(e,t){let r=t?e:e.copy();return r.index=_f(0,e.shape[0]).map(n=>"row"+Tf(n,(r.index.length-1).toString().length)),r}qs.exports=Df});var ge=c((jb,Ns)=>{var Ff=h(),Af=S(),jf=m(),Ef=q(),If=g();function bs(e){if(Ef(e)||If(e))return bs(e.values);Ff(jf(e),"The `product` function only works on arrays, Series, and DataFrames!");try{return e.length===0?NaN:Af(e).reduce((t,r)=>t*r,1)}catch{return NaN}}Ns.exports=bs});var Me=c((Eb,Os)=>{var qe=h(),vs=S(),ws=m(),Mf=q(),Ss=p(),Uf=g(),Bf=ge(),Cf=v();function Ot(e,t){if(Mf(e)||Uf(e))return Ot(e.values,t);if(qe(ws(e),"The first argument passed into the `reshape` function must be an array!"),Ss(t)&&(t=[t]),qe(ws(t),"The second argument passed into the `reshape` function must be a whole number or a one-dimensional array of whole numbers!"),qe(Cf(t).length===1,"The first argument passed into the `reshape` function must be a whole number or a one-dimensional array of whole numbers!"),t.forEach(i=>{qe(Ss(i)&&parseInt(i)===i&&i>0,"The first argument passed into the `reshape` function must be a whole number or a one-dimensional array of whole numbers!")}),t.length===0)return vs(e);let r=vs(e);if(t.length===1&&t[0]===r.length)return r;qe(Bf(t)===r.length,"The new shape doesn't match the number of values available in `x` (the first argument passed into the `reshape` function)!");let n=[],s=parseInt(r.length/t[0]);for(let i=0;i<t[0];i++){let o=r.slice(i*s,(i+1)*s);n.push(Ot(o,t.slice(1)))}return n}Os.exports=Ot});var ee=c((Ib,js)=>{var{copy:_s}=B(),Pf=h(),zf=m(),kf=p(),Ds=b(),Jf=k(),$f=ge(),Rf=Me(),Fs=Math.pow(2,64),w=[];As(parseInt(Math.random()*Fs));function Yf(e,t){e=x(e);function r(){e+=x("0x9e3779b97f4a7c15");let s=_s(e);return s=(s^s>>BigInt(30))*x("0xbf58476d1ce4e5b9"),s=(s^s>>BigInt(27))*x("0x94d049bb133111eb"),s^s>>BigInt(31)}let n=[];for(let s=0;s<t;s++)n.push(r());return n}function x(e){return BigInt.asUintN(64,BigInt(e))}function xs(e,t){return e=x(e),t=BigInt(t),x(x(e<<t)|x(e>>x(BigInt(64)-t)))}function As(e){if(Ds(e))return _s(w);{Pf(kf(e),"If passing a value into the `seed` function, then that value must be an integer!");let t=Yf(parseInt(e),4);w[0]=t[0],w[1]=t[1],w[2]=t[2],w[3]=t[3]}}function Ts(){let e=x(xs(w[0]+w[3],23)+w[0]),t=x(w[1]<<BigInt(17));return w[2]=x(w[2]^w[0]),w[3]=x(w[3]^w[1]),w[1]=x(w[1]^w[2]),w[0]=x(w[0]^w[3]),w[2]=x(w[2]^t),w[3]=xs(w[3],45),parseInt(e)/Fs}function Lf(e){return Ds(e)?Ts():(zf(e)||(e=[e]),Rf(Jf($f(e)).map(Ts),e))}js.exports={random:Lf,seed:As}});var Ue=c((Mb,Es)=>{var{random:Kf}=ee(),Vf=h(),Gf=m(),Wf=q(),Hf=g();function Xf(e){if(Wf(e)||Hf(e))return e.shuffle(...Object.values(arguments).slice(1));Vf(Gf(e),"The `shuffle` function only works on arrays, Series, and DataFrames!");let t=[],r=e.slice();for(let n=0;n<e.length;n++){let s=parseInt(Kf()*r.length);t.push(r.splice(s,1)[0])}return t}Es.exports=Xf});var Us=c((Ub,Ms)=>{var Qf=h(),Zf=b(),Is=Ue();function eh(e,t){return Zf(t)&&(t=0),Qf(t===0||t===1,"The `axis` parameter to the `shuffle` must be 0, 1, or undefined."),e.get(t===0?Is(e.index):null,t===1?Is(e.columns):null)}Ms.exports=eh});var Be=c((Bb,Bs)=>{function th(e){return typeof e=="boolean"}Bs.exports=th});var Js=c((Cb,ks)=>{var{random:rh}=ee(),A=h(),nh=S(),Cs=m(),xt=Be(),zs=D(),Ce=p(),te=F(),Tt=b(),sh=j(),Ps=v(),_t=J();function ih(e,t,r){return zs(t)?oh(e,t,r):uh(e,t,r)}function oh(e,t,r){if(r=Tt(r)?0:r,A(zs(t),"When sorting a DataFrame using a function, the first argument to the `sort` method must be a function!"),A(Ce(r),"When sorting a DataFrame using a function, the second argument to the `sort` method must be null, undefined, 0, or 1 to indicate the axis along which the data should be sorted! An axis of 0 means that the rows will be sorted relative to each other, whereas an axis of 1 means that the columns will be sorted relative to each other."),r===0){let n=_t(e.index,(s,i)=>t(e.get(s,null),e.get(i,null)));return e.get(n,null)}else{let n=_t(e.columns,(s,i)=>t(e.get(null,s),e.get(null,i)));return e.get(null,n)}}function uh(e,t,r){let n=e.copy(),s=rh().toString();return n=n.assign(s,n.index),Tt(t)&&(t=[s],r=[!0]),(Ce(t)||te(t))&&(t=[t],(xt(r)||te(r))&&(r=[r])),A(Cs(t),"The first parameter of the `sort` method must be (1) a string or index representing a column name or index, respectively; (2) a 1-dimensional array of strings and/or indices; or (3) null."),A(Ps(t).length===1,"The first parameter of the `sort` method must be (1) a string or index representing a column name or index, respectively; (2) a 1-dimensional array of strings and/or indices; or (3) null."),Tt(r)&&(r=sh(0,t.length).map(()=>!0)),A(Cs(r),"The second parameter of the `sort` method must be (1) a string or boolean representing the sort direction ('ascending' / 'descending', or true / false); (2) a 1-dimensional array of strings and/or booleans; or (3) null."),A(Ps(r).length===1,"The second parameter of the `sort` method must be (1) a string or boolean representing the sort direction ('ascending' / 'descending', or true / false); (2) a 1-dimensional array of strings and/or booleans; or (3) null."),A(t.length===r.length,"The arrays passed into the `sort` method must be equal in length."),t=t.map(i=>{if(A(te(i)||Ce(i),"Column references can either be column names (as strings) or column indices (as whole numbers)."),te(i)){let o=n.columns.indexOf(i);return A(o>-1,`The column "${i}" does not exist!`),o}if(Ce(i))return A(parseInt(i)===i,"Column indices must be whole numbers!"),A(i>=0,`The column index ${i} is out of bounds!`),A(i<n.columns.length,`The index ${i} is out of bounds!`),i}),r=r.map(i=>{if(A(te(i)||xt(i),"Direction references can either be strings ('ascending' or 'descending') or booleans (true or false)."),te(i)){let o=i.trim().toLowerCase();return A(o==="ascending"||o==="descending","Direction references can either be strings ('ascending' or 'descending') or booleans (true or false)."),o==="ascending"}if(xt(i))return i}),n.values=_t(n.values,(i,o)=>{let u=0;for(;i[t[u]]===o[t[u]]&&u<t.length;)u++;let a=r[u];if(i[t[u]]===o[t[u]])return 0;if(i[t[u]]<o[t[u]])return a?-1:1;if(i[t[u]]>o[t[u]])return a?1:-1}),n.index=nh(n.get(null,s).values),n=n.dropColumns(s),n}ks.exports=ih});var Rs=c((Pb,$s)=>{var ah=h(),ch=b();function lh(e,t){ch(t)?t=0:ah(t===0||t===1,"The axis parameter of the `toDetailedObject` method must be undefined, 0, or 1. An axis of 0 indicates that the returned object should be organized first by rows and then by columns. An axis of 1 indicates that the returned object should be organized first by columns and then by rows.");let r={};return t===0?e.index.forEach((n,s)=>{let i={};e.columns.forEach((o,u)=>{i[o]=e.values[s][u]}),r[n]=i}):e.columns.forEach((n,s)=>{let i={};e.index.forEach((o,u)=>{i[o]=e.values[u][s]}),r[n]=i}),r}$s.exports=lh});var Dt=c((zb,Ys)=>{function fh(e,t){return JSON.stringify(e.toObject(t))}Ys.exports=fh});var Ls=c((kb,At)=>{var Ft=X(),hh=Dt();function mh(e,t,r){let n=hh(e,r),s=!1,i=!1,o,u;try{let a=t;if(t.includes("/")){let f=t.split("/");a=f[f.length-1]}let l=document.createElement("a");l.href=`data:application/json;charset=utf-8,${encodeURIComponent(n)}`,l.download=a,l.dispatchEvent(new MouseEvent("click")),s=!0}catch(a){o=a}try{let a=qr("fs"),l=qr("path");a.writeFileSync(l.resolve(t),n,"utf8"),i=!0}catch(a){u=a}if(!s&&!i)throw typeof window<"u"?new Ft(o):typeof At<"u"?new Ft(u):new Ft("I don't know what's going wrong, but it doesn't seem like you're in Node or the browser, and we couldn't download and/or write the file to disk!");return e}At.exports=mh});var Vs=c((Jb,Ks)=>{function dh(e){let t={};return e.columns.forEach(r=>{t[r]=e.get(r).values}),t}Ks.exports=dh});var H=c(($b,Hs)=>{var Gs=h(),ph=m(),gh=q(),qh=g(),yh=k(),Ws=he(),bh=v();function Nh(e){if(gh(e)||qh(e))return e.transpose();Gs(ph(e),"The `transpose` function only works on arrays, Series, and DataFrames!");let t=bh(e);if(Gs(t.length<=2,"I'm not smart enough to know how to transpose arrays that have more than 2 dimensions. Sorry for the inconvenience! Please only pass 1- or 2-dimensional arrays into the `transpose` function!"),t.length===1)return Ws(e);if(t.length===2){let r=yh(Ws(t));for(let n=0;n<t[0];n++)for(let s=0;s<t[1];s++)r[s][n]=e[n][s];return r}}Hs.exports=Nh});var ei=c((Rb,Zs)=>{var Xs=h(),vh=m(),wh=q(),Sh=Te(),Oh=g(),xh=v();function Qs(e,t,r){if(Oh(r))return new e(t.values.concat(r.values));if(vh(r)){let n=xh(r);Xs(n.length===1&&!Sh(n),"Only vectors can be appended to Series!");let s=t.copy();return r.forEach((i,o)=>{s._values.push(i),s._index.push("item"+(t.values.length+o))}),s}return Xs(!wh(r),"DataFrames cannot be appended to Series!"),Qs(t,[r])}Zs.exports=Qs});var ri=c((Yb,ti)=>{var Th=h(),_h=D();function Dh(e,t){Th(_h(t),"The parameter to the `apply` method must be a function.");let r=e.copy();return r._values=r._values.map((n,s)=>t(n,s)),r}ti.exports=Dh});var si=c((Lb,ni)=>{var Fh=b();function Ah(e){let t=e.copy(),r=[];return t._values=t.values.filter((n,s)=>Fh(n)?!1:(r.push(t.index[s]),!0)),t._index=r,t}ni.exports=Ah});var oi=c((Kb,ii)=>{var jh=p();function Eh(e,t){let r=[],n=[];t.values.forEach((i,o)=>{jh(i)&&(n.push(i),r.push(t.index[o]))});let s=new e(n);return s.name=t.name,s.index=r,s}ii.exports=Eh});var ai=c((Vb,ui)=>{var{copy:Ih}=B();function Mh(e,t,r){let n=t.copy(),s=Ih(n.index),i=[],o=n.values.filter((u,a)=>{let l=r(u,a,n.values);return l||i.push(n.index[a]),l});return i.forEach(u=>{s.splice(s.indexOf(u),1)}),o.length===0?(n=new e,n.name=t.name,n):(n.values=o,n.index=s,n)}ui.exports=Mh});var li=c((Gb,ci)=>{var Y=h(),Uh=p(),Bh=F(),Ch=b(),Ph=E();function zh(e,t){(Bh(t)||Uh(t))&&(t=[t]);let r=Ph((t||[]).map(n=>typeof n));return Y(r.length<=2,"Only whole numbers and/or strings are allowed in `get` arrays!"),r.length===1&&Y(r[0]==="string"||r[0]==="number","Only whole numbers and/or strings are allowed in `get` arrays!"),r.length===2&&(Y(r.indexOf("string")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!"),Y(r.indexOf("number")>-1,"Only whole numbers and/or strings are allowed in `get` arrays!")),Ch(t)||(t=t.map(n=>{if(typeof n=="string")return Y(e.index.indexOf(n)>-1,`Index "${n}" does not exist!`),n;if(typeof n=="number")return Y(n>=0,`Index ${n} is out of bounds!`),Y(parseInt(n)===n,"Indices must be integers!"),Y(n<e.index.length,`Index ${n} is out of bounds!`),e.index[n]})),e.getSubsetByNames(t)}ci.exports=zh});var hi=c((Wb,fi)=>{var ye=h(),kh=m(),Jh=b(),$h=me(),Rh=j(),Yh=v();function Lh(e,t){let r=e.shape;Jh(t)&&(t=Rh(0,r[0])),ye(kh(t),"The `indices` array must be 1-dimensional array of whole numbers."),ye(Yh(t).length===1,"The `indices` array must be a 1-dimensional array of whole numbers."),ye(t.length>0,"The `indices` array must contain at least one index."),t.forEach(s=>{ye($h(s),"The `indices` array must be a 1-dimensional array of whole numbers."),ye(s<e.index.length,`The row index ${s} is out of bounds.`)});let n=t.map(s=>e.index[s]);return e.getSubsetByNames(n)}fi.exports=Lh});var di=c((Hb,mi)=>{var be=h(),Kh=m(),Vh=F(),Gh=b(),Wh=v();function Hh(e,t,r){Gh(r)&&(r=t.index),be(Kh(r),"The `indices` array must be a 1-dimensional array of strings."),be(Wh(r).length===1,"The `indices` array must be a 1-dimensional array of strings."),be(r.length>0,"The `indices` array must contain at least one index name."),r.forEach(i=>{be(Vh(i),"The `indices` array must contain only strings."),be(t.index.indexOf(i)>-1,`The name "${i}" does not exist in the index.`)});let n=r.map(i=>t.values[t.index.indexOf(i)]);if(n.length===1)return n[0];let s=new e(n);return s.index=r,s.name=t.name,s}mi.exports=Hh});var qi=c((Xb,gi)=>{var{copy:Xh}=B(),pi=j();function Qh(e){let t=e.copy(),r=typeof window>"u"?20:10;if(t.index.length>r){t=t.get(pi(0,r/2).concat(pi(t.index.length-r/2,t.index.length)));let s=Xh(t.index);s.splice(parseInt(s.length/2),0,"..."),t.values.push("..."),t.index.push("..."),t=t.get(s)}let n={};return t.values.forEach((s,i)=>{let o={};o[t.name]=s,n[t.index[i]]=o}),console.table(n),console.log("Shape:",e.shape,`
|
|
17
|
+
`),e}gi.exports=Qh});var bi=c((Qb,yi)=>{var Zh=Ue();function em(e){let t=e.copy();return t.get(Zh(t.index))}yi.exports=em});var vi=c((Zb,Ni)=>{var tm=h(),rm=D(),nm=b(),sm=J(),im=H();function om(e,t,r){r=r||((a,l)=>a<l?-1:1),tm(nm(r)||rm(r),"You must pass undefined, null, or a comparison function as the second argument to the `sort` method!");let n=im([t.values,t.index]),s=sm(n,(a,l)=>r(a[0],l[0])),i=[],o=[];s.forEach(a=>{i.push(a[0]),o.push(a[1])});let u=new e;return u._values=i,u._index=o,u.name=t.name,u}Ni.exports=om});var Oi=c((eN,Si)=>{var um=J(),wi=H();function am(e,t){let r=wi([t.values,t.index]);r=wi(um(r,(s,i)=>{if(s[1]===i[1])return 0;if(s[1]<i[1])return-1;if(s[1]>i[1])return 1}));let n=new e(r[0]);return n.index=r[1],n.name=t.name,n}Si.exports=am});var Ti=c((tN,xi)=>{function cm(e){let t={};return t[e.name]={},e.index.forEach((r,n)=>{t[e.name][r]=e.values[n]}),t}xi.exports=cm});var ji=c((rN,Ai)=>{var{copy:Pe}=B(),C=h(),jt=m(),lm=F(),fm=b(),_i=Ie(),Di=j(),ze=he(),hm=ei(),mm=ri(),dm=si(),pm=oi(),gm=ai(),qm=li(),ym=hi(),bm=di(),Nm=qi(),vm=bi(),wm=vi(),Sm=Oi(),Om=Ti(),Ne=v(),xm=H(),Fi=Symbol.for("@jrc03c/js-math-tools/series");Ai.exports=function(e){class t{static[Symbol.hasInstance](n){try{return!!n._symbol&&n._symbol===Fi}catch{return!1}}constructor(n){if(this.name="data",Object.defineProperty(this,"_symbol",{configurable:!1,enumerable:!1,writable:!1,value:Fi}),Object.defineProperty(this,"_values",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(this,"values",{configurable:!0,enumerable:!0,get(){return this._values},set(s){C(jt(s),"The new values must be a 1-dimensional array!");let i=Ne(s);C(i.length===1,"The new array of values must be 1-dimensional!"),i[0]<this._index.length?this._index=this._index.slice(0,i[0]):i[0]>this._index.length&&(this._index=this._index.concat(Di(this._index.length,i[0]).map(o=>"item"+_i(o,(s.length-1).toString().length)))),this._values=s}}),Object.defineProperty(this,"_index",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(this,"index",{configurable:!0,enumerable:!0,get(){return this._index},set(s){C(jt(s),"The new index must be a 1-dimensional array of strings!"),C(s.length===this.shape[0],"The new index must be the same length as the old index!"),C(Ne(s).length===1,"The new index must be a 1-dimensional array of strings!"),s.forEach(i=>{C(lm(i),"All of the row names must be strings!")}),this._index=s}}),n){if(n instanceof t)this.name=n.name,this.values=Pe(n.values),this.index=Pe(n.index);else if(jt(n)){let s=Ne(n);C(s.length===1,"When passing an array into the constructor of a Series, the array must be 1-dimensional!"),this.values=n}else if(n instanceof Object){let s=Object.keys(n).concat(Object.getOwnPropertySymbols(n)).map(u=>u.toString());C(s.length===1,"When passing an object into the constructor of a Series, the object must have only 1 key-value pair, where the key is the name of the data and the value is the 1-dimensional array of values!");let i=s[0],o=n[i];C(Ne(o).length===1,"When passing an object into the constructor of a Series, the object must have only 1 key-value pair, where the key is the name of the data and the value is the 1-dimensional array of values!"),this.name=i,this.values=o.slice()}}}get shape(){return Ne(this.values)}get length(){return this.shape[0]}get isEmpty(){return this.values.filter(n=>!fm(n)).length===0}clear(){let n=this.copy();return n.values.forEach((s,i)=>{n.values[i]=void 0}),n}get(n){return qm(this,n)}getSubsetByNames(n){return bm(t,this,n)}getSubsetByIndices(n){return ym(this,n)}loc(n){return this.getSubsetByNames(n)}iloc(n){return this.getSubsetByIndices(n)}reverse(){let n=new t(ze(this.values));return n.index=ze(this.index),n.name=this.name,n}resetIndex(){let n=this.copy();return n.index=Di(0,this.shape[0]).map(s=>"item"+_i(s,(n.index.length-1).toString().length)),n}copy(){let n=new t;return n._values=Pe(this.values),n._index=Pe(this.index),n.name=this.name,n}append(n){return hm(t,this,n)}apply(n){return mm(this,n)}concat(n){return this.append(n)}dropMissing(n,s){return dm(this,n,s)}dropNaN(){return pm(t,this)}toObject(){return Om(this)}print(){return Nm(this)}shuffle(){return vm(this)}sort(n){return wm(t,this,n)}sortByIndex(){return Sm(t,this)}filter(n){return gm(t,this,n)}toDataFrame(){let n=new e(xm([this.values]));return n.columns=[this.name],n.index=this.index,n}transpose(){let n=this.copy();return n.values=ze(n.values),n.index=ze(n.index),n}getDummies(){return this.toDataFrame().getDummies()}oneHotEncode(){return this.getDummies()}}return t}});var we=c((nN,Bi)=>{var{copy:Et}=B(),M=h(),Ei=le(),Tm=gn(),_m=vn(),Dm=xn(),Fm=_n(),Am=Mn(),jm=Cn(),Em=Jn(),Im=Ln(),Mm=Gn(),Ii=es(),Um=as(),Bm=ms(),Cm=ps(),Pm=ys(),zm=Us(),km=Js(),Jm=Rs(),$m=Ls(),Rm=Dt(),Ym=Vs(),Lm=S(),ve=m(),Km=z(),It=b(),Mt=Ie(),Vm=k(),Ut=j(),Gm=E(),re=v(),Mi=H(),Ui=Symbol.for("@jrc03c/js-math-tools/dataframe");function ke(e){let t="abcdefghijklmnopqrstuvwxyz1234567890",r="";for(let n=0;n<e;n++)r+=t[parseInt(Math.random()*t.length)];return r}var O=class{static[Symbol.hasInstance](t){try{return!!t._symbol&&t._symbol===Ui}catch{return!1}}constructor(t){if(Object.defineProperty(this,"_symbol",{configurable:!1,enumerable:!1,writable:!1,value:Ui}),Object.defineProperty(this,"_values",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(this,"values",{configurable:!0,enumerable:!0,get(){return this._values.length===0||!It(this._values[0])&&this._values[0].length===0?[[]]:this._values},set(r){M(ve(r),"The new values must be a 2-dimensional array!");let n=re(r);M(n.length===2,"The new array of values must be 2-dimensional!"),n[0]<this._index.length?this._index=this._index.slice(0,n[0]):n[0]>this._index.length&&(this._index=this._index.concat(Ut(this._index.length,n[0]).map(s=>"row"+Mt(s,(n[0]-1).toString().length)))),n[1]<this._columns.length?this._columns=this._columns.slice(0,n[1]):n[1]>this._columns.length&&(this._columns=this._columns.concat(Ut(this._columns.length,n[1]).map(s=>"col"+Mt(s,(n[1]-1).toString().length)))),this._values=r}}),Object.defineProperty(this,"_columns",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(this,"columns",{configurable:!0,enumerable:!0,get(){return this._columns},set(r){M(ve(r),"The new columns list must be a 1-dimensional array of strings!"),M(this.isEmpty||r.length===this.shape[1],"The new columns list must be the same length as the old columns list!"),M(re(r).length===1,"The new columns list must be a 1-dimensional array of strings!"),r=r.map(s=>(typeof s!="string"&&(s=JSON.stringify(s)||s.toString()),s.trim().length===0?"untitled_"+ke(8):s.trim()));let n=(()=>{let s=Ei(r),i={};return s.forEach(o=>{i[o.value]=o.count}),i})();r=r.map(s=>n[s]>1?s+"_"+ke(8):s),this._columns=r}}),Object.defineProperty(this,"_index",{value:[],configurable:!0,enumerable:!1,writable:!0}),Object.defineProperty(this,"index",{configurable:!0,enumerable:!0,get(){return this._index},set(r){M(ve(r),"The new index must be a 1-dimensional array of strings!"),M(this.isEmpty||r.length===this.shape[0],"The new index must be the same length as the old index!"),M(re(r).length===1,"The new index must be a 1-dimensional array of strings!"),r=r.map(s=>(typeof s!="string"&&(s=JSON.stringify(s)||s.toString()),s.trim().length===0?"untitled_"+ke(8):s.trim()));let n=(()=>{let s=Ei(r),i={};return s.forEach(o=>{i[o.value]=o.count}),i})();r=r.map(s=>n[s]>1?s+"_"+ke(8):s),this._index=r}}),M(It(t)||Km(t)||ve(t),"The `data` passed into the constructor of a DataFrame must be either (1) an object where the key-value pairs are (respectively) column names and 1-dimensional arrays of values, or (2) a 2-dimensional array of values."),t)if(t instanceof O)this.values=Et(t.values),this.columns=Et(t.columns),this.index=Et(t.index);else if(ve(t)){let r=re(t);M(r.length===2,"The `data` array passed into the constructor of a DataFrame must be 2-dimensional!"),M(Gm(t.map(n=>n.length)).length===1,"The 2-dimensional array passed into the constructor of a DataFrame must not contain sub-arrays (i.e., rows) of different lengths!"),this.values=t}else{this._columns=Object.keys(t).concat(Object.getOwnPropertySymbols(t)).map(o=>o.toString());let r=[],n=null,s=null;this._columns.forEach(o=>{It(s)&&(n=o,s=t[o].length),M(t[o].length===s,`The object passed into the DataFrame constructor contains arrays of different lengths! The key "${n}" points to an array containing ${s} items, and the key "${o}" points to an array containing ${t[o].length} items.`),s=t[o].length;let u=t[o];r.push(u)}),this._values=Mi(r);let i=re(this.values);this._index=Ut(0,i[0]).map(o=>"row"+Mt(o,(i[0]-1).toString().length))}}get shape(){return re(this.values)}get length(){return this.shape[0]}get width(){return this.shape[1]}get rows(){return this.index}set rows(t){this.index=t}get isEmpty(){return Lm(this.values).length===0}clear(){let t=new O(Vm(this.shape));return t.columns=this.columns.slice(),t.index=this.index.slice(),t}get(t,r){if(arguments.length===0)return this;if(arguments.length===1)try{return this.get(null,t)}catch{return this.get(t,null)}return Mm(this,t,r)}getSubsetByNames(t,r){return Bm(O,L,this,t,r)}getSubsetByIndices(t,r){return Um(this,t,r)}getDummies(t){return Ii(O,this,t)}oneHotEncode(t){return Ii(O,this,t)}transpose(){let t=new O(Mi(this.values));return t.columns=this.index.slice(),t.index=this.columns.slice(),t}get T(){return this.transpose()}resetIndex(t){return Pm(this,t)}copy(){return Fm(O,this)}assign(t,r){return Dm(O,L,this,t,r)}apply(t,r){return _m(O,L,this,t,r)}dropMissing(t,r,n){return jm(O,L,this,t,r,n)}dropNaN(t,r,n){return Em(O,this,t,r,n)}drop(t,r){return Am(O,L,this,t,r)}dropColumns(t){return this.drop(null,t)}dropRows(t){return this.drop(t,null)}toDetailedObject(t){return Jm(this,t)}toObject(){return Ym(this)}toJSONString(t){return Rm(this,t)}saveAsJSON(t,r){return $m(this,t,r)}print(){return Cm(O,L,this)}sort(t,r){return km(this,t,r)}sortByIndex(){return this.sort()}filter(t,r){return Im(O,L,this,t,r)}shuffle(t){return zm(this,t)}append(t,r){return Tm(this,t,r)}concat(t,r){return this.append(t,r)}join(t,r){return this.append(t,r)}toString(){return JSON.stringify(this)}},L=ji()(O);Bi.exports={DataFrame:O,Series:L}});var ne=c((sN,Pi)=>{var Wm=h(),Hm=S(),Xm=m(),Qm=q(),Zm=g();function Ci(e){if(Qm(e)||Zm(e))return Ci(e.values);Wm(Xm(e),"The `max` function only works on arrays, Series, and DataFrames!");try{e=Hm(e);let t=-1/0;for(let r of e)r>t&&(t=r);return t}catch{return NaN}}Pi.exports=Ci});var N=c((iN,Ri)=>{var{DataFrame:zi,Series:ki}=we(),Ji=h(),Se=m(),Bt=q(),$i=U(),ed=D(),Ct=g(),td=ne(),rd=j(),Je=v();function nd(e){return Se(e)||Ct(e)||Bt(e)}function sd(e){return Ji(ed(e),"You must pass a function into the `vectorize` function!"),function t(){let r,n,s=[],i=[],o=Object.keys(arguments).filter(u=>{let a=arguments[u];return Se(a)?!0:Ct(a)?(r=!0,s.push(a),!0):Bt(a)?(n=!0,i.push(a),!0):!1}).map(u=>arguments[u]);if(o.slice(0,-1).forEach((u,a)=>{Ji($i(Se(u)?Je(u):u.shape,Se(o[a+1])?Je(o[a+1]):o[a+1].shape),`When passing multiple arrays into the \`${e.name}\` function, all of the arrays must have the same shape!`)}),o.length>0){let u=td(o.map(l=>l.length?l.length:l.values.length)),a=rd(0,u).map(l=>{let f=Object.keys(arguments).map(d=>{if(nd(arguments[d])){if(Se(arguments[d]))return arguments[d][l];if(Ct(arguments[d]))return arguments[d].values[l];if(Bt(arguments[d]))return arguments[d].values[l]}else return arguments[d]});return t(...f)});if(n)try{if(i.length===1&&$i(Je(i[0]),Je(a))){let l=new zi(a);return l.index=i[0].index.slice(),l.columns=i[0].columns.slice(),l}else return new zi(a)}catch{return a}if(r)try{if(s.length===1&&s[0].length===a.length){let l=new ki(a);return l.name=s[0].name,l.index=s[0].index.slice(),l}else return new ki(a)}catch{return a}return a}else return e(...arguments)}}Ri.exports=sd});var $e=c((oN,Yi)=>{var id=p(),od=N();function ud(e){try{return id(e)?Math.abs(e):NaN}catch{return NaN}}Yi.exports=od(ud)});var Re=c((uN,Li)=>{var ad=p(),cd=N();function ld(){try{let e=0,t=Object.values(arguments);for(let r=0;r<t.length;r++){if(!ad(t[r]))return NaN;e+=t[r]}return e}catch{return NaN}}Li.exports=cd(ld)});var Oe=c((aN,Ki)=>{var fd=N();function hd(e,t){try{return t(e)}catch{return NaN}}Ki.exports=fd(hd)});var Gi=c((cN,Vi)=>{var md=p(),dd=N();function pd(e){try{return md(e)?Math.acos(e):NaN}catch{return NaN}}Vi.exports=dd(pd)});var Hi=c((lN,Wi)=>{var gd=p(),qd=N();function yd(e){try{return gd(e)?Math.asin(e):NaN}catch{return NaN}}Wi.exports=qd(yd)});var Qi=c((fN,Xi)=>{var bd=p(),Nd=N();function vd(e){try{return bd(e)?Math.atan(e):NaN}catch{return NaN}}Xi.exports=Nd(vd)});var eo=c((hN,Zi)=>{var wd=h(),Sd=oe(),Od=m(),xd=q(),Td=g(),_d=ne();function Pt(e){if(xd(e)){let t=Pt(e.values);return[e.index[t[0]],e.columns[t[1]]]}if(Td(e)){let t=Pt(e.values);return[e.index[t]]}wd(Od(e),"The `argmax` function only works on arrays, Series, and DataFrames!");try{let t=Sd(e,_d(e));return t?t.length===0?void 0:t.length===1?t[0]:t:void 0}catch{return}}Zi.exports=Pt});var Ye=c((mN,ro)=>{var Dd=h(),Fd=S(),Ad=m(),jd=q(),Ed=g();function to(e){if(jd(e)||Ed(e))return to(e.values);Dd(Ad(e),"The `min` function only works on arrays, Series, and DataFrames!");try{e=Fd(e);let t=1/0;for(let r of e)r<t&&(t=r);return t}catch{return NaN}}ro.exports=to});var so=c((dN,no)=>{var Id=h(),Md=oe(),Ud=m(),Bd=q(),Cd=g(),Pd=Ye();function zt(e){if(Bd(e)){let t=zt(e.values);return[e.index[t[0]],e.columns[t[1]]]}if(Cd(e)){let t=zt(e.values);return[e.index[t]]}Id(Ud(e),"The `argmin` function only works on arrays, Series, and DataFrames!");try{let t=Md(e,Pd(e));return t?t.length===0?void 0:t.length===1?t[0]:t:void 0}catch{return}}no.exports=zt});var Rt=c((pN,uo)=>{var io=m(),kt=Be(),zd=q(),Jt=ae(),kd=U(),oo=p(),Jd=z(),$d=g(),$t=b();function P(e,t){if(zd(e)||$d(e))return e.apply(r=>P(r,t));if(io(e))return e.map(r=>P(r,t));if(t==="null")return null;if(t==="number"){if($t(e))return NaN;let r=P(e,"boolean");if(kt(r))return r?1:0;try{JSON.parse(e)}catch{let i=P(e,"date");if(Jt(i))return i.getTime()}let n=parseFloat(e);return isNaN(n)?NaN:n}if(t==="boolean"){if(kt(e))return e;if(oo(e))return e===0?!1:e===1?!0:null;try{let r=(typeof e=="object"?e.toString()==="null"?"false":JSON.stringify(e):e.toString()).trim().toLowerCase();return r==="true"||r==="yes"||r==="y"?!0:r==="false"||r==="no"||r==="n"?!1:null}catch{return null}}if(t==="date"){if(Jt(e))return e;if($t(e))return null;let r=parseFloat(e);if(!isNaN(r)){let s=new Date(e);return Jt(s)?s:null}let n=Date.parse(e);return isNaN(n)?null:new Date(n)}if(t==="object"){if(Jd(e))return e;let r=P(e,"boolean");if(kt(r))return null;try{let s=P(e,"number");if(oo(s))return JSON.parse(e),null}catch{}let n=P(e,"date");if(n)return n;try{let s=JSON.parse(e);return io(s)?s.map(i=>P(i,t)):s}catch{return null}}if(t==="string")return $t(e)?kd(e,void 0)?"undefined":"null":e instanceof Date?e.toJSON():(()=>typeof e=="object"?e===null?"null":JSON.stringify(e):e.toString())()}uo.exports=P});var co=c((gN,ao)=>{var Rd=p(),Yd=N();function Ld(e){try{return Rd(e)?Math.ceil(e):NaN}catch{return NaN}}ao.exports=Yd(Ld)});var ho=c((qN,fo)=>{var Kd=$e(),lo=p(),Vd=b(),Gd=N();function Wd(e,t){try{if(!lo(e))return NaN;if(Vd(t))t=1e-10;else if(!lo(t))return NaN;return Kd(e)<t?0:e}catch{return NaN}}fo.exports=Gd(Wd)});var po=c((yN,mo)=>{var Yt=p(),Hd=N();function Xd(e,t,r){try{return Yt(e)?Yt(t)?Yt(r)?e<t?t:e>r?r:e:NaN:NaN:NaN}catch{return NaN}}mo.exports=Hd(Xd)});var qo=c((bN,go)=>{var Lt=h(),Qd=S(),Zd=m(),ep=q(),tp=p(),rp=g();function Kt(e,t){if(ep(e)||rp(e))return Kt(e.values,t);if(Lt(Zd(e),"The `combinations` function only works on arrays, Series, and DataFrames!"),Lt(tp(t),"`r` must be a whole number!"),e=Qd(e),t>e.length)return[e];if(t<=0)return[[]];if(Lt(t===parseInt(t),"`r` must be a whole number!"),e.length<2)return e;let r=[];return e.forEach((n,s)=>{let i=e.slice(s+1);if(i.length<t-1)return;Kt(i,t-1).forEach(u=>{r.push([n].concat(u))})}),r}go.exports=Kt});var Le=c((NN,bo)=>{var np=h(),sp=S(),ip=m(),op=q(),up=g();function yo(e){if(op(e)||up(e))return yo(e.values);np(ip(e),"The `mean` function only works on arrays, Series, and DataFrames!");try{let t=sp(e),r=0;return t.forEach(n=>{r+=n}),r/t.length}catch{return NaN}}bo.exports=yo});var Gt=c((vN,xo)=>{var No=h(),vo=m(),Ke=p(),wo=g(),So=Le(),Oo=v();function Vt(e,t){if(wo(e))return Vt(e.values,t);if(wo(t))return Vt(e,t.values);No(vo(e)&&vo(t)&&Oo(e).length===1&&Oo(t).length===1,"The `covariance` function only works on 1-dimensional arrays and Series!"),No(e.length===t.length,"The two arrays or Series passed into the `covariance` function must have the same length!");try{let r=So(e),n=So(t);if(!Ke(r)||!Ke(n))return NaN;let s=Math.max(e.length,t.length),i=0;for(let o=0;o<s;o++){if(!Ke(e[o]))return NaN;if(!Ke(t[o]))return NaN;i+=(e[o]-r)*(t[o]-n)}return i/e.length}catch{return NaN}}xo.exports=Vt});var Ve=c((wN,To)=>{var ap=p(),cp=N();function lp(e){try{return ap(e)?Math.sqrt(e):NaN}catch{return NaN}}To.exports=cp(lp)});var Wt=c((SN,Do)=>{var fp=h(),hp=S(),mp=m(),dp=q(),pp=p(),gp=g(),qp=Le();function _o(e){if(dp(e)||gp(e))return _o(e.values);fp(mp(e),"The `variance` function only works on arrays, Series, and DataFrames!");try{let t=hp(e),r=qp(t),n=0;for(let s=0;s<t.length;s++){if(!pp(t[s]))return NaN;n+=(t[s]-r)*(t[s]-r)}return n/t.length}catch{return NaN}}Do.exports=_o});var Ge=c((ON,Ao)=>{var yp=h(),bp=m(),Np=q(),vp=g(),wp=Ve(),Sp=Wt();function Fo(e){if(Np(e)||vp(e))return Fo(e.values);yp(bp(e),"The `std` function only works on arrays, Series, and DataFrames!");try{return wp(Sp(e))}catch{return NaN}}Ao.exports=Fo});var Co=c((xN,Bo)=>{var jo=h(),Op=Gt(),Eo=m(),Io=g(),Mo=v(),Uo=Ge();function Ht(e,t){if(Io(e))return Ht(e.values,t);if(Io(t))return Ht(e,t.values);jo(Eo(e)&&Eo(t)&&Mo(e).length===1&&Mo(t).length===1,"The `correl` function only works on 1-dimensional arrays and Series!"),jo(e.length===t.length,"The two arrays or Series passed into the `correl` function must have the same length!");try{return Op(e,t)/(Uo(e)*Uo(t))}catch{return NaN}}Bo.exports=Ht});var zo=c((TN,Po)=>{var xp=p(),Tp=N();function _p(e){try{return xp(e)?Math.cos(e):NaN}catch{return NaN}}Po.exports=Tp(_p)});var Jo=c((_N,ko)=>{ko.exports=Object.freeze({boolean:"boolean",date:"date",null:"null",number:"number",object:"object",string:"string"})});var Vo=c((DN,Ko)=>{var Dp=h(),$o=m(),Ro=q(),Fp=U(),Yo=g(),Lo=E();function Xt(e,t){if(Ro(e)||Yo(e))return Xt(e.values,t);if(Ro(t)||Yo(t))return Xt(e,t.values);Dp($o(e)&&$o(t),"The `diff` function only works on arrays, Series, and DataFrames!");let r=Lo(e),n=Lo(t),s=[];return r.forEach(i=>{n.findIndex(o=>Fp(o,i))<0&&s.push(i)}),s}Ko.exports=Xt});var We=c((FN,Wo)=>{var Go=p(),Ap=N();function jp(e,t){try{return Go(e)?Go(t)?Math.pow(e,t):NaN:NaN}catch{return NaN}}Wo.exports=Ap(jp)});var Qt=c((AN,Ho)=>{var Ep=p(),Ip=N();function Mp(){try{let e=Object.values(arguments);if(e.length===0)return NaN;let t=1;for(let r=0;r<e.length;r++){if(!Ep(e[r]))return NaN;t*=e[r]}return t}catch{return NaN}}Ho.exports=Ip(Mp)});var se=c((jN,Xo)=>{var Up=Qt();function Bp(){return Up(...arguments)}Xo.exports=Bp});var Zt=c((EN,Qo)=>{var Cp=Re(),Pp=se();function zp(e,t){return Cp(e,Pp(t,-1))}Qo.exports=zp});var He=c((IN,eu)=>{var kp=h(),Jp=S(),$p=m(),Rp=q(),Yp=g();function Zo(e){if(Rp(e)||Yp(e))return Zo(e.values);kp($p(e),"The `sum` function only works on arrays, Series, and DataFrames!");try{return e.length===0?NaN:Jp(e).reduce((t,r)=>t+r,0)}catch{return NaN}}eu.exports=Zo});var uu=c((MN,ou)=>{var Lp=$e(),Kp=h(),tu=m(),ru=q(),Vp=U(),nu=p(),su=g(),Gp=We(),iu=v(),Wp=Ve(),Hp=Zt(),Xp=He();function er(e,t){if(nu(e)&&nu(t))return Lp(e-t);if(ru(e)||su(e))return er(e.values,t);if(ru(t)||su(t))return er(e,t.values);tu(e)&&tu(t)&&Kp(Vp(iu(e),iu(t)),"If passing two arrays, Series, or DataFrames into the `distance` function, then those objects must have the same shape!");try{return Wp(Xp(Gp(Hp(e,t),2)))}catch{return NaN}}ou.exports=er});var cu=c((UN,au)=>{var Qp=We(),Zp=se();function eg(e,t){return Zp(e,Qp(t,-1))}au.exports=eg});var rr=c((BN,pu)=>{var{DataFrame:lu,Series:fu}=we(),Xe=h(),hu=S(),mu=m(),tr=q(),tg=p(),Qe=g(),rg=se(),Ze=v(),ng=He(),du=H();function K(e,t){if(tr(e)){let s=K(e.values,t);if(Ze(s).length===1){let i=new fu(s);return i.name=Qe(t)?t.name:i.name,i.index=e.index.slice(),i}else{let i=new lu(s);return i.index=e.index.slice(),tr(t)&&(i.columns=t.columns.slice()),i}}if(tr(t)){let s=K(e,t.values);if(Ze(s).length===1){let i=new fu(s);return i.name=Qe(e)?e.name:i.name,i.index=t.columns.slice(),i}else{let i=new lu(s);return i.columns=t.columns.slice(),i}}if(Qe(e))return K(e.values,t);if(Qe(t))return K(e,t.values);Xe(mu(e)&&mu(t),"The `dot` function only works on arrays, Series, and DataFrames!"),hu(e).concat(hu(t)).forEach(s=>{Xe(tg(s),"One of the arrays you passed into the `dot` function contains non-numerical values!")});let r=Ze(e),n=Ze(t);if(Xe(r.length<=2&&n.length<=2,"I'm not smart enough to know how to get the dot-product of arrays that have more than 2 dimensions. Sorry for the inconvenience! Please only pass 1- or 2-dimensional arrays into the `dot` function!"),Xe(r[r.length-1]===n[0],`There's a dimension misalignment in the two arrays you passed into the \`dot\` function. (${r[r.length-1]} !== ${n[0]})`),r.length===1&&n.length===1)return ng(rg(e,t));if(r.length===1&&n.length===2)return du(t).map(s=>K(e,s));if(r.length===2&&n.length===1)return e.map(s=>K(s,t));if(r.length===2&&n.length===2){let s=du(t),i=[];for(let o=0;o<e.length;o++){let u=[];for(let a=0;a<s.length;a++)u.push(K(e[o],s[a]));i.push(u)}return i}}pu.exports=K});var nr=c((CN,qu)=>{var sg=h(),ig=m(),og=q(),ug=g(),ag=b();function gu(e){if(og(e)||ug(e))return e.dropMissing(...Object.values(arguments).slice(1));sg(ig(e),"The `dropMissing` function only works on arrays, Series, and DataFrames!");let t=[];return e.forEach(r=>{try{return t.push(gu(r))}catch{ag(r)||t.push(r)}}),t}qu.exports=gu});var xu=c((PN,Ou)=>{var yu=h(),bu=m(),Nu=q(),cg=U(),vu=g(),wu=b(),Su=v();function et(e,t){if(Nu(e)||vu(e))return et(e.values,t);if(Nu(t)||vu(t))return et(e,t.values);yu(bu(e)&&bu(t),"The `dropMissingPairwise` function only works on arrays, Series, and DataFrames!"),yu(cg(Su(e),Su(t)),"The two arrays, Series, and/or DataFrames passed into the `dropMissingPairwise` function must have the same shape!");let r=[],n=[];for(let s=0;s<e.length;s++)try{let[i,o]=et(e[s],t[s]);r.push(i),n.push(o)}catch{!wu(e[s])&&!wu(t[s])&&(r.push(e[s]),n.push(t[s]))}return[r,n]}Ou.exports=et});var Iu=c((zN,Eu)=>{var Tu=h(),_u=m(),Du=q(),lg=U(),Fu=p(),Au=g(),ju=v();function tt(e,t){if(Du(e)||Au(e))return tt(e.values,t);if(Du(t)||Au(t))return tt(e,t.values);Tu(_u(e)&&_u(t),"The `dropNaNPairwise` only works on arrays, Series, and DataFrames!"),Tu(lg(ju(e),ju(t)),"The two arrays, Series, and/or DataFrames passed into the `dropNaNPairwise` must have the same shape!");let r=[],n=[];for(let s=0;s<e.length;s++)try{let[i,o]=tt(e[s],t[s]);r.push(i),n.push(o)}catch{Fu(e[s])&&Fu(t[s])&&(r.push(e[s]),n.push(t[s]))}return[r,n]}Eu.exports=tt});var Uu=c((kN,Mu)=>{var fg=nr();function hg(e){return fg(e)}Mu.exports=hg});var Cu=c((JN,Bu)=>{var mg=p(),dg=N();function pg(e){try{return mg(e)?Math.exp(e):NaN}catch{return NaN}}Bu.exports=dg(pg)});var ku=c(($N,zu)=>{var gg=N();function Pu(e){try{return e!==parseInt(e)?NaN:e<=1?1:e*Pu(e-1)}catch{return NaN}}zu.exports=gg(Pu)});var Yu=c((RN,Ru)=>{var qg=h(),yg=S(),Ju=m(),bg=q(),Ng=D(),$u=z(),vg=g();function sr(e,t){if(bg(e))return sr(yg(e.values),t);if(vg(e))return sr(e.values,t);if(qg($u(e)||Ju(e),"You must pass (1) an object, array, Series, or DataFrame and (2) a function or value into the `find` function!"),!Ng(t)){let s=t;t=i=>i===s}function r(s,i,o){if(o=o||[],o.indexOf(s)>-1)return null;if($u(s)){o.push(s);let u=Object.keys(s).concat(Object.getOwnPropertySymbols(s));for(let a=0;a<u.length;a++){let l=u[a],f=s[l];if(i(f))return f;let d=r(f,i,o);if(d)return d}}else if(Ju(s)){o.push(s);for(let u=0;u<s.length;u++){let a=s[u];if(i(a))return a;let l=r(a,i,o);if(l)return l}}else if(i(s))return s;return null}function n(s){try{return t(s)}catch{return!1}}return r(e,n)}Ru.exports=sr});var Gu=c((YN,Vu)=>{var wg=h(),Sg=S(),Lu=m(),Og=q(),xg=D(),Ku=z(),Tg=g();function ir(e,t){if(Og(e))return ir(Sg(e.values),t);if(Tg(e))return ir(e.values,t);if(wg(Ku(e)||Lu(e),"You must pass (1) an object, array, Series, or DataFrame and (2) a function or value into the `findAll` function!"),!xg(t)){let i=t;t=o=>o===i}function r(i,o,u){if(u=u||[],u.indexOf(i)>-1)return null;if(Ku(i)){u.push(i);let a=Object.keys(i).concat(Object.getOwnPropertySymbols(i)),l=[];for(let f=0;f<a.length;f++){let d=a[f],y=i[d],T=!1;o(y)&&(l.push(y),T=!0);let G=r(y,o,u);G&&G.length>0&&G.slice(T?1:0).forEach(_=>l.push(_))}return l}else if(Lu(i)){u.push(i);let a=[];for(let l=0;l<i.length;l++){let f=i[l],d=!1;o(f)&&(a.push(f),d=!0);let y=r(f,o,u);y&&y.length>0&&y.slice(d?1:0).forEach(T=>a.push(T))}return a}else if(o(i))return[i];return null}function n(i){try{return t(i)}catch{return!1}}let s=r(e,n);return s&&s.length>0?s:null}Vu.exports=ir});var Hu=c((LN,Wu)=>{var _g=p(),Dg=N();function Fg(e){try{if(e==="Infinity")return 1/0;if(e==="-Infinity")return-1/0;let t=JSON.parse(e);return _g(t)?t:NaN}catch{return NaN}}Wu.exports=Dg(Fg)});var Qu=c((KN,Xu)=>{var Ag=p(),jg=N();function Eg(e){try{return Ag(e)?Math.floor(e):NaN}catch{return NaN}}Xu.exports=jg(Eg)});var or=c((VN,Zu)=>{var Ig=p(),Mg=ge(),Ug=Me();function Bg(e){Ig(e)&&(e=[e]);let t=[],r=Mg(e);for(let n=0;n<r;n++)t.push(0);return Ug(t,e)}Zu.exports=Bg});var ta=c((GN,ea)=>{var rt=h(),Cg=p(),Pg=b(),zg=or();function kg(e){rt(!Pg(e),"You must pass an integer greater than 0 (representing the size) into the `identity` function!"),rt(Cg(e),"You must pass an integer greater than 0 (representing the size) into the `identity` function!"),rt(parseInt(e)===e,"You must pass an integer greater than 0 (representing the size) into the `identity` function!"),rt(e>0,"You must pass an integer greater than 0 (representing the size) into the `identity` function!");let t=zg([e,e]);for(let r=0;r<e;r++)t[r][r]=1;return t}ea.exports=kg});var na=c((WN,ra)=>{ra.exports=["true","false","yes","no"]});var ia=c((HN,sa)=>{sa.exports=["null","none","nan","na","n/a","","undefined"]});var la=c((XN,ca)=>{var Jg=Oe(),$g=h(),Rg=na(),Yg=Rt(),Lg=le(),ua=S(),ur=m(),Kg=q(),oa=ae(),aa=p(),Vg=g(),Gg=F(),Wg=ia();function nt(e){return e.type==="number"&&(typeof e.value<"u"?e.isInteger=parseInt(e.value)===e.value:e.isInteger=ua(e.values).every(t=>aa(t)?parseInt(t)===t:!0)),e}function st(e){if(Kg(e)){let s=e.copy(),i=st(e.values);return s.values=i.values,nt({type:i.type,values:s})}if(Vg(e)){let s=e.copy(),i=st(e.values);return s.values=i.values,nt({type:i.type,values:s})}if(!ur(e)){let s=st([e]);return s.value=s.values[0],delete s.values,nt(s)}$g(ur(e),"The `inferType` function only works on arrays, Series, and DataFrames!");let t=ua(e).map(s=>{if(s===void 0)return"null";try{if(typeof s=="object"){let u=new Date(s.getTime());if(oa(u))return"date"}}catch{}Gg(s)||(s=JSON.stringify(s));let o=s.toLowerCase().trim();if(Wg.indexOf(o)>-1)return"null";if(Rg.indexOf(o)>-1)return"boolean";try{let u=JSON.parse(s);return aa(u)?"number":typeof u=="object"?ur(u)?"string":"object":"string"}catch{let a=new Date(s);return oa(a)?"date":"string"}}),n=Lg(t).sort((s,i)=>i.count-s.count)[0].value;return nt({type:n,values:Jg(e,s=>Yg(s,n))})}ca.exports=st});var ha=c((QN,fa)=>{var Hg=p(),Xg=N();function Qg(e){try{let t=JSON.parse(e);return Hg(t)?parseInt(t):NaN}catch{return NaN}}fa.exports=Xg(Qg)});var da=c((ZN,ma)=>{var Zg=h(),eq=m(),tq=q(),rq=U(),nq=g(),ar=E();function sq(){let e=Object.values(arguments).map(r=>tq(r)||nq(r)?ar(r.values):(Zg(eq(r),"The `intersect` function only works on arrays, Series, and DataFrames!"),ar(r)));return ar(e).filter(r=>e.every(n=>n.findIndex(s=>rq(s,r))>-1))}ma.exports=sq});var ya=c((e0,qa)=>{var pa=Re(),V=h(),iq=rr(),oq=S(),uq=m(),aq=q(),cr=p(),ga=se(),cq=v();function it(e){if(aq(e)){let r=e.copy();return r.values=it(r.values),r}V(uq(e),"The `inverse` function only works on square 2-dimensional arrays or DataFrames!"),oq(e).forEach(r=>V(cr(r),"The array passed into the `inverse` function must contain only numbers!"));let t=cq(e);if(V(t.length===2,"The array passed into the `inverse` function must be exactly two-dimensional and square!"),V(t[0]===t[1],"The array passed into the `inverse` function must be exactly two-dimensional and square!"),V(t[0]>=0,"The array passed into the `inverse` function must be exactly two-dimensional and square!"),t[0]===0)return e;if(t[0]===1)return V(e[0][0]!==0,"This matrix cannot be inverted!"),1/e[0][0];if(t[0]===2){let r=e[0][0],n=e[0][1],s=e[1][0],i=e[1][1],o=r*i-n*s;V(o!==0,"This matrix cannot be inverted!");let u=[[i,-n],[-s,r]];return ga(u,1/o)}else if(t[0]>1){let r=(n,s)=>cr(n)||cr(s)?ga(n,s):iq(n,s);for(let n=1;n<t[0]-1;n++)try{let s=e.slice(0,n).map(_=>_.slice(0,n)),i=e.slice(0,n).map(_=>_.slice(n,t[0])),o=e.slice(n,t[0]).map(_=>_.slice(0,n)),u=e.slice(n,t[0]).map(_=>_.slice(n,t[0])),a=it(s),l=it(pa(u,r(-1,r(r(o,a),i)))),f=pa(a,r(r(r(r(a,i),l),o),a)),d=r(-1,r(r(a,i),l)),y=r(-1,r(r(l,o),a)),T=l;return f.map((_,at)=>_.concat(d[at])).concat(y.map((_,at)=>_.concat(T[at])))}catch{}V(!1,"This matrix cannot be inverted!")}}qa.exports=it});var Na=c((t0,ba)=>{var lq=new Function(`
|
|
18
18
|
try {
|
|
19
19
|
return this === window
|
|
20
20
|
} catch(e) {}
|
|
@@ -24,4 +24,4 @@
|
|
|
24
24
|
} catch(e){}
|
|
25
25
|
|
|
26
26
|
return false
|
|
27
|
-
`);
|
|
27
|
+
`);ba.exports=lq});var wa=c((r0,va)=>{var lr=p(),fq=N();function hq(e,t,r){try{return lr(e)?lr(t)?lr(r)?r*(t-e)+e:NaN:NaN:NaN}catch{return NaN}}va.exports=fq(hq)});var xa=c((n0,Oa)=>{var Sa=p(),mq=b(),dq=N();function pq(e,t){try{return t=mq(t)?Math.E:t,Sa(e)?Sa(t)?Math.log(e)/Math.log(t):NaN:NaN}catch{return NaN}}Oa.exports=dq(pq)});var Da=c((s0,_a)=>{var gq=h(),qq=S(),yq=m(),bq=q(),Nq=g(),vq=J();function Ta(e){if(bq(e)||Nq(e))return Ta(e.values);gq(yq(e),"The `median` function only works on arrays, Series, and DataFrames!");try{let t=vq(qq(e));return t.length===0?NaN:t.length%2===0?(t[t.length/2-1]+t[t.length/2])/2:t[parseInt(t.length/2)]}catch{return NaN}}_a.exports=Ta});var ja=c((i0,Aa)=>{var Fa=p(),wq=N();function Sq(e,t){try{return Fa(e)?Fa(t)?e%t:NaN:NaN}catch{return NaN}}Aa.exports=wq(Sq)});var Ua=c((o0,Ma)=>{var Oq=h(),xq=le(),Tq=S(),_q=m(),Dq=q(),Fq=g(),Aq=E(),Ea=J();function Ia(e){if(Dq(e)||Fq(e))return Ia(e.values);Oq(_q(e),"The `mode` function only works on arrays, Series, and DataFrames!");try{if(e.length===0)return NaN;let t=Tq(e);if(t.length===0)return NaN;let r={},n=Aq(t);n.forEach(u=>{r[u]=xq(t,u)});let s=Ea(n,(u,a)=>r[a]-r[u]),i=s[0];return Ea(s.filter(u=>r[u]===r[i]))}catch{return NaN}}Ma.exports=Ia});var za=c((u0,Pa)=>{var{random:Ba}=ee(),jq=Oe(),Eq=b(),Iq=k();function Ca(){let e=Ba(),t=Ba();return Math.sqrt(-2*Math.log(e))*Math.cos(2*Math.PI*t)}function Mq(e){return Eq(e)?Ca():jq(Iq(e),Ca)}Pa.exports=Mq});var Ja=c((a0,ka)=>{var Uq=Oe(),Bq=k();function Cq(e){return Uq(Bq(e),()=>1)}ka.exports=Cq});var Ra=c((c0,$a)=>{var fr=h(),Pq=S(),zq=m(),kq=q(),Jq=p(),$q=g(),Rq=b();function ot(e,t){if(kq(e)||$q(e))return ot(e.values,t);if(fr(zq(e),"The `permutations` function only works on arrays, Series, and DataFrames!"),Rq(t)&&(t=e.length),fr(Jq(t),"`r` must be a whole number!"),e=Pq(e),t>e.length)return ot(e);if(t<=0)return[[]];if(fr(t===parseInt(t),"`r` must be a whole number!"),e.length<2)return e;let r=[];return e.forEach((n,s)=>{let i=e.slice(0,s),o=e.slice(s+1),u=i.concat(o);ot(u,t-1).forEach(l=>{r.push([n].concat(l))})}),r}$a.exports=ot});var La=c((l0,Ya)=>{var{DataFrame:Yq,Series:Lq}=we(),Kq=m(),Vq=q(),Gq=fe(),Wq=g(),Hq=v();function Xq(){Object.keys(arguments).forEach(e=>{let t=arguments[e];if(Kq(t))if(Gq(t))console.log(t);else{let r=Hq(t);r.length===1?new Lq(t).print():r.length==2?new Yq(t).print():console.log(t)}else Vq(t)||Wq(t)?t.print():console.log(t)})}Ya.exports=Xq});var Ga=c((f0,Va)=>{var Qq=m(),Zq=p(),Ka=b(),ey=ne(),ty=Ye(),ry=N(),ny=ry(function(e,t,r,n,s){try{return[e,t,r,n,s].every(i=>Zq(i))?r-t===0?NaN:(s-n)*(e-t)/(r-t)+n:NaN}catch{return NaN}});function sy(e,t,r,n,s){return Qq(e)&&Ka(n)&&Ka(s)&&(n=t,s=r,t=ty(e),r=ey(e)),ny(e,t,r,n,s)}Va.exports=sy});var Ha=c((h0,Wa)=>{var iy=p(),oy=N();function uy(e){try{return iy(e)?Math.round(e):NaN}catch{return NaN}}Wa.exports=oy(uy)});var Qa=c((m0,Xa)=>{var ay=p(),cy=N();function ly(e){try{return ay(e)?e<0?-1:e>0?1:0:NaN}catch{return NaN}}Xa.exports=cy(ly)});var ec=c((d0,Za)=>{var fy=p(),hy=N();function my(e){try{return fy(e)?Math.sin(e):NaN}catch{return NaN}}Za.exports=hy(my)});var rc=c((p0,tc)=>{var dy=Ge();function py(e){return dy(e)}tc.exports=py});var sc=c((g0,nc)=>{var gy=p(),qy=N();function yy(e){try{return gy(e)?Math.tan(e):NaN}catch{return NaN}}nc.exports=qy(yy)});var ut=c((q0,uc)=>{var ic=h(),oc=D();function by(e,t){ic(oc(e),"`fn` must be a function!");let r=new Date;return t?e(...t):e(),new Date-r}async function Ny(e,t){ic(oc(e),"`fn` must be a function!");let r=new Date;return t?await e(...t):await e(),new Date-r}uc.exports={timeSync:by,timeAsync:Ny}});var cc=c((y0,ac)=>{var vy=m(),wy=q(),Sy=g(),Oy=E();function xy(){return Oy([...arguments].map(e=>vy(e)?e:wy(e)||Sy(e)?e.values:[e]))}ac.exports=xy});var fc=c((b0,lc)=>{var Ty=h(),_y=m(),Dy=q(),Fy=g(),Ay=b(),jy=ne(),Ey=j();function Iy(){let e=[],t=Object.values(arguments).map(r=>((Dy(r)||Fy(r))&&(r=r.values),Ty(_y(r),"The `zip` function only works on arrays, Series, and DataFrames!"),r));return Ey(0,jy(t.map(r=>r.length))).forEach(r=>{let n=[];t.forEach(s=>{let i=s[r];n.push(Ay(i)?void 0:i)}),e.push(n)}),e}lc.exports=Iy});var hc=c((N0,hr)=>{var{copy:My,decycle:Uy}=B(),{DataFrame:By,Series:Cy}=we(),ie={abs:$e(),add:Re(),apply:Oe(),arccos:Gi(),arcsin:Hi(),arctan:Qi(),argmax:eo(),argmin:so(),assert:h(),cast:Rt(),ceil:co(),chop:ho(),clamp:po(),combinations:qo(),copy:My,correl:Co(),cos:zo(),count:le(),covariance:Gt(),DataFrame:By,dataTypes:Jo(),decycle:Uy,diff:Vo(),distance:uu(),divide:cu(),dot:rr(),dropMissing:nr(),dropMissingPairwise:xu(),dropNaN:vt(),dropNaNPairwise:Iu(),dropUndefined:Uu(),exp:Cu(),factorial:ku(),find:Yu(),findAll:Gu(),flatten:S(),float:Hu(),floor:Qu(),identity:ta(),indexOf:oe(),inferType:la(),int:ha(),intersect:da(),inverse:ya(),isArray:m(),isBoolean:Be(),isBrowser:Na(),isDataFrame:q(),isDate:ae(),isEqual:U(),isFunction:D(),isJagged:fe(),isNested:Te(),isNumber:p(),isObject:z(),isSeries:g(),isString:F(),isUndefined:b(),lerp:wa(),log:xa(),MathError:X(),max:ne(),mean:Le(),median:Da(),min:Ye(),mod:ja(),mode:Ua(),multiply:Qt(),ndarray:k(),normal:za(),ones:Ja(),permutations:Ra(),pow:We(),print:La(),product:ge(),random:ee().random,range:j(),remap:Ga(),reshape:Me(),reverse:he(),round:Ha(),scale:se(),seed:ee().seed,Series:Cy,set:E(),shape:v(),shuffle:Ue(),sign:Qa(),sin:ec(),sort:J(),sqrt:Ve(),std:Ge(),stdev:rc(),subtract:Zt(),sum:He(),tan:sc(),time:ut().timeSync,timeSync:ut().timeSync,timeAsync:ut().timeAsync,transpose:H(),union:cc(),variance:Wt(),vectorize:N(),zeros:or(),zip:fc(),dump:function(){let e=typeof globalThis<"u"?globalThis:typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:void 0;if(!e)throw new ie.MathError("Cannot dump functions into global scope because none of `globalThis`, `global`, `window`, or `self` exist in the current context!");Object.keys(ie).forEach(t=>{try{Object.defineProperty(e,t,{configurable:!1,enumerable:!0,writable:!1,value:ie[t]})}catch{e[t]=ie[t]}})}};typeof hr<"u"&&(hr.exports=ie);typeof window<"u"&&(window.JSMathTools=ie)});var Jy=c((v0,gr)=>{var{assert:mr,int:dr,isNumber:pr,isString:Py,random:zy,seed:ky}=hc();function mc(e,t,r){arguments.length===2&&(pr(arguments[1])?r=null:(r=t,t=null)),mr(pr(e)&&dr(e)===e,"`keyLength` must be an integer!"),t&&(mr(pr(t)&&dr(t)===t,"`keySeed` must be an integer!"),ky(t)),r&&mr(Py(r),"`charset` must be a string!");let n="";r=r||"abcdefg1234567890";for(let s=0;s<e;s++)n+=r[dr(zy()*r.length)];return n}typeof gr<"u"&&(gr.exports=mc);typeof window<"u"&&(window.makeKey=mc)});Jy();})();
|
package/moon.yml
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
dependsOn:
|
|
2
|
+
- js-math-tools
|
|
3
|
+
language: javascript
|
|
4
|
+
tasks:
|
|
5
|
+
build:
|
|
6
|
+
command:
|
|
7
|
+
- esbuild
|
|
8
|
+
- src/index.js
|
|
9
|
+
- --bundle
|
|
10
|
+
- --outfile=dist/make-key.js
|
|
11
|
+
- --minify
|
|
12
|
+
inputs:
|
|
13
|
+
- "package.json"
|
|
14
|
+
- "src/**/*"
|
|
15
|
+
outputs:
|
|
16
|
+
- "dist/make-key.js"
|
|
17
|
+
platform: node
|
|
18
|
+
pub:
|
|
19
|
+
command:
|
|
20
|
+
- npm
|
|
21
|
+
- publish
|
|
22
|
+
- --access=public
|
|
23
|
+
deps:
|
|
24
|
+
- ~:pub-dep1
|
|
25
|
+
local: true
|
|
26
|
+
platform: node
|
|
27
|
+
pub-dep1:
|
|
28
|
+
command:
|
|
29
|
+
- npm
|
|
30
|
+
- version
|
|
31
|
+
- patch
|
|
32
|
+
- --force
|
|
33
|
+
local: true
|
|
34
|
+
platform: node
|
|
35
|
+
test:
|
|
36
|
+
command: jest
|
|
37
|
+
platform: node
|
|
38
|
+
watch:
|
|
39
|
+
command:
|
|
40
|
+
- esbuild
|
|
41
|
+
- src/index.js
|
|
42
|
+
- --bundle
|
|
43
|
+
- --outfile=dist/make-key.js
|
|
44
|
+
- --minify
|
|
45
|
+
- --watch
|
|
46
|
+
inputs:
|
|
47
|
+
- "package.json"
|
|
48
|
+
- "src/**/*"
|
|
49
|
+
local: true
|
|
50
|
+
outputs:
|
|
51
|
+
- "dist/make-key.js"
|
|
52
|
+
platform: node
|
package/package.json
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jrc03c/make-key",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.16",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "src/index.js",
|
|
6
|
-
"
|
|
7
|
-
"
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"pub": "npm version patch --force && npm publish --access=public"
|
|
6
|
+
"devDependencies": {
|
|
7
|
+
"esbuild": "^0.17.11",
|
|
8
|
+
"eslint": "^8.36.0",
|
|
9
|
+
"jest": "^29.5.0"
|
|
11
10
|
},
|
|
12
11
|
"keywords": [],
|
|
13
12
|
"author": "",
|
|
@@ -17,11 +16,6 @@
|
|
|
17
16
|
"key": "./bin.js"
|
|
18
17
|
},
|
|
19
18
|
"dependencies": {
|
|
20
|
-
"@jrc03c/js-math-tools": "^0.0.
|
|
21
|
-
},
|
|
22
|
-
"devDependencies": {
|
|
23
|
-
"esbuild": "^0.17.11",
|
|
24
|
-
"eslint": "^8.36.0",
|
|
25
|
-
"jest": "^29.5.0"
|
|
19
|
+
"@jrc03c/js-math-tools": "^0.0.63"
|
|
26
20
|
}
|
|
27
21
|
}
|