Le 24. 01. 11 18:22, Gabor Grothendieck a écrit :
On Mon, Jan 24, 2011 at 12:07 PM, Matthieu Stigler
<matthieu.stig...@gmail.com>  wrote:
hi

I am seeing a strange behavior I can't understand... doing:

source("/tmp/RFile.r",echo=TRUE)
Error in rep.int(c(prompt.echo, continue.echo), c(leading, length(dep) -  :
  invalid 'times' value
traceback()
3: rep.int(c(prompt.echo, continue.echo), c(leading, length(dep) -
       leading))
2: paste(rep.int(c(prompt.echo, continue.echo), c(leading, length(dep) -
       leading)), dep, sep = "", collapse = "\n")
1: source("/tmp/RFile.r", echo = TRUE)>>

But the file I am trying to source is very simple... see:
$ more /tmp/RFile.r
###################################################
### chunk number 1:
###################################################
#line 516 "VolStocksDec2010.Rnw"
path<-"~/Dropbox/FAO/Papers/Volatility only"
pathMarkov<-"~/Dropbox/FAO/Markov Model/"
library(zoo)

Any idea where it can come from? It works fine when echo=FALSE... I am using
R 2.12, on Ubuntu Linux 10.4 (R from CRAN), full session info below. Should
I rather send this to r-devel?

Does this work?

source("/tmp/RFile.r", echo = TRUE, prompt.echo = NULL, continue.echo = "+ ")


Thanks for your quick answer!
Unfortunately, it does not change:
source("/tmp/RFile.r", echo = TRUE, prompt.echo = NULL, continue.echo = "+ ")
Error in rep.int(c(prompt.echo, continue.echo), c(leading, length(dep) -  :
  invalid 'times' value
> traceback()
3: rep.int(c(prompt.echo, continue.echo), c(leading, length(dep) -
       leading))
2: paste(rep.int(c(prompt.echo, continue.echo), c(leading, length(dep) -
       leading)), dep, sep = "", collapse = "\n")
1: source("/tmp/RFile.r", echo = TRUE, prompt.echo = NULL, continue.echo = "+ ")

note this is not a systematic problem, but can't say exactly when/why it works or not...

thanks

______________________________________________
R-help@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.

Reply via email to