[O] Make bar graph vertical

This commit is contained in:
Hykilpikonna
2019-09-29 17:31:29 -04:00
parent d8f276005d
commit a9a9cf5f11
@@ -30,14 +30,13 @@ export default class GraphAverage extends Vue
// X axis represents course names // X axis represents course names
xAxis: xAxis:
{ {
type: 'value' type: 'category',
}, },
// Y axis represents GPAs and MaxGPAs // Y axis represents GPAs and MaxGPAs
yAxis: yAxis:
{ {
type: 'category', type: 'value'
data: this.courses.map(course => course.name)
}, },
// Data // Data
@@ -47,16 +46,16 @@ export default class GraphAverage extends Vue
type: 'bar', type: 'bar',
encode: encode:
{ {
x: 1, x: 0,
y: 0 y: 1
} }
}, },
{ {
type: 'bar', type: 'bar',
encode: encode:
{ {
x: 2, x: 0,
y: 0 y: 2
} }
} }
] ]