Re: [R] fractional factorial design in R

2006-01-21 Thread Martin Maechler
BertG == Berton Gunter [EMAIL PROTECTED] on Fri, 20 Jan 2006 14:15:49 -0800 writes: BertG I'm not sure what you mean by a fractional BertG factorial design here. it's a pretty well known term, in (at least some schools of) classical analysis of variance, e.g. in the famous Box,

[R] Latest revision of lme4 requires 'Matrix' = 0.995.2 but that version is not available on CRAN

2006-01-21 Thread Søren Højsgaard
I just updated the packages on my pc (windows xp). When loading lme4 I get library(lme4) Error: package 'Matrix' 0.995-1 was found, but = 0.995.2 is required by 'lme4' 'Matrix' 0.995-1 is indeed installed on my computer, but update.packages() does not capture a never version; and seemingly

Re: [R] Latest revision of lme4 requires 'Matrix' = 0.995.2 but that version is not available on CRAN

2006-01-21 Thread Peter Dalgaard
Søren Højsgaard [EMAIL PROTECTED] writes: I just updated the packages on my pc (windows xp). When loading lme4 I get library(lme4) Error: package 'Matrix' 0.995-1 was found, but = 0.995.2 is required by 'lme4' 'Matrix' 0.995-1 is indeed installed on my computer, but

Re: [R] abline() or predict.lm() when log=x

2006-01-21 Thread Richard Chandler
Sorry that was a typo when I said 'resposnse'... I meant predictor. I want to fit lm(y ~ log(x)) and plot the line with confidence intervals on a log=x plot so that I can see the real units of x rather than the log(x) units. I can't get the real line using predict.lm() without removing the

Re: [R] Latest revision of lme4 requires 'Matrix' = 0.995.2 but that version is not available on CRAN

2006-01-21 Thread Uwe Ligges
Peter Dalgaard wrote: Søren Højsgaard [EMAIL PROTECTED] writes: I just updated the packages on my pc (windows xp). When loading lme4 I get library(lme4) Error: package 'Matrix' 0.995-1 was found, but = 0.995.2 is required by 'lme4' 'Matrix' 0.995-1 is indeed installed on my computer,

Re: [R] Latest revision of lme4 requires 'Matrix' = 0.995.2 but that version is not available on CRAN

2006-01-21 Thread Søren Højsgaard
We (Doug, Martin and I) are trying hard to debug an error in Matrix. Martin and Doug have ideas for a bugfix and I am checking right now. The latest version of Matrix that passed the checks was Matrix_0.995-1 which is still available from http://cran.r-project.org/bin/windows/contrib/2.2/last/

Re: [R] Latest revision of lme4 requires 'Matrix' = 0.995.2 but that version is not available on CRAN

2006-01-21 Thread Uwe Ligges
Søren Højsgaard wrote: We (Doug, Martin and I) are trying hard to debug an error in Matrix. Martin and Doug have ideas for a bugfix and I am checking right now. The latest version of Matrix that passed the checks was Matrix_0.995-1 which is still available from

Re: [R] Influence measure + lme ?

2006-01-21 Thread Spencer Graves
My search just now found no mention of Cook's distance or influenc measures. The closest I found was an unanswered question on this from April 2003 (http://finzi.psych.upenn.edu/R/Rhelp02a/archive/4797.html). Beyond that, there is an excellent discussion of Examining a

Re: [R] function kde2d

2006-01-21 Thread Marco Geraci
As far as I understood, this mailing list is not intended for basic statistical teaching or for arguments. Your first question was In particular I'd like to know: what bandwidth is used which can be answered simply with ?kde2d. Now your question is I just wanted to know what does

[R] converting help files with Sd2Rd

2006-01-21 Thread Fredrik Lundgren
Dear list, I would like to convert several .d files to several .Rd files in cmd.exe (Win XP home): R CMD Sd2Rd *.d prints all files to the screen, I want the individual files saved to disk R CMD Sd2Rd *.d foo.Rd puts them into one file, I want the individual files R CMD Sd2Rd *.d *.Rd

Re: [R] converting help files with Sd2Rd

2006-01-21 Thread Uwe Ligges
Fredrik Lundgren wrote: Dear list, I would like to convert several .d files to several .Rd files in cmd.exe (Win XP home): R CMD Sd2Rd *.d prints all files to the screen, I want the individual files saved to disk R CMD Sd2Rd *.d foo.Rd puts them into one file, I want the

Re: [R] Latest revision of lme4 requires 'Matrix' = 0.995.2 but that version is not available on CRAN

2006-01-21 Thread Prof Brian Ripley
On Sat, 21 Jan 2006, Peter Dalgaard wrote: Søren Højsgaard [EMAIL PROTECTED] writes: I just updated the packages on my pc (windows xp). When loading lme4 I get library(lme4) Error: package 'Matrix' 0.995-1 was found, but = 0.995.2 is required by 'lme4' [...] 2) When actually trying to

Re: [R] converting help files with Sd2Rd

2006-01-21 Thread Gabor Grothendieck
Here is a slightly shorter version: ## Start R and type: setwd(path_to_.d_files) pat - \\.d for(f in list.files(pattern = pat)) shell(paste(R CMD Sd2Rd, f, , sub(pat, .Rd, f))) q(no) On 1/21/06, Uwe Ligges [EMAIL PROTECTED] wrote: Fredrik Lundgren wrote: Dear list, I would like to

Re: [R] mcmcsamp() in lmer

2006-01-21 Thread Spencer Graves
Dear Prof. Gelman: Thanks for providing such a simple, replicable example. I got the same results you describe under Windows XP Pro with: sessionInfo() R version 2.2.1, 2005-12-20, i386-pc-mingw32 attached base packages: [1] methods stats graphics grDevices utils

Re: [R] mcmcsamp() in lmer

2006-01-21 Thread Douglas Bates
On 1/21/06, Spencer Graves [EMAIL PROTECTED] wrote: Dear Prof. Gelman: Thanks for providing such a simple, replicable example. I got the same results you describe under Windows XP Pro with: sessionInfo() R version 2.2.1, 2005-12-20, i386-pc-mingw32 attached base packages: [1]

Re: [R] abline() or predict.lm() when log=x

2006-01-21 Thread Richard Chandler
Please ignore my last message, I've realized that Peter's first reply was all I needed...thanks. Richard Quoting Richard Chandler [EMAIL PROTECTED]: Sorry that was a typo when I said 'resposnse'... I meant predictor. I want to fit lm(y ~ log(x)) and plot the line with confidence

Re: [R] mcmcsamp() in lmer

2006-01-21 Thread Spencer Graves
Hi, Doug: Thanks for all your hard work and creativity with mixed-effects models -- and for your quick reply to my question about how to use 'showMethods' to view the source. Best Wishes, spencer graves Douglas Bates wrote: On 1/21/06, Spencer Graves [EMAIL

Re: [R] mcmcsamp() in lmer

2006-01-21 Thread Martin Maechler
DougB == Douglas Bates [EMAIL PROTECTED] on Sat, 21 Jan 2006 16:13:37 -0600 writes: DougB On 1/21/06, Spencer Graves [EMAIL PROTECTED] DougB wrote: Dear Prof. Gelman: Thanks for providing such a simple, replicable example. I got the same results you describe

[R] Means from balanced incomplete block design

2006-01-21 Thread N.W.Galwey
The code below is intended to analyse a textbook example of a balanced incomplete block design: # # Data taken from pp. 219-230 in # Cox, D.R. (1958) Planning of Experiments. John Wiley and Son, Inc. New York. 308 pp. # day - factor(rep(1:10, each = 3)) T -

[R] Making a markov transition matrix

2006-01-21 Thread Ajay Narottam Shah
Folks, I am holding a dataset where firms are observed for a fixed (and small) set of years. The data is in long format - one record for one firm for one point in time. A state variable is observed (a factor). I wish to make a markov transition matrix about the time-series evolution of that

Re: [R] Making a markov transition matrix

2006-01-21 Thread jim holtman
Is this what you want: set.seed(1001) # Raw data in long format -- raw - data.frame(name=c(f1,f1,f1,f1,f2,f2,f2,f2), year=c(83, 84, 85, 86, 83, 84, 85, 86), state=sample(1:3, 8, replace=TRUE) ) # Shift to wide format -- fixedup -

Re: [R] Making a markov transition matrix

2006-01-21 Thread jim holtman
Ignore last reply. I sent the wrong script. set.seed(1001) # Raw data in long format -- raw - data.frame(name=c(f1,f1,f1,f1,f2,f2,f2,f2), + year=c(83, 84, 85, 86, 83, 84, 85, 86), + state=sample(1:3, 8, replace=TRUE) + ) # Shift to

Re: [R] Making a markov transition matrix

2006-01-21 Thread Bill.Venables
If you can be sure that there are no missing years within firms, I think I would do it this way: raw - raw[do.call(order, raw), ] # not needed here raw01 - subset(data.frame(raw[-nrow(raw), ], raw[-1, ]), name == name.1) with(raw01, table(state, state.1)) state.1 state 1 2 3 1 1 0

Re: [R] Making a markov transition matrix

2006-01-21 Thread Gabor Grothendieck
See: http://finzi.psych.upenn.edu/R/Rhelp02a/archive/42934.html On 1/21/06, Ajay Narottam Shah [EMAIL PROTECTED] wrote: Folks, I am holding a dataset where firms are observed for a fixed (and small) set of years. The data is in long format - one record for one firm for one point in time. A

Re: [R] Making a markov transition matrix

2006-01-21 Thread Ajay Narottam Shah
On Sun, Jan 22, 2006 at 01:47:00PM +1100, [EMAIL PROTECTED] wrote: If this is a real problem, here is a slightly tidier version of the function I gave on R-help: transitionM - function(name, year, state) { raw - data.frame(name = name, state = state)[order(name, year), ] raw01 -

Re: [R] numericDeriv() giving a vector when multiple variables input

2006-01-21 Thread Spencer Graves
I've never used numericDeriv before, but from reading the documentation and working throught the example, a little thought led me to the following example: f - function(g., A){ A %*% g. } g - function(x1, x2, x3, x4, G){ G %*%c(x1, x2, x3, x4) } env234 - new.env() A - array(1:6,