因为我新建数据后,不能读出例子中sp.raw原来的效果,比如S&P500指数收盘价的时间序列图老是出不来,请高手帮忙。
正确的原程序如下,
# motivating example of extreme value theory
#
# create percentage return data
spto87 = getReturns(sp.raw,type="discrete",percentage=T)
par(mfrow=c(2,1))
plot(sp.raw,main="Daily Closing Prices")
plot(spto87,main="Daily Percentage Returns")
par(mfrow=c(1,1))