pub fn normal_pdf(x: f64, mean: f64, std_dev: f64) -> f64Expand description
calculate the normal probability density function
Arguments:
x- value to calculate the probability density function ofmean- mean of the normal distributionstd_dev- standard deviation of the normal distribution
Returns:
f64- probability density function ofx
ยงExamples
use mscore::algorithm::isotope::normal_pdf;
let pdf = normal_pdf(0.0, 0.0, 1.0);
assert_eq!(pdf, 0.39894228040143265);