Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export function CHISQDISTRT(x, k) {
if (!x || !k) {
return errorObj.ERROR_NA;
}
if (x < 1 || k > Math.pow(10, 10)) {
return errorObj.ERROR_NUM;
}
if ((typeof x !== 'number') || (typeof k !== 'number')) {
return errorObj.ERROR_VALUE;
}
return 1 - jStat.chisquare.cdf(x, k);
};
export function CHISQ__INV(probability, k) {
probability = parseNumber(probability);
k = parseNumber(k);
return jStat.chisquare.inv(probability, k);
};