楼主: anthust
2453 2

请教一个问题 [推广有奖]

  • 0关注
  • 14粉丝

擎天柱

已卖:14724份资源

讲师

44%

还不是VIP/贵宾

-

威望
0
论坛币
56917 个
通用积分
37.1167
学术水平
71 点
热心指数
66 点
信用等级
47 点
经验
18300 点
帖子
315
精华
2
在线时间
360 小时
注册时间
2005-11-5
最后登录
2022-2-25

楼主
anthust 发表于 2007-8-17 15:42:00 |AI写论文

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币

R里面的mcmc包可以做时间序列的问题么?

非常感谢!

二维码

扫码加我 拉你入群

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

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

关键词:mcmc 时间序列 非常感谢 CMC 请教

沙发
amoybc 发表于 2007-8-17 18:36:00
可以。不过取决于你使用什么模型
Believe what you find it reasonable to believe

藤椅
DM小菜鸟 发表于 2014-12-28 22:01:43

一般不用这个包做时间序列

  

时间序列常用的包见:http://www.zhihu.com/question/23117581

   

例子——


install.packages("astsa") # install it ... you'll be asked to choose the closest CRAN mirror
require(astsa)            # then load it (has to be done at the start of each session)


data(jj)  # load the data - you don't have to do this anymore with astsa, but you do in general
jj        # print it to the screen
ls()         # list your objects
rm(worry)    # remove your worry object
jj[1]       # the first element
jj[84]      # the last element
jj[1:4]     # the first 4 elements
jj[-(1:80)] # everything EXCEPT the first 80 elements
length(jj)  # the number of elements
dim(jj)     # but no dimensions ...
nrow(jj)    # ... no rows
ncol(jj)    # ... and no columns


#-- if you want it to be a column vector (in R, a matrix), an easy way to go is:
jjm = as.matrix(jj)
dim(jjm)   
options(digits=2)  # the default is 7, but it's more than I want now
options           # to see your options (it's the help file)
rnorm             # we're using it on the next line
(zardoz = ts(rnorm(48), start=c(2293,6), frequency=12))


# use window() if you want a part of a ts object
(oz = window(zardoz, start=2293, end=c(2295,12)))
time(jj)   
cycle(jj)  
plot(jj, ylab="Earnings per Share", main="J & J")   

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

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