For this question, I was provided the following information.

Data in code form:
order_data = {'Alice': {5: 'chocolate'},
'Bob': {9: 'vanilla'},
'Clair': {7: 'strawberry'},
'Drake': {10: 'chocolate' },
'Emma': {82: 'vanilla'},
'Alice': {70: 'strawberry'},
'Emma': {42: 'chocolate'},
'Ginger': {64: 'strawberry'} }
I was asked to make a bar graph detailing this data. The bar graph and the code used to make it using Altair is provided below.
import altair
data = altair.Data(customer=['Alice', 'Bob', 'Claire', 'Drake', 'Emma','Alice', 'Emma', 'Ginger'],
cakes=[5,9,7,10,82,70,42,64],
flavor=['chocolate', 'vanilla', 'strawberry','chocolate','vanilla','strawberry','chocolate','strawberry'])
chart = altair.Chart(data)
mark = chart.mark_bar()
enc = mark.encode(x='customer:N',y='cakes',color='flavor:N')
enc.display()
My question is: What is the best way to go about constructing this graph using matplotlib?
I know this isn't an unusual graph per say but it is unusual in the sense that I have not found any replications of this kind of graph. Thank you!



