qesuite 1.0.0

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/README.md ADDED
Binary file
@@ -0,0 +1,8 @@
1
+ /**
2
+ // * Calculates the mean of the array supplied.
3
+ // * @customfunction
4
+ // * @param data An array of numbers. The numbers can be supplied as number types or strings
5
+ // */
6
+ declare function Mean(data: any[]): number;
7
+
8
+ export { Mean };
@@ -0,0 +1,8 @@
1
+ /**
2
+ // * Calculates the mean of the array supplied.
3
+ // * @customfunction
4
+ // * @param data An array of numbers. The numbers can be supplied as number types or strings
5
+ // */
6
+ declare function Mean(data: any[]): number;
7
+
8
+ export { Mean };
package/dist/index.js ADDED
@@ -0,0 +1,36 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: true });
8
+ };
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") {
11
+ for (let key of __getOwnPropNames(from))
12
+ if (!__hasOwnProp.call(to, key) && key !== except)
13
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
+ }
15
+ return to;
16
+ };
17
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
+
19
+ // index.ts
20
+ var QESuite_exports = {};
21
+ __export(QESuite_exports, {
22
+ Mean: () => Mean
23
+ });
24
+ module.exports = __toCommonJS(QESuite_exports);
25
+ function Mean(data) {
26
+ let n = data.length;
27
+ let sum = 0;
28
+ data.forEach((num) => {
29
+ sum += Number(num);
30
+ });
31
+ return sum / n;
32
+ }
33
+ // Annotate the CommonJS export names for ESM import in node:
34
+ 0 && (module.exports = {
35
+ Mean
36
+ });
package/dist/index.mjs ADDED
@@ -0,0 +1,12 @@
1
+ // index.ts
2
+ function Mean(data) {
3
+ let n = data.length;
4
+ let sum = 0;
5
+ data.forEach((num) => {
6
+ sum += Number(num);
7
+ });
8
+ return sum / n;
9
+ }
10
+ export {
11
+ Mean
12
+ };
package/index.ts ADDED
@@ -0,0 +1,13 @@
1
+ /**
2
+ // * Calculates the mean of the array supplied.
3
+ // * @customfunction
4
+ // * @param data An array of numbers. The numbers can be supplied as number types or strings
5
+ // */
6
+ export function Mean(data: any[]) {
7
+ let n = data.length;
8
+ let sum = 0;
9
+ data.forEach(num => {
10
+ sum += Number(num);
11
+ })
12
+ return sum / n;
13
+ }
package/package.json ADDED
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "qesuite",
3
+ "version": "1.0.0",
4
+ "description": "Performs advanced statistical analysis of data. Specifically designed for engineering statistical analysis",
5
+ "main": "dist/index.js",
6
+ "module": "dist/index.mjs",
7
+ "types": "dist/index.d.ts",
8
+ "scripts": {
9
+ "build": "tsup index.ts --format cjs,esm --dts",
10
+ "test": "echo \"Error: no test specified\" && exit 1"
11
+ },
12
+ "repository": {
13
+ "type": "git",
14
+ "url": "git+https://github.com/Lucius-LaFromboise-Enterprises-LLC/qesuite.git"
15
+ },
16
+ "keywords": [
17
+ "QESuite"
18
+ ],
19
+ "author": "EngSuite.org",
20
+ "license": "MIT",
21
+ "bugs": {
22
+ "url": "https://github.com/Lucius-LaFromboise-Enterprises-LLC/qesuite/issues"
23
+ },
24
+ "homepage": "https://github.com/Lucius-LaFromboise-Enterprises-LLC/qesuite#readme",
25
+ "dependencies": {
26
+ "tsup": "^7.1.0",
27
+ "typescript": "^5.1.6"
28
+ }
29
+ }