Skip to content

Commit 90f0ddf

Browse files
committed
fix: add missing decimals
--- 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: na - 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: passed - 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 6e8daa6 commit 90f0ddf

File tree

1 file changed

+4
-4
lines changed
  • lib/node_modules/@stdlib/stats/base/dists/signrank/pdf/src

1 file changed

+4
-4
lines changed

lib/node_modules/@stdlib/stats/base/dists/signrank/pdf/src/main.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,16 @@ static double weights( double x, const int32_t n ) {
3535
double mlim;
3636

3737
if ( n == 0 ) {
38-
return ( x == 0 ) ? 1 : 0;
38+
return ( x == 0 ) ? 1.0 : 0.0;
3939
}
4040
mlim = ( (double)n * ( (double)n + 1.0 ) ) / 2.0;
4141
if ( x < 0 || x > mlim ) {
42-
return 0;
42+
return 0.0;
4343
}
44-
if ( x > mlim / 2 ) {
44+
if ( x > mlim / 2.0 ) {
4545
x = mlim - x;
4646
}
47-
return weights( x - (double)n, n - 1 ) + weights( x, n - 1 );
47+
return weights( x-(double)n, n-1 ) + weights( x, n-1 );
4848
}
4949

5050
/**

0 commit comments

Comments
 (0)