Skip to content

Commit 8bde004

Browse files
committed
Auto-generated commit
1 parent 59103a2 commit 8bde004

7 files changed

Lines changed: 58 additions & 49 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2025-04-01)
7+
## Unreleased (2025-04-29)
88

99
<section class="features">
1010

@@ -34,6 +34,7 @@ This release closes the following issue:
3434

3535
<details>
3636

37+
- [`e658ffd`](https://github.com/stdlib-js/stdlib/commit/e658ffd3c46b5cb1ba33c0be61e55bf6995237ca) - **bench:** update random value generation [(#6856)](https://github.com/stdlib-js/stdlib/pull/6856) _(by Harsh)_
3738
- [`a1e230f`](https://github.com/stdlib-js/stdlib/commit/a1e230f29297caa89880e9c194c615a0400fb7bc) - **chore:** clean up cppcheck-suppress comments _(by Karan Anand)_
3839
- [`a51a6b7`](https://github.com/stdlib-js/stdlib/commit/a51a6b7ae837114b7d9fa0854d31d03afe1e1111) - **chore:** explicitly cast and change tolerance _(by Philipp Burckhardt)_
3940
- [`d465523`](https://github.com/stdlib-js/stdlib/commit/d465523f1465201c42ca8491ecf14c6bde261031) - **feat:** add C implementation for `stats/base/dists/binomial/kurtosis` [(#4411)](https://github.com/stdlib-js/stdlib/pull/4411) _(by Prashant Kumar Yadav, Philipp Burckhardt, stdlib-bot)_
@@ -50,8 +51,9 @@ This release closes the following issue:
5051

5152
### Contributors
5253

53-
A total of 3 people contributed to this release. Thank you to the following contributors:
54+
A total of 4 people contributed to this release. Thank you to the following contributors:
5455

56+
- Harsh
5557
- Karan Anand
5658
- Philipp Burckhardt
5759
- Prashant Kumar Yadav

CONTRIBUTORS

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,15 @@ Dev Goel <135586571+corsairier@users.noreply.github.com>
4343
Dhanyabad behera <110620935+dhanyabad11@users.noreply.github.com>
4444
Dhruv Arvind Singh <154677013+DhruvArvindSingh@users.noreply.github.com>
4545
Dhruvil Mehta <68022411+dhruvilmehta@users.noreply.github.com>
46+
Dipjyoti Das <126075231+dipexplorer@users.noreply.github.com>
4647
Divyansh Seth <59174836+sethdivyansh@users.noreply.github.com>
4748
Dominic Lim <46486515+domlimm@users.noreply.github.com>
4849
Dominik Moritz <domoritz@gmail.com>
4950
Dorrin Sotoudeh <dorrinsotoudeh123@gmail.com>
5051
EuniceSim142 <77243938+EuniceSim142@users.noreply.github.com>
5152
Frank Kovacs <fran70kk@gmail.com>
5253
GK Bishnoi <gkishan1kyt@gmail.com>
54+
GURU PRASAD SHARMA <168292003+GURUPRASADSHARMA@users.noreply.github.com>
5355
Gaurav <gaurav70380@gmail.com>
5456
Gautam sharma <gautamkrishnasharma1@gmail.com>
5557
Golden Kumar <103646877+AuenKr@users.noreply.github.com>
@@ -75,7 +77,8 @@ Jordan Gallivan <115050475+Jordan-Gallivan@users.noreply.github.com>
7577
Joris Labie <joris.labie1@gmail.com>
7678
Justin Dennison <justin1dennison@gmail.com>
7779
Justyn Shelby <96994781+ShelbyJustyn@users.noreply.github.com>
78-
Karan Anand <119553199+anandkaranubc@users.noreply.github.com>
80+
Karan Anand <anandkarancompsci@gmail.com>
81+
Karan Yadav <77043443+karanBRAVO@users.noreply.github.com>
7982
Karthik Prakash <116057817+skoriop@users.noreply.github.com>
8083
Kaushikgtm <162317291+Kaushikgtm@users.noreply.github.com>
8184
Kavyansh-Bagdi <153486713+Kavyansh-Bagdi@users.noreply.github.com>
@@ -85,6 +88,7 @@ Krishnendu Das <86651039+itskdhere@users.noreply.github.com>
8588
Kshitij-Dale <152467202+Kshitij-Dale@users.noreply.github.com>
8689
Lovelin Dhoni J B <100030865+lovelindhoni@users.noreply.github.com>
8790
MANI <77221000+Eternity0207@users.noreply.github.com>
91+
Mahfuza Humayra Mohona <mhmohona@gmail.com>
8892
Manik Sharma <maniksharma.rke@gmail.com>
8993
Manvith M <148960168+manvith2003@users.noreply.github.com>
9094
Marcus Fantham <mfantham@users.noreply.github.com>
@@ -95,10 +99,14 @@ Mohammad Bin Aftab <48010758+MohammadBinAftab@users.noreply.github.com>
9599
Mohammad Kaif <mdkaifprofession@gmail.com>
96100
Momtchil Momtchev <momtchil@momtchev.com>
97101
Muhammad Haris <harriskhan047@outlook.com>
102+
Muhammad Taaha Tariq <166188821+Taaha-Tariq@users.noreply.github.com>
103+
Muhmmad Saad <106260977+saad-imran-dev@users.noreply.github.com>
98104
Naresh Jagadeesan <naresh.naresh000@gmail.com>
99105
Naveen Kumar <stupiddint@gmail.com>
100106
Neeraj Pathak <neerajrpathak710@gmail.com>
107+
NirvedMishra <139633597+NirvedMishra@users.noreply.github.com>
101108
Nishant Shinde <97207366+nishant-s7@users.noreply.github.com>
109+
Nishant singh <38534128+Nishantsingh11@users.noreply.github.com>
102110
Nishchay Rajput <121144841+NishchayRajput@users.noreply.github.com>
103111
Nithin Katta <88046362+nithinkatta@users.noreply.github.com>
104112
Nourhan Hasan <109472010+TheNourhan@users.noreply.github.com>
@@ -111,8 +119,10 @@ Prajwal Kulkarni <prajwalkulkarni76@gmail.com>
111119
Pranav Goswami <pranavchiku11@gmail.com>
112120
Pranjal Jha <97080887+PraneGIT@users.noreply.github.com>
113121
Prashant Kumar Yadav <144602492+0PrashantYadav0@users.noreply.github.com>
122+
PrathamBhamare <164445568+PrathamBhamare@users.noreply.github.com>
114123
Pratik Singh <97464067+Pratik772846@users.noreply.github.com>
115124
Pratyush Kumar Chouhan <pratyushkumar0308@gmail.com>
125+
Pravesh Kunwar <praveshkunwar04@gmail.com>
116126
Priyansh Prajapati <88396544+itsspriyansh@users.noreply.github.com>
117127
Priyanshu Agarwal <113460573+AgPriyanshu18@users.noreply.github.com>
118128
Pulkit Gupta <65711278+pulkitgupta2@users.noreply.github.com>
@@ -126,6 +136,7 @@ Rishav <115060907+rishav2404@users.noreply.github.com>
126136
Rishav Tarway <rishavtarway@gmail.com>
127137
Robert Gislason <gztown2216@yahoo.com>
128138
Roman Stetsyk <25715951+romanstetsyk@users.noreply.github.com>
139+
Rupa <102663541+Rupa-Rd@users.noreply.github.com>
129140
Rutam Kathale <138517416+performant23@users.noreply.github.com>
130141
Ruthwik Chikoti <145591715+ruthwikchikoti@users.noreply.github.com>
131142
Ryan Seal <splrk@users.noreply.github.com>
@@ -168,9 +179,11 @@ Yaswanth Kosuru <116426380+yaswanthkosuru@users.noreply.github.com>
168179
Yernar Yergaziyev <yernar.yergaziyev@erg.kz>
169180
Yugal Kaushik <yugalkaushik14@gmail.com>
170181
Yuvi Mittal <128018763+yuvi-mittal@users.noreply.github.com>
182+
devshree-bhati <147095250+devshree-bhati@users.noreply.github.com>
171183
ditsu <170345142+ditsus@users.noreply.github.com>
172184
ekambains <bainsinbusiness@gmail.com>
173185
fadiothman22 <48636283+fadiothman22@users.noreply.github.com>
186+
iraandrushko <71790513+iraandrushko@users.noreply.github.com>
174187
lohithganni <116790357+lohithganni@users.noreply.github.com>
175188
olenkabilonizhka <62379231+olenkabilonizhka@users.noreply.github.com>
176189
pranav-1720 <123018993+pranav-1720@users.noreply.github.com>

benchmark/benchmark.js

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,8 @@
2121
// MODULES //
2222

2323
var bench = require( '@stdlib/bench-harness' );
24-
var Float64Array = require( '@stdlib/array-float64' );
25-
var uniform = require( '@stdlib/random-base-uniform' );
26-
var discreteUniform = require( '@stdlib/random-base-discrete-uniform' );
24+
var uniform = require( '@stdlib/random-array-uniform' );
25+
var discreteUniform = require( '@stdlib/random-array-discrete-uniform' );
2726
var isnan = require( '@stdlib/math-base-assert-is-nan' );
2827
var pkg = require( './../package.json' ).name;
2928
var kurtosis = require( './../lib' );
@@ -32,23 +31,21 @@ var kurtosis = require( './../lib' );
3231
// MAIN //
3332

3433
bench( pkg, function benchmark( b ) {
35-
var len;
34+
var opts;
3635
var n;
3736
var p;
3837
var y;
3938
var i;
4039

41-
len = 100;
42-
n = new Float64Array( len );
43-
p = new Float64Array( len );
44-
for ( i = 0; i < len; i++ ) {
45-
n[ i ] = discreteUniform( 1, 100 );
46-
p[ i ] = uniform( 0.0, 1.0 );
47-
}
40+
opts = {
41+
'dtype': 'float64'
42+
};
43+
n = discreteUniform( 100, 1, 100, opts );
44+
p = uniform( 100, 0.0, 1.0, opts );
4845

4946
b.tic();
5047
for ( i = 0; i < b.iterations; i++ ) {
51-
y = kurtosis( n[ i % len ], p[ i % len ] );
48+
y = kurtosis( n[ i % n.length ], p[ i % p.length ] );
5249
if ( isnan( y ) ) {
5350
b.fail( 'should not return NaN' );
5451
}

benchmark/benchmark.native.js

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,9 @@
2222

2323
var resolve = require( 'path' ).resolve;
2424
var bench = require( '@stdlib/bench-harness' );
25-
var Float64Array = require( '@stdlib/array-float64' );
2625
var tryRequire = require( '@stdlib/utils-try-require' );
27-
var uniform = require( '@stdlib/random-base-uniform' );
28-
var discreteUniform = require( '@stdlib/random-base-discrete-uniform' );
26+
var uniform = require( '@stdlib/random-array-uniform' );
27+
var discreteUniform = require( '@stdlib/random-array-discrete-uniform' );
2928
var isnan = require( '@stdlib/math-base-assert-is-nan' );
3029
var pkg = require( './../package.json' ).name;
3130

@@ -41,22 +40,21 @@ var opts = {
4140
// MAIN //
4241

4342
bench( pkg+'::native', opts, function benchmark( b ) {
44-
var len;
43+
var opts;
4544
var n;
4645
var p;
4746
var y;
4847
var i;
4948

50-
n = new Float64Array( len );
51-
p = new Float64Array( len );
52-
for ( i = 0; i < len; i++ ) {
53-
n[ i ] = discreteUniform( 1, 100 );
54-
p[ i ] = uniform( 0.0, 1.0 );
55-
}
49+
opts = {
50+
'dtype': 'float64'
51+
};
52+
n = discreteUniform( 1000, 1, 100, opts );
53+
p = uniform( 1000, 0.0, 1.0, opts );
5654

5755
b.tic();
5856
for ( i = 0; i < b.iterations; i++ ) {
59-
y = kurtosis( n[ i % len ], p[ i % len ] );
57+
y = kurtosis( n[ i % n.length ], p[ i % p.length ] );
6058
if ( isnan( y ) ) {
6159
b.fail( 'should not return NaN' );
6260
}

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,15 +47,14 @@
4747
"@stdlib/utils-library-manifest": "^0.2.2"
4848
},
4949
"devDependencies": {
50-
"@stdlib/array-float64": "^0.2.2",
5150
"@stdlib/constants-float64-eps": "^0.2.2",
5251
"@stdlib/constants-float64-ninf": "^0.2.2",
5352
"@stdlib/math-base-special-abs": "^0.2.2",
5453
"@stdlib/math-base-special-ceil": "^0.2.2",
5554
"@stdlib/math-base-special-round": "^0.3.0",
56-
"@stdlib/random-base-discrete-uniform": "^0.2.1",
55+
"@stdlib/random-array-discrete-uniform": "^0.2.1",
56+
"@stdlib/random-array-uniform": "^0.2.1",
5757
"@stdlib/random-base-randu": "^0.2.1",
58-
"@stdlib/random-base-uniform": "^0.2.1",
5958
"@stdlib/utils-try-require": "^0.2.2",
6059
"tape": "git+https://github.com/kgryte/tape.git#fix/globby",
6160
"istanbul": "^0.4.1",

test/test.js

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,13 @@ tape( 'main export is a function', function test( t ) {
4444

4545
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', function test( t ) {
4646
var v = kurtosis( NaN, 0.5 );
47-
t.equal( isnan( v ), true, 'returns NaN' );
47+
t.equal( isnan( v ), true, 'returns expected value' );
4848

4949
v = kurtosis( 10, NaN );
50-
t.equal( isnan( v ), true, 'returns NaN' );
50+
t.equal( isnan( v ), true, 'returns expected value' );
5151

5252
v = kurtosis( NaN, NaN );
53-
t.equal( isnan( v ), true, 'returns NaN' );
53+
t.equal( isnan( v ), true, 'returns expected value' );
5454

5555
t.end();
5656
});
@@ -59,19 +59,19 @@ tape( 'if provided an `n` which is not a nonnegative integer, the function retur
5959
var v;
6060

6161
v = kurtosis( 1.5, 0.5 );
62-
t.equal( isnan( v ), true, 'returns NaN' );
62+
t.equal( isnan( v ), true, 'returns expected value' );
6363

6464
v = kurtosis( -2, 0.5 );
65-
t.equal( isnan( v ), true, 'returns NaN' );
65+
t.equal( isnan( v ), true, 'returns expected value' );
6666

6767
v = kurtosis( -1, 0.5 );
68-
t.equal( isnan( v ), true, 'returns NaN' );
68+
t.equal( isnan( v ), true, 'returns expected value' );
6969

7070
v = kurtosis( 2.5, 0.5 );
71-
t.equal( isnan( v ), true, 'returns NaN' );
71+
t.equal( isnan( v ), true, 'returns expected value' );
7272

7373
v = kurtosis( PINF, 0.5 );
74-
t.equal( isnan( v ), true, 'returns NaN' );
74+
t.equal( isnan( v ), true, 'returns expected value' );
7575

7676
t.end();
7777
});
@@ -80,16 +80,16 @@ tape( 'if provided a success probability `p` outside of `[0,1]`, the function re
8080
var v;
8181

8282
v = kurtosis( 20, -1.0 );
83-
t.equal( isnan( v ), true, 'returns NaN' );
83+
t.equal( isnan( v ), true, 'returns expected value' );
8484

8585
v = kurtosis( 20, 1.5 );
86-
t.equal( isnan( v ), true, 'returns NaN' );
86+
t.equal( isnan( v ), true, 'returns expected value' );
8787

8888
v = kurtosis( 20, NINF );
89-
t.equal( isnan( v ), true, 'returns NaN' );
89+
t.equal( isnan( v ), true, 'returns expected value' );
9090

9191
v = kurtosis( 20, PINF );
92-
t.equal( isnan( v ), true, 'returns NaN' );
92+
t.equal( isnan( v ), true, 'returns expected value' );
9393

9494
t.end();
9595
});

test/test.native.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,10 @@ tape( 'main export is a function', opts, function test( t ) {
5353

5454
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', opts, function test( t ) {
5555
var v = kurtosis( 10, NaN );
56-
t.equal( isnan( v ), true, 'returns NaN' );
56+
t.equal( isnan( v ), true, 'returns expected value' );
5757

5858
v = kurtosis( NaN, NaN );
59-
t.equal( isnan( v ), true, 'returns NaN' );
59+
t.equal( isnan( v ), true, 'returns expected value' );
6060

6161
t.end();
6262
});
@@ -65,10 +65,10 @@ tape( 'if provided an `n` which is not a nonnegative integer, the function retur
6565
var v;
6666

6767
v = kurtosis( -2, 0.5 );
68-
t.equal( isnan( v ), true, 'returns NaN' );
68+
t.equal( isnan( v ), true, 'returns expected value' );
6969

7070
v = kurtosis( -1, 0.5 );
71-
t.equal( isnan( v ), true, 'returns NaN' );
71+
t.equal( isnan( v ), true, 'returns expected value' );
7272

7373
t.end();
7474
});
@@ -77,16 +77,16 @@ tape( 'if provided a success probability `p` outside of `[0,1]`, the function re
7777
var v;
7878

7979
v = kurtosis( 20, -1.0 );
80-
t.equal( isnan( v ), true, 'returns NaN' );
80+
t.equal( isnan( v ), true, 'returns expected value' );
8181

8282
v = kurtosis( 20, 1.5 );
83-
t.equal( isnan( v ), true, 'returns NaN' );
83+
t.equal( isnan( v ), true, 'returns expected value' );
8484

8585
v = kurtosis( 20, NINF );
86-
t.equal( isnan( v ), true, 'returns NaN' );
86+
t.equal( isnan( v ), true, 'returns expected value' );
8787

8888
v = kurtosis( 20, PINF );
89-
t.equal( isnan( v ), true, 'returns NaN' );
89+
t.equal( isnan( v ), true, 'returns expected value' );
9090

9191
t.end();
9292
});

0 commit comments

Comments
 (0)