[R] Error in axis ????

Uwe Ligges ligges at statistik.tu-dortmund.de
Thu Nov 10 11:06:48 CET 2011


This is plot.xts that generates the error. Argument col seems to be 
unsuppotred. Please ask the package maintainer or send patches to 
improve the xts package.

Uwe Ligges


On 10.11.2011 04:38, eric wrote:
> Recently updated my packages (update.packages() and also updated rstudio to
> the latest version. Had some problems but I thought I was able to get around
> them by moving my folders. However, now I'm seeing a bit of a snag with some
> code that previously ran fine.  Hoping someone can suggest a fix. Here's the
> screen output:
>
> require(quantmod)
> Loading required package: quantmod
> Loading required package: Defaults
> Loading required package: xts
> Loading required package: zoo
>
> Attaching package: ‘zoo’
>
> The following object(s) are masked from ‘package:base’:
>
>      as.Date, as.Date.numeric
>
> Loading required package: TTR
>
>> require(rdatamarket)
> Loading required package: rdatamarket
>
>> g
>> <-dmlist("http://datamarket.com/data/set/1jz5/st-louis-financial-stress-index#display=line&ds=1jz5")
>> g$Date<-as.Date(g[,1], "%Y-%m-%d")
>> h<-as.xts(g, order.by=g[,1])
>> j<-h[,2]
>> s<-getSymbols('^GSPC', from="1990-01-01", to=Sys.Date())
>> s<-to.weekly(GSPC)
>> s<-s[,6]
>> x<-na.omit(merge(s,j)) ; names(x)<-c("sp","stress")
>> print(head(x))
>                 sp stress
> 1993-12-31 466.45 -0.453
> 1994-01-07 469.90 -0.442
> 1994-01-14 474.91 -0.435
> 1994-01-21 474.72 -0.449
> 1994-01-28 478.70 -0.462
> 1994-02-04 469.81 -0.513
>> par(mfrow=c(2,1))
>> plot(x[,1]/400, ylim=c(-1,5), col="blue")
> Error in axis(1, at = xycoords$x, labels = FALSE, col = "#BBBBBB", ...) :
>    formal argument "col" matched by multiple actual arguments
>> lines(x[,2], col="red")
>> ccf(drop(x[,1]), drop(x[,2]))
>
>
>
> --
> View this message in context: http://r.789695.n4.nabble.com/Error-in-axis-tp4022364p4022364.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list