如何找出由ggplot的stat_smooth()拟合的线性回归线的斜率?

时间:2017-03-22 16:35:52

标签: r ggplot2

我使用ggplot制作了一个情节,其中包含以下代码:

ggplot(tb_us, aes(year_new, count)) + 
  geom_point() + 
  stat_smooth(method = 'lm')

情节如下: enter image description here

这一切都很好。但我也有兴趣找出这条线性拟合线的斜率。我怎样才能做到这一点?感谢

0 个答案:

没有答案