Re: [R] data type for block data?

2007-06-19 Thread Stephen Tucker
Hi Paul, Hope this is what you're looking for: ## reading in text (the first 13 rows of cc from your posting) ## and using smaller indices [(3,8) instead of (10,40)] ## for this example cc - mode-(do.call(rbind, +strsplit(readLines(textConnection(txt))[-1],[ ]{2,}))[,-1], +

Re: [R] Augment 'Matrix' matrices

2007-06-19 Thread Martin Maechler
SH == Scott Hyde [EMAIL PROTECTED] on Mon, 18 Jun 2007 16:59:00 -1000 (HST) writes: SH Martin, How does Matrix implement augmented matrices? I SH tried this and got the expected result: {Replying to R-help, since this question has come up several times } V=matrix(1,2,3)

[R] [R-pkgs] ggplot2 0.5.2

2007-06-19 Thread hadley wickham
ggplot2 === ggplot2 is a plotting system for R, based on the grammar of graphics, which tries to take the good parts of base and lattice graphics and none of the bad parts. It takes care of many of the fiddly details that make plotting a hassle (like drawing

[R] Controlling text and strip arrangement in xyplot

2007-06-19 Thread Juan Pablo Lewinger
I've searched the archives and read the xyplot help but can't figure out the 2 lattice questions below? Consider: library(lattice) DF - data.frame(x=rnorm(20), y=rnorm(20), g1=rep(letters[1:2], 10), g2=rep(LETTERS[1:2], each=10), g3=rep(rep(letters[3:4],each=5),2)) xyplot(y

[R] application of ridge function to all predictors

2007-06-19 Thread carol white
Hi, How is it possible to specify all predictors in ridge function? suppose that I have 100 predictors and I want to apply ridge to all 100 variables. instead of putting the name of all variables separated by , (see 2nd code line below), which notation should I use so that ridge would be

[R] Help in ARIMA

2007-06-19 Thread Roshan Sumbaly
I am working on a data set which has the waiting times taken of jobs running on a cluster. I need to come up with a method to use this historical data to come up with a prediction for the future. Even probably try simulating the full history (as in I have history of the job submission time and

[R] About Genetic Algorithm package

2007-06-19 Thread Nitish Kumar Mishra
Hi R-help group member, Please give me idea about Genetic algorithm and Simulated anealing package in R(Unix). I want to use this for the feature selection in Chemoinformatics. Thanking you. -- Nitish Kumar Mishra Junior Research Fellow BIC, IMTECH, Chandigarh, India E-Mail Address: [EMAIL

Re: [R] Controlling text and strip arrangement in xyplot

2007-06-19 Thread hadley wickham
On 6/19/07, Juan Pablo Lewinger [EMAIL PROTECTED] wrote: I've searched the archives and read the xyplot help but can't figure out the 2 lattice questions below? Consider: library(lattice) DF - data.frame(x=rnorm(20), y=rnorm(20), g1=rep(letters[1:2], 10),

Re: [R] Unix-like permissions to allow a user to update recommen

2007-06-19 Thread John Logsdon
R-ists When you move from version to version of R a completely new directory tree is installed so in principal if you *know* that a package is not updated you can re-install it from the old tree or copy it to your new tree and install it. Maybe an 'import packages from previous versions' could

[R] How do I avoid a loop?

2007-06-19 Thread Feng, Ken
Hi, I start with an array of booleans: x - c( TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE ); I want to define an y - f(x) such that: y - c( 1, 2, 3, 0, 0, 1, 2, 0, 1 ); In other words, do a cumsum when I see a TRUE, but reset to 0 if I see a FALSE. I know I can do

Re: [R] psm/survreg coefficient values ?

2007-06-19 Thread John Logsdon
In survreg() the predictor is log(characteristic life) for Weibull (= exponential when scale=1) - ie the 63.2%ile. For the others the predictor is log(median). This causes problems when comparing predictions and a better way IMHO is to correct the Weibull prediction by a factor

[R] outlying

2007-06-19 Thread elyakhlifi mustapha
hello, are there functions to detecte outlying observations in samples? thanks. ___ [[alternative HTML version deleted]] __

Re: [R] Unix-like permissions to allow a user to update recommen

2007-06-19 Thread Patrick Connolly
On Mon, 18-Jun-2007 at 10:25PM +0100, Ted Harding wrote: [] | I'm still wondering, though, why you don't just run the command | update.packages() as root. You have root access, and you said (in | the adding user to group context) that only one user is involved | (presumably yourself?). In

Re: [R] How to install RMySQL package in R 2.5 in Windows OS?

2007-06-19 Thread Prof Brian Ripley
I can confirm problems with the current mysql 5.0.41: I get library(RMySQL) Loading required package: DBI Error in dyn.load(x, as.logical(local), as.logical(now)) : unable to load shared library 'd:/R/library/RMySQL/libs/RMySQL.dll': LoadLibrary failure: Invalid access to memory

Re: [R] Problem with binding data-frames

2007-06-19 Thread Junnila, Jouni
Hi, Yes, I'm aware that the problem is that I have differing number of columns in the different datasets. My question still remains. Is there some way I can allow column numbers to be different, or is there some other way combining these datasets? Thanks, -Jouni On Mon, 18 Jun 2007, Petr

[R] plotting order of lines in xyplot panels while using conditioning variable and groups

2007-06-19 Thread RICHARD PITMAN
I am using the following code: library(lattice) data-read.csv(data.csv) attach(data) fig-xyplot(S_t~month|event, key= list(text=list(lab=c(Time to first CV event - Data, Survival post first CV event - Model,

[R] Odp: outlying

2007-06-19 Thread Petr PIKAL
Hi It often depends on your attitude to limits for outlying observations. Boxplot has some identifying routine for selecting outlying points. Any procedure usually requires somebody to choose which observation is outlying and why. You can use e.g. all values which are beyond some threshold

Re: [R] Problem with binding data-frames

2007-06-19 Thread Prof Brian Ripley
On Tue, 19 Jun 2007, Junnila, Jouni wrote: Hi, Yes, I'm aware that the problem is that I have differing number of columns in the different datasets. My question still remains. Is there some way I can allow column numbers to be different, or is there some other way combining these datasets?

Re: [R] How do I avoid a loop?

2007-06-19 Thread jim holtman
This should do it for you: x - c( TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE ); y - rle(x) unlist(lapply(seq(length(y$lengths)), function(.indx){ + if (y$values[.indx]) seq(y$lengths[.indx]) + else rep(0, y$lengths[.indx]) + })) [1] 1 2 3 0 0 1 2 0 1 On 6/19/07, Feng,

Re: [R] triangle contour plots

2007-06-19 Thread Jim Lemon
Robin Hankin wrote: Suppose I have three numbers p1, p2, p3 with 0 = p1,p2,p3 = 1 and p1+p2+p3=1, and a function f=f(p1,p2,p3) = f(p1,p2,1-p1-p2). How to draw a contour plot of f() on the p1+p2+p3=1 plane, that is, an equilateral triangle? Functions triplot(), triangle.plot(), and

[R] Odp: Odp: outlying

2007-06-19 Thread Petr PIKAL
[EMAIL PROTECTED] napsal dne 19.06.2007 12:23:58: Hi It often depends on your attitude to limits for outlying observations. Boxplot has some identifying routine for selecting outlying points. Any procedure usually requires somebody to choose which observation is outlying and why. You

Re: [R] outlying

2007-06-19 Thread John Kane
You might want to have a look at the outliers package on CRAN. --- elyakhlifi mustapha [EMAIL PROTECTED] wrote: hello, are there functions to detecte outlying observations in samples? thanks.

Re: [R] How do I avoid a loop?

2007-06-19 Thread Gabor Grothendieck
xx is 1 in every position of the first run of TRUE, 2 in every position in the 2nd run of TRUE and so on. The parenthesized expression in the second line converts those to increasing values and multiplying it by x zaps the garbage in the positions that correspond to FALSE in x. xx -

[R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread spime
I haven't find any helpful thread. How can i calculate BIC and Hosmer-Lemeshow statistic for a logistic regression model. I have used glm for logistic fit. -- View this message in context: http://www.nabble.com/BIC-and-Hosmer-Lemeshow-statistic-for-logistic-regression-tf3945943.html#a11193273

Re: [R] How to compare GLM and GAM models

2007-06-19 Thread Ben Bolker
Yuanchang xie xieyc at hotmail.com writes: Dear Listers, I want to compare two negative binomial models fitted using glm.nb and gam(mgcv) based on the same data. What would be the most appropriate criteria to compare these two models? Can someone point me to some references? Thank you

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread Frank E Harrell Jr
spime wrote: I haven't find any helpful thread. How can i calculate BIC and Hosmer-Lemeshow statistic for a logistic regression model. I have used glm for logistic fit. See the Design package's lrm function and residuals.lrm for a better GOF test. -- Frank E Harrell Jr Professor and

[R] converting proc mixed to lme for a random effects meta-analysis

2007-06-19 Thread Lucia Costanzo
I would like to convert the following SAS code for a Random Effects meta-analysis model for use in R but, I am running into difficulties. The results are not similar, R should be reporting 0.017 for the between-study variance component, 0.478 for the estimated parameter and 0.130 for the

[R] Dissimilarity Analysis

2007-06-19 Thread Birgit Lemcke
Hello you all! I am a completely new user of R and I have a problem to solve. I am using Mac OS X on a PowerBook. I have a table that looks like this: species X1 X2 X3 X4 X5 X6 X7 X8 X9 X10 X11 X12 X13 X14 X15 X16 X17 X18 X19 X20 X21 1Anth_cap1 1 0 0 1 0 1 0 0 1

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread Gavin Simpson
On Tue, 2007-06-19 at 04:59 -0700, spime wrote: I haven't find any helpful thread. How can i calculate BIC and Hosmer-Lemeshow statistic for a logistic regression model. I have used glm for logistic fit. Not sure about the Hosmer-Lemeshow, but AIC() with argument k = log(n), where n is

Re: [R] How do I avoid a loop?

2007-06-19 Thread Martin Becker
Gabor Grothendieck wrote: xx is 1 in every position of the first run of TRUE, 2 in every position in the 2nd run of TRUE and so on. The parenthesized expression in the second line converts those to increasing values and multiplying it by x zaps the garbage in the positions that correspond to

Re: [R] Controlling text and strip arrangement in xyplot

2007-06-19 Thread Mark Difford
Hi Pablo, DF - data.frame(x=rnorm(20), y=rnorm(20), g1=rep(letters[1:2], 10), g2=rep(LETTERS[1:2], each=10), g3=rep(rep(letters[3:4],each=5),2)) xyplot(y ~ x | g1 + g2, groups=g3, data=DF) ... I remember findling with this some time ago and getting most of the way there. If you

Re: [R] converting proc mixed to lme for a random effects meta-analysis

2007-06-19 Thread Bernd Weiss
On 19 Jun 2007 at 8:13, Lucia Costanzo wrote: Date sent: Tue, 19 Jun 2007 08:13:30 -0400 From: Lucia Costanzo [EMAIL PROTECTED] To: r-help@stat.math.ethz.ch Subject:[R] converting proc mixed to lme for a random effects

Re: [R] converting proc mixed to lme for a random effectsmeta-analysis

2007-06-19 Thread Viechtbauer Wolfgang \(STAT\)
That was going to be my suggestion =) By the way, lme does not give you the right results because the residual variance is not constrained to 1 (and it is not possible to do so). Best, -- Wolfgang Viechtbauer  Department of Methodology and Statistics  University of Maastricht, The

[R] Rmpi and rsprng for Windows

2007-06-19 Thread Eric Ferreira
Dear f_R_iends, I'm new on parallel programming and trying to use a machine with Windows to access a linux computer cluster. I could install the 'snow' package, but not 'Rmpi' nor 'rsprng'. Some tips for intalling such packages for Windows R ? All the best, -- Barba Departamento de Ciências

Re: [R] Rmpi and rsprng for Windows

2007-06-19 Thread Martin Morgan
Eric - http://www.stats.uwo.ca/faculty/yu/Rmpi/ (the Rmpi package author page) has helpful Windows instructions. Martin Eric Ferreira [EMAIL PROTECTED] writes: Dear f_R_iends, I'm new on parallel programming and trying to use a machine with Windows to access a linux computer cluster. I

[R] plot only x- and y-axis with origin, no box()

2007-06-19 Thread Talloen, Willem [PRDBE]
hi all, I'm trying for quite some time to have an x- and y-axis, but no entire box. plot(..,axes=F) axis(1) axis(2) Gives this, but their axes do not go to the origin. Quite a number of people find this gap between the two axes disturbing. Has anyone an idea how to let these axes go to the

Re: [R] How do I avoid a loop?

2007-06-19 Thread Martin Becker
Gabor Grothendieck wrote: xx is 1 in every position of the first run of TRUE, 2 in every position in the 2nd run of TRUE and so on. The parenthesized expression in the second line converts those to increasing values and multiplying it by x zaps the garbage in the positions that correspond to

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread spime
Is there any windows version of Design package??? Frank E Harrell Jr wrote: spime wrote: I haven't find any helpful thread. How can i calculate BIC and Hosmer-Lemeshow statistic for a logistic regression model. I have used glm for logistic fit. See the Design package's lrm

Re: [R] psm/survreg coefficient values ?

2007-06-19 Thread Thomas Lumley
On Tue, 19 Jun 2007, John Logsdon wrote: In survreg() the predictor is log(characteristic life) for Weibull (= exponential when scale=1) - ie the 63.2%ile. For the others the predictor is log(median). This causes problems when comparing predictions and a better way IMHO is to correct the

Re: [R] Help in ARIMA

2007-06-19 Thread sj
Sounds more like you would want to explore the use of some sort of Queueing model. A quick search of R help did not yield any packages that could be used to develop such models, but I think that modeling simple queuing systems and estimating wait times is pretty straight forward and could be

Re: [R] plot only x- and y-axis with origin, no box()

2007-06-19 Thread Marc Schwartz
On Tue, 2007-06-19 at 15:15 +0200, Talloen, Willem [PRDBE] wrote: hi all, I'm trying for quite some time to have an x- and y-axis, but no entire box. plot(..,axes=F) axis(1) axis(2) Gives this, but their axes do not go to the origin. Quite a number of people find this gap between the

[R] cash or nothing option

2007-06-19 Thread Luca Aresu
Hi, i need help building a program for the evaluation of a cash or nothing option. The option is written on a stock that today has a price of X. Nine months before i will have this situation: If aXb the option pays 3 dollars If Xa or Xb the option pays nothing The price of the title is

Re: [R] How do I avoid a loop?

2007-06-19 Thread Erik Iverson
One more variation on the solution, no idea how it compares in speed. Using your x ... ifelse(x, unlist(mapply(seq, to = rle(x)$lengths, from = 1)), 0) [1] 1 2 3 0 0 1 2 0 1 Feng, Ken wrote: Hi, I start with an array of booleans: x - c( TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, TRUE,

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread Thomas Lumley
On Tue, 19 Jun 2007, spime wrote: Is there any windows version of Design package??? Not at the moment. It is being updated for changes in R 2.5.0. [This would be a FAQ except that it should stop being asked soon] -thomas Frank E Harrell Jr wrote: spime wrote: I haven't

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread Henrique Dallazuanna
For Hosmer-Lemeshow statistic look: http://people.ufpr.br/~giolo/CE073/CodigosR/gof_bino.txt -- Henrique Dallazuanna Curitiba-Paraná-Brasil 25° 25' 40 S 49° 16' 22 Ohttp://maps.google.com/maps?f=qhl=enq=Curitiba,+Brazillayer=ie=UTF8z=18ll=-25.448315,-49.276916spn=0.002054,0.005407t=kom=1 On

[R] cash or nothing option

2007-06-19 Thread Luca Aresu
Hi, i need help building a program for the evaluation of a cash or nothing option. The option is written on a stock that today has a price of X. Nine months before i will have this situation: If aXb the option pays 3 dollars If Xa or Xb the option pays nothing The price of the title is

Re: [R] How do I avoid a loop?

2007-06-19 Thread Gabor Grothendieck
Here is a slight variation. The second line is unchanged from my prior solution but the first line is different. The previous one I posted was slightly more complex and took about 50% longer to run than this one: xx - (cumsum(!x) + 1) * x (seq_along(x) - match(xx, xx) + 1) * x #

Re: [R] Optimization

2007-06-19 Thread livia
It is of great help for your advice. Thanks a lot to you all. livia wrote: Hi, I would like to minimize the value of x1-x2, x2 is a fixed value of 0.01, x1 is the quantile of normal distribution (0.0032,x) with probability of 0.7, and the changing value should be x. Initial value for x is

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread Prof Brian Ripley
On Tue, 19 Jun 2007, spime wrote: Is there any windows version of Design package??? Yes, the version put up this morning works on 2.5.x (at last). You should be able to get a Windows build now: it is showing for me on CRANextras (where I put it an hour or so ago: it will reach CRAN mirrors in

[R] names over names

2007-06-19 Thread elyakhlifi mustapha
Hello, I wonder if it's possible to put names above column names. Do you know if it's possible? thanks. ___ [[alternative HTML version deleted]]

Re: [R] plot only x- and y-axis with origin, no box()

2007-06-19 Thread Romain Francois
Hello, You are looking for the box function, and its bty argument. For example, this one will do the trick. R box( bty = L) ?par gives more information on the potential values for bty. Cheers, Romain Talloen, Willem [PRDBE] wrote: hi all, I'm trying for quite some time to have an x- and

[R] [R-pkgs] RGtk2 2.10.x series available

2007-06-19 Thread Michael Lawrence
The new 2.10.x series of the RGtk2 package has recently become available on CRAN. RGtk2 is a package for creating graphical user interfaces (GUI's) in R and is similar in purpose to the tcltk package. RGtk2 binds to and enables the extension of the GTK+ user interface library, as well as several

[R] Function -return value

2007-06-19 Thread livia
Hi, I am trying to write a function with the following codes and I would like it to return the values for alpha beta para parab seperately. Then I would like to use this funstion for variable with factor a and b. But the result turns out to be a matrix with element like Numeric,2 ... I guess

[R] Could not find lmer function in {Matrix} package

2007-06-19 Thread Steve Brady
I am having trouble calling the lmer function in the {Matrix} package. I first installed and loaded {Matrix} as follows: install.packages(Matrix) library(Matrix) The package loaded successfully, however when I attempted to call lmer, I received the following message: Error: could not

[R] Histogram

2007-06-19 Thread livia
Hello, I am using the following codes to plot a histogram and density line for x. For the density line, I just want it to show the two tails, eg, for x larger than 0.05 ans smaller than -0.05 hist (x, seq(-0.1,0.1,0.01),freq = FALSE) lines (density(x,bw=SJ), x 0.05 x (-0.05), col = red) But is

[R] Linear model predictions, differences in class

2007-06-19 Thread John Phillips
Hi, I am using R to fit statistical models to data were the observations are means of the original data. R is used to calculate the mean before fitting the model. My problem is: When R calculates the means using tapply, the class of the means differs from the class of the original data, which

Re: [R] Could not find lmer function in {Matrix} package

2007-06-19 Thread Steve Brady
That did the trick. Thanks. Steve On Jun 19, 2007, at 12:10 PM, David Barron wrote: It's now in the lme4 package. On 19/06/07, Steve Brady [EMAIL PROTECTED] wrote: I am having trouble calling the lmer function in the {Matrix} package. I first installed and loaded {Matrix} as follows:

Re: [R] outlying

2007-06-19 Thread Robert A LaBudde
At 05:29 AM 6/19/2007, elyakhlifi wrote: hello, are there functions to detecte outlying observations in samples? thanks. library('car') ? outlier.test library('outliers') ? grubbs.test ? dixon.test ? cochran.test ? chisq.out.test

Re: [R] plot only x- and y-axis with origin, no box()

2007-06-19 Thread Greg Snow
Try: plot(.., bty='l') Does that do what you want? (see the bty parameter in ?par for details) If you don't want the lines extending beyond the axes on the right and top then you could do something more like: plot(5:10, 5:10, bty='n') library(TeachingDemos) lines(cnvrt.coords( c(0,0,.5),

Re: [R] Could not find lmer function in {Matrix} package

2007-06-19 Thread David Barron
It's now in the lme4 package. On 19/06/07, Steve Brady [EMAIL PROTECTED] wrote: I am having trouble calling the lmer function in the {Matrix} package. I first installed and loaded {Matrix} as follows: install.packages(Matrix) library(Matrix) The package loaded successfully, however

Re: [R] Histogram

2007-06-19 Thread David Barron
I expect there's a more elegant way of doing this, but this should work: set.seed(101) x - rnorm(500,sd=.03) hist (x, seq(-0.1,0.1,0.01),freq = FALSE) d - density(x,bw=SJ) lowt - d$x -.05 upt - d$x .05 lines (d$x[lowt],d$y[lowt], col = red) lines(d$x[upt],d$y[upt], col = red) On 19/06/07,

[R] help w/ nonlinear regression

2007-06-19 Thread Eduardo Esteves
Dear All, I'd like to fit a kind of logistic model to small data-set using nonlinear least-squares regression. A transcript of R-script are reproduced below. Estimated B and T (the model's coeff, herein B=-8,50 and T=5,46) seem appropriate (at least visually) but are quite diff from those

Re: [R] Function -return value

2007-06-19 Thread Christophe Pallier
You wChange the function 'parameter' sapply(split(variable,list(a,b)),parameter) On 6/19/07, livia [EMAIL PROTECTED] wrote: Hi, I am trying to write a function with the following codes and I would like it to return the values for alpha beta para parab seperately. Then I would like to use

Re: [R] Function -return value

2007-06-19 Thread Christophe Pallier
First, to return several values from your function 'parameter', you can use a list: parameter - function (...) { ... list(alpha=alpha,beta=beta,para=para,parab=parab) } Then, you may use: sapply(split(variable,list(a,b)), parameter) (tapply also works but return a matrix of lists)

[R] How to compute Wilk's Lambda

2007-06-19 Thread Dietrich Trenkler
Dear helpeRs, the following data set comes from Johnson/Wichern: Applied Multivariate Statistical Analysis, 6th ed, pp. 304-306. /X - structure(c(9, 6, 9, 3, 2, 7), .Dim = as.integer(c(3, 2))) Y - structure(c(0, 2, 4, 0), .Dim = as.integer(c(2, 2))) Z - structure(c(3, 1, 2, 8, 9, 7), .Dim =

Re: [R] Linear model predictions, differences in class

2007-06-19 Thread Prof Brian Ripley
tapply gives an array: you want to use as.vector() on its result. On Tue, 19 Jun 2007, John Phillips wrote: Hi, I am using R to fit statistical models to data were the observations are means of the original data. R is used to calculate the mean before fitting the model. My problem is:

Re: [R] How to compute Wilk's Lambda

2007-06-19 Thread Richard M. Heiberger
m - manova(U~factor(rep(1:3, c(3, 2, 3 summary(m,test=Wilks) Df Wilks approx F num Df den Df Pr(F) factor(rep(1:3, c(3, 2, 3))) 2 0.0385 8.1989 4 8 0.006234 ** Residuals 5 ---

Re: [R] How to compute Wilk's Lambda

2007-06-19 Thread Peter Dalgaard
Dietrich Trenkler wrote: Dear helpeRs, the following data set comes from Johnson/Wichern: Applied Multivariate Statistical Analysis, 6th ed, pp. 304-306. /X - structure(c(9, 6, 9, 3, 2, 7), .Dim = as.integer(c(3, 2))) Y - structure(c(0, 2, 4, 0), .Dim = as.integer(c(2, 2))) Z -

Re: [R] help w/ nonlinear regression

2007-06-19 Thread S Ellison
Your B coefficient differs by a suspicious-looking factor of 2.30... (ln(10). Does SPSS log() mean log10 or ln? R log(x) uses ln(x). S Eduardo Esteves [EMAIL PROTECTED] 19/06/2007 17:19:35 Dear All, I'd like to fit a kind of logistic model to small data-set using nonlinear least-squares

Re: [R] Could not find lmer function in {Matrix} package

2007-06-19 Thread John Kane
I don't think it's there. I have had a look at the ref doc and lmer does not show up. Have a look at http://finzi.psych.upenn.edu/R/Rhelp02a/archive/67904.html It looks like it's in the lme4 package now. --- Steve Brady [EMAIL PROTECTED] wrote: I am having trouble calling the lmer

[R] : create a PDF file (text (print list) and grafics)

2007-06-19 Thread Ana Patricia Martins
Dear helpers, I need help to create a PDF file like the example --- |Title | --- | | | Text (print a list) |

Re: [R] Histogram

2007-06-19 Thread John Kane
Your subsetting expression in lines does not make any sense at all. Not tested but maybe something like: lines (density(subset(x, x 0.05 x -0.05)bw=SJ), col='red) --- livia [EMAIL PROTECTED] wrote: Hello, I am using the following codes to plot a histogram and density line for x. For the

Re: [R] Controlling text and strip arrangement in xyplot

2007-06-19 Thread Deepayan Sarkar
On 6/19/07, Juan Pablo Lewinger [EMAIL PROTECTED] wrote: I've searched the archives and read the xyplot help but can't figure out the 2 lattice questions below? Consider: library(lattice) DF - data.frame(x=rnorm(20), y=rnorm(20), g1=rep(letters[1:2], 10),

Re: [R] Histograms with strings, grouped by repeat count (w/ data)

2007-06-19 Thread Deepayan Sarkar
On 6/18/07, Matthew Trunnell [EMAIL PROTECTED] wrote: Aha! So to expand that from the original expression, table(table(d$filename, d$email_addr)) 0 1 2 3 253 20 8 9 I think that is exactly what I'm looking for. I knew it must be simple!!! What does the 0 column represent?

[R] how to create .rda data file and load it for contributed package

2007-06-19 Thread Deli Wang
Hi All, I am trying to build an R package. My code and help files work through smoothly when I run Rcmd check. However, examples couldn't pass the check. The reason maybe that the data files I wanted to use were not created and loaded. What I have done is the following: 1. use save command to

Re: [R] plotting order of lines in xyplot panels while using conditioning variable and groups

2007-06-19 Thread Deepayan Sarkar
On 6/19/07, RICHARD PITMAN [EMAIL PROTECTED] wrote: I am using the following code: library(lattice) data-read.csv(data.csv) attach(data) fig-xyplot(S_t~month|event, key= list(text=list(lab=c(Time to first CV event - Data, Survival post

[R] Matrix library error: should never happen; please report

2007-06-19 Thread Jose Quesada
Hi, I got the following error. Sorry but this time I couldn't reproduce it with a simple chunk of code: .TM.repl.i.2col(): drop 'matrix' case ... Error in .nextMethod(x = x, i = i, j = j) : 'i' has no integer column number should never happen; please report In addition: Warning

Re: [R] Controlling text and strip arrangement in xyplot

2007-06-19 Thread Mark Difford
Hi Deepayan, I, and probably quite a few others, will find this very useful until you find the time to wrap up a proper implementation. Many thanks, BestR, Mark. Deepayan Sarkar wrote: On 6/19/07, Juan Pablo Lewinger [EMAIL PROTECTED] wrote: I've searched the archives and read the xyplot

[R] Multiple plot jpeg file

2007-06-19 Thread Bill Hunsicker
R-Help, I am executing a R script and would like to put multiple plots into a single file. For some reason the contents of plotfile.jpg always seem to contain the last plot and not all plots. If I do same thing with pdf, a multiple plot file is created. Can you help me? Regards, Bill Bill

Re: [R] Multiple plot jpeg file

2007-06-19 Thread Marc Schwartz
On Tue, 2007-06-19 at 15:39 -0400, Bill Hunsicker wrote: R-Help, I am executing a R script and would like to put multiple plots into a single file. For some reason the contents of plotfile.jpg always seem to contain the last plot and not all plots. If I do same thing with pdf, a

[R] A question about plots and lists in functions

2007-06-19 Thread Jason Q McClintic
R-helpers: I tried googling and couldn't find anything. I have a function I am sourcing into R that does some calculations to generate a simulated dataset. I currently have a a list set up to store the outputs from the function and a plot of one of them (a set of ordered pairs) like this:

Re: [R] BIC and Hosmer-Lemeshow statistic for logistic regression

2007-06-19 Thread Frank E Harrell Jr
spime wrote: Is there any windows version of Design package??? Soon the new version will will make its way to Windows, probably in a day or two. Frank Frank E Harrell Jr wrote: spime wrote: I haven't find any helpful thread. How can i calculate BIC and Hosmer-Lemeshow

[R] Preconditions for a variance analysis

2007-06-19 Thread Daniel Tahin
Hello everbody, i'm currently using the anova()-test for a small data.frame of 40 rows and 2 columns. It works well, but is there any preconditions for a valid variance analysis, that i should consider? Thank you for your answer, Daniel __

Re: [R] Multiple plot jpeg file

2007-06-19 Thread Prof Brian Ripley
On Tue, 19 Jun 2007, Marc Schwartz wrote: On Tue, 2007-06-19 at 15:39 -0400, Bill Hunsicker wrote: R-Help, I am executing a R script and would like to put multiple plots into a single file. For some reason the contents of plotfile.jpg always seem to contain the last plot and not all

Re: [R] Multiple plot jpeg file

2007-06-19 Thread Marc Schwartz
On Tue, 2007-06-19 at 21:09 +0100, Prof Brian Ripley wrote: On Tue, 19 Jun 2007, Marc Schwartz wrote: On Tue, 2007-06-19 at 15:39 -0400, Bill Hunsicker wrote: R-Help, I am executing a R script and would like to put multiple plots into a single file. For some reason the contents of

[R] axis labels in multiple plots

2007-06-19 Thread Héctor Villalobos
Hi, I'am trying to make a multiple bar plot over a map and I'm having difficulties with the distance between axes labels and the axis. Trying to control this with mgp does not help because it controls both axes simultaneously. For example, with default values (mgp = c(3, 1, 0)) y-axis labels

[R] Speed up R

2007-06-19 Thread Robert McFadden
Dear R Users, I hope that there is someone who has an experience with a problem that I describe below and will help me. I must buy new desktop computer and I'm wondering which processor to choose if my only aim is to speed up R. I would like to reduce a simulation time - sometimes it takes days.

[R] Error handling

2007-06-19 Thread Peter Sajosi
Hello, I have a question about error handling. I run simulation studies and often the program stops with an error, for example during maximum likelihood. I would like the program not to stop but to continue and I would like to ask how the error handling can be set up for this (if it can).

Re: [R] axis labels in multiple plots

2007-06-19 Thread Marc Schwartz
On Tue, 2007-06-19 at 14:31 -0600, Héctor Villalobos wrote: Hi, I'am trying to make a multiple bar plot over a map and I'm having difficulties with the distance between axes labels and the axis. Trying to control this with mgp does not help because it controls both axes simultaneously.

Re: [R] Speed up R

2007-06-19 Thread Matthew Keller
Hi Robert, Here's my 2 cents. 64-bit is a memory issue, not a speed issue per se. If a concern is increasing RAM (which is important in R since objects are stored in RAM), then you will want to get 64 bit if you plan on getting a computer with over 4GB RAM. I'm not sure about this (someone

Re: [R] Error handling

2007-06-19 Thread Thomas Lumley
This is FAQ 7.32 How can I capture or ignore errors in a long simulation? -thomas On Tue, 19 Jun 2007, Peter Sajosi wrote: Hello, I have a question about error handling. I run simulation studies and often the program stops with an error, for example during maximum likelihood. I

Re: [R] Speed up R

2007-06-19 Thread Prof Brian Ripley
On Tue, 19 Jun 2007, Robert McFadden wrote: Dear R Users, I hope that there is someone who has an experience with a problem that I describe below and will help me. I must buy new desktop computer and I'm wondering which processor to choose if my only aim is to speed up R. I would like to

Re: [R] help with using grid to modify ggplot/lattice plots

2007-06-19 Thread Paul Murrell
Hi Vikas Rawal wrote: I want to use grid to modify some boxplots made using ggplot. I would really appreciate if somebody could guide me to a resource on how to use grid to modify such graphics. I guess the basic approach will be similar to using grid to modify lattice graphics. To that

[R] Date and selection

2007-06-19 Thread Chung-hong Chan
Dear R experts, Suppose I have a data.frame recording the date and test results of some subjects like this: Name Date results John 01/01/1991 2 John 02/01/1991 3 John 09/0101991 4 Micheal 02/01/1991 4 Micheal 04/01/1991 5 How to select the earliest (or latest) test result from all

[R] making a Time of Day axis

2007-06-19 Thread Alan Jackson
I am wrestling with time and date data. I came up with a way to plot and label a histogram with time of day on the x-axis, but it seemed like a lot more work than should be necessary. Is there a better way to do what I am trying to do? require(chron) # read input data data =

Re: [R] Date and selection

2007-06-19 Thread jim holtman
Here is one way of doing it: x - Name Date results + John 01/01/1991 2 + John 02/01/1991 3 + John 09/01/1991 4 + Micheal 02/01/1991 4 + Micheal 04/01/1991 5 x - read.table(textConnection(x), header=TRUE, as.is=TRUE) x$Date - as.POSIXct(strptime(x$Date, %m/%d/%Y)) # earliest (early - by(x,

Re: [R] A question about plots and lists in functions

2007-06-19 Thread Greg Snow
?invisible -Original Message- From: Jason Q McClintic [EMAIL PROTECTED] To: r-help@stat.math.ethz.ch r-help@stat.math.ethz.ch Sent: 6/19/07 2:04 PM Subject: [R] A question about plots and lists in functions R-helpers: I tried googling and couldn't find anything. I have a function I am

[R] Help With Sweave:

2007-06-19 Thread M. Jankowski
Hi All, I am running Ubuntu Feisty (7.04) on a Thinkpad T41. I've installed the nowebm package for Ubuntu. Working from this HowTo: http://www.ci.tuwien.ac.at/~leisch/Sweave/example-1.Snw I try to compile the example *.Snw as in the Sweave manual: [EMAIL PROTECTED]:~/Desktop/Sweave/example1$

Re: [R] Help With Sweave:

2007-06-19 Thread Dirk Eddelbuettel
Matt, On 19 June 2007 at 21:23, M. Jankowski wrote: | Hi All, | | I am running Ubuntu Feisty (7.04) on a Thinkpad T41. I've installed | the nowebm package for Ubuntu. Working from this HowTo: | http://www.ci.tuwien.ac.at/~leisch/Sweave/example-1.Snw | I try to compile the example *.Snw as in

Re: [R] Help With Sweave:

2007-06-19 Thread M. Jankowski
Dirk, Your solution worked wonders! This is outstanding! Thank you! Matt On 6/19/07, Dirk Eddelbuettel [EMAIL PROTECTED] wrote: Matt, On 19 June 2007 at 21:23, M. Jankowski wrote: | Hi All, | | I am running Ubuntu Feisty (7.04) on a Thinkpad T41. I've installed | the nowebm package for

  1   2   >