Skip to content

Commit f64e693

Browse files
chore: address commit comments
PR-URL: #5202 Closes: #5146 Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
1 parent dbe9565 commit f64e693

File tree

4 files changed

+11
-9
lines changed

4 files changed

+11
-9
lines changed

lib/node_modules/@stdlib/stats/base/dists/exponential/logpdf/README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -137,10 +137,6 @@ for ( i = 0; i < 10; i++ ) {
137137

138138
<!-- /.examples -->
139139

140-
<!-- Section to include cited references. If references are included, add a horizontal rule *before* the section. Make sure to keep an empty line after the `section` element and another before the `/section` close. -->
141-
142-
<section class="references">
143-
144140
<!-- C interface documentation. -->
145141

146142
* * *
@@ -231,6 +227,12 @@ int main( void ) {
231227

232228
</section>
233229

230+
<!-- Section to include cited references. If references are included, add a horizontal rule *before* the section. Make sure to keep an empty line after the `section` element and another before the `/section` close. -->
231+
232+
<section class="references">
233+
234+
</section>
235+
234236
<!-- /.references -->
235237

236238
<!-- Section for related `stdlib` packages. Do not manually edit this section, as it is automatically populated. -->

lib/node_modules/@stdlib/stats/base/dists/exponential/logpdf/benchmark/benchmark.native.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
var resolve = require( 'path' ).resolve;
2424
var bench = require( '@stdlib/bench' );
2525
var Float64Array = require( '@stdlib/array/float64' );
26-
var randu = require( '@stdlib/random/base/randu' );
26+
var uniform = require( '@stdlib/random/base/uniform' );
2727
var isnan = require( '@stdlib/math/base/assert/is-nan' );
2828
var EPS = require( '@stdlib/constants/float64/eps' );
2929
var tryRequire = require( '@stdlib/utils/try-require' );
@@ -51,8 +51,8 @@ bench( pkg+'::native', opts, function benchmark( b ) {
5151
x = new Float64Array( len );
5252
lambda = new Float64Array( len );
5353
for ( i = 0; i < len; i++ ) {
54-
x[ i ] = ( randu()*100.0 );
55-
lambda[ i ] = ( randu()*100.0 ) + EPS;
54+
x[ i ] = uniform( 0.0, 100.0 );
55+
lambda[ i ] = uniform( EPS, 100.0 );
5656
}
5757

5858
b.tic();

lib/node_modules/@stdlib/stats/base/dists/exponential/logpdf/benchmark/c/benchmark.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ static double benchmark( void ) {
107107

108108
t = tic();
109109
for ( i = 0; i < ITERATIONS; i++ ) {
110-
y = stdlib_base_dists_exponential_logpdf( x[ i % 100 ], lambda[ i % 100 ]);
110+
y = stdlib_base_dists_exponential_logpdf( x[ i % 100 ], lambda[ i % 100 ] );
111111
if ( y != y ) {
112112
printf( "should not return NaN\n" );
113113
break;

lib/node_modules/@stdlib/stats/base/dists/exponential/logpdf/src/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ double stdlib_base_dists_exponential_logpdf( const double x, const double lambda
4242
) {
4343
return 0.0/0.0; // NaN
4444
}
45-
if( x < 0.0){
45+
if ( x < 0.0 ) {
4646
return STDLIB_CONSTANT_FLOAT64_NINF;
4747
}
4848
return ( -x*lambda ) + stdlib_base_ln( lambda );

0 commit comments

Comments
 (0)