全部版块 我的主页
论坛 数据科学与人工智能 数据分析与数据科学 R语言论坛
9851 8
2011-12-13
decompose()中type参数为additive时,季节指数是怎么计算的啊?我只知道长期趋势是移动平均得到的。
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2011-12-13 22:44:39
或者帮我看看后面两句话什么意思吧,就可以操作了
The function first determines the trend component using a moving average (if filter is NULL, a symmetric window with equal weights is used), and removes it from the time series. Then, the seasonal figure is computed by averaging, for each time unit, over all periods. The seasonal figure is then centered.
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-25 14:32:06
You have to apply centered moving average of order 12 (if monthly data) or 4 (if quarterly date) to get the trend-cycle pattern. Subtract the trend-cycle from the original data, the rest is seasoal component and irregular component. Seasonal component is the average of monthly data. For example, your data is a monthly one from 2009 to 2011, then the seasonal index for January is the average of January 2009, January 2010 and January 2011.
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-25 15:24:28
waterhorse 发表于 2011-12-25 14:32
You have to apply centered moving average of order 12 (if monthly data) or 4 (if quarterly date) to  ...
Thx,I have solved successfully thorough several attempt.
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-27 01:11:12
楼主是不是学Introductory time series with R呢?我也遇到了这个问题,按照3楼的说法好像也没解决,因为趋势项前后有缺失啊,比如月度数据,前6项与最后6项在求平均的时候缺失了。那么在求季节效应的时候用原来序列减去趋势项,缺失项怎么办?
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-27 05:13:44
zippo414 发表于 2011-12-27 01:11
楼主是不是学Introductory time series with R呢?我也遇到了这个问题,按照3楼的说法好像也没解决,因为趋 ...
Ignore 缺失项, unless your time series is too short.
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

点击查看更多内容…
相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群