Skip to content

Commit d357b96

Browse files
authored
chore: minor clean-up
Signed-off-by: Philipp Burckhardt <[email protected]>
1 parent 822f466 commit d357b96

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

lib/node_modules/@stdlib/stats/base/dists/planck/logcdf/README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ for ( i = 0; i < lambda.length; i++ ) {
158158

159159
#### stdlib_base_dists_planck_logcdf( x, lambda )
160160

161-
Evaluates the logarithm of cumulative distribution function (logcdf) for an planck distribution with shape parameter `lambda`.
161+
Evaluates the logarithm of the [cumulative distribution function][cdf] for a Planck (discrete exponential) distribution with shape parameter `lambda`.
162162

163163
```c
164164
double out = stdlib_base_dists_planck_logcdf( 2, 0.5,);
@@ -197,17 +197,19 @@ double stdlib_base_dists_planck_logcdf
197197
#include "stdlib/stats/base/dists/planck/logcdf.h"
198198
#include <stdlib.h>
199199
#include <stdio.h>
200+
200201
static double random_uniform( const double min, const double max ) {
201202
double v = (double)rand() / ( (double)RAND_MAX + 1.0 );
202203
return min + ( v*(max-min) );
203204
}
205+
204206
static int discrete_uniform( const int min, const int max ) {
205207
return min + (rand() % (max - min + 1));
206208
}
207209

208210
int main( void ) {
209-
double x;
210211
double lambda;
212+
double x;
211213
double y;
212214
int i;
213215

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,8 @@ static int discrete_uniform( const int min, const int max ) {
9797
*/
9898
static double benchmark( void ) {
9999
double elapsed;
100-
double x[ 100 ];
101100
double lambda[ 100 ];
101+
double x[ 100 ];
102102
double y;
103103
double t;
104104
int i;

lib/node_modules/@stdlib/stats/base/dists/planck/logcdf/examples/c/example.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ static int discrete_uniform( const int min, const int max ) {
3030
}
3131

3232
int main( void ) {
33-
double x;
3433
double lambda;
34+
double x;
3535
double y;
3636
int i;
3737

0 commit comments

Comments
 (0)