楼主: wudechao06
22533 8

R语言实现LM检验并举例 [推广有奖]

  • 0关注
  • 0粉丝

已卖:4份资源

大专生

53%

还不是VIP/贵宾

-

威望
0
论坛币
4277 个
通用积分
0
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
362 点
帖子
45
精华
0
在线时间
63 小时
注册时间
2010-11-24
最后登录
2015-5-24

楼主
wudechao06 发表于 2010-12-7 10:58:07 |AI写论文
140论坛币
R语言实现LM检验

关键词:lm检验 R语言 检验 语言 举例

沙发
qoiqpwqr 发表于 2010-12-8 00:03:15
arch {vars}R Documentation
ARCH-LM testDescriptionThis function computes univariate and multivariate ARCH-LM tests for aVAR(p).
Usagearch(x, lags.single = 16, lags.multi = 5, multivariate.only = TRUE)
Arguments
xObject of class ‘varest’; generated byVAR(), or an object of class ‘vec2var’; generated byvec2var().
lags.singleAn integer specifying the lags to be used for theunivariate ARCH statistics.
lags.multiAn integer specifying the lags to be used for themultivariate ARCH statistic.
multivariate.onlyIf TRUE (the default), onlythe multivariate test statistic is computed.
DetailsThe multivariate ARCH-LM test is based on the following regression(the univariate test can be considered as special case of theexhibtion below and is skipped):

vech(hat{u}_t hat{u}_t') = β_0 + B_1vech(hat{u}_{t-1} hat{u}_{t-1}') + ... + B_qvech(hat{u}_{t-q} hat{u}_{t-q}' + v_t)

whereby v_t assigns a spherical error process andvech is the column-stacking operator for symmetric matricesthat stacks the columns from the main diagonal on downwards. Thedimension of β_0 is frac{1}{2}K(K +1) and forthe coefficient matrices B_i with i=1, ..., q,frac{1}{2}K(K +1) times frac{1}{2}K(K +1). The nullhypothesis is: H_0 := B_1 = B_2 = ... = B_q = 0 and thealternative is: H_1: B_1 neq 0 or B_2 neq 0 or ... B_q  neq0.The test statistic is:

VARCH_{LM}(q) = frac{1}{2}T K (K + 1)R_m^2 quad ,

with

R_m^2 = 1 - frac{2}{K(K+1)}tr(hat{Omega} hat{Omega}_0^{-1})quad ,

and hat{Omega} assigns the covariance matrix of the abovedefined regression model. This test statistic is distributed aschi^2(qK^2(K+1)^2/4).
ValueA list with class attribute ‘varcheck’ holding thefollowing elements:

residA matrix with the residuals of the VAR.
arch.uniA list with objects of class ‘htest’containing the univariate ARCH-LM tests per equation. This elementis only returned if multivariate.only = FALSE is set.
arch.mulAn object with class attribute ‘htest’containing the multivariate ARCH-LM statistic.
Author(s)Bernhard Pfaff
ReferencesDoornik, J. A. and D. F. Hendry (1997), Modelling DynamicSystems Using PcFiml 9.0 for Windows, International ThomsonBusiness Press, London.
Engle, R. F. (1982), Autoregressive conditional heteroscedasticitywith estimates of the variance of United Kingdom inflation,Econometrica, 50: 987-1007.
Hamilton, J. (1994), Time Series Analysis, PrincetonUniversity Press, Princeton.
L
已有 1 人评分论坛币 收起 理由
admin_kefu + 30 热心帮助其他会员

总评分: 论坛币 + 30   查看全部评分

藤椅
trier2006 发表于 2010-12-8 09:24:51
这个。。。楼上的基本就是抄help吧,呵呵
最好的医生是自己,最好的药物是时间……

板凳
qoiqpwqr 发表于 2010-12-8 21:28:09
是啊,不过不是基本抄,简直就是完全的复制粘贴.希望能有帮助,钱是不要的.

报纸
Sunshine飞鸟 学生认证  发表于 2015-9-15 22:10:33
用专门做金融时间序列的FinTS包,其中ArchTest()函数就是用来做Arch LM检验的
例子:
dat <- ArchTest(x, lags=12, demean = FALSE)
参数解释:
x                numeric vector  #数值型向量
lags                positive integer number of lags #滞后阶数
demean        logical: If TRUE, remove the mean before computing the test statistic. #是否做中心化处理
可以参考蔡瑞胸的金融时间序列分析一书哦~
已有 1 人评分论坛币 收起 理由
admin_kefu + 20 热心帮助其他会员

总评分: 论坛币 + 20   查看全部评分

地板
蜗牛斌 学生认证  发表于 2017-3-20 08:52:13
Sunshine飞鸟 发表于 2015-9-15 22:10
用专门做金融时间序列的FinTS包,其中ArchTest()函数就是用来做Arch LM检验的
例子:
dat
那你说的,对面板数据怎么检验啊?解释变量有四五个呢

7
晓风易幻 发表于 2017-9-7 18:05:17
Sunshine飞鸟 发表于 2015-9-15 22:10
用专门做金融时间序列的FinTS包,其中ArchTest()函数就是用来做Arch LM检验的
例子:
dat
您好,为什么我安装FinTS包是说不存在这个包

8
屋檐滴语 发表于 2017-12-18 00:54:26
晓风易幻 发表于 2017-9-7 18:05
您好,为什么我安装FinTS包是说不存在这个包
这个包确实不支持R 的新版本

9
淅沥小雨 发表于 2018-4-18 20:57:49
屋檐滴语 发表于 2017-12-18 00:54
这个包确实不支持R 的新版本
那还有什么别的方法呢?

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注cda
拉您进交流群
GMT+8, 2025-12-22 04:27