UNPKG
@sgratzl/science
Version:
latest (2.0.0)
2.0.0
Scientific and statistical computing in JavaScript.
github.com/sgratzl/science.js
sgratzl/science.js
@sgratzl/science
/
src
/
stats
/
phi.js
6 lines
(4 loc)
•
108 B
JavaScript
View Raw
1
2
3
4
5
6
import
erf
from
'./erf'
;
export
default
function
phi
(
x
) {
return
.5
* (
1
+
erf
(x /
Math
.
SQRT2
)); };