added documentation for CI

This commit is contained in:
Stephen McQuay 2014-11-23 00:29:35 -08:00
parent b673118473
commit 74b57a41fe

View File

@ -95,6 +95,8 @@ func (os *OnlineStat) StdDev() float64 {
return math.Sqrt(os.Variance())
}
// CI returns a 95% confidence interval
// https://en.wikipedia.org/wiki/Confidence_interval
func (os *OnlineStat) CI() (float64, float64) {
// 95% from http://mathworld.wolfram.com/ConfidenceInterval.html
conf := 1.95996