mirror of
https://github.com/octoleo/syncthing.git
synced 2024-11-14 01:04:14 +00:00
Forgot 5% for floats
This commit is contained in:
parent
d71a782179
commit
ec85c9fdfe
2
main.go
2
main.go
@ -235,7 +235,7 @@ func statsForInts(data []int) map[string]int {
|
||||
func statsForFloats(data []float64) map[string]float64 {
|
||||
sort.Float64s(data)
|
||||
res := make(map[string]float64, 4)
|
||||
res["min"] = data[0]
|
||||
res["fp"] = data[int(float64(len(data))*0.05)]
|
||||
res["med"] = data[len(data)/2]
|
||||
res["nfp"] = data[int(float64(len(data))*0.95)]
|
||||
res["max"] = data[len(data)-1]
|
||||
|
Loading…
Reference in New Issue
Block a user