added median#19
Conversation
| experiment_data=experiment_data, | ||
| ) | ||
| print(format_benchmark_result(result, len(control_data.runtimes))) | ||
| print(format_benchmark_result(result, len(control_data.runtimes), control_data.runtimes, experiment_data.runtimes, show_median)) |
There was a problem hiding this comment.
This line is getting pretty long - perhaps it'd be best to break it on the new trailing comma so it'd be easier to scan – maybe like this?
print(format_benchmark_result(result, len(control_data.runtimes),
control_data.runtimes, …| sorted_runs = sorted(runs) | ||
| middle = len(runs) / 2 | ||
| if len(runs) % 2 == 0: | ||
| return sum(sorted_runs[middle-1:middle+1])/2 |
There was a problem hiding this comment.
I generally find this a little easier to read with spaces around the operators
|
|
||
|
|
||
| def format_benchmark_result(result, num_points): | ||
| def format_benchmark_result(result, num_points, control_data, experiment_data, show_median): |
There was a problem hiding this comment.
I'm wondering whether show_median should be a keyword argument here as well - that list is getting a bit long but it's not too bad.
|
I left a couple of minor stylistic points above. A larger question: the basic part is whether we should use |
No description provided.