Created
November 8, 2023 11:07
-
-
Save cbaragao/1101753a5fb3c169a8808469776d6348 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// white wine dataset used from http://archive.ics.uci.edu/dataset/186/wine+quality | |
{ | |
"data": { | |
"name": "dataset" | |
}, | |
"params": [ | |
{ | |
"name": "grid", | |
"select": "interval", | |
"bind": "scales" | |
} | |
], | |
"hconcat": [ | |
{ | |
"vconcat": [ | |
{ | |
"mark": "bar", | |
"height": 100, | |
"width": 400, | |
"encoding": { | |
"x": { | |
"bin": true, | |
"field": "Fixed Acidity", | |
"axis": null | |
}, | |
"y": { | |
"aggregate": "count", | |
"axis": null | |
}, | |
"yOffset": { | |
"field": "Fixed Acidity" | |
} | |
} | |
}, | |
{ | |
"mark": "circle", | |
"height": 400, | |
"width": 400, | |
"encoding": { | |
"x": { | |
"field": "Fixed Acidity", | |
"type": "quantitative", | |
"scale": { | |
"domain": [ | |
1, | |
15 | |
] | |
} | |
}, | |
"y": { | |
"field": "Alcohol", | |
"type": "quantitative", | |
"scale": { | |
"domain": [ | |
5, | |
15 | |
] | |
} | |
}, | |
"size": { | |
"field": "Quality", | |
"type": "quantitative" | |
} | |
} | |
} | |
] | |
}, | |
{ | |
"vconcat": [ | |
{ | |
"mark": "text", | |
"height": 150, | |
"width": 150 | |
}, | |
{ | |
"mark": "bar", | |
"height": 250, | |
"width": 150, | |
"encoding": { | |
"y": { | |
"bin": true, | |
"field": "Alcohol", | |
"axis": null | |
}, | |
"x": { | |
"aggregate": "count", | |
"axis": null | |
}, | |
"xOffset": { | |
"field": "Alcohol" | |
} | |
} | |
} | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment