Performs the Portmanteau test to assess the Null Hypothesis of Independence in a Time Series
diag_portmanteau_(x, order = NULL, stop_lag = 20, stdres = FALSE,
test = "Ljung-Box", plot = TRUE)
An arima
or data set.
An integer
indicating the degrees of freedom. If `x` is
not a series of residuals, then set equal to 0.
An integer
indicating the length of lags that should
be calculated.
A boolean
indicating whether to standardize the
residualizes (e.g. \(res/sd(res)\)) or not.
A string
indicating whether to perform Ljung-Box test or
Box-Pierce test.
A logical. If TRUE
(the default) a plot should be produced.