@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | D::intv(6, 9, 2 / 10), |
| 40 | 40 | ]; |
| 41 | 41 | |
| 42 | -$longDateFormat = function (DateTime $bound) { |
|
| 42 | +$longDateFormat = function(DateTime $bound) { |
|
| 43 | 43 | return $bound->format('Y-m-d H:i:s'); |
| 44 | 44 | }; |
| 45 | 45 | |
@@ -50,18 +50,18 @@ discard block |
||
| 50 | 50 | */ |
| 51 | 51 | |
| 52 | 52 | // An aggregate function for arrays representing fractions with the same denominator. |
| 53 | -$agg = function ($a, $b) { |
|
| 53 | +$agg = function($a, $b) { |
|
| 54 | 54 | if ($a === null && $b === null) return null; |
| 55 | 55 | return [$a[0] + $b[0], $b[1]]; |
| 56 | 56 | }; |
| 57 | 57 | |
| 58 | 58 | // A toNumeric function… |
| 59 | -$toNumeric = function ($a) { |
|
| 59 | +$toNumeric = function($a) { |
|
| 60 | 60 | return $a === null ? null : (int)($a[0] / $a[1] * 100); |
| 61 | 61 | }; |
| 62 | 62 | |
| 63 | 63 | // A toString function… |
| 64 | -$toString = function ($a) { |
|
| 64 | +$toString = function($a) { |
|
| 65 | 65 | return $a === null ? null : ($a[0] . '/' . $a[1]); |
| 66 | 66 | }; |
| 67 | 67 | |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | D::intv(2, 3, 3 / 10), |
| 104 | 104 | [$intv3, $intv3], |
| 105 | 105 | ])) |
| 106 | - ->setBoundToString($longDateFormat);; |
|
| 106 | + ->setBoundToString($longDateFormat); ; |
|
| 107 | 107 | |
| 108 | 108 | $intvGraphs = []; |
| 109 | 109 | foreach (range(0, 20) as $t) { |
@@ -190,14 +190,14 @@ discard block |
||
| 190 | 190 | <?php |
| 191 | 191 | |
| 192 | 192 | /* ADDITIONAL INFORMATION */ |
| 193 | -$toString2 = function ($a) { |
|
| 193 | +$toString2 = function($a) { |
|
| 194 | 194 | if ($a === null) { |
| 195 | 195 | return null; |
| 196 | 196 | } |
| 197 | 197 | return $a[0] . '/' . $a[1] . ($a[2] ? '*' : ''); |
| 198 | 198 | }; |
| 199 | 199 | |
| 200 | -$agg2 = function ($a, $b) { |
|
| 200 | +$agg2 = function($a, $b) { |
|
| 201 | 201 | if ($a === null && $b === null) return null; |
| 202 | 202 | return [ |
| 203 | 203 | $a[0] + $b[0], |
@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <div class='intvg'> |
| 2 | 2 | <?php foreach ($vs as $k => $v) : ?> |
| 3 | - <?php if (count($v) === 2 ): // Isolated date.?> |
|
| 3 | + <?php if (count($v) === 2): // Isolated date.?> |
|
| 4 | 4 | <div class='bar bar-date bar<?= $k; ?>' style='left:<?= $v[0] ?>%;' data-title='<?= $v[1] ?>'></div> |
| 5 | 5 | <?php else: ?> |
| 6 | 6 | <div class='bar bar-intv bar<?= $k; ?> <?= $v[2] ?> <?= strpos($v[5], '*') ? 'striped' : '' ?>' |