I have the following data set that I would like to plot: column growth rate is in % meaning 0.01 = 1%
month country growth_rate 2018-01 DE 0.01 2018-02 DE 0.05 2018-03 DE 0.07 2018-01 IN 0.01 2019-02 IN 325.01 2019-03 IN 0.05
Now I will plot the above data with the following code : sns.lineplot(data=df, x="month", y="growth_rate", hue="country") But the chart I am getting is too skewed for the country IN as one of the values is too huge- 325.01 and the rest of the values are suppressed by that and not shown correctly on the trend
sns.lineplot(data=df, x="month", y="growth_rate", hue="country")
What is the best way to treat this? Can I scale down somehow to still show the impact of that huge growth and also show the trend of other values in the data frame?
How about setting a log scale on the y-axis?
fig, ax = plt.subplots() ax.set(yscale="log") sns.lineplot(data=df, x="month", y="growth_rate", ax = ax, hue="country")
2.1m questions
2.1m answers
60 comments
57.0k users