Re: [R] question on boot

2005-06-10 Thread Frank Samuelson
boot will handle multivariate data as well as multistratum data, though it isn't clear from your question what is multivariate about your problem or what you are bootstrapping. Lisa Wang wrote: > Hello there: > > Dear Dr. Murdoch, > > I'm a statistician at Princess Margaret Hospital. Could you

Re: [R] [R-pkgs] New versions of Matrix and lme4 packages for R-2.4.0

2006-10-03 Thread Frank Samuelson
Thanks, Douglas. It works. Only one gripe. Every time I want to try a new version of your software, I have to get, compile, patch the latest bleeding edge version of R as well: ERROR: This R is version 2.3.1 package 'Matrix' needs R >= 2.4.0 Douglas Bates wrote: > Versions 0.9975-1 o

[R] extracting nested variances from lme4 model

2006-10-04 Thread Frank Samuelson
I have a model: mod1<-lmer( x ~ (1|rtr)+ trth/(1|cs) , data=dtf) # Here, cs and rtr are crossed random effects. cs 1-5 are of type TRUE, cs 6-10 are of type FALSE, so cs is nested in trth, which is fixed. So for cs I should get a fit for 1-5 and 6-10. This appears to be the case from the random

Re: [R] problem to install R on linux

2006-02-09 Thread Frank Samuelson
For the rpm install you may also need to install a package called info-x.x.x.x-x.rpm. For the compilation you'll need to be certain that you've installed readline-x.x.x.x.x.rpm and and perhaps readline-devel-x.x.x.x.rpm Those should be in your mandriva distn André Beló wrote: > Dear members, >

[R] tk mouse cursor icon widget tkwinfo tkfocus questions

2006-02-11 Thread Frank Samuelson
1. I want to change the mouse cursor over my window into a wait/watch icon while R computes. Can this be done directly? Some ancient tcltk mailing lists said change the cursor over every widget in the window: foreach widget [winfo children $window] {

Re: [R] using kernel density estimates to infer mode of distribution

2006-02-17 Thread Frank Samuelson
A density() fit calls the eval x and estimate y: fit<-density(data) plot(fit$x,fit$y) Adelchi Azzalini wrote: > On Wed, 15 Feb 2006 18:28:25 -0500, Dan Rabosky wrote: > > DR> > DR> Is it possible to use "density" or another kernel density > DR> estimator to identify the mode of a distributi

Re: [R] How to compare areas under ROC curves calculated with ROCR package

2006-03-23 Thread Frank Samuelson
The seROC routine you included is an very good approximation to the standard error of the Mann-Whitney-Wilcoxon/Area under the ROC curve statistic. It is derived from negative exponential models, but works very well in general (e.g. Hanley and McNeil, Diagnostic Radiology, 1982, v. 143, p. 29). A

Re: [R] all.equal() and which()

2006-05-28 Thread Frank Samuelson
I think that this thread demonstrates a useful point: The more logical and useful output of all.equal(A,B) would be a vector of TRUEs and FALSEs with a length equal to that of the arguments, rather than some human readable text string. If I really want a tolerance I can always do sd/min/max/etc(abs

Re: [R] executable file with R

2006-06-02 Thread Frank Samuelson
Romain Lorrilliere wrote: > Hi, > > I made an R function, and I want make an executable applet with it. Do > you know how it is possible? > More details about what you want would be helpful. Here is what I do and it may be useful to you. Under *nix,OSX, etc use bash's "here document" feature.

[R] Spare some CPU cycles for testing lme?

2004-09-13 Thread Frank Samuelson
If anyone has a few extra CPU cycles to spare, I'd appreciate it if you could verify a problem that I have encountered. Run the code below and tell me if it crashes your R before completion. library(lme4) data(bdf) dump<-sapply( 1:5, function(i) { fm <- lme(langPOST ~ IQ.ver.cen + avg.IQ.v

[R] .Random.seed in R-devel

2004-09-13 Thread Frank Samuelson
I'm running R-2.0.0 (yesterday's snapshot)in its own directory, and everything works great, except: >.Random.seed Error: Object ".Random.seed" not found Does 2.0.0 not use .Random.seed for saving, etc, like it says in the help page? Thanks for any help. -Frank __

Re: [R] .Random.seed in R-devel

2004-09-13 Thread Frank Samuelson
Oh. I guess I had a different definition of "when one is required" than the help page. :) Thanks. Prof Brian Ripley wrote: `Like it says on the help page'! Initially, there is no seed; a new one is created from the current time when one is required. Hence, different sessions will

Re: [R] R in Linux Redhat 9.0

2004-09-13 Thread Frank Samuelson
rpm -ql R should show you your installed files. Did you try typing "R"? Bryan Tseng wrote: Hi, my name is Bryan and I just installed R on my Redhat 9.0. I imported the key from the net as directed, and tested the integreity of the rpm package- it was fine. I then went ahead and installed the i386.r

[R] lattice, xyplot layout questions

2004-10-19 Thread Frank Samuelson
1. How do I get a grid in the background of my xyplots, like Figure 1 of http://www.ci.tuwien.ac.at/Conferences/DSC-2001/Proceedings/Murrell.pdf 2. In my scatter xyplot I have multiple columns and rows of panels. I would like to have different y scales for panels in different rows (panel

Re: [R] pasting indexes to variables within loops

2004-10-19 Thread Frank Samuelson
as.numeric(apply(haplo, 1 ,function(x) paste(x,collapse=""))) perhaps? Kristin Kay Nicodemus wrote: Hi all, Hope someone can help me. I start out with a matrix called haplo with 600 rows and two columns. To start with, the elements of the matrix are character strings of 20 numbers. I then want

Re: [R] avoiding loops

2005-01-29 Thread Frank Samuelson
Along the lines of this thread, is there a general apply type function that allows me to take one vector at a time from a matrix (or row from a data frame) and another vector from another matrix and apply them on a general function? Sort of a multidimensional mapply, or an 'inner' routine where yo