Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1129)

Unified Diff: client/dom/benchmarks/dromaeo/tests/Common.dart

Issue 9374026: Move dromaeo to third_party (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Moved Dromaeo to third party. Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « client/dom/benchmarks/dromaeo/test-tail.html ('k') | client/dom/benchmarks/dromaeo/tests/RunnerSuite.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/dom/benchmarks/dromaeo/tests/Common.dart
diff --git a/client/dom/benchmarks/dromaeo/tests/Common.dart b/client/dom/benchmarks/dromaeo/tests/Common.dart
deleted file mode 100644
index 2e4f174dacf6d8baeae849e12f0ede11b851242e..0000000000000000000000000000000000000000
--- a/client/dom/benchmarks/dromaeo/tests/Common.dart
+++ /dev/null
@@ -1,51 +0,0 @@
-class Result {
- int get runs() { return _sorted.length; }
-
- double get sum() {
- double result = 0.0;
- _sorted.forEach((double e) { result += e; });
- return result;
- }
-
- double get min() { return _sorted[0]; }
- double get max() { return _sorted[runs - 1]; }
-
- double get mean() { return sum / runs; }
-
- double get median() {
- return (runs % 2 == 0) ?
- (_sorted[runs ~/ 2] + _sorted[runs ~/ 2 + 1]) / 2 : _sorted[runs ~/ 2];
- }
-
- double get variance() {
- double m = mean;
- double result = 0.0;
- _sorted.forEach((double e) { result += Math.pow(e - m, 2.0); });
- return result / (runs - 1);
- }
-
- double get deviation() { return Math.sqrt(variance); }
-
- // Compute Standard Errors Mean
- double get sem() { return (deviation / Math.sqrt(runs)) * T_DISTRIBUTION; }
-
- double get error() { return (sem / mean) * 100; }
-
- // TODO: Implement writeOn.
- String toString() {
- return '[Result: mean = ${mean}]';
- }
-
- factory Result(List<double> runsPerSecond) {
- runsPerSecond.sort(int _(double a, double b) => a.compareTo(b));
- return new Result._internal(runsPerSecond);
- }
-
- Result._internal(this._sorted) {}
-
- List<double> _sorted;
-
- // Populated from: http://www.medcalc.be/manual/t-distribution.php
- // 95% confidence for N - 1 = 4
- static final double T_DISTRIBUTION = 2.776;
-}
« no previous file with comments | « client/dom/benchmarks/dromaeo/test-tail.html ('k') | client/dom/benchmarks/dromaeo/tests/RunnerSuite.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698