You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lib/node_modules/@stdlib/random/streams/arcsine/README.md
+9-12
Original file line number
Diff line number
Diff line change
@@ -37,24 +37,21 @@ var randomStream = require( '@stdlib/random/streams/arcsine' );
37
37
Returns a [readable stream][readable-stream] for generating pseudorandom numbers drawn from an [arcsine][arcsine] distribution with parameters `a` (minimum support) and `b` (maximum support).
38
38
39
39
```javascript
40
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
40
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
By default, the function returns a [stream][stream] which can generate an infinite number of values (i.e., the [stream][stream] will **never** end). To limit the number of generated pseudorandom numbers, set the `iter` option.
87
84
88
85
```javascript
89
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
86
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
90
87
91
88
functionlog( chunk ) {
92
89
console.log( chunk.toString() );
@@ -105,7 +102,7 @@ stream.pipe( iStream );
105
102
By default, when not operating in [objectMode][object-mode], a returned [stream][stream] delineates generated pseudorandom numbers using a newline character. To specify an alternative separator, set the `sep` option.
106
103
107
104
```javascript
108
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
105
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
109
106
110
107
functionlog( chunk ) {
111
108
console.log( chunk.toString() );
@@ -125,7 +122,7 @@ stream.pipe( iStream );
125
122
To seed the underlying pseudorandom number generator, set the `seed` option.
126
123
127
124
```javascript
128
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
125
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
129
126
130
127
functionlog( v ) {
131
128
console.log( v );
@@ -150,7 +147,7 @@ stream.pipe( iStream );
150
147
To return a [readable stream][readable-stream] with an underlying pseudorandom number generator having a specific initial state, set the `state` option.
151
148
152
149
```javascript
153
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
150
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
154
151
155
152
functionlog( v ) {
156
153
console.log( v );
@@ -361,7 +358,7 @@ The method accepts the same `options` as [`randomStream()`](#random-stream).
361
358
This method is a convenience function to create [streams][stream] which **always** operate in [objectMode][object-mode].
362
359
363
360
```javascript
364
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
361
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
365
362
366
363
functionlog( v ) {
367
364
console.log( v );
@@ -433,7 +430,7 @@ function onState( state ) {
433
430
<!-- eslint no-undef: "error" -->
434
431
435
432
```javascript
436
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
433
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
437
434
var randomStream =require( '@stdlib/random/streams/arcsine' );
Copy file name to clipboardExpand all lines: lib/node_modules/@stdlib/random/streams/box-muller/README.md
+9-12
Original file line number
Diff line number
Diff line change
@@ -37,24 +37,21 @@ var randomStream = require( '@stdlib/random/streams/box-muller' );
37
37
Returns a [readable stream][readable-stream] for generating pseudorandom numbers drawn from a [standard normal][normal] distribution using the [Box-Muller transform][@stdlib/random/base/box-muller].
38
38
39
39
```javascript
40
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
40
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
41
41
42
42
var iStream;
43
43
var stream;
44
-
var count;
45
44
46
-
functionlog( chunk ) {
47
-
count +=1;
45
+
functionlog( chunk, idx ) {
48
46
console.log( chunk.toString() );
49
-
if ( count===10 ) {
47
+
if ( idx===10 ) {
50
48
stream.destroy();
51
49
}
52
50
}
53
51
54
52
stream =randomStream();
55
53
iStream =inspectStream( log );
56
54
57
-
count =0;
58
55
stream.pipe( iStream );
59
56
```
60
57
@@ -86,7 +83,7 @@ var stream = randomStream( opts );
86
83
By default, the function returns a [stream][stream] which can generate an infinite number of values (i.e., the [stream][stream] will **never** end). To limit the number of generated pseudorandom numbers, set the `iter` option.
87
84
88
85
```javascript
89
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
86
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
90
87
91
88
functionlog( chunk ) {
92
89
console.log( chunk.toString() );
@@ -105,7 +102,7 @@ stream.pipe( iStream );
105
102
By default, when not operating in [objectMode][object-mode], a returned [stream][stream] delineates generated pseudorandom numbers using a newline character. To specify an alternative separator, set the `sep` option.
106
103
107
104
```javascript
108
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
105
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
109
106
110
107
functionlog( chunk ) {
111
108
console.log( chunk.toString() );
@@ -125,7 +122,7 @@ stream.pipe( iStream );
125
122
To seed the underlying pseudorandom number generator, set the `seed` option.
126
123
127
124
```javascript
128
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
125
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
129
126
130
127
functionlog( v ) {
131
128
console.log( v );
@@ -150,7 +147,7 @@ stream.pipe( iStream );
150
147
To return a [readable stream][readable-stream] with an underlying pseudorandom number generator having a specific initial state, set the `state` option.
151
148
152
149
```javascript
153
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
150
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
154
151
155
152
functionlog( v ) {
156
153
console.log( v );
@@ -341,7 +338,7 @@ The method accepts the same `options` as [`randomStream()`](#random-stream).
341
338
This method is a convenience function to create [streams][stream] which **always** operate in [objectMode][object-mode].
342
339
343
340
```javascript
344
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
341
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
345
342
346
343
functionlog( v ) {
347
344
console.log( v );
@@ -413,7 +410,7 @@ function onState( state ) {
413
410
<!-- eslint no-undef: "error" -->
414
411
415
412
```javascript
416
-
var inspectStream =require( '@stdlib/streams/utils/inspect' );
413
+
var inspectStream =require( '@stdlib/streams/utils/inspect-sink' );
417
414
var randomStream =require( '@stdlib/random/streams/box-muller' );
0 commit comments