Re: [R] dev.print

2004-03-27 Thread Prof Brian Ripley
dev.print is designed for *print* devices which compute sizes in inches. The help says 'dev.print' is most useful for producing a postscript print (its default) when the following applies. Unless 'file' is specified, the plot will be printed. Unless 'width', 'height' and

[R] par(yaxp) linear versus log tick mark coordinates

2004-03-27 Thread Al Piszcz
As a linear axis I obtain the correct number of intervals for the tick marks. source(test-lin.r) par(yaxp) [1] 0 2 4 However log returns 1? source(test-log.r) par(yaxp) [1] 1 1 1 I'll use log10(par(yaxp)[2]) for now. I was wondering why '1' is returned instead

Re: [R] a question about scoping functions

2004-03-27 Thread Duncan Murdoch
On Fri, 26 Mar 2004 21:28:08 -0500, Rajarshi Guha [EMAIL PROTECTED] wrote : Is there anyway to take the functions helper1 and helper2 outside func (but in the same file) yet keep them from showing up in the global namespace when the source file for func() is loaded? A simpler (but slightly less

RE: [R] stop() vs. error() ?

2004-03-27 Thread Liaw, Andy
[I don't see any reason to keep this off-list. Apology to those bored by this thread.] From: Andrew Robinson [mailto:[EMAIL PROTECTED] On Friday 26 March 2004 18:43, you wrote: OK, I guess I'm dense (again?)... I ain't kidding! Stop where, and do what? Stop where the condition is

[R] availability of version 1.9.0?

2004-03-27 Thread Erin Hodgess
Dear R People: When will version 1.9 (for Windows) be ready, please? My reason for asking: there is an interesting library from Bioconductor called tkWidgets. However, it will only work with version 1.9.0 or higher. Are there ways around this, or should I just be patient? Thanks so much in

[R] building a list in loop

2004-03-27 Thread Fred J.
Hello getdata - function(p){ fname - NULL; dl - list()#build the sturcture builddl - function(q,s){ fname - c(fname,s) #where s is a string dl - list( dl, dt2) } list(names = fname, data = dl) } data - getdata(c:\somepath) data $names [1] fname $data $data[[1]] --- since there is no

Re: [R] availability of version 1.9.0?

2004-03-27 Thread Jeff Gentry
When will version 1.9 (for Windows) be ready, please? You can download the beta version at http://cran.r-project.org/bin/windows/base/rdevel.html My reason for asking: there is an interesting library from Bioconductor called tkWidgets. However, it will only work with version 1.9.0 or

Re: [R] stop() vs. error() ?

2004-03-27 Thread ivo welch
hi andy: mea culpa. it is the exit function in most other languages. It would be exit(0) invocation in C (C++) and perl, for example. regards, /iaw Liaw, Andy wrote: So you still have not told us what exactly what you are looking for. What do you want some sort of stop() to do inside a

Re: [R] building a list in loop

2004-03-27 Thread Uwe Ligges
Fred J. wrote: Hello getdata - function(p){ fname - NULL; dl - list()#build the sturcture builddl - function(q,s){ fname - c(fname,s) #where s is a string dl - list( dl, dt2) Fred J. alias phddas, you are really not going to use - here, please read the manuals. } list(names = fname,

Re: [R] variable scope

2004-03-27 Thread Duncan Murdoch
On Sat, 27 Mar 2004 07:08:09 -0800 (PST), Fred J. [EMAIL PROTECTED] wrote : The normal way would be to define builddl() within getdata(), i.e. getdata - function(p){ builddl - function(q,s){ fname - c(fname,s) dl - list( dl, q) } fname - NULL; dl - list(NULL)#build the

Re: [R] availability of version 1.9.0?

2004-03-27 Thread Chuck Cleland
Douglas Bates wrote: Erin Hodgess [EMAIL PROTECTED] writes: When will version 1.9 (for Windows) be ready, please? The original release date for the R-1.9.0 source code was April 4 but there will be an as-yet-unspecified delay due to a breakin on the main archive site. We had to do a lot of

Re: [R] availability of version 1.9.0?

2004-03-27 Thread Duncan Murdoch
On 27 Mar 2004 09:20:53 -0600, Douglas Bates [EMAIL PROTECTED] wrote : I believe that Duncan Murdoch has beta test versions of the Windows binary for R-1.9.0 available from his web site. I have forgotten the URL. Perhaps someone can remind us. No, they're on CRAN now. There's a link from the

Re: [R] stop() vs. error() ?

2004-03-27 Thread Prof Brian Ripley
That's called q() in R. On Sat, 27 Mar 2004, ivo welch wrote: hi andy: mea culpa. it is the exit function in most other languages. It would be exit(0) invocation in C (C++) and perl, for example. regards, /iaw Liaw, Andy wrote: So you still have not told us what exactly what you

Re: [R] building a list in loop

2004-03-27 Thread Fred J.
--- Uwe Ligges [EMAIL PROTECTED] wrote: Fred J. wrote: Hello getdata - function(p){ fname - NULL; dl - list()#build the sturcture builddl - function(q,s){ fname - c(fname,s) #where s is a string dl - list( dl, dt2) Fred J. alias phddas, you are really not going to

Re: [R] stop() vs. error() ?

2004-03-27 Thread ivo welch
hi brian: thanks. I will put in a suggestion that the docs refer to q() in see also for stop. regards, /ivo Prof Brian Ripley wrote: That's called q() in R. snip __ [EMAIL PROTECTED] mailing list

Re: [R] stop() vs. error() ?

2004-03-27 Thread Prof Brian Ripley
On Sat, 27 Mar 2004, ivo welch wrote: hi brian: thanks. I will put in a suggestion that the docs refer to q() in see also for stop. I don't think anyone else is confusing `exit' with `stop', though. I hope you don't when driving regards, /ivo Prof Brian Ripley wrote:

[R] Estimating SIR model parameters in R

2004-03-27 Thread Marco Albani
Hello, does anyone have a reference, pointer, example etc.. on how to estimate the parameters for a classical SIR model for spread of disease with R? I am particlarly interested in the case where only the R term is known in time. Cheers Marco __

[R] Re: [S] scalability

2004-03-27 Thread Patrick Burns
I think this is an interesting discussion -- I've learned from both Steve's and Brian's comments, and I'm broadening it to R-help since I think others will be interested as well. The problem up for comment is: result - apply(array.3D, 1:2, sum) Where array.3D is 3000 by 300 by 3. The original

Re: [R] cbind question

2004-03-27 Thread Prof Brian Ripley
cbind on vectors/matrices which are not atomic is unsupported: we had a bug report on that within the last 24 hours (but it seems to be intentional). You can just concatenate the lists and add a suitable dimension: res - c(ll, sym) dim(res) - c(508,2) if I understand your intentions. I think.

Re: [R] multicolumn sort on dataframe?

2004-03-27 Thread Spencer Graves
?order includes the following: order(..., na.last = TRUE, decreasing = FALSE) Arguments: ...: a sequence of vectors, all of the same length. Examples: (ii - order(x - c(1,1,3:1,1:4,3), y - c(9,9:1), z -c(2,1:9))) ## 6 5 2 1 7 4 10 8 3 9 rbind(x,y,z)[,ii]

RE: [R] cbind question

2004-03-27 Thread Han, Hillary
Thanks very much. I used c, and got the two lists merged fine. I would like to write the results into a file. So used write.table(try, file = try.txt) Error in cbind(...) : cannot create a matrix from these types Got into the same cbind error... Any suggestions? Thanks in advance. code:

RE: [R] cbind question

2004-03-27 Thread Prof Brian Ripley
On Sat, 27 Mar 2004, Han, Hillary wrote: Thanks very much. I used c, and got the two lists merged fine. I would like to write the results into a file. So used write.table(try, file = try.txt) Error in cbind(...) : cannot create a matrix from these types Got into the same cbind error...

[R] Re: [S] scalability

2004-03-27 Thread Prof Brian Ripley
On Sat, 27 Mar 2004, Patrick Burns wrote: I think this is an interesting discussion -- I've learned from both Steve's and Brian's comments, and I'm broadening it to R-help since I think others will be interested as well. The problem up for comment is: result - apply(array.3D, 1:2, sum)

[R] Dopt program!

2004-03-27 Thread Xianggui QU
Hi all, Does anybody have a workable dopt program in R to generate D-optimal designs. I downloaded dopt.zip from stat homepage of the university of oxford, whenever I load it into R and try to run, the following error comes: Error: couldn't find function Dopt. Any information will be highly

Re: [R] cbind question

2004-03-27 Thread Gabor Grothendieck
Suppose you have these two variables: x1 - matrix(list(a,b,c),3,1) x2 - matrix(list(1,2,3),3,1) You can unlist them and then create a data frame out of them: data.frame(x1=unlist(x1),x2=unlist(x2)) Aside from the above solution, you might want to question why your variables are

[R] R and S-plus

2004-03-27 Thread prad s u
Hi, I apologize in advance if this is the wrong area to post this message. I would like to know if there is an R equivalent for the S+finMetrics package? I'd like to be able to use R to go through the examples provided in the book Modeling Financial Time-Series with S-Plus (E. Zivot and J.

Re: [R] Dopt program!

2004-03-27 Thread Prof Brian Ripley
On Sat, 27 Mar 2004, Xianggui QU wrote: Does anybody have a workable dopt program in R to generate D-optimal designs. I downloaded dopt.zip from stat homepage of the university of oxford, whenever I load it into R and try to run, the following error comes: Error: couldn't find function Dopt.