I have a data frame as shown below
product bought_date Monthly_profit Average_discout
A 2016 85000000 5
A 2017 55000000 5.6
A 2018 45000000 10
A 2019 35000000 9.8
B 2016 75000000 5
B 2017 55000000 4.6
B 2018 75000000 11
B 2019 45000000 9.8
C 2016 95000000 5.3
C 2017 55000000 5.1
C 2018 50000000 10.2
C 2019 45000000 9.8
From the above I would like to plot 3 subplots.
one for product A, B and C.
In each subplot there should be 3 line plot, where
X axis = bought_date
Y axis1 = Monthly_profit
Y axis2 = Average_discout
I tried below code.
sns.set(style = 'darkgrid')
sns.lineplot(x = 'bought_date', y = 'Monthly_profit', style = 'product',
data = df1, markers = True, ci = 68, err_style='bars')