ACF Plot with ggplot2: Setting width of geom_bar

前端 未结 4 1017
时光说笑
时光说笑 2021-02-18 23:25

With acf we can make ACF plot in base R graph.

x <- lh
acf(x)

4条回答
  •  甜味超标
    2021-02-19 00:08

    From the forecast package comes a function ggtsdisplay that plots both ACF and PACF with ggplot. x is the residuals from the model fit (fit$residuals).

    forecast::ggtsdisplay(x,lag.max=30)
    

提交回复
热议问题