Skip to content

Commit

Permalink
chore: minor clean-up
Browse files Browse the repository at this point in the history
---
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: passed
  - task: lint_package_json
    status: na
  - task: lint_repl_help
    status: na
  - task: lint_javascript_src
    status: passed
  - task: lint_javascript_cli
    status: na
  - task: lint_javascript_examples
    status: na
  - task: lint_javascript_tests
    status: passed
  - 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: passed
  - 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
---
  • Loading branch information
Planeshifter committed Jan 20, 2025
1 parent 33a4af8 commit cc32a34
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 6 deletions.
4 changes: 2 additions & 2 deletions lib/node_modules/@stdlib/stats/base/dists/beta/mean/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ The function accepts the following arguments:
- **beta**: `[in] double` second shape parameter.

```c
double stdlib_base_dists_beta_mean( const double a, const double b );
double stdlib_base_dists_beta_mean( const double alpha, const double beta );
```
</section>
Expand Down Expand Up @@ -222,7 +222,7 @@ int main( void ) {
double beta;
double y;
int i;
for ( i = 0; i < 25; i++ ) {
alpha = random_uniform( 0.0, 10.0 );
beta = random_uniform( 0.0, 10.0 );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ static double benchmark( void ) {
int i;

for ( i = 0; i < 100; i++ ) {
alpha[ i ] = random_uniform( -20.0, 0.0 );
beta[ i ] = random_uniform( alpha[ i ], alpha[ i ]+40.0 );
alpha[ i ] = random_uniform( STDLIB_CONSTANT_FLOAT64_EPS, 20.0 );
beta[ i ] = random_uniform( STDLIB_CONSTANT_FLOAT64_EPS, 20.0 );
}

t = tic();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ tape( 'the function returns the mean of a beta distribution', function test( t )
t.equal( y, expected[i], 'alpha: '+alpha[i]+', beta: '+beta[i]+', y: '+y+', expected: '+expected[i] );
} else {
delta = abs( y - expected[ i ] );
tol = 15.0 * EPS * abs( expected[ i ] );
tol = 1.0 * EPS * abs( expected[ i ] );
t.ok( delta <= tol, 'within tolerance. alpha: '+alpha[i]+'. beta: '+beta[i]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' );
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ tape( 'the function returns the mean of a beta distribution', opts, function tes
t.equal( y, expected[i], 'alpha: '+alpha[i]+', beta: '+beta[i]+', y: '+y+', expected: '+expected[i] );
} else {
delta = abs( y - expected[ i ] );
tol = 15.0 * EPS * abs( expected[ i ] );
tol = 1.0 * EPS * abs( expected[ i ] );
t.ok( delta <= tol, 'within tolerance. alpha: '+alpha[i]+'. beta: '+beta[i]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' );
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ var addon = require( './../src/addon.node' );
/**
* Returns the skewness of a discrete uniform distribution.
*
* @private
* @param {integer} a - minimum support
* @param {integer} b - maximum support
* @returns {number} skewness
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ var addon = require( './../src/addon.node' );
/**
* Evaluates the natural logarithm of the cumulative density function (CDF) for a uniform distribution with minimum support `a` and maximum support `b` at a value `x`.
*
* @private
* @param {number} x - input value
* @param {PositiveNumber} a - first shape parameter
* @param {PositiveNumber} b - second shape parameter
Expand Down

0 comments on commit cc32a34

Please sign in to comment.