Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Signed-off-by: Philipp Burckhardt <[email protected]>
  • Loading branch information
Planeshifter authored Mar 15, 2024
1 parent 8d85a35 commit 512349e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,13 +85,13 @@ var truncatedNormal = require( '@stdlib/stats/base/dists/truncated-normal' );
* In this example, we'll assume a = 150 (minimum height), b = 200 (maximum height), mu = 175 (location parameter), and sigma = 10 (scale parameter).
*/

var a = 150;
var b = 200;
var mu = 175;
var sigma = 10;
var a = 150.0;
var b = 200.0;
var mu = 175.0;
var sigma = 10.0;

// Calculate the probability density function (PDF) for a height of 180 cm:
console.log(truncatedNormal.pdf(180, a, b, mu, sigma));
console.log( truncatedNormal.pdf( 180, a, b, mu, sigma ) );
// => ~0.036
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ var truncatedNormal = require( './../lib' );
* In this example, we'll assume a = 150 (minimum height), b = 200 (maximum height), mu = 175 (location parameter), and sigma = 10 (scale parameter).
*/

var a = 150;
var b = 200;
var mu = 175;
var sigma = 10;
var a = 150.0;
var b = 200.0;
var mu = 175.0;
var sigma = 10.0;

// Calculate the probability density function (PDF) for a height of 180 cm:
console.log(truncatedNormal.pdf(180, a, b, mu, sigma));
console.log(truncatedNormal.pdf( 180, a, b, mu, sigma ) );
// => ~0.036

0 comments on commit 512349e

Please sign in to comment.