Add Z-Score Algorithm (#3065)

Co-authored-by: Andrii Siriak <siryaka@gmail.com>
This commit is contained in:
Raghav Taneja
2022-05-29 03:16:04 -05:00
committed by GitHub
parent 2e09e44a38
commit bb5b50dea2
2 changed files with 36 additions and 0 deletions

View File

@ -0,0 +1,9 @@
package com.thealgorithms.maths;
public class StandardScore {
public static double zScore(double num, double mean, double stdDev)
{
double z = (num - mean)/stdDev;
return z;
}
}