indiquer le % sur chaque barre de l'histogramme - Follow Up Deployment
Browse filesFiles changed (2)
- index.html+50-6
- prompts.txt+3-1
615 unmodified lines6166176186196206216226236246256266276286296306316326336346356366376386396406416426435 unmodified lines64965065165265365465525 unmodified lines681682683684685686615 unmodified lines})).sort((a, b) => b.score - a.score);window.evolutionChart = new Chart(ctx, {type: 'bar',data: {labels: sortedBlocks.map(block => block.name),datasets: [{label: 'Score cumulé des rangs',data: sortedBlocks.map(block => block.score),backgroundColor: sortedBlocks.map(block => block.barColor),borderColor: sortedBlocks.map(block => block.barColor.replace('bg-', 'border-')),borderWidth: 1}]},options: {indexAxis: 'y',responsive: true,maintainAspectRatio: false,scales: {x: {beginAtZero: true,title: {display: true,text: 'Score pondéré',font: {size: 14,weight: 'bold'5 unmodified lines}}},y: {title: {display: true,text: 'Blocs',25 unmodified lines},legend: {display: false}},layout: {615 unmodified lines6166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836845 unmodified lines69069169269369469569625 unmodified lines722723724725726727728729730615 unmodified lines})).sort((a, b) => b.score - a.score);// Calculate percentages instead of raw scoresconst totalScore = sortedBlocks.reduce((sum, block) => sum + block.score, 0);const percentages = sortedBlocks.map(block => Math.round((block.score / totalScore) * 100));window.evolutionChart = new Chart(ctx, {type: 'bar',data: {labels: sortedBlocks.map(block => block.name),datasets: [{label: 'Répartition des priorités (%)',data: percentages,backgroundColor: sortedBlocks.map(block => block.barColor),borderColor: sortedBlocks.map(block => block.barColor.replace('bg-', 'border-')),borderWidth: 1}]},plugins: [{id: 'percentageLabels',afterDatasetsDraw(chart, args, options) {const {ctx, data, chartArea: {top, bottom, left, right, width, height}, scales: {x, y}} = chart;ctx.font = 'bold 12px sans-serif';ctx.textAlign = 'center';ctx.textBaseline = 'middle';data.datasets.forEach((dataset, i) => {chart.getDatasetMeta(i).data.forEach((bar, index) => {const value = dataset.data[index];ctx.fillStyle = '#000';ctx.fillText(`${value}%`, bar.x, bar.y - 10);});});}}],options: {indexAxis: 'x',responsive: true,maintainAspectRatio: false,animation: {onComplete: function() {const chart = this;const ctx = chart.ctx;ctx.font = 'bold 12px sans-serif';ctx.textAlign = 'center';ctx.textBaseline = 'middle';this.data.datasets.forEach((dataset, i) => {const meta = chart.getDatasetMeta(i);meta.data.forEach((bar, index) => {const data = dataset.data[index];ctx.fillStyle = '#000';ctx.fillText(`${data}%`, bar.x, bar.y - 10);});});}},scales: {y: {beginAtZero: true,max: 100,title: {display: true,text: 'Pourcentage (%)',font: {size: 14,weight: 'bold'5 unmodified lines}}},x: {title: {display: true,text: 'Blocs',25 unmodified lines},legend: {display: false},datalabels: {display: false}},layout: {
45 unmodified lines4647484945 unmodified linesle graphique doit être de type Streamgraph ou area chart empilé ordonné par rangle graphe doit être Heatmap de rangsle graphique doit représenter sous forme d'histogramme horizontal le score cumulé des rangs du classement des diverses semainesle score doit être le plus grand pour le rang le plus proche de 1. la représentations graphique doit être en couleur et plus grande45 unmodified lines46474849505145 unmodified linesle graphique doit être de type Streamgraph ou area chart empilé ordonné par rangle graphe doit être Heatmap de rangsle graphique doit représenter sous forme d'histogramme horizontal le score cumulé des rangs du classement des diverses semainesle score doit être le plus grand pour le rang le plus proche de 1. la représentations graphique doit être en couleur et plus grandele graphique doit nommer tous les bloques sur l'axe des x. Les barres doivent être proportionnées sur 100%indiquer le % sur chaque barre de l'histogramme
index.html+50-6
prompts.txt+3-1