Skip to content

Commit c2a964f

Browse files
committed
fix: address review issues in stats/base/dists/planck/logcdf C implementation
1 parent 0367026 commit c2a964f

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

lib/node_modules/@stdlib/stats/base/dists/planck/logcdf/benchmark/benchmark.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ bench( pkg, function benchmark( b ) {
4242
lambda = new Float64Array( len );
4343
x = new Float64Array( len );
4444
for ( i = 0; i < len; i++ ) {
45-
x[i] = discreteUniform(0, 40);
46-
lambda[i] = uniform(1.0, 11.0);
45+
x[i] = discreteUniform( 0, 40 );
46+
lambda[i] = uniform( 1.0, 11.0 );
4747
}
4848

4949
b.tic();

lib/node_modules/@stdlib/stats/base/dists/planck/logcdf/benchmark/benchmark.native.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ var opts = {
4040

4141
// MAIN //
4242

43-
bench( pkg+'::native', opts, function benchmark( b ) {
43+
bench( pkg + '::native', opts, function benchmark( b ) {
4444
var lambda;
4545
var len;
4646
var x;
@@ -51,8 +51,8 @@ bench( pkg+'::native', opts, function benchmark( b ) {
5151
lambda = new Float64Array( len );
5252
x = new Float64Array( len );
5353
for ( i = 0; i < len; i++ ) {
54-
x[i] = discreteUniform(0, 40);
55-
lambda[i] = uniform(1.0, 10.0);
54+
x[i] = discreteUniform( 0, 40 );
55+
lambda[i] = uniform( 1.0, 10.0 );
5656
}
5757

5858
b.tic();

lib/node_modules/@stdlib/stats/base/dists/planck/logcdf/include/stdlib/stats/base/dists/planck/logcdf.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ extern "C" {
2727
#endif
2828

2929
/**
30-
*Evaluates the logarithm of cumulative distribution function (logcdf) for an planck distribution with shape parameter `lambda`.
30+
* Evaluates the logarithm of the cumulative distribution function (logCDF) for a Planck distribution with shape parameter `lambda`.
3131
*/
3232
double stdlib_base_dists_planck_logcdf( const double x, const double lambda );
3333

lib/node_modules/@stdlib/stats/base/dists/planck/logcdf/lib/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ function logcdf( x, lambda ) {
7272
if ( x === PINF ) {
7373
return 0.0;
7474
}
75-
return ln( -expm1( -lambda * ( floor(x)+1.0 ) ) );
75+
return ln( -expm1( -lambda * ( floor( x ) + 1.0 ) ) );
7676
}
7777

7878

0 commit comments

Comments
 (0)