From 49f5d932000439dede42ead2574d0fe200010c46 Mon Sep 17 00:00:00 2001 From: surtur Date: Sat, 18 Jun 2022 00:51:51 +0200 Subject: [PATCH] go(stats): update FuncStats definition --- stats/stats.go | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/stats/stats.go b/stats/stats.go index 5e72a67..36a994e 100644 --- a/stats/stats.go +++ b/stats/stats.go @@ -11,10 +11,14 @@ import ( "os" ) +type BenchRound struct { + Iteration int + Results []float64 +} + type FuncStats struct { BenchName string - Results []float64 - Iteration int + Solution []BenchRound } type Stats struct { @@ -25,11 +29,10 @@ type Stats struct { Generations int } -func GetFuncStats(funcName string, results []float64, iteration int) FuncStats { +func GetFuncStats(funcName string, solution []BenchRound) FuncStats { f := FuncStats{ BenchName: funcName, - Results: results, - Iteration: iteration, + Solution: solution, } return f