Re: [R] possible bug in image() ??

2005-10-10 Thread vincent
Gareth Davies a écrit : Hi everyone. The function image() seems not to be correctly plotting some matrices that I give it. (I’m using R 2.1.1) ..where the first column in x (vector ccc) is depicted horizontally along the bottom of the image. Hello, here's a way to have an image

[R] (no subject)

2005-10-10 Thread pekar
Hello, Can anybody tell me, please, how to get a matrix of SE of differences (or any SE) from a GLM object? Both model.tables and se.contrast work only for ANOVA objects. I remember there was a disp s directive in GLIM package. I would need something like that. Many thanks. Wishes, Stano Pekar

[R] details about lm()

2005-10-10 Thread Domenico Cozzetto
Dear all, I'd like to get a linear regression of some data, and impose that the line goes through a given point P. I've tried to use the lm() method in the package stats, but I wasn't able to specify the coordinates of the point P. Maybe I should use another method? I also have another question:

[R] interpretation output glmmPQL

2005-10-10 Thread Emmanuelle TASTARD
Hi ! We study the effect of several variables on fruit set for 44 individuals (plants). For each individual, we have the number of fruits, the number of flowers and a value for each variable. Here is our first model in R : y - cbind(indnbfruits,indnbflowers); model1

Re: [R] R version 2.01.1, Crimson Editor and the one from nowhere

2005-10-10 Thread Olivier ETERRADOSSI
Thanks a lot, really, Philippe, for this explanation... and sorry for taking some of your time. Of course your guess is right : I turned to French (and forgot to tell...). So I'll use your second suggestion (turn to english in MDI). Once again this list works amazingly well ! Olivier Philippe

Re: [R] sqlFetch on MySQL-DB

2005-10-10 Thread Prof Brian Ripley
On Mon, 10 Oct 2005, Bernd Weiss wrote: I successfully set up a local MySQL-database. Connecting via RODBC is not problem, the same in fetching 3 of 4 tables. But trying to connect to table 4 fails. author-sqlFetch(test,author) Error in fromchar(unclass(x)) : character string is not in a

Re: [R] possible bug in image() ??

2005-10-10 Thread Uwe Ligges
I guess what you see is the limited resolution of your screen rather than a bug in R. Try to produce a reliably image, e.g. some pdf file: pdf(test.pdf) cc=runif(n=1500,min=0.1,max=1.2) ccc=ceiling(cc-1) dd=runif(n=1500,min=0.1,max=1.2) ddd=ceiling(dd-1)

Re: [R] ATLAS version for Rblas.dll under Windows; was: (no subject)

2005-10-10 Thread Uwe Ligges
Bing Ho wrote: Hello, I noticed that the README found in /bin/windows/contrib/ATLAS indicates that the ATLAS version is 3.4.1. According to the ATLAS sourceforge site, 3.6.0 the latest stable version. Does anybody know if the ATLAS Rblas.dll are 3.4.1 or 3.6.0, and if they are not the

[R] R: integration problem

2005-10-10 Thread Clark Allan
hi all an integration problem. i would like an exact or good approximation for the following, but i do not want to use a computer. any suggestions: integral of exp(b*x)/sqrt(1-x^2) where b is a constant greater than or equal to 0 and the integral runs from 0 to 1 any help would be

Re: [R] details about lm()

2005-10-10 Thread vincent
Domenico Cozzetto a écrit : Dear all, I'd like to get a linear regression of some data, and impose that the line goes through a given point P. I've tried to use the lm() method in the package stats, but I wasn't able to specify the coordinates of the point P. Maybe I should use another

Re: [R] interpretation output glmmPQL

2005-10-10 Thread Lorenz . Gygax
We study the effect of several variables on fruit set for 44 individuals (plants). For each individual, we have the number of fruits, the number of flowers and a value for each variable. ... - Glm does not take account of the correlation between the flowers of a unique individual. So we

Re: [R] details about lm()

2005-10-10 Thread Uwe Ligges
[EMAIL PROTECTED] wrote: Domenico Cozzetto a écrit : Dear all, I'd like to get a linear regression of some data, and impose that the line goes through a given point P. I've tried to use the lm() method in the package stats, but I wasn't able to specify the coordinates of the point P. Maybe I

[R] Show Progress in loop

2005-10-10 Thread Rainer M. Krug
Hi I have a loop which is doing time consuming calculations and I would like to be able to have some feedback on where it is in it's calculations. I tried to simply show the counter variable in the loop, but id doesn't work as all display seems to be delayed until the loop is completed. Is

Re: [R] Show Progress in loop

2005-10-10 Thread Peter Dalgaard
Rainer M. Krug [EMAIL PROTECTED] writes: Hi I have a loop which is doing time consuming calculations and I would like to be able to have some feedback on where it is in it's calculations. I tried to simply show the counter variable in the loop, but id doesn't work as all display seems

Re: [R] question about ways to solve nonlinear system

2005-10-10 Thread Uwe Ligges
Leite,Walter wrote: Dear R users I am trying to write an R function to solve for a,b,c in the following system of equations, given any value of x1, x2 and x3: b^2 + 6*b*a + 2*c^2 + 15*a^2 = x1 2*c*(b^2 + 24*b*a + 105*a^2 + 2) = x2 24*(b*a + c^2*(1 + b^2 + 28*b*a) + a*(12 + 48 *b*a +

Re: [R] Show Progress in loop

2005-10-10 Thread Uwe Ligges
Rainer M. Krug wrote: Hi I have a loop which is doing time consuming calculations and I would like to be able to have some feedback on where it is in it's calculations. I tried to simply show the counter variable in the loop, but id doesn't work as all display seems to be delayed until

Re: [R] Show Progress in loop

2005-10-10 Thread Rainer M. Krug
I put print(i) in the loop instead of i, but it still only prints (in the Windows R GUI) i after it finished the calculations. I guess it might be due to the output buffering you mentioned - but how do I unset it? Rainer Peter Dalgaard wrote: Rainer M. Krug [EMAIL PROTECTED] writes: Hi I

Re: [R] R: integration problem

2005-10-10 Thread Uwe Ligges
Clark Allan wrote: hi all an integration problem. i would like an exact or good approximation for the following, but i do not want to use a computer. any suggestions: integral of exp(b*x)/sqrt(1-x^2) Sounds like the problem of integrating the Gaussian density... Uwe Ligges where

Re: [R] Show Progress in loop

2005-10-10 Thread Rainer M. Krug
Thanks - flush.console() did the trick. As you might guess, I am quite new to R. I like the idea of vectorizing the calculation, but I guess it is not possible in this case - I will ask in a new thread. Thanks, Rainer Uwe Ligges wrote: Rainer M. Krug wrote: Hi I have a loop which is

[R] Vectorizing loop

2005-10-10 Thread Rainer M. Krug
Hi I have the following loop and would like to vectorize it. Any ideas if it is possible? Thanks, Rainer Tha Loop: for (i in 2:Result$NoSims) { ppp - runifpoint(Result$NoPlants) K - Kest(ppp) Result$LSim[i,] - sqrt(K$iso / pi) - K$r CM - (Result$LSim[i,] *

Re: [R] Show Progress in loop

2005-10-10 Thread Philippe Grosjean
Hello, You must explicitly use print(), show() on an object -here, use print(i)- in a loop or alternatively, use cat() to display string like: cat(loop, i, \n) With RGui under Windows, there is another subtility: if you have turn on 'Misc - Buffered output' (it is ON by default), all output

Re: [R] Show Progress in loop

2005-10-10 Thread Peter Dalgaard
Rainer M. Krug [EMAIL PROTECTED] writes: I put print(i) in the loop instead of i, but it still only prints (in the Windows R GUI) i after it finished the calculations. I guess it might be due to the output buffering you mentioned - but how do I unset it? Using the user friendly

Re: [R] Show Progress in loop

2005-10-10 Thread vincent
Rainer M. Krug a écrit : Hi I have a loop which is doing time consuming calculations and I would like to be able to have some feedback on where it is in it's calculations. I tried to simply show the counter variable in the loop, but id doesn't work as all display seems to be delayed until

Re: [R] Show Progress in loop

2005-10-10 Thread ernesto
Rainer M. Krug wrote: Hi I have a loop which is doing time consuming calculations and I would like to be able to have some feedback on where it is in it's calculations. I tried to simply show the counter variable in the loop, but id doesn't work as all display seems to be delayed until the

Re: [R] Show Progress in loop

2005-10-10 Thread Prof Brian Ripley
On Mon, 10 Oct 2005, Philippe Grosjean wrote: Hello, You must explicitly use print(), show() on an object -here, use print(i)- in a loop or alternatively, use cat() to display string like: cat(loop, i, \n) With RGui under Windows, there is another subtility: if you have turn on 'Misc -

[R] plot - no main title and missing abscissa value

2005-10-10 Thread Iain Gallagher
Hi all. I have defined a plot thus: par(mar=c(5,5,4,5),las=1, xpd=NA) plot(Day, Ym1Imp, ylim=c(0,100), type=b, bty=l, main=Ym1 Expression, cex=1.3, xaxt=n, yaxt=n) #plot implant data axis(side=1, at=c(0,1,3,5,7,10,14,21), labels=c(0,1,3,5,7,10,14,21)) # label x axis mtext(Day, side =1, at=10,

[R] text(x,y,greek character)

2005-10-10 Thread Roy Little
Dear list, I would like to plot points with two types of labels, one at the data point (the name of the point) and another offset a bit with another factor which is either of the two greek characters alpha or beta. I have tried to get the routine to plot a greek character with expression() or

Re: [R] plot - no main title and missing abscissa value

2005-10-10 Thread Uwe Ligges
Iain Gallagher wrote: Hi all. I have defined a plot thus: par(mar=c(5,5,4,5),las=1, xpd=NA) plot(Day, Ym1Imp, ylim=c(0,100), type=b, bty=l, main=Ym1 Expression, cex=1.3, xaxt=n, yaxt=n) #plot implant data axis(side=1, at=c(0,1,3,5,7,10,14,21), labels=c(0,1,3,5,7,10,14,21)) # label x

Re: [R] matrix operation

2005-10-10 Thread Tuszynski, Jaroslaw W.
There a re a few ways to do it without loop. Here is one: dat = matrix(runif(100), 50,2) dat[,1] = dat[,1] = dat[,2] Jarek \ Jarek Tuszynski, PhD. o / \ Science Applications International Corporation

Re: [R] plot - no main title and missing abscissa value

2005-10-10 Thread Iain Gallagher
Hi. Sorry (esp to Uwe for the repeated messages!) Here is the data and my code in full. Thanks for the help. Data. Day Ym1Imp Ym1sham Semimp Semsham 0 5.785.781.221.36 1 44.36 42.116.26 18.83 3 38.39 14.66 18.02 2.86 5 57.76 1.03

Re: [R] glm contrasts (was: no subject)

2005-10-10 Thread Dieter Menne
pekar at sci.muni.cz writes: Can anybody tell me, please, how to get a matrix of SE of differences (or any SE) from a GLM object? Both model.tables and se.contrast work only for ANOVA objects. I remember there was a disp s directive in GLIM package. I would need something like that.

Re: [R] Vectorizing loop

2005-10-10 Thread Liaw, Andy
Not unless we know what runifpoint() and Kest() are. AFAIK these are not part of base R. If you use functions from add-on packages, please state them so as not to leave others guessing. (This is in the Posting Guide, which you were asked to read.) Andy From: Rainer M. Krug Hi I have

Re: [R] Vectorizing loop

2005-10-10 Thread Rainer M. Krug
Sorry runifpoint() and Kest are from the package spatstat Rainer Liaw, Andy wrote: Not unless we know what runifpoint() and Kest() are. AFAIK these are not part of base R. If you use functions from add-on packages, please state them so as not to leave others guessing. (This is in the

Re: [R] text(x,y,greek character)

2005-10-10 Thread Marc Schwartz
On Mon, 2005-10-10 at 07:59 -0400, Roy Little wrote: Dear list, I would like to plot points with two types of labels, one at the data point (the name of the point) and another offset a bit with another factor which is either of the two greek characters alpha or beta. I have tried to get

Re: [R] details about lm()

2005-10-10 Thread vincent
Uwe Ligges a écrit : [EMAIL PROTECTED] wrote: Domenico Cozzetto a écrit : Dear all, I'd like to get a linear regression of some data, and impose that the line goes through a given point P. I've tried to use the lm() method in the package stats, but I wasn't able to specify the

[R] Question about Survey Package

2005-10-10 Thread Real Miranda Rigoberto
To whom it may concern, I have a question referring to the calculation of variance estimation of the survey package I need to estimate the variance for different Domains but for a stratified sampling desing in several stages. Särndal et al (1992), CAP 10, makes reference to this

[R] lmer / variance-covariance matrix random effects

2005-10-10 Thread Roel de Jong
Hello, has someone written by chance a function to extract the variance-covariance matrix from a lmer-object? I've noticed the VarCorr function, but it gives unhandy output. Regards, Roel de Jong __ R-help@stat.math.ethz.ch mailing list

Re: [R] details about lm()

2005-10-10 Thread Uwe Ligges
[EMAIL PROTECTED] wrote: Uwe Ligges a écrit : [EMAIL PROTECTED] wrote: Domenico Cozzetto a écrit : Dear all, I'd like to get a linear regression of some data, and impose that the line goes through a given point P. I've tried to use the lm() method in the package stats, but I wasn't

[R] R.app window size

2005-10-10 Thread Jason Horn
Hi all, This is a question for any of you who use R.app (OS X). Is there any way to resize the quartz plot window from within R? I know that you can resize the window by dragging the corner of the window, and fro the preferences panel. But is there a way to specify the window size from

[R] decreasing performance of for() loop

2005-10-10 Thread bogdan romocea
Dear useRs, I'm wondering why the for() loop below runs slower as it progresses. On a Win XP box, the iterations at the beginning run much faster than those at the end: 1%, iteration 2000, 10:10:16 2%, iteration 4000, 10:10:17 3%, iteration 6000, 10:10:17 98%, iteration 196000, 10:24:04 99%,

[R] wildcards and removing variables

2005-10-10 Thread Afshartous, David
All, Is there are a wildcard in R for varible names as in unix? For example, rm(results*) to remove all variable or function names that begin w/ results? cheers, Dave ps - please respond directly to [EMAIL PROTECTED]

Re: [R] decreasing performance of for() loop

2005-10-10 Thread bogdan romocea
Nevermind, I found the fix. Declaring the length for out eliminates the performance decrease, out - vector(mode=numeric,length=length(test)) On 10/10/05, bogdan romocea [EMAIL PROTECTED] wrote: Dear useRs, I'm wondering why the for() loop below runs slower as it progresses. On a Win XP

Re: [R] wildcards and removing variables

2005-10-10 Thread Marc Schwartz (via MN)
On Mon, 2005-10-10 at 10:37 -0400, Afshartous, David wrote: All, Is there are a wildcard in R for varible names as in unix? For example, rm(results*) to remove all variable or function names that begin w/ results? cheers, Dave ps - please

Re: [R] sqlFetch on MySQL-DB

2005-10-10 Thread Bernd Weiss
Am 10 Oct 2005 um 7:51 hat christian schulz geschrieben: Hi, there is a problem with the type of attributes - is it varchar!? IMHO you should play a bit with different type's in mysql and the consequence in R. I recognize similar problems with RMySQL, if you have variables with type

Re: [R] wildcards and removing variables

2005-10-10 Thread Johan Sandblom
rm() can take a list of object names as an argument and ls(pattern='^results') gives such a list. So rm(ls(pattern='^results')) would remove all objects that are matched by the regular expression, that is all that begin with 'results' HTH, Johan 2005/10/10, Marc Schwartz (via MN) [EMAIL

Re: [R] wildcards and removing variables

2005-10-10 Thread Gabor Grothendieck
On 10/10/05, Marc Schwartz (via MN) [EMAIL PROTECTED] wrote: On Mon, 2005-10-10 at 10:37 -0400, Afshartous, David wrote: All, Is there are a wildcard in R for varible names as in unix? For example, rm(results*) to remove all variable or function names

Re: [R] wildcards and removing variables

2005-10-10 Thread Prof Brian Ripley
On Mon, 10 Oct 2005, Marc Schwartz (via MN) wrote: On Mon, 2005-10-10 at 10:37 -0400, Afshartous, David wrote: All, Is there are a wildcard in R for varible names as in unix? For example, rm(results*) to remove all variable or function names that begin w/ results?

Re: [R] wildcards and removing variables

2005-10-10 Thread Roger D. Peng
In R 2.2.0, there is the function 'glob2rx()' which can be used for this purpose. As in rm(list = ls(pattern = glob2rx(results*))) -roger Afshartous, David wrote: All, Is there are a wildcard in R for varible names as in unix? For example, rm(results*) to

Re: [R] wildcards and removing variables

2005-10-10 Thread Marc Schwartz (via MN)
On Mon, 2005-10-10 at 16:01 +0100, Prof Brian Ripley wrote: On Mon, 10 Oct 2005, Marc Schwartz (via MN) wrote: On Mon, 2005-10-10 at 10:37 -0400, Afshartous, David wrote: All, Is there are a wildcard in R for varible names as in unix? For example, rm(results*) to

Re: [R] greek symbols using pch

2005-10-10 Thread Earl F. Glynn
FISCHER, Matthew [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] In a plot, can I specify pch to be a greek symbol? (I looked at show.pch() in the Hmisc package but couldn't see the right symbols in there). If not, I guess I can get around this using text(x,y,expression()). I'm

[R] passing char to Fortran routine

2005-10-10 Thread Ingmar Visser
Hello all, I am using an existing Fortran routine that takes a single character string as argument. The routine echoes the argument that I provide. When working on OS X 3.9 there seems to be no problem, ie the Fortran routine nicely echoes my argument. However, I compiled the same package on a PC

Re: [R] plot - no main title and missing abscissa value

2005-10-10 Thread Iain Gallagher
For anyone who's looked at my previously posted problem I have managed to solve the missing graph title by removing the main=Graph Title call from my plot definition and adding a line defining the graph title as a title call. i.e. from plot(Day, Ym1Imp, ylim=c(0,100), type=b, bty=l, main=Ym1

Re: [R] trouble installing AnalyzeFMRI package: please help

2005-10-10 Thread Berton Gunter
maintainer if I can figure out who he is. Any clues? Try reading the docs! library(help='AnalyzeFMRI') -- Bert Gunter __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide!

Re: [R] R.app window size

2005-10-10 Thread Paul Roebuck
On Mon, 10 Oct 2005, Jason Horn wrote: This is a question for any of you who use R.app (OS X). Is there any way to resize the quartz plot window from within R? I know that you can resize the window by dragging the corner of the window, and fro the preferences panel. But is there a way to

Re: [R] passing char to Fortran routine

2005-10-10 Thread Prof Brian Ripley
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Programming questions are appropriate for R-devel, as it says there. The issue is OS-specific, but we don't see what your Fortran code is. If you send a reproducible example to the R-devel list, people may be able

Re: [R] R.app window size

2005-10-10 Thread Rob J Goedman
Jason, ?quartz lists the options, e.g. quartz(width=6, height=7, pointsize=24) All from the console. A better alias for these questions is R-Sig-Mac (r-sig- [EMAIL PROTECTED]). Rob On Oct 10, 2005, at 7:25 AM, Jason Horn wrote: Hi all, This is a question for any of you who use R.app

Re: [R] R: integration problem

2005-10-10 Thread Ravi Varadhan
Hi, If your limits were to be from -1 to +1 (instead of lower limit being 0), your integral is: pi * I_0(b) Where I_0 is the modified Bessel's function of the zeroth order. If it is from 0 to 1, then there is no closed form (the integrand is not symmetric about 0). You must evaluate the

[R] problem with lapply(x, subset, ...) and variable select argument

2005-10-10 Thread joerg van den hoff
I need to extract identically named columns from several data frames in a list. the column name is a variable (i.e. not known in advance). the whole thing occurs within a function body. I'd like to use lapply with a variable 'select' argument. example: tt - function (n) { x -

Re: [R] details about lm()

2005-10-10 Thread vincent
Uwe Ligges a écrit : [EMAIL PROTECTED] wrote: Sorry for my lack of knowledge, but will the above trick really force the regression line to pass through P ? adding (0,0) in this new system of coordinates isn't it equivalent to add P to the dataset in the original system ? Well, you do not

Re: [R] Question about Survey Package

2005-10-10 Thread Thomas Lumley
On Mon, 10 Oct 2005, Real Miranda Rigoberto wrote: I have a question referring to the calculation of variance estimation of the survey package I need to estimate the variance for different Domains but for a stratified sampling desing in several stages. S?rndal et al (1992), CAP 10, makes

[R] RE : interpretation output glmmPQL

2005-10-10 Thread Emmanuelle TASTARD
Thank you for your response. Sorry for insisting but I haven’t understood if the data do not permit to include an individual effect or if it is just the models I run. We have several flowers and several fruits per individual plant. So there is a correlation between the flowers/fruits of one

Re: [R] problem with lapply(x, subset, ...) and variable select argument

2005-10-10 Thread Thomas Lumley
On Mon, 10 Oct 2005, joerg van den hoff wrote: I need to extract identically named columns from several data frames in a list. the column name is a variable (i.e. not known in advance). the whole thing occurs within a function body. I'd like to use lapply with a variable 'select' argument.

Re: [R] problem with lapply(x, subset, ...) and variable select argument

2005-10-10 Thread Gabor Grothendieck
The problem is that subset looks into its parent frame but in this case the parent frame is not the environment in tt but the environment in lapply since tt does not call subset directly but rather lapply does. Try this which is similar except we have added the line beginning with environment

[R] R on a supercomputer

2005-10-10 Thread Kimpel, Mark William
I am using R with Bioconductor to perform analyses on large datasets using bootstrap methods. In an attempt to speed up my work, I have inquired about using our local supercomputer and asked the administrator if he thought R would run faster on our parallel network. I received the following reply:

[R] Under-dispersion - a stats question?

2005-10-10 Thread Martin Henry H. Stevens
Hello all: I frequently have glm models in which the residual variance is much lower than the residual degrees of freedom (e.g. Res.Dev=30.5, Res.DF = 82). Is it appropriate for me to use a quasipoisson error distribution and test it with an F distribution? It seems to me that I could

Re: [R] R on a supercomputer

2005-10-10 Thread Tony Plate
In general, R is not written in such a way that data remain in cache. However, R can use optimized BLAS libraries, and these are. So if your version of R is compiled to use an optimized BLAS library appropriate to the machine (e.g., ATLAS, or Prof. Goto's Blas), AND a considerable amount of

Re: [R] Under-dispersion - a stats question?

2005-10-10 Thread Peter Dalgaard
Martin Henry H. Stevens [EMAIL PROTECTED] writes: Hello all: I frequently have glm models in which the residual variance is much lower than the residual degrees of freedom (e.g. Res.Dev=30.5, Res.DF = 82). Is it appropriate for me to use a quasipoisson error distribution and test it

Re: [R] plot - no main title and missing abscissa value

2005-10-10 Thread Uwe Ligges
Iain Gallagher wrote: Hi. Sorry (esp to Uwe for the repeated messages!) Here is the data and my code in full. Thanks for the help. Data. Day Ym1Imp Ym1sham Semimp Semsham 0 5.785.781.221.36 1 44.36 42.116.26 18.83 3 38.39 14.66 18.02 2.86 5

[R] Has anyone written scripts to read CPS data?

2005-10-10 Thread Bill West
Hello, Has anyone ever written the R code that would extract data from the CPS March Supplements? If not, I'll give it a go. --Bill __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting

[R] labels of a conditioning variable in xyplot

2005-10-10 Thread Nathan Leon Pace, MD, MStat
I am running R 2.1.1 on a Mac g5 under Mac OS 10.4.2. I have an xyplot with a single conditioning variable (8 levels) . Here is the code for the conditioning variable used in the formula argument of xyplot: factor( drugauthoryear, levels = c(

Re: [R] labels of a conditioning variable in xyplot

2005-10-10 Thread Berton Gunter
Error in do.call(pmax, lapply(cond, is.na)) : symbol print-name too long When I delete the labels vector, the code runs without difficulty. Any thoughts on this error message? Yes ... the labels are too long to be printed in the space available. Use shorter labels. For example,

Re: [R] labels of a conditioning variable in xyplot

2005-10-10 Thread Nathan Leon Pace, MD, MStat
This error is a curious one. When I remove the labels vector, the names of the levels are printed by default in the strip without difficulty. The names of the levels have lengths of 14 to 16 characters. My labels had length 18 characters. When I reduce the labels to length 10 characters (as

[R] Writing to a file with fixed precision

2005-10-10 Thread Richard Hedger
Hi, I'm trying to ouput to a filled with a fixed precision: eg. if I have data x=c(1.0,1.4,2.0), I want to be able to ouput the following to a file: 1.00 1.40 2.00 I was wondering if there was a function to do this in R? Thanks, Richard Richard Hedger

[R] iterative output to file by row

2005-10-10 Thread Christina Yau
Hi, I'm sort of a newbie to using R to deal with array data. I'm trying to create a simple filtering function, which outputs only the rows of a data frame that satisfies a specific criterion. I've set up an iterative loop to apply the condition to each row. I can create a new matrix and use

Re: [R] labels of a conditioning variable in xyplot

2005-10-10 Thread Berton Gunter
Well -- that **IS** curious. It sounds to me like a software bug or a typo somewhere (are all your little 's OK?), but now you exceed my modest expertise -- especially on a Mac (which apparently can be curious little devils at times). Deepayan -- where are you? Cheers, Bert -Original

Re: [R] Writing to a file with fixed precision

2005-10-10 Thread Marc Schwartz
On Mon, 2005-10-10 at 19:50 -0400, Richard Hedger wrote: Hi, I'm trying to ouput to a filled with a fixed precision: eg. if I have data x=c(1.0,1.4,2.0), I want to be able to ouput the following to a file: 1.00 1.40 2.00 I was wondering if there was a

Re: [R] Multiple expressions, when using substitute()

2005-10-10 Thread Spencer Graves
Have you received a reply to this post? I couldn't find one, and I couldn't find a solution, even though one must exist. I can get the substitute to work in main but not legend: B - 2:3 eB - substitute(y==a*x^b, list(a=B[1], b=B[2])) plot(1:2, 1:2, main=eB) You should be

Re: [R] iterative output to file by row

2005-10-10 Thread Marc Schwartz
On Mon, 2005-10-10 at 17:04 -0700, Christina Yau wrote: Hi, I'm sort of a newbie to using R to deal with array data. I'm trying to create a simple filtering function, which outputs only the rows of a data frame that satisfies a specific criterion. I've set up an iterative loop to apply the

[R] Sometimes having problems finding a minimum using optim(), optimize(), and nlm() (while searching for noncentral F parameters)

2005-10-10 Thread Ken Kelley
Hi everyone. I have a problem that I have been unable to determine either the best way to proceed and why the methods I'm trying to use sometimes fail. I'm using the pf() function in an optimization function to find a noncentrality parameter that leads to a specific value at a specified

Re: [R] greek symbols using pch

2005-10-10 Thread ecatchpole
On 11/10/05 01:12, Earl F. Glynn wrote,: FISCHER, Matthew [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] In a plot, can I specify pch to be a greek symbol? (I looked at show.pch() in the Hmisc package but couldn't see the right symbols in there). If not, I guess I can get

Re: [R] Sometimes having problems finding a minimum using optim(), optimize(), and nlm() (while searching for noncentral F parameters)

2005-10-10 Thread Gabor Grothendieck
I haven't look at your code but here a couple of things to try: 1. try using the square of the difference rather than the absolute value as your objective so that your objective is differentiable. 2. your objective function may be relatively flat in which case it will be difficult to get a

[R] Is this correct?

2005-10-10 Thread Joe
Dear userR, With the following results, are they correct or acceptable? x - c(1.4, 1.2, 2.8) sum(x) [1] 5.4 sum(x) == 5.4 [1] FALSE (1.4 + 1.2 + 2.8) - 5.4 [1] -8.881784e-16 (1.4 + 1.2) - 2.6 [1] -4.440892e-16 2.6 - 1.5 - 1.1 [1] 0 version _ platform i386-pc-mingw32 arch

Re: [R] Is this correct?

2005-10-10 Thread ecatchpole
See the R FAQ list, section 7. Why doesn't R think these numbers are equal? Ted. On 11/10/05 15:42, Joe wrote,: Dear userR, With the following results, are they correct or acceptable? x - c(1.4, 1.2, 2.8) sum(x) [1] 5.4 sum(x) == 5.4 [1] FALSE (1.4 + 1.2 + 2.8) - 5.4 [1] -8.881784e-16