fixed first views

master
parent b1e08fb7b7
commit 7ad5f7be6a
  1. BIN
      __pycache__/run.cpython-37.pyc
  2. 117
      frontend/src/components/AlgorithmHyperParam.vue
  3. 187
      frontend/src/components/Algorithms.vue
  4. 158
      frontend/src/components/BarChart.vue
  5. 4
      frontend/src/components/Main.vue
  6. 7
      frontend/src/components/Parameters.vue
  7. 29
      frontend/src/components/ResetClass.vue
  8. 4
      frontend/src/main.js

Binary file not shown.

@ -18,6 +18,8 @@ export default {
return {
ModelsPerformance: 0,
selAlgorithm: 0,
keyAllOrClass: true,
listClassPerf: [],
pc: 0,
factors: [1,1,1,0,0
,1,0,0,1,0
@ -133,8 +135,8 @@ export default {
+ (factorsLocal[10] * Object.values(performanceAlgLDA['mean_test_recall_macro'])[j]) + (factorsLocal[11] * Object.values(performanceAlgLDA['mean_test_recall_weighted'])[j]) + (factorsLocal[12] * Object.values(performanceAlgLDA['f5_micro'])[j]) + (factorsLocal[13] * Object.values(performanceAlgLDA['f5_macro'])[j]) + (factorsLocal[14] * Object.values(performanceAlgLDA['f5_weighted'])[j]) + (factorsLocal[15] * Object.values(performanceAlgLDA['f1_micro'])[j])
+ (factorsLocal[16] * Object.values(performanceAlgLDA['f1_macro'])[j]) + (factorsLocal[17] * Object.values(performanceAlgLDA['f1_weighted'])[j]) + (factorsLocal[18] * Object.values(performanceAlgLDA['f2_micro'])[j]) + (factorsLocal[19] * Object.values(performanceAlgLDA['f2_macro'])[j]) + (factorsLocal[20] * Object.values(performanceAlgLDA['f2_weighted'])[j]) + (factorsLocal[21] * Object.values(performanceAlgLDA['matthews_corrcoef'])[j])
+ (factorsLocal[22] * Object.values(performanceAlgLDA['mean_test_roc_auc_ovo_weighted'])[j]) + (factorsLocal[23] * (1 - Object.values(performanceAlgLDA['log_loss'])[j]))
if (sumLR <= 0) {
sumLR = 0
if (sumLDA <= 0) {
sumLDA = 0
}
McLDA.push((sumLDA/divide)*100)
}
@ -261,46 +263,88 @@ export default {
var ArrayCombined = []
var temp
for (var i = 0; i < valuesPerf.length; i++) {
if (this.selAlgorithm === 'KNN') {
// There is a problem here!
newObjectsParamsΚΝΝ.push({model: i,'# performance (%) #': McKNN[i],'n_neighbors':ObjectsParams[i].n_neighbors,'metric':ObjectsParams[i].metric,'algorithm':ObjectsParams[i].algorithm,'weights':ObjectsParams[i].weights})
ArrayCombined[i] = newObjectsParamsΚΝΝ[i]
} else if (this.selAlgorithm === 'SVC') {
newObjectsParamsSVC.push({model: this.SVCModels + i,'# performance (%) #': McSVC[i],'C':ObjectsParams[i].C,'kernel':ObjectsParams[i].kernel})
ArrayCombined[i] = newObjectsParamsSVC[i]
} else if (this.selAlgorithm === 'GausNB') {
newObjectsParamsGausNB.push({model: this.GausNBModels + i,'# performance (%) #': McGausNB[i],'var_smoothing':ObjectsParams[i].var_smoothing})
ArrayCombined[i] = newObjectsParamsGausNB[i]
} else if (this.selAlgorithm === 'MLP') {
newObjectsParamsMLP.push({model: this.MLPModels + i,'# performance (%) #': McMLP[i],'alpha':ObjectsParams[i].alpha,'tol':ObjectsParams[i].tol,'activation':ObjectsParams[i].activation,'max_iter':ObjectsParams[i].max_iter,'solver':ObjectsParams[i].solver})
ArrayCombined[i] = newObjectsParamsMLP[i]
} else if (this.selAlgorithm === 'LR') {
newObjectsParamsLR.push({model: this.LRModels + i,'# performance (%) #': McLR[i],'C':ObjectsParams[i].C,'max_iter':ObjectsParams[i].max_iter,'solver':ObjectsParams[i].solver,'penalty':ObjectsParams[i].penalty})
ArrayCombined[i] = newObjectsParamsLR[i]
} else if (this.selAlgorithm === 'LDA') {
newObjectsParamsLDA.push({model: this.LDAModels + i,'# performance (%) #': McLDA[i],'shrinkage':ObjectsParams[i].shrinkage,'solver':ObjectsParams[i].solver})
ArrayCombined[i] = newObjectsParamsLDA[i]
} else if (this.selAlgorithm === 'QDA') {
newObjectsParamsQDA.push({model: this.QDAModels + i,'# performance (%) #': McQDA[i],'reg_param':ObjectsParams[i].reg_param,'tol':ObjectsParams[i].tol})
ArrayCombined[i] = newObjectsParamsQDA[i]
} else if (this.selAlgorithm === 'RF') {
newObjectsParamsRF.push({model: this.RFModels + i,'# performance (%) #': McRF[i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion})
ArrayCombined[i] = newObjectsParamsRF[i]
} else if (this.selAlgorithm === 'ExtraT') {
newObjectsParamsExtraT.push({model: this.ExtraTModels + i,'# performance (%) #': McExtraT[i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion})
ArrayCombined[i] = newObjectsParamsExtraT[i]
} else if (this.selAlgorithm === 'AdaB') {
newObjectsParamsAdaB.push({model: this.AdaBModels + i,'# performance (%) #': McAdaB[i],'n_estimators':ObjectsParams[i].n_estimators,'learning_rate':ObjectsParams[i].learning_rate,'algorithm':ObjectsParams[i].algorithm})
ArrayCombined[i] = newObjectsParamsAdaB[i]
if (this.keyAllOrClass) {
if (this.selAlgorithm === 'KNN') {
newObjectsParamsΚΝΝ.push({model: i,'# performance (%) #': McKNN[i],'n_neighbors':ObjectsParams[i].n_neighbors,'metric':ObjectsParams[i].metric,'algorithm':ObjectsParams[i].algorithm,'weights':ObjectsParams[i].weights})
ArrayCombined[i] = newObjectsParamsΚΝΝ[i]
} else if (this.selAlgorithm === 'SVC') {
newObjectsParamsSVC.push({model: this.SVCModels + i,'# performance (%) #': McSVC[i],'C':ObjectsParams[i].C,'kernel':ObjectsParams[i].kernel})
ArrayCombined[i] = newObjectsParamsSVC[i]
} else if (this.selAlgorithm === 'GausNB') {
newObjectsParamsGausNB.push({model: this.GausNBModels + i,'# performance (%) #': McGausNB[i],'var_smoothing':ObjectsParams[i].var_smoothing})
ArrayCombined[i] = newObjectsParamsGausNB[i]
} else if (this.selAlgorithm === 'MLP') {
newObjectsParamsMLP.push({model: this.MLPModels + i,'# performance (%) #': McMLP[i],'alpha':ObjectsParams[i].alpha,'tol':ObjectsParams[i].tol,'activation':ObjectsParams[i].activation,'max_iter':ObjectsParams[i].max_iter,'solver':ObjectsParams[i].solver})
ArrayCombined[i] = newObjectsParamsMLP[i]
} else if (this.selAlgorithm === 'LR') {
newObjectsParamsLR.push({model: this.LRModels + i,'# performance (%) #': McLR[i],'C':ObjectsParams[i].C,'max_iter':ObjectsParams[i].max_iter,'solver':ObjectsParams[i].solver,'penalty':ObjectsParams[i].penalty})
ArrayCombined[i] = newObjectsParamsLR[i]
} else if (this.selAlgorithm === 'LDA') {
newObjectsParamsLDA.push({model: this.LDAModels + i,'# performance (%) #': McLDA[i],'shrinkage':ObjectsParams[i].shrinkage,'solver':ObjectsParams[i].solver})
ArrayCombined[i] = newObjectsParamsLDA[i]
} else if (this.selAlgorithm === 'QDA') {
newObjectsParamsQDA.push({model: this.QDAModels + i,'# performance (%) #': McQDA[i],'reg_param':ObjectsParams[i].reg_param,'tol':ObjectsParams[i].tol})
ArrayCombined[i] = newObjectsParamsQDA[i]
} else if (this.selAlgorithm === 'RF') {
newObjectsParamsRF.push({model: this.RFModels + i,'# performance (%) #': McRF[i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion})
ArrayCombined[i] = newObjectsParamsRF[i]
} else if (this.selAlgorithm === 'ExtraT') {
newObjectsParamsExtraT.push({model: this.ExtraTModels + i,'# performance (%) #': McExtraT[i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion})
ArrayCombined[i] = newObjectsParamsExtraT[i]
} else if (this.selAlgorithm === 'AdaB') {
newObjectsParamsAdaB.push({model: this.AdaBModels + i,'# performance (%) #': McAdaB[i],'n_estimators':ObjectsParams[i].n_estimators,'learning_rate':ObjectsParams[i].learning_rate,'algorithm':ObjectsParams[i].algorithm})
ArrayCombined[i] = newObjectsParamsAdaB[i]
} else {
newObjectsParamsGradB.push({model: this.GradBModels + i,'# performance (%) #': McGradB[i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion,'learning_rate':ObjectsParams[i].learning_rate})
ArrayCombined[i] = newObjectsParamsGradB[i]
}
} else {
newObjectsParamsGradB.push({model: this.GradBModels + i,'# performance (%) #': McGradB[i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion,'learning_rate':ObjectsParams[i].learning_rate})
ArrayCombined[i] = newObjectsParamsGradB[i]
if (this.selAlgorithm === 'KNN') {
newObjectsParamsΚΝΝ.push({model: i,'# performance (%) #': this.listClassPerf[0][i],'n_neighbors':ObjectsParams[i].n_neighbors,'metric':ObjectsParams[i].metric,'algorithm':ObjectsParams[i].algorithm,'weights':ObjectsParams[i].weights})
ArrayCombined[i] = newObjectsParamsΚΝΝ[i]
} else if (this.selAlgorithm === 'SVC') {
newObjectsParamsSVC.push({model: this.SVCModels + i,'# performance (%) #': this.listClassPerf[1][i],'C':ObjectsParams[i].C,'kernel':ObjectsParams[i].kernel})
ArrayCombined[i] = newObjectsParamsSVC[i]
} else if (this.selAlgorithm === 'GausNB') {
newObjectsParamsGausNB.push({model: this.GausNBModels + i,'# performance (%) #': this.listClassPerf[2][i],'var_smoothing':ObjectsParams[i].var_smoothing})
ArrayCombined[i] = newObjectsParamsGausNB[i]
} else if (this.selAlgorithm === 'MLP') {
newObjectsParamsMLP.push({model: this.MLPModels + i,'# performance (%) #': this.listClassPerf[3][i],'alpha':ObjectsParams[i].alpha,'tol':ObjectsParams[i].tol,'activation':ObjectsParams[i].activation,'max_iter':ObjectsParams[i].max_iter,'solver':ObjectsParams[i].solver})
ArrayCombined[i] = newObjectsParamsMLP[i]
} else if (this.selAlgorithm === 'LR') {
newObjectsParamsLR.push({model: this.LRModels + i,'# performance (%) #': this.listClassPerf[4][i],'C':ObjectsParams[i].C,'max_iter':ObjectsParams[i].max_iter,'solver':ObjectsParams[i].solver,'penalty':ObjectsParams[i].penalty})
ArrayCombined[i] = newObjectsParamsLR[i]
} else if (this.selAlgorithm === 'LDA') {
newObjectsParamsLDA.push({model: this.LDAModels + i,'# performance (%) #': this.listClassPerf[5][i],'shrinkage':ObjectsParams[i].shrinkage,'solver':ObjectsParams[i].solver})
ArrayCombined[i] = newObjectsParamsLDA[i]
} else if (this.selAlgorithm === 'QDA') {
newObjectsParamsQDA.push({model: this.QDAModels + i,'# performance (%) #': this.listClassPerf[6][i],'reg_param':ObjectsParams[i].reg_param,'tol':ObjectsParams[i].tol})
ArrayCombined[i] = newObjectsParamsQDA[i]
} else if (this.selAlgorithm === 'RF') {
newObjectsParamsRF.push({model: this.RFModels + i,'# performance (%) #': this.listClassPerf[7][i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion})
ArrayCombined[i] = newObjectsParamsRF[i]
} else if (this.selAlgorithm === 'ExtraT') {
newObjectsParamsExtraT.push({model: this.ExtraTModels + i,'# performance (%) #': this.listClassPerf[8][i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion})
ArrayCombined[i] = newObjectsParamsExtraT[i]
} else if (this.selAlgorithm === 'AdaB') {
newObjectsParamsAdaB.push({model: this.AdaBModels + i,'# performance (%) #': this.listClassPerf[9][i],'n_estimators':ObjectsParams[i].n_estimators,'learning_rate':ObjectsParams[i].learning_rate,'algorithm':ObjectsParams[i].algorithm})
ArrayCombined[i] = newObjectsParamsAdaB[i]
} else {
newObjectsParamsGradB.push({model: this.GradBModels + i,'# performance (%) #': this.listClassPerf[10][i],'n_estimators':ObjectsParams[i].n_estimators,'criterion':ObjectsParams[i].criterion,'learning_rate':ObjectsParams[i].learning_rate})
ArrayCombined[i] = newObjectsParamsGradB[i]
}
}
}
EventBus.$emit('AllAlModels', ArrayCombined.length)
this.pc = ParCoords()("#PCP")
.data(ArrayCombined)
.color(colorGiv)
.margin({
top: 25,
left: 25,
right: 25,
bottom: 25
})
.hideAxis(['model'])
.bundlingStrength(0) // set bundling strength
.smoothness(0)
@ -335,6 +379,9 @@ export default {
EventBus.$on('CallFactorsView', data => { this.factors = data })
EventBus.$on('CallFactorsView', this.PCPView)
EventBus.$on('boxplotSet', data => { this.listClassPerf = data })
EventBus.$on('boxplotCall', data => { this.keyAllOrClass = data })
// reset view
EventBus.$on('resetViews', this.reset)
EventBus.$on('clearPCP', this.reset)

@ -33,7 +33,9 @@ export default {
ExtraTModels: 2606,
AdaBModels: 2766,
GradBModels: 2926,
listClassPerf: [],
WH: [],
keyAllOrClass: true,
parameters: [],
algorithm1: [],
algorithm2: [],
@ -127,10 +129,10 @@ export default {
+ (factorsLocal[10] * Object.values(performanceAlgMLP['mean_test_recall_macro'])[j]) + (factorsLocal[11] * Object.values(performanceAlgMLP['mean_test_recall_weighted'])[j]) + (factorsLocal[12] * Object.values(performanceAlgMLP['f5_micro'])[j]) + (factorsLocal[13] * Object.values(performanceAlgMLP['f5_macro'])[j]) + (factorsLocal[14] * Object.values(performanceAlgMLP['f5_weighted'])[j]) + (factorsLocal[15] * Object.values(performanceAlgMLP['f1_micro'])[j])
+ (factorsLocal[16] * Object.values(performanceAlgMLP['f1_macro'])[j]) + (factorsLocal[17] * Object.values(performanceAlgMLP['f1_weighted'])[j]) + (factorsLocal[18] * Object.values(performanceAlgMLP['f2_micro'])[j]) + (factorsLocal[19] * Object.values(performanceAlgMLP['f2_macro'])[j]) + (factorsLocal[20] * Object.values(performanceAlgMLP['f2_weighted'])[j]) + (factorsLocal[21] * Object.values(performanceAlgMLP['matthews_corrcoef'])[j])
+ (factorsLocal[22] * Object.values(performanceAlgMLP['mean_test_roc_auc_ovo_weighted'])[j]) + (factorsLocal[23] * (1 - Object.values(performanceAlgMLP['log_loss'])[j]))
if (sumMLP <= 0) {
if (sumMLP <= 0) {
sumMLP = 0
}
McMLP.push((sumMLP/divide)*100)
McMLP.push((sumMLP/divide)*100)
}
var McLR = []
const performanceAlgLR = JSON.parse(this.PerformanceAllModels[38])
@ -141,10 +143,10 @@ export default {
+ (factorsLocal[10] * Object.values(performanceAlgLR['mean_test_recall_macro'])[j]) + (factorsLocal[11] * Object.values(performanceAlgLR['mean_test_recall_weighted'])[j]) + (factorsLocal[12] * Object.values(performanceAlgLR['f5_micro'])[j]) + (factorsLocal[13] * Object.values(performanceAlgLR['f5_macro'])[j]) + (factorsLocal[14] * Object.values(performanceAlgLR['f5_weighted'])[j]) + (factorsLocal[15] * Object.values(performanceAlgLR['f1_micro'])[j])
+ (factorsLocal[16] * Object.values(performanceAlgLR['f1_macro'])[j]) + (factorsLocal[17] * Object.values(performanceAlgLR['f1_weighted'])[j]) + (factorsLocal[18] * Object.values(performanceAlgLR['f2_micro'])[j]) + (factorsLocal[19] * Object.values(performanceAlgLR['f2_macro'])[j]) + (factorsLocal[20] * Object.values(performanceAlgLR['f2_weighted'])[j]) + (factorsLocal[21] * Object.values(performanceAlgLR['matthews_corrcoef'])[j])
+ (factorsLocal[22] * Object.values(performanceAlgLR['mean_test_roc_auc_ovo_weighted'])[j]) + (factorsLocal[23] * (1 - Object.values(performanceAlgLR['log_loss'])[j]))
if (sumLR <= 0) {
if (sumLR <= 0) {
sumLR = 0
}
McLR.push((sumLR/divide)*100)
McLR.push((sumLR/divide)*100)
}
var McLDA = []
const performanceAlgLDA = JSON.parse(this.PerformanceAllModels[46])
@ -257,52 +259,97 @@ export default {
this.algorithmAdaB = []
this.algorithmGradB = []
this.parameters = []
for (var i = 0; i < Object.keys(PerformAlgorKNN['params']).length; i++) {
this.algorithmKNN.push({'# Performance (%) #': McKNN[i],Algorithm:'KNN',Model:'Model ' + AlgorKNNIDs[i] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorKNN['params'])[i])+'; # Performance (%) # ',ModelID:AlgorKNNIDs[i]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorKNN['params'])[i]))
}
for (let j = 0; j < Object.keys(PerformAlgorSVC['params']).length; j++) {
this.algorithmSVC.push({'# Performance (%) #': McSVC[j],Algorithm:'SVC',Model:'Model ' + AlgorSVCIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorSVC['params'])[j])+'; # Performance (%) # ',ModelID:AlgorSVCIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorSVC['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorGausNB['params']).length; j++) {
this.algorithmGausNB.push({'# Performance (%) #': McGausNB[j],Algorithm:'GausNB',Model:'Model ' + AlgorGausNBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorGausNB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorGausNBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorGausNB['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorMLP['params']).length; j++) {
this.algorithmMLP.push({'# Performance (%) #': McMLP[j],Algorithm:'MLP',Model:'Model ' + AlgorMLPIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorMLP['params'])[j])+'; # Performance (%) # ',ModelID:AlgorMLPIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorMLP['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorLR['params']).length; j++) {
this.algorithmLR.push({'# Performance (%) #': McLR[j],Algorithm:'LR',Model:'Model ' + AlgorLRIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorLR['params'])[j])+'; # Performance (%) # ',ModelID:AlgorLRIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorLR['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorLDA['params']).length; j++) {
this.algorithmLDA.push({'# Performance (%) #': McLDA[j],Algorithm:'LDA',Model:'Model ' + AlgorLDAIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorLDA['params'])[j])+'; # Performance (%) # ',ModelID:AlgorLDAIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorLDA['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorQDA['params']).length; j++) {
this.algorithmQDA.push({'# Performance (%) #': McQDA[j],Algorithm:'QDA',Model:'Model ' + AlgorQDAIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorQDA['params'])[j])+'; # Performance (%) # ',ModelID:AlgorQDAIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorQDA['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorRF['params']).length; j++) {
this.algorithmRF.push({'# Performance (%) #': McRF[j],Algorithm:'RF',Model:'Model ' + AlgorRFIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorRF['params'])[j])+'; # Performance (%) # ',ModelID:AlgorRFIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorRF['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorExtraT['params']).length; j++) {
this.algorithmExtraT.push({'# Performance (%) #': McExtraT[j],Algorithm:'ExtraT',Model:'Model ' + AlgorExtraTIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorExtraT['params'])[j])+'; # Performance (%) # ',ModelID:AlgorExtraTIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorExtraT['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorAdaB['params']).length; j++) {
this.algorithmAdaB.push({'# Performance (%) #': McAdaB[j],Algorithm:'AdaB',Model:'Model ' + AlgorAdaBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorAdaB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorAdaBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorAdaB['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorGradB['params']).length; j++) {
this.algorithmGradB.push({'# Performance (%) #': McGradB[j],Algorithm:'GradB',Model:'Model ' + AlgorGradBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorGradB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorGradBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorGradB['params'])[j]))
if (this.keyAllOrClass) {
for (var j = 0; j < Object.keys(PerformAlgorKNN['params']).length; j++) {
this.algorithmKNN.push({'# Performance (%) #': McKNN[j],Algorithm:'KNN',Model:'Model ' + AlgorKNNIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorKNN['params'])[j])+'; # Performance (%) # ',ModelID:AlgorKNNIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorKNN['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorSVC['params']).length; j++) {
this.algorithmSVC.push({'# Performance (%) #': McSVC[j],Algorithm:'SVC',Model:'Model ' + AlgorSVCIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorSVC['params'])[j])+'; # Performance (%) # ',ModelID:AlgorSVCIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorSVC['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorGausNB['params']).length; j++) {
this.algorithmGausNB.push({'# Performance (%) #': McGausNB[j],Algorithm:'GausNB',Model:'Model ' + AlgorGausNBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorGausNB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorGausNBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorGausNB['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorMLP['params']).length; j++) {
this.algorithmMLP.push({'# Performance (%) #': McMLP[j],Algorithm:'MLP',Model:'Model ' + AlgorMLPIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorMLP['params'])[j])+'; # Performance (%) # ',ModelID:AlgorMLPIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorMLP['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorLR['params']).length; j++) {
this.algorithmLR.push({'# Performance (%) #': McLR[j],Algorithm:'LR',Model:'Model ' + AlgorLRIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorLR['params'])[j])+'; # Performance (%) # ',ModelID:AlgorLRIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorLR['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorLDA['params']).length; j++) {
this.algorithmLDA.push({'# Performance (%) #': McLDA[j],Algorithm:'LDA',Model:'Model ' + AlgorLDAIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorLDA['params'])[j])+'; # Performance (%) # ',ModelID:AlgorLDAIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorLDA['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorQDA['params']).length; j++) {
this.algorithmQDA.push({'# Performance (%) #': McQDA[j],Algorithm:'QDA',Model:'Model ' + AlgorQDAIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorQDA['params'])[j])+'; # Performance (%) # ',ModelID:AlgorQDAIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorQDA['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorRF['params']).length; j++) {
this.algorithmRF.push({'# Performance (%) #': McRF[j],Algorithm:'RF',Model:'Model ' + AlgorRFIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorRF['params'])[j])+'; # Performance (%) # ',ModelID:AlgorRFIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorRF['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorExtraT['params']).length; j++) {
this.algorithmExtraT.push({'# Performance (%) #': McExtraT[j],Algorithm:'ExtraT',Model:'Model ' + AlgorExtraTIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorExtraT['params'])[j])+'; # Performance (%) # ',ModelID:AlgorExtraTIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorExtraT['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorAdaB['params']).length; j++) {
this.algorithmAdaB.push({'# Performance (%) #': McAdaB[j],Algorithm:'AdaB',Model:'Model ' + AlgorAdaBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorAdaB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorAdaBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorAdaB['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorGradB['params']).length; j++) {
this.algorithmGradB.push({'# Performance (%) #': McGradB[j],Algorithm:'GradB',Model:'Model ' + AlgorGradBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorGradB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorGradBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorGradB['params'])[j]))
}
} else {
for (var j = 0; j < Object.keys(PerformAlgorKNN['params']).length; j++) {
this.algorithmKNN.push({'# Performance (%) #': this.listClassPerf[0][j],Algorithm:'KNN',Model:'Model ' + AlgorKNNIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorKNN['params'])[j])+'; # Performance (%) # ',ModelID:AlgorKNNIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorKNN['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorSVC['params']).length; j++) {
this.algorithmSVC.push({'# Performance (%) #': this.listClassPerf[1][j],Algorithm:'SVC',Model:'Model ' + AlgorSVCIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorSVC['params'])[j])+'; # Performance (%) # ',ModelID:AlgorSVCIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorSVC['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorGausNB['params']).length; j++) {
this.algorithmGausNB.push({'# Performance (%) #': this.listClassPerf[2][j],Algorithm:'GausNB',Model:'Model ' + AlgorGausNBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorGausNB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorGausNBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorGausNB['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorMLP['params']).length; j++) {
this.algorithmMLP.push({'# Performance (%) #': this.listClassPerf[3][j],Algorithm:'MLP',Model:'Model ' + AlgorMLPIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorMLP['params'])[j])+'; # Performance (%) # ',ModelID:AlgorMLPIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorMLP['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorLR['params']).length; j++) {
this.algorithmLR.push({'# Performance (%) #': this.listClassPerf[4][j],Algorithm:'LR',Model:'Model ' + AlgorLRIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorLR['params'])[j])+'; # Performance (%) # ',ModelID:AlgorLRIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorLR['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorLDA['params']).length; j++) {
this.algorithmLDA.push({'# Performance (%) #': this.listClassPerf[5][j],Algorithm:'LDA',Model:'Model ' + AlgorLDAIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorLDA['params'])[j])+'; # Performance (%) # ',ModelID:AlgorLDAIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorLDA['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorQDA['params']).length; j++) {
this.algorithmQDA.push({'# Performance (%) #': this.listClassPerf[6][j],Algorithm:'QDA',Model:'Model ' + AlgorQDAIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorQDA['params'])[j])+'; # Performance (%) # ',ModelID:AlgorQDAIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorQDA['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorRF['params']).length; j++) {
this.algorithmRF.push({'# Performance (%) #': this.listClassPerf[7][j],Algorithm:'RF',Model:'Model ' + AlgorRFIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorRF['params'])[j])+'; # Performance (%) # ',ModelID:AlgorRFIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorRF['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorExtraT['params']).length; j++) {
this.algorithmExtraT.push({'# Performance (%) #': this.listClassPerf[8][j],Algorithm:'ExtraT',Model:'Model ' + AlgorExtraTIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorExtraT['params'])[j])+'; # Performance (%) # ',ModelID:AlgorExtraTIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorExtraT['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorAdaB['params']).length; j++) {
this.algorithmAdaB.push({'# Performance (%) #': this.listClassPerf[9][j],Algorithm:'AdaB',Model:'Model ' + AlgorAdaBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorAdaB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorAdaBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorAdaB['params'])[j]))
}
for (let j = 0; j < Object.keys(PerformAlgorGradB['params']).length; j++) {
this.algorithmGradB.push({'# Performance (%) #': this.listClassPerf[10][j],Algorithm:'GradB',Model:'Model ' + AlgorGradBIDs[j] + '; Parameters '+JSON.stringify(Object.values(PerformAlgorGradB['params'])[j])+'; # Performance (%) # ',ModelID:AlgorGradBIDs[j]})
this.parameters.push(JSON.stringify(Object.values(PerformAlgorGradB['params'])[j]))
}
}
EventBus.$emit('ParametersAll', this.parameters)
// concat the data
@ -325,7 +372,7 @@ export default {
this.chart.width(this.WH[0]*10) // interactive visualization
this.chart.height(this.WH[1]*0.9) // interactive visualization
//call chart on a div
this.chart('#exploding_boxplot')
this.chart('#exploding_boxplot')
// colorscale
const previousColor = ['#a6cee3','#1f78b4','#b2df8a','#33a02c','#fb9a99','#e31a1c','#fdbf6f','#ff7f00','#cab2d6','#6a3d9a','#b15928']
@ -358,8 +405,9 @@ export default {
flagEmptyKNN = 1
} else {
flagEmptyKNN = 0
}
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagKNN', flagEmptyKNN)
EventBus.$emit('PCPCall', 'KNN')
EventBus.$emit('updateBarChart', [])
@ -376,7 +424,8 @@ export default {
} else {
flagEmptySVC = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagSVC', flagEmptySVC)
EventBus.$emit('PCPCall', 'SVC')
EventBus.$emit('updateBarChart', [])
@ -393,7 +442,8 @@ export default {
} else {
flagEmptyGausNB = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagGausNB', flagEmptyGausNB)
EventBus.$emit('PCPCall', 'GausNB')
EventBus.$emit('updateBarChart', [])
@ -410,7 +460,8 @@ export default {
} else {
flagEmptyMLP = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagMLP', flagEmptyMLP)
EventBus.$emit('PCPCall', 'MLP')
EventBus.$emit('updateBarChart', [])
@ -427,7 +478,8 @@ export default {
} else {
flagEmptyLR = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagLR', flagEmptyLR)
EventBus.$emit('PCPCall', 'LR')
EventBus.$emit('updateBarChart', [])
@ -444,7 +496,8 @@ export default {
} else {
flagEmptyLDA = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagLDA', flagEmptyLDA)
EventBus.$emit('PCPCall', 'LDA')
EventBus.$emit('updateBarChart', [])
@ -462,6 +515,7 @@ export default {
flagEmptyQDA = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagQDA', flagEmptyQDA)
EventBus.$emit('PCPCall', 'QDA')
EventBus.$emit('updateBarChart', [])
@ -479,6 +533,7 @@ export default {
flagEmptyRF = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagRF', flagEmptyRF)
EventBus.$emit('PCPCall', 'RF')
EventBus.$emit('updateBarChart', [])
@ -495,7 +550,8 @@ export default {
} else {
flagEmptyExtraT = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagExtraT', flagEmptyExtraT)
EventBus.$emit('PCPCall', 'ExtraT')
EventBus.$emit('updateBarChart', [])
@ -512,7 +568,8 @@ export default {
} else {
flagEmptyAdaB = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagAdaB', flagEmptyAdaB)
EventBus.$emit('PCPCall', 'AdaB')
EventBus.$emit('updateBarChart', [])
@ -529,7 +586,8 @@ export default {
} else {
flagEmptyGradB = 0
}
EventBus.$emit('clearPCP')
EventBus.$emit('updateFlagGradB', flagEmptyGradB)
EventBus.$emit('PCPCall', 'GradB')
EventBus.$emit('updateBarChart', [])
@ -549,6 +607,7 @@ export default {
flagEmptyGradB = 0
EventBus.$emit('clearPCP')
EventBus.$emit('alternateFlagLock')
EventBus.$emit('updateBarChart', [])
}
// check if brushed through all boxplots and not only one at a time
@ -737,6 +796,7 @@ export default {
}
}
}
EventBus.$emit('flagBrushedAll', 1)
EventBus.$emit('sendParameters', this.parameters)
EventBus.$emit('updateActiveModels', modelsActive)
this.UpdateBarChart()
@ -770,8 +830,6 @@ export default {
for (let j = 0; j < this.brushedBoxPl.length; j++) {
modelsActive.push(this.brushedBoxPl[j].model)
}
console.log(modelsActive)
console.log(this.selectedAlgorithm)
for (let i = 0; i < allPoints.length; i++) {
if (this.selectedAlgorithm === 'KNN') {
allPoints[i].style.fill = previousColor[0]
@ -902,6 +960,7 @@ export default {
}
}
}
EventBus.$emit('flagBrushedAll', 0)
EventBus.$emit('sendParameters', this.parameters)
EventBus.$emit('updateActiveModels', modelsActive)
this.UpdateBarChart()
@ -1024,7 +1083,7 @@ export default {
$(el)[10].dispatchEvent(new Event('click'))
}
}
}
},
},
mounted () {
EventBus.$on('emittedEventCallingModelBrushed', this.selectedPointsPerAlgorithm)
@ -1047,6 +1106,10 @@ export default {
EventBus.$on('CallFactorsView', data => { this.factors = data })
EventBus.$on('CallFactorsView', this.boxplot)
EventBus.$on('boxplotSet', data => { this.listClassPerf = data })
EventBus.$on('boxplotCall', data => { this.keyAllOrClass = data })
EventBus.$on('boxplotCall', this.boxplot)
// reset the views
EventBus.$on('resetViews', this.reset)
}

@ -140,6 +140,19 @@ export default {
var tempExtraT = 0
var tempAdaB = 0
var tempGradB = 0
var storeKNN = []
var storeSVC = []
var storeGausNB = []
var storeMLP = []
var storeLR = []
var storeLDA = []
var storeQDA = []
var storeRF = []
var storeExtraT = []
var storeAdaB = []
var storeGradB = []
for (var i=0;i<target_names.length;i++) {
tempKNN = 0
tempSVC = 0
@ -152,58 +165,80 @@ export default {
tempExtraT = 0
tempAdaB = 0
tempGradB = 0
for (var j=0;j<Object.keys(PerClassMetricsKNN[target_names[i]]).length;j++){
tempKNN = tempKNN + ((Object.values(PerClassMetricsKNN)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][j]['recall']*factorRecall))/divide
storeKNN[target_names[i]] = []
storeSVC[target_names[i]] = []
storeGausNB[target_names[i]] = []
storeMLP[target_names[i]] = []
storeLR[target_names[i]] = []
storeLDA[target_names[i]] = []
storeQDA[target_names[i]] = []
storeRF[target_names[i]] = []
storeExtraT[target_names[i]] = []
storeAdaB[target_names[i]] = []
storeGradB[target_names[i]] = []
for (var k=0;k<Object.keys(PerClassMetricsKNN[target_names[i]]).length;k++){
tempKNN = tempKNN + ((Object.values(PerClassMetricsKNN)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][k]['recall']*factorRecall))/divide
storeKNN[target_names[i]][k] = 100*((Object.values(PerClassMetricsKNN)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][k]['recall']*factorRecall))/divide
}
tempKNN = tempKNN/Object.keys(PerClassMetricsKNN[target_names[i]]).length
sum.push(tempKNN)
for (var k=0;k<Object.keys(PerClassMetricsSVC[target_names[i]]).length;k++){
tempSVC = tempSVC + ((Object.values(PerClassMetricsSVC)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsSVC)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsSVC)[i][k]['recall']*factorRecall))/divide
storeSVC[target_names[i]][k] = 100*((Object.values(PerClassMetricsSVC)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsSVC)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsSVC)[i][k]['recall']*factorRecall))/divide
}
tempSVC = tempSVC/Object.keys(PerClassMetricsSVC[target_names[i]]).length
sum.push(tempSVC)
for (var k=0;k<Object.keys(PerClassMetricsGausNB[target_names[i]]).length;k++){
tempGausNB = tempGausNB + ((Object.values(PerClassMetricsGausNB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGausNB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGausNB)[i][k]['recall']*factorRecall))/divide
storeGausNB[target_names[i]][k] = 100*((Object.values(PerClassMetricsGausNB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGausNB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGausNB)[i][k]['recall']*factorRecall))/divide
}
tempGausNB = tempGausNB/Object.keys(PerClassMetricsGausNB[target_names[i]]).length
sum.push(tempGausNB)
for (var k=0;k<Object.keys(PerClassMetricsMLP[target_names[i]]).length;k++){
tempMLP = tempMLP + ((Object.values(PerClassMetricsMLP)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsMLP)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsMLP)[i][k]['recall']*factorRecall))/divide
storeMLP[target_names[i]][k] = 100*((Object.values(PerClassMetricsMLP)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsMLP)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsMLP)[i][k]['recall']*factorRecall))/divide
}
tempMLP = tempMLP/Object.keys(PerClassMetricsMLP[target_names[i]]).length
sum.push(tempMLP)
for (var k=0;k<Object.keys(PerClassMetricsLR[target_names[i]]).length;k++){
tempLR = tempLR + ((Object.values(PerClassMetricsLR)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLR)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLR)[i][k]['recall']*factorRecall))/divide
storeLR[target_names[i]][k] = 100*((Object.values(PerClassMetricsLR)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLR)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLR)[i][k]['recall']*factorRecall))/divide
}
tempLR = tempLR/Object.keys(PerClassMetricsLR[target_names[i]]).length
sum.push(tempLR)
for (var k=0;k<Object.keys(PerClassMetricsLDA[target_names[i]]).length;k++){
tempLDA = tempLDA + ((Object.values(PerClassMetricsLDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLDA)[i][k]['recall']*factorRecall))/divide
storeLDA[target_names[i]][k] = 100*((Object.values(PerClassMetricsLDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLDA)[i][k]['recall']*factorRecall))/divide
}
tempLDA = tempLDA/Object.keys(PerClassMetricsLDA[target_names[i]]).length
sum.push(tempLDA)
for (var k=0;k<Object.keys(PerClassMetricsQDA[target_names[i]]).length;k++){
tempQDA = tempQDA + ((Object.values(PerClassMetricsQDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsQDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsQDA)[i][k]['recall']*factorRecall))/divide
}
storeQDA[target_names[i]][k] = 100*((Object.values(PerClassMetricsQDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsQDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsQDA)[i][k]['recall']*factorRecall))/divide
}
tempQDA = tempQDA/Object.keys(PerClassMetricsQDA[target_names[i]]).length
sum.push(tempQDA)
for (var k=0;k<Object.keys(PerClassMetricsRF[target_names[i]]).length;k++){
tempRF = tempRF + ((Object.values(PerClassMetricsRF)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsRF)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsRF)[i][k]['recall']*factorRecall))/divide
storeRF[target_names[i]][k] = 100*((Object.values(PerClassMetricsRF)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsRF)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsRF)[i][k]['recall']*factorRecall))/divide
}
tempRF = tempRF/Object.keys(PerClassMetricsRF[target_names[i]]).length
sum.push(tempRF)
for (var k=0;k<Object.keys(PerClassMetricsExtraT[target_names[i]]).length;k++){
tempExtraT = tempExtraT + ((Object.values(PerClassMetricsExtraT)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsExtraT)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsExtraT)[i][k]['recall']*factorRecall))/divide
storeExtraT[target_names[i]][k] = 100*((Object.values(PerClassMetricsExtraT)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsExtraT)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsExtraT)[i][k]['recall']*factorRecall))/divide
}
tempExtraT = tempExtraT/Object.keys(PerClassMetricsExtraT[target_names[i]]).length
sum.push(tempExtraT)
for (var k=0;k<Object.keys(PerClassMetricsAdaB[target_names[i]]).length;k++){
tempAdaB = tempAdaB + ((Object.values(PerClassMetricsAdaB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsAdaB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsAdaB)[i][k]['recall']*factorRecall))/divide
storeAdaB[target_names[i]][k] = 100*((Object.values(PerClassMetricsAdaB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsAdaB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsAdaB)[i][k]['recall']*factorRecall))/divide
}
tempAdaB = tempAdaB/Object.keys(PerClassMetricsAdaB[target_names[i]]).length
sum.push(tempAdaB)
for (var k=0;k<Object.keys(PerClassMetricsGradB[target_names[i]]).length;k++){
tempGradB = tempGradB + ((Object.values(PerClassMetricsGradB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGradB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGradB)[i][k]['recall']*factorRecall))/divide
storeGradB[target_names[i]][k] = 100*((Object.values(PerClassMetricsGradB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGradB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGradB)[i][k]['recall']*factorRecall))/divide
}
tempGradB = tempGradB/Object.keys(PerClassMetricsGradB[target_names[i]]).length
sum.push(tempGradB)
@ -234,133 +269,133 @@ export default {
tempAdaB = 0
tempGradB = 0
if (KNNModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsKNN[target_names[i]]).length;j++){
tempKNN = tempKNN + ((Object.values(PerClassMetricsKNN)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsKNN[target_names[i]]).length;k++){
tempKNN = tempKNN + ((Object.values(PerClassMetricsKNN)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][k]['recall']*factorRecall))/divide
}
tempKNN = tempKNN/Object.keys(PerClassMetricsKNN[target_names[i]]).length
} else {
for (var j=0;j<KNNModels.length;j++){
tempKNN = tempKNN + ((Object.values(PerClassMetricsKNN)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<KNNModels.length;k++){
tempKNN = tempKNN + ((Object.values(PerClassMetricsKNN)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsKNN)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsKNN)[i][k]['recall']*factorRecall))/divide
}
tempKNN = tempKNN/KNNModels.length
}
sumLine.push(tempKNN)
if (SVCModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsSVC[target_names[i]]).length;j++){
tempSVC = tempSVC + ((Object.values(PerClassMetricsSVC)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsSVC)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsSVC)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsSVC[target_names[i]]).length;k++){
tempSVC = tempSVC + ((Object.values(PerClassMetricsSVC)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsSVC)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsSVC)[i][k]['recall']*factorRecall))/divide
}
tempSVC = tempSVC/Object.keys(PerClassMetricsSVC[target_names[i]]).length
} else {
for (var j=0;j<SVCModels.length;j++){
tempSVC = tempSVC + ((Object.values(PerClassMetricsSVC)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsSVC)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsSVC)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<SVCModels.length;k++){
tempSVC = tempSVC + ((Object.values(PerClassMetricsSVC)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsSVC)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsSVC)[i][k]['recall']*factorRecall))/divide
}
tempSVC = tempSVC/SVCModels.length
}
sumLine.push(tempSVC)
if (GausNBModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsGausNB[target_names[i]]).length;j++){
tempGausNB = tempGausNB + ((Object.values(PerClassMetricsGausNB)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsGausNB)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsGausNB)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsGausNB[target_names[i]]).length;k++){
tempGausNB = tempGausNB + ((Object.values(PerClassMetricsGausNB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGausNB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGausNB)[i][k]['recall']*factorRecall))/divide
}
tempGausNB = tempGausNB/Object.keys(PerClassMetricsGausNB[target_names[i]]).length
} else {
for (var j=0;j<GausNBModels.length;j++){
tempGausNB = tempGausNB + ((Object.values(PerClassMetricsGausNB)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsGausNB)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsGausNB)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<GausNBModels.length;k++){
tempGausNB = tempGausNB + ((Object.values(PerClassMetricsGausNB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGausNB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGausNB)[i][k]['recall']*factorRecall))/divide
}
tempGausNB = tempGausNB/GausNBModels.length
}
sumLine.push(tempGausNB)
if (MLPModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsMLP[target_names[i]]).length;j++){
tempMLP = tempMLP + ((Object.values(PerClassMetricsMLP)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsMLP)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsMLP)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsMLP[target_names[i]]).length;k++){
tempMLP = tempMLP + ((Object.values(PerClassMetricsMLP)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsMLP)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsMLP)[i][k]['recall']*factorRecall))/divide
}
tempMLP = tempMLP/Object.keys(PerClassMetricsMLP[target_names[i]]).length
} else {
for (var j=0;j<MLPModels.length;j++){
tempMLP = tempMLP + ((Object.values(PerClassMetricsMLP)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsMLP)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsMLP)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<MLPModels.length;k++){
tempMLP = tempMLP + ((Object.values(PerClassMetricsMLP)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsMLP)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsMLP)[i][k]['recall']*factorRecall))/divide
}
tempMLP = tempMLP/MLPModels.length
}
sumLine.push(tempMLP)
if (LRModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsLR[target_names[i]]).length;j++){
tempLR = tempLR + ((Object.values(PerClassMetricsLR)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsLR)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsLR)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsLR[target_names[i]]).length;k++){
tempLR = tempLR + ((Object.values(PerClassMetricsLR)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLR)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLR)[i][k]['recall']*factorRecall))/divide
}
tempLR = tempLR/Object.keys(PerClassMetricsLR[target_names[i]]).length
} else {
for (var j=0;j<LRModels.length;j++){
tempLR = tempLR + ((Object.values(PerClassMetricsLR)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsLR)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsLR)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<LRModels.length;k++){
tempLR = tempLR + ((Object.values(PerClassMetricsLR)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLR)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLR)[i][k]['recall']*factorRecall))/divide
}
tempLR = tempLR/LRModels.length
}
sumLine.push(tempLR)
if (LDAModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsLDA[target_names[i]]).length;j++){
tempLDA = tempLDA + ((Object.values(PerClassMetricsLDA)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsLDA)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsLDA)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsLDA[target_names[i]]).length;k++){
tempLDA = tempLDA + ((Object.values(PerClassMetricsLDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLDA)[i][k]['recall']*factorRecall))/divide
}
tempLDA = tempLDA/Object.keys(PerClassMetricsLDA[target_names[i]]).length
} else {
for (var j=0;j<LDAModels.length;j++){
tempLDA = tempLDA + ((Object.values(PerClassMetricsLDA)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsLDA)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsLDA)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<LDAModels.length;k++){
tempLDA = tempLDA + ((Object.values(PerClassMetricsLDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsLDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsLDA)[i][k]['recall']*factorRecall))/divide
}
tempLDA = tempLDA/LDAModels.length
}
sumLine.push(tempLDA)
if (QDAModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsQDA[target_names[i]]).length;j++){
tempQDA = tempQDA + ((Object.values(PerClassMetricsQDA)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsQDA)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsQDA)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsQDA[target_names[i]]).length;k++){
tempQDA = tempQDA + ((Object.values(PerClassMetricsQDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsQDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsQDA)[i][k]['recall']*factorRecall))/divide
}
tempQDA = tempQDA/Object.keys(PerClassMetricsQDA[target_names[i]]).length
} else {
for (var j=0;j<QDAModels.length;j++){
tempQDA = tempQDA + ((Object.values(PerClassMetricsQDA)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsQDA)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsQDA)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<QDAModels.length;k++){
tempQDA = tempQDA + ((Object.values(PerClassMetricsQDA)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsQDA)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsQDA)[i][k]['recall']*factorRecall))/divide
}
tempQDA = tempQDA/QDAModels.length
}
sumLine.push(tempQDA)
if (RFModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsRF[target_names[i]]).length;j++){
tempRF = tempRF + ((Object.values(PerClassMetricsRF)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsRF)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsRF)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsRF[target_names[i]]).length;k++){
tempRF = tempRF + ((Object.values(PerClassMetricsRF)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsRF)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsRF)[i][k]['recall']*factorRecall))/divide
}
tempRF = tempRF/Object.keys(PerClassMetricsRF[target_names[i]]).length
} else {
for (var j=0;j<RFModels.length;j++){
tempRF = tempRF + ((Object.values(PerClassMetricsRF)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsRF)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsRF)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<RFModels.length;k++){
tempRF = tempRF + ((Object.values(PerClassMetricsRF)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsRF)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsRF)[i][k]['recall']*factorRecall))/divide
}
tempRF = tempRF/RFModels.length
}
sumLine.push(tempRF)
if (ExtraTModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsExtraT[target_names[i]]).length;j++){
tempExtraT = tempExtraT + ((Object.values(PerClassMetricsExtraT)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsExtraT)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsExtraT)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsExtraT[target_names[i]]).length;k++){
tempExtraT = tempExtraT + ((Object.values(PerClassMetricsExtraT)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsExtraT)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsExtraT)[i][k]['recall']*factorRecall))/divide
}
tempExtraT = tempExtraT/Object.keys(PerClassMetricsExtraT[target_names[i]]).length
} else {
for (var j=0;j<ExtraTModels.length;j++){
tempExtraT = tempExtraT + ((Object.values(PerClassMetricsExtraT)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsExtraT)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsExtraT)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<ExtraTModels.length;k++){
tempExtraT = tempExtraT + ((Object.values(PerClassMetricsExtraT)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsExtraT)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsExtraT)[i][k]['recall']*factorRecall))/divide
}
tempExtraT = tempExtraT/ExtraTModels.length
}
sumLine.push(tempExtraT)
if (AdaBModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsAdaB[target_names[i]]).length;j++){
tempAdaB = tempAdaB + ((Object.values(PerClassMetricsAdaB)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsAdaB)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsAdaB)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsAdaB[target_names[i]]).length;k++){
tempAdaB = tempAdaB + ((Object.values(PerClassMetricsAdaB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsAdaB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsAdaB)[i][k]['recall']*factorRecall))/divide
}
tempAdaB = tempAdaB/Object.keys(PerClassMetricsAdaB[target_names[i]]).length
} else {
for (var j=0;j<AdaBModels.length;j++){
tempAdaB = tempAdaB + ((Object.values(PerClassMetricsAdaB)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsAdaB)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsAdaB)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<AdaBModels.length;k++){
tempAdaB = tempAdaB + ((Object.values(PerClassMetricsAdaB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsAdaB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsAdaB)[i][k]['recall']*factorRecall))/divide
}
tempAdaB = tempAdaB/AdaBModels.length
}
sumLine.push(tempAdaB)
if (GradBModels.length == 0) {
for (var j=0;j<Object.keys(PerClassMetricsGradB[target_names[i]]).length;j++){
tempGradB = tempGradB + ((Object.values(PerClassMetricsGradB)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsGradB)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsGradB)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<Object.keys(PerClassMetricsGradB[target_names[i]]).length;k++){
tempGradB = tempGradB + ((Object.values(PerClassMetricsGradB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGradB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGradB)[i][k]['recall']*factorRecall))/divide
}
tempGradB = tempGradB/Object.keys(PerClassMetricsGradB[target_names[i]]).length
} else {
for (var j=0;j<GradBModels.length;j++){
tempGradB = tempGradB + ((Object.values(PerClassMetricsGradB)[i][j]['f1-score']*factorF1)+(Object.values(PerClassMetricsGradB)[i][j]['precision']*factorPrec)+(Object.values(PerClassMetricsGradB)[i][j]['recall']*factorRecall))/divide
for (var k=0;k<GradBModels.length;k++){
tempGradB = tempGradB + ((Object.values(PerClassMetricsGradB)[i][k]['f1-score']*factorF1)+(Object.values(PerClassMetricsGradB)[i][k]['precision']*factorPrec)+(Object.values(PerClassMetricsGradB)[i][k]['recall']*factorRecall))/divide
}
tempGradB = tempGradB/GradBModels.length
}
@ -392,6 +427,7 @@ export default {
tickangle: 'auto',
exponentformat: 'e',
showexponent: 'all',
side: 'top'
},
bargap:0.1,
bargroupgap: 0.2,
@ -402,7 +438,8 @@ export default {
t: 30,
pad: 0
},
legend: {"orientation": "h"}
legend: {orientation: 'h', xanchor: 'center', x: 0.5},
hovermode: 'closest'
}
var traces = []
var tracesSel = []
@ -411,16 +448,18 @@ export default {
var sumLineList = []
var keepSum
var keepSumLine
var loopStartUntil = sum.length/target_names.length
for (var i = 0; i < target_names.length; i++) {
keepSum = []
keepSumLine = []
for (var j = i; j < sum.length; j+=target_names.length) {
keepSum.push(sum[j]*100)
keepSumLine.push(sumLine[j]*100)
for (var k = i*loopStartUntil; k < (i+1)*loopStartUntil; k++) {
keepSum.push(sum[k]*100)
keepSumLine.push(sumLine[k]*100)
}
sumList[i] = keepSum
sumLineList[i] = keepSumLine
}
for (var i = 0; i < target_names.length; i++) {
traces[i] = {
x: ['KNN','SVC','GausNB','MLP','LR','LDA','QDA','RF','ExtraT','AdaB','GradB'],
@ -449,7 +488,22 @@ export default {
data.push(traces[i])
data.push(tracesSel[i])
}
Plotly.newPlot('barChart', data, layout)
var barc = document.getElementById('barChart');
Plotly.newPlot(barc, data, layout)
var X, Y;
barc.on('plotly_click', (eventData) => {
var tName
eventData.points.forEach((e) => {
tName = e.data.name.replace(/ *\([^)]*\) */g, "")
});
EventBus.$emit('clearPCP')
EventBus.$emit('alternateFlagLock')
EventBus.$emit('boxplotSet', [storeKNN[tName],storeSVC[tName],storeGausNB[tName],storeMLP[tName],storeLR[tName],storeLDA[tName],storeQDA[tName],storeRF[tName],storeExtraT[tName],storeAdaB[tName],storeGradB[tName]])
EventBus.$emit('boxplotCall', false)
});
},
reset ()
{

@ -74,7 +74,7 @@
</b-col>
<b-col cols="9">
<mdb-card style="margin-top: 15px;">
<mdb-card-header color="primary-color" tag="h5" class="text-center"><small class="float-left" style="padding-top: 3px;">Metrics Support: [5, 6, 7 (F1)]</small>Performance of the Algorithms for Each Class</mdb-card-header>
<mdb-card-header color="primary-color" tag="h5" class="text-center"><small class="float-left" style="padding-top: 3px;">Metrics Support: [5, 6, 7 (F1)]</small>Performance of the Algorithms for Each Class<small class="float-right"><ResetClass/></small></mdb-card-header>
<mdb-card-body>
<BarChart/>
</mdb-card-body>
@ -148,6 +148,7 @@ import DataSetExecController from './DataSetExecController.vue'
import Algorithms from './Algorithms.vue'
import AlgorithmHyperParam from './AlgorithmHyperParam.vue'
import Controller from './Controller.vue'
import ResetClass from './ResetClass.vue'
import SlidersController from './SlidersController.vue'
import ScatterPlot from './ScatterPlot.vue'
import PerMetricBarChart from './PerMetricBarChart.vue'
@ -182,6 +183,7 @@ export default Vue.extend({
Algorithms,
AlgorithmHyperParam,
Controller,
ResetClass,
SlidersController,
ScatterPlot,
PerMetricBarChart,

@ -42,6 +42,7 @@ export default {
FlagExtraT: 0,
FlagAdaB: 0,
FlagGradB: 0,
FlagBrushAll: 0,
SVCModels: 576,
GausNBModels: 736,
MLPModels: 1236,
@ -415,7 +416,7 @@ export default {
var AdaBSelection = 0
var GradBSelection = 0
if (this.FlagKNN == 0 && this.FlagSVC == 0 && this.FlagGausNB == 0 && this.FlagMLP == 0 && this.FlagLR == 0 && this.FlagLDA == 0 && this.FlagQDA == 0 && this.FlagRF == 0 && this.FlagExtraT == 0 && this.FlagAdaB == 0 && this.FlagGradB == 0) {
if (this.FlagBrushAll == 0 && this.FlagKNN == 0 && this.FlagSVC == 0 && this.FlagGausNB == 0 && this.FlagMLP == 0 && this.FlagLR == 0 && this.FlagLDA == 0 && this.FlagQDA == 0 && this.FlagRF == 0 && this.FlagExtraT == 0 && this.FlagAdaB == 0 && this.FlagGradB == 0) {
this.storeActiveModels = []
this.allActiveKNN = []
this.allActiveSVC = []
@ -461,7 +462,7 @@ export default {
countAdaBRelated.push(JSON.parse(this.storeParameters[this.storeActiveModels[i]]))
countAdaB++
} else if (this.storeActiveModels[i] > this.ExtraTModels) {
countExtraT.push(JSON.parse(this.storeParameters[this.storeActiveModels[i]]))
countExtraTRelated.push(JSON.parse(this.storeParameters[this.storeActiveModels[i]]))
countExtraT++
} else if (this.storeActiveModels[i] > this.RFModels) {
countRFRelated.push(JSON.parse(this.storeParameters[this.storeActiveModels[i]]))
@ -651,6 +652,8 @@ export default {
EventBus.$on('updateFlagAdaB', data => { this.FlagAdaB = data })
EventBus.$on('updateFlagGradB', data => { this.FlagGradB = data })
EventBus.$on('flagBrushedAll', data => { this.FlagBrushAll = data })
EventBus.$on('updateFlagKNN', this.overview)
EventBus.$on('updateFlagSVC', this.overview)
EventBus.$on('updateFlagGausNB', this.overview)

@ -0,0 +1,29 @@
<template>
<button style="floatfloat: right;"
id="ResetClass"
v-on:click="resetClass">
<font-awesome-icon icon="sync-alt" />
{{ valueResetC }}
</button>
</template>
<script>
import { EventBus } from '../main.js'
export default {
name: 'ResetClass',
data () {
return {
valueResetC: 'Reset Class Optimization'
}
},
methods: {
resetClass () {
EventBus.$emit('clearPCP')
EventBus.$emit('alternateFlagLock')
EventBus.$emit('boxplotCall', true)
}
}
}
</script>

@ -6,10 +6,10 @@ import 'bootstrap-vue/dist/bootstrap-vue.css'
import router from './router'
import { library } from '@fortawesome/fontawesome-svg-core'
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
import { faUpload, faPlay, faCheck, faSave, faTrash, faPlus, faBalanceScale, faMinus, faEraser, faClone, faObjectGroup, faUndo } from '@fortawesome/free-solid-svg-icons'
import { faUpload, faPlay, faCheck, faSave, faTrash, faPlus, faBalanceScale, faMinus, faEraser, faClone, faObjectGroup, faUndo, faSyncAlt } from '@fortawesome/free-solid-svg-icons'
import bFormSlider from 'vue-bootstrap-slider'
library.add(faUpload, faPlay, faCheck, faSave, faTrash, faPlus, faBalanceScale, faMinus, faEraser, faClone, faObjectGroup, faUndo)
library.add(faUpload, faPlay, faCheck, faSave, faTrash, faPlus, faBalanceScale, faMinus, faEraser, faClone, faObjectGroup, faUndo, faSyncAlt)
Vue.component('font-awesome-icon', FontAwesomeIcon)

Loading…
Cancel
Save