从ACF相关图中提取置信区间值 [英] Extract confidence interval values from ACF correlogram

查看:49
本文介绍了从ACF相关图中提取置信区间值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在R中,我们可以运行时间序列的ACF相关图,并且置信区间带将以浅蓝色绘制.但是,当我提取ACF对象的结构时,找不到这些值.有谁知道如何提取置信区间带的值?

In R, we can run an ACF correlogram of time series and the confidence interval bands will be plotted in light blue. But when I pull the structure of ACF object, I cannot find these values. Does anyone know how to extract the values of the confidence interval bands?

例如

List of 6
 $ acf   : num [1:27, 1, 1] 1 0.06453 -0.06354 0.00213 -0.01324 ...
 $ type  : chr "correlation"
 $ n.used: int 501
 $ lag   : num [1:27, 1, 1] 0 1 2 3 4 5 6 7 8 9 ...
 $ series: chr "tser[i:(i + 500)]"
 $ snames: NULL
 - attr(*, "class")= chr "acf"

推荐答案

我看过该函数,但找不到一种简单的方法来提取置信区间.该区域是在 plot.acf 函数中计算的.要查看此功能,请使用

I've had a look at the function and I can't see an easy way to extract the confidence interval. The region is calculated in the plot.acf function. To see this function, use

getS3method("plot", "acf")

此函数中有一个变量 clim ,这是您要使用的变量.最简单的方法是将 plot.acf 复制到 myplot.acf ,但是返回 clim 值.

In this function, there is a variable clim, this is the one you are after. The easiest way is to copy plot.acf to myplot.acf, but return the clim value.

这篇关于从ACF相关图中提取置信区间值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆