#Einlesen der FTAPrice Daten von Jan 1965 bis Dez 1965 #Mills ',p.328 #Bilden von Differenzen und Returns # R: text( ) nicht ausserhalb des Plot-Rahmens FTA<- scan("FTAPrice.dat") Time<- 1:371 # Werte des 371 x 1 Datenvektors Time length(FTA); mean(FTA); sqrt(var(FTA)) postscript(file="FTAmo.ps",height=16,width=10,horizontal=F) par(mfrow=c(3,1)) plot(Time,FTA,type="l",lty=1,xlim=c(0,400),ylim=c(0,2000), xlab="Month, from Jan 1965",ylab="FTA All Shares Price Index",cex=0.55) title(main="FT Actuaries All Shares, Monthly, Jan 1965 - Dec 1995",cex=0.8) segments(0,-300,0,-20); segments(371,-300,371,-20) text(0,-400,"Jan '65",cex=0.55); text(371,-400,"Dez '95",cex=0.55) FTAt<- FTA[2:371]; FTAtm<- FTA[1:370] FTADif<- FTAt - FTAtm mean(FTADif); sqrt(var(FTADif)) plot(Time[1:370],FTADif,type="l",lty=1,xlim=c(0,400),ylim=c(-100,100), xlab="Month, from Jan 1965",ylab="FTA AllShares Differences",cex=0.55) abline(h=0,lty=2) segments(0,-130,0,-100); segments(371,-130,371,-100) text(0,-140,"Jan '65",cex=0.55); text(371,-140,"Dez '95",cex=0.55) FTARet<- FTADif/FTAtm mean(FTARet); sqrt(var(FTARet)) plot(Time[1:370],FTARet,type="l",lty=1,xlim=c(0,400),ylim=c(-0.5,0.5), xlab="Month, from Jan 1965",ylab="FTA AllShares Returns",cex=0.55) abline(h=0,lty=2) segments(0,-0.6,0,-0.50); segments(371,-0.6,371,-0.50) text(0,-0.69,"Jan '65",cex=0.55); text(371,-0.69,"Dez '95",cex=0.55) dev.off() rm(FTA,FTAt,FTAtm,FTADif,FTARet,Time)