Skip to content

Commit 274dbd9

Browse files
committed
updated comments
1 parent b236546 commit 274dbd9

File tree

4 files changed

+12
-9
lines changed

4 files changed

+12
-9
lines changed

lib/node_modules/@stdlib/stats/base/dists/cauchy/cdf/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ Evaluates the [cumulative distribution function][cdf] (CDF) for a [Cauchy][cauch
171171

172172
```c
173173
double out = stdlib_base_dists_cauchy_cdf( 0.5, 0.0, 2.0 );
174-
// returns ~0.333
174+
// returns ~0.578
175175
```
176176

177177
The function accepts the following arguments:
@@ -213,9 +213,10 @@ static double random_uniform( const double min, const double max ) {
213213
}
214214
215215
int main( void ) {
216+
//correct order based on the length
216217
double gamma;
217-
double x;
218218
double x0;
219+
double x;
219220
double y;
220221
int i;
221222

lib/node_modules/@stdlib/stats/base/dists/cauchy/cdf/benchmark/benchmark.native.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ var pkg = require( './../package.json' ).name;
3131

3232

3333
// VARIABLES //
34-
35-
var logcdf = tryRequire( resolve( __dirname, './../lib/native.js' ) );
34+
//corected variable name
35+
var cdf = tryRequire( resolve( __dirname, './../lib/native.js' ) );
3636
var opts = {
37-
'skip': ( logcdf instanceof Error )
37+
'skip': ( cdf instanceof Error )
3838
};
3939

4040

lib/node_modules/@stdlib/stats/base/dists/cauchy/cdf/examples/c/example.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,13 @@ static double random_uniform( const double min, const double max ) {
2626
}
2727

2828
int main( void ) {
29-
double gamma;
29+
//corrected order
30+
int i;
3031
double x;
31-
double x0;
3232
double y;
33-
int i;
33+
double x0;
34+
double gamma;
35+
3436

3537
for ( i = 0; i < 25; i++ ) {
3638
x = random_uniform( 0.0, 10.0 );

lib/node_modules/@stdlib/stats/base/dists/cauchy/cdf/include/stdlib/stats/base/dists/cauchy/cdf.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 cumulative distribution function (CDF) for a Weibull distribution with shape parameter `k` and scale parameter `lambda` at a value `x`.
30+
* Evaluates the cumulative distribution function (CDF) for a Cauchy distribution with location parameter `x0` and scale parameter `gamma` at a value `x`.
3131
*/
3232
double stdlib_base_dists_cauchy_cdf( const double x, const double x0, const double gamma );
3333

0 commit comments

Comments
 (0)