Skip to content

Commit

Permalink
Update chart_1.html
Browse files Browse the repository at this point in the history
  • Loading branch information
LiesIsLeuk authored Nov 30, 2023
1 parent 1498487 commit 406367d
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions layouts/shortcodes/chart_1.html
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ <h3>
(e) => {return e[1]['per_subject']}
);

var heldoutResults = items.map(
(e) => {return e[1]['per_subject']}
);

console.log(withinResults);


Expand Down Expand Up @@ -122,20 +126,28 @@ <h3>
};
new Chart(ctx, options);


const boxplotData = {
const boxplotData = {
// define label tree
labels: groupNames.slice(10),
datasets: [{
label: 'Test set: held-out subjects',
label: 'Test set ',
backgroundColor: 'rgba(255,0,0,0.5)',
borderColor: 'red',
borderWidth: 1,
outlierColor: 'rgba(255,0,0,0.5)',
padding: 10,
itemRadius: 0,
data: withinResults.slice(10)
},]
}, {
label: 'Test set',
backgroundColor: 'rgba(0,0,255,0.5)',
borderColor: 'blue',
borderWidth: 1,
outlierColor: 'rgba(0,0,255,0.5)',
padding: 10,
itemRadius: 0,
data:heldoutResults.slice(10)
}]
};
var ctx = document.getElementById("canvas").getContext("2d");
new Chart(ctx, {
Expand Down Expand Up @@ -173,7 +185,6 @@ <h3>
}
});


// data for table with all results
const tmpUrl2 = "../scores_task1_means.json";
const data_table = await (await fetch(tmpUrl2)).json();
Expand Down

0 comments on commit 406367d

Please sign in to comment.