diff --git a/core/AlgorithmAnalyzer.js b/core/AlgorithmAnalyzer.js index dac9c03..71f7a96 100644 --- a/core/AlgorithmAnalyzer.js +++ b/core/AlgorithmAnalyzer.js @@ -1,5 +1,5 @@ import ArrayGen from "../utils/ArrayGen.js"; -import genGraphic from "../utils/genGraphic.js"; +import genGraphic from "../utils/GenGraphic.js"; import ProgressManager from "../utils/ProgressManager.js"; import genLoadBalance from "../utils/genLoadBalance.js"; @@ -69,9 +69,9 @@ export default class AlgorithmAnalyzer { }); // Generate Results and Save Images - genGraphic(randomData, xAxisLabels, "random-scenario-comparison"); - genGraphic(increasingData, xAxisLabels, "increasing-scenario-comparison"); - genGraphic(decreasingData, xAxisLabels, "decreasing-scenario-comparison"); + genGraphic(randomData, xAxisLabels, ["random-scenario-comparison", "Cenario de numeros aleatorios"]); + genGraphic(increasingData, xAxisLabels, ["increasing-scenario-comparison", "Cenario de numeros crescentes"]); + genGraphic(decreasingData, xAxisLabels, ["decreasing-scenario-comparison", "Cenario de numeros decrescentes"]); this.progressManager.updateProgress(); } diff --git a/simulation-config.json b/simulation-config.json index 940ef4f..6ea2548 100644 --- a/simulation-config.json +++ b/simulation-config.json @@ -6,12 +6,7 @@ "vector": [ 100, 1000, - 5000, - 30000, - 50000, - 100000, - 150000, - 200000 + 5000 ], "balanceType": "preSelected", "algorithms": [ diff --git a/utils/GenGraphic.js b/utils/GenGraphic.js index 603eda5..896cb1c 100644 --- a/utils/GenGraphic.js +++ b/utils/GenGraphic.js @@ -22,7 +22,7 @@ export default (data, labels, graphName) => { y: { suggestedMin: 0, suggestedMax: 100, - max: 150, + max: 1000, ticks: { callback: function (value) { return value + " ms"; @@ -39,7 +39,7 @@ export default (data, labels, graphName) => { }, title: { display: true, - text: "Sorting Algorithms Comparison", + text: graphName[1], }, }, }, @@ -50,7 +50,7 @@ export default (data, labels, graphName) => { mkdirSync(resultDir); } - const outputPath = `${resultDir}/${graphName}.png`; + const outputPath = `${resultDir}/${graphName[0]}.png`; const out = createWriteStream(outputPath); const stream = canvas.createPNGStream(); stream.pipe(out);