@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Dataset; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Metric; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Metric; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Exception; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Preprocessing; |
6 | 6 | |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | { |
13 | 13 | const NORM_L1 = 1; |
14 | 14 | const NORM_L2 = 2; |
15 | - const NORM_STD= 3; |
|
15 | + const NORM_STD = 3; |
|
16 | 16 | |
17 | 17 | /** |
18 | 18 | * @var int |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | foreach ($sample as $feature) { |
118 | 118 | $norm2 += $feature * $feature; |
119 | 119 | } |
120 | - $norm2 = sqrt((float)$norm2); |
|
120 | + $norm2 = sqrt((float) $norm2); |
|
121 | 121 | |
122 | 122 | if (0 == $norm2) { |
123 | 123 | $sample = array_fill(0, count($sample), 1); |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Classification; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | namespace Phpml\Math\Statistic; |
6 | 6 | |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | // Ref: https://en.wikipedia.org/wiki/Normal_distribution |
40 | 40 | $std2 = $this->std ** 2; |
41 | 41 | $mean = $this->mean; |
42 | - return exp(- (($value - $mean) ** 2) / (2 * $std2)) / sqrt(2 * $std2 * pi()); |
|
42 | + return exp(-(($value - $mean) ** 2) / (2 * $std2)) / sqrt(2 * $std2 * pi()); |
|
43 | 43 | } |
44 | 44 | |
45 | 45 | /** |