I would like to create a stacked bar chart showing for each Day_Since_Acquisition
the number of Total_Customers
for each Aquisition_Channel
.
I am having issues creating a stacked bar plot out of this df that show on the X-axis on the values for Day_Since_Acquisition
and nothing in between.
DF
Aquisition_Channel Day_Since_Acquisition Total_Customers
Digital 7 10
Digital 14 12
Digital 21 16
Digital 28 20
Organic 7 32
Organic 14 40
Organic 21 41
Organic 28 45
Offline 7 23
Offline 14 30
Offline 21 46
Offline 28 55
This is my current code:
fig = px.bar(df, x="Day_Since_Acquisition", y="Total_Customers",
color="Day_Since_Acquisition", barmode = 'stack')
fig.show()