Skip to content

Commit 320bc09

Browse files
committed
feat: add header file with results struct
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: passed - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent 571f10d commit 320bc09

File tree

3 files changed

+91
-0
lines changed

3 files changed

+91
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
/**
2+
* @license Apache-2.0
3+
*
4+
* Copyright (c) 2025 The Stdlib Authors.
5+
*
6+
* Licensed under the Apache License, Version 2.0 (the "License");
7+
* you may not use this file except in compliance with the License.
8+
* You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing, software
13+
* distributed under the License is distributed on an "AS IS" BASIS,
14+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
* See the License for the specific language governing permissions and
16+
* limitations under the License.
17+
*/
18+
19+
#ifndef STDLIB_STATS_BASE_ZTEST_ONE_SAMPLE_RESULTS_FLOAT32_H
20+
#define STDLIB_STATS_BASE_ZTEST_ONE_SAMPLE_RESULTS_FLOAT32_H
21+
22+
#include <stdbool.h>
23+
#include <stdint.h>
24+
25+
/**
26+
* Struct for storing test results.
27+
*/
28+
struct stdlib_stats_ztest_one_sample_float32_results {
29+
// Boolean indicating whether the null hypothesis was rejected:
30+
bool rejected;
31+
32+
// Alternative hypothesis:
33+
int8_t alternative;
34+
35+
// Significance level:
36+
float alpha;
37+
38+
// p-value:
39+
float pValue;
40+
41+
// Test statistic:
42+
float statistic;
43+
44+
// Confidence interval:
45+
float ci[ 2 ];
46+
47+
// Mean value under the null hypothesis:
48+
float nullValue;
49+
50+
// Standard error of the mean:
51+
float sd;
52+
};
53+
54+
#endif // !STDLIB_STATS_BASE_ZTEST_ONE_SAMPLE_RESULTS_FLOAT32_H
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"options": {},
3+
"fields": [
4+
{
5+
"field": "src",
6+
"resolve": true,
7+
"relative": true
8+
},
9+
{
10+
"field": "include",
11+
"resolve": true,
12+
"relative": true
13+
},
14+
{
15+
"field": "libraries",
16+
"resolve": false,
17+
"relative": false
18+
},
19+
{
20+
"field": "libpath",
21+
"resolve": true,
22+
"relative": false
23+
}
24+
],
25+
"confs": [
26+
{
27+
"src": [],
28+
"include": [
29+
"./include"
30+
],
31+
"libraries": [],
32+
"libpath": [],
33+
"dependencies": []
34+
}
35+
]
36+
}

lib/node_modules/@stdlib/stats/base/ztest/one-sample/results/float32/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"benchmark": "./benchmark",
1919
"doc": "./docs",
2020
"example": "./examples",
21+
"include": "./include",
2122
"lib": "./lib",
2223
"test": "./test"
2324
},

0 commit comments

Comments
 (0)