Passed
Push — master ( 37e99a...e89913 )
by Ruben
01:57
created
src/Statistics.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -26,14 +26,14 @@
 block discarded – undo
26 26
     public static function ABtest($testCounts, $targetCounts)
27 27
     {
28 28
         $ntotal = 0;
29
-        $resp  = [];
30
-        foreach($testCounts as $testCount) {
29
+        $resp = [];
30
+        foreach ($testCounts as $testCount) {
31 31
             $ntotal += $testCount[1];
32 32
         }
33
-        foreach($testCounts as $testCount) {
33
+        foreach ($testCounts as $testCount) {
34 34
             foreach ($targetCounts as $targetCount) {
35
-                if ($testCount[0] === $targetCount[1]) {
36
-                    $resp[] = [$testCount[0], $testCount[1], $testCount[1]/$ntotal, $targetCount[2], $targetCount[2]/$testCount[1],$targetCount[2]/$ntotal];
35
+                if ($testCount[0]===$targetCount[1]) {
36
+                    $resp[] = [$testCount[0], $testCount[1], $testCount[1] / $ntotal, $targetCount[2], $targetCount[2] / $testCount[1], $targetCount[2] / $ntotal];
37 37
                 }                
38 38
             }
39 39
             
Please login to merge, or discard this patch.