diff --git a/Front/src/app/app.component.html b/Front/src/app/app.component.html index a8e2f24..2635a98 100644 --- a/Front/src/app/app.component.html +++ b/Front/src/app/app.component.html @@ -88,5 +88,9 @@ +
+
+

Procent trafionych predykcji: {{ ((TP / matches.length) * 100).toFixed(2) }}%

+
diff --git a/Front/src/app/app.component.ts b/Front/src/app/app.component.ts index c2fe485..421fb15 100644 --- a/Front/src/app/app.component.ts +++ b/Front/src/app/app.component.ts @@ -52,6 +52,7 @@ export class AppComponent implements OnInit { this.apiHelper.getJson(this.globalConfig.apiAdress + 'matches').subscribe( data => { this.matches = data; + this.countStatistics(); console.log(data); this.loading = false; }, @@ -92,6 +93,7 @@ export class AppComponent implements OnInit { this.countFMeasure(); } + countRMSE() { } @@ -101,9 +103,11 @@ export class AppComponent implements OnInit { } countTPFPFN() { - /*this.matches.forEach(x => { - if - });*/ + this.matches.forEach(x => { + if (x.predictedResult === x.result) { + this.TP += 1; + } + }); } countPrecision() {