[R] Please Help pairwise.t.test!!

2009-06-12 Thread Chunhao Tu
Hi R users, My question is, If I have 3 groups, A, B, C and I know mean of A =20, B=21, and C=20.5 and I also know the standard error of A =1.1, B=2.2, C=3.2. Plus, I know A has 30 observations, B has 78, C has 45. But I do not have the raw data. Can I use pairwise.t.test to conduct a

Re: [R] deSolve question

2009-06-12 Thread Thomas Petzoldt
insun nam wrote: Dear All, I like to simulate a physiologically based pharmacokinetics model using R but am having a problem with the daspk routine. The same problem has been implemented in Berkeley madonna and Winbugs so that I know that it is working. However, with daspk it is not, and the

Re: [R] deSolve question

2009-06-12 Thread Karline
In-Sun, It is very simple. You define your state variables in the following order: y - c(Agi = 0,Alu = 0, Abr = 0, Ah = 0, Ali = 0, Ak = 0, Am = 0, Ask = 0, Aad = 0, Apa = 0, Asp = 0, Aar = 0, Ave = 0) and your rates of change in another order: dy = c(dAar, dAve, dAlu, dAli, dAbr,

[R] Sending a function as an argument to C code.

2009-06-12 Thread Christophe Genolini
Hi the list, I am writing a function (myFunc) that is using an other function (let say distance). +++ dist1 - function(x,y)dist(rbind(x,y)) dist2 - function(x,y)y2 myFunc - function(x,distance){ cat(...\n) cat(distance(1,x)) } myFunc(x=3,distance=dist1)

Re: [R] gfortran command not found?

2009-06-12 Thread chaogai
Hi Alon, It works for me. According to YAST I got libgfortran4.3, gcc-43fortran and gcc-fortran installed Kees Marc Schwartz wrote: On Jun 11, 2009, at 12:34 PM, Alon Ben-Ari wrote: Hello, I have openSUSE 11.1 Trying to install randomForest as SU after invoking R

Re: [R] removing elements from a unit vector

2009-06-12 Thread baptiste auguie
Paul Murrell wrote: Hi The bug is now fixed in the development version (thanks to Duncan for the diagnosis and suggested fix). Paul Thank you both for your help and dedication! Best regards, baptiste -- _ Baptiste Auguié School of Physics University of

[R] Changing CRAN package compile option defaults?

2009-06-12 Thread Allan Engelhardt
Is there an easy way to override the compile options when installing packages from CRAN on Unix-style systems? I tried setting CFLAGS, CXXFLAGS, and FFLAGS but they are not picked up. For example (with a random package and adding -mtune only to try to get rid of the default) export

[R] how to trigger variable creation?

2009-06-12 Thread Thomas Liebig
Hello R users, i'm wondering how to trigger variable creation. Whenever a variable is created i want my own function myFun(...) to be started. if (exists(x)) {rm(x)} # after removal of x # any of these calls x-10# should call myFun x=10

Re: [R] Automatically placing legend in location of most whitespace.

2009-06-12 Thread Jim Lemon
Jason Rupert wrote: Just read the following: https://stat.ethz.ch/pipermail/r-help/2003-October/039940.html Is the labcurve function, really the putKey function, in the Hmisc package the best way the to go about automatically placing legend in location of most whitespace? Hi Jason, I

[R] (kein Betreff)

2009-06-12 Thread helios16
Hi all, first of all: Sorry for my bad englis, and now the Question: I have some problems with running R from Java. First i tried using rJava (JRI). But the examples didnt work properly. Now im trying to establish a connection by using Rserve and JRclient (RF503). I have the following code,

[R] How to plot hyperbolic iso-lines of a cost function?

2009-06-12 Thread Nikos Alexandris
Hi R-specialists! I would like to draw some hyperbolic (iso-)lines of a cost function in a bi-dimensional space ( =shapes of a cost function ), based on (the general form): C(x) = c1*Ce + c2*Oe + c3*{ 1 - [ (1 - Ce)^a * (1 - Oe)^b ] } where: - Oe/Ce are Omission/Commission (ranging between 0

[R] Function for AIC or logLIK for nlsList object

2009-06-12 Thread Lindsay Banin
Dear R users, Does anybody have a function to calculate logLik or AIC for nlsList objects? After receiving error messages, another user helped me ascertain that this function is not currently written into R. Many thanks Lindsay __

[R] JRclient.RSrvException Exception: Handshake

2009-06-12 Thread helios16
Hi all, first of all: Sorry for my bad englis, and now the Question: I have some problems with running R from Java. First i tried using rJava (JRI). But the examples didnt work properly. Now im trying to establish a connection by using Rserve and JRclient (RF503). I have the following code,

[R] Comparing model fits for NLME when models are not nested

2009-06-12 Thread Lindsay Banin
Hi there, I am looking to compare nonlinear mixed effects models that have different nonlinear functions (different types of growth curve)embedded. Most of the literature I can find focuses on comparing nested models with likelihood ratios and AIC. Is there a way to compare model fits when

[R] Replacing 0s with NA

2009-06-12 Thread Christine Griffiths
Hello I have a dataset in which I would like to replace 0s with NAs. There is a lot of information on how to replace NAs with 0, but I have struggled to find anything with regards to doing the reverse. Any recommendations would be great. Cheers Christine

Re: [R] Replacing 0s with NA

2009-06-12 Thread Chuck Cleland
On 6/12/2009 4:55 AM, Christine Griffiths wrote: Hello I have a dataset in which I would like to replace 0s with NAs. There is a lot of information on how to replace NAs with 0, but I have struggled to find anything with regards to doing the reverse. Any recommendations would be great. X -

[R] replacing zeros by NAs

2009-06-12 Thread Robert Kinley
something like ... x-c(1,2,3,0,5,6,0) is.na(x[x==0])-T x [1] 1 2 3 NA 5 6 NA Robert Kinley [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

[R] Installing Rmpi on Fedora Linux [was: Re: help installing Rmpi]

2009-06-12 Thread Allan Engelhardt
On 11/06/09 22:46, ALAN SMITH wrote: Hello R users and developers, I would like to install Rmpi so that I may take advantage of all of the CPUs in my computer Package multicore *may* be easier for this. , but I cannot get it to install [...] The configuration file for Rmpi is, unfortunately,

Re: [R] Replacing 0s with NA

2009-06-12 Thread Gavin Simpson
On Fri, 2009-06-12 at 09:55 +0100, Christine Griffiths wrote: Hello I have a dataset in which I would like to replace 0s with NAs. There is a lot of information on how to replace NAs with 0, but I have struggled to find anything with regards to doing the reverse. Any recommendations would

Re: [R] Replacing 0s with NA

2009-06-12 Thread Gabor Grothendieck
Also try this: X[X == 0] - NA or X2 - replace(X, X == 0, NA) On Fri, Jun 12, 2009 at 5:54 AM, Chuck Clelandcclel...@optonline.net wrote: On 6/12/2009 4:55 AM, Christine Griffiths wrote: Hello I have a dataset in which I would like to replace 0s with NAs. There is a lot of information on

Re: [R] Changing CRAN package compile option defaults?

2009-06-12 Thread Prof Brian Ripley
On Fri, 12 Jun 2009, Allan Engelhardt wrote: Is there an easy way to override the compile options when installing packages from CRAN on Unix-style systems? I tried setting CFLAGS, CXXFLAGS, and FFLAGS but they are not picked up. For example (with a random package and adding -mtune only to

Re: [R] Tables without names

2009-06-12 Thread Duncan Murdoch
On 11/06/2009 5:35 PM, Stavros Macrakis wrote: A table without names displays like a vector: unname(table(2:3)) [1] 1 1 1 and preserves the table class (as with unname in general): dput(unname(table(2:3))) structure(c(1L, 1L), .Dim = 2L, class = table) Does that make sense?

Re: [R] replacing zeros by NAs

2009-06-12 Thread tommaso_unifi
Other method: a-matrix(seq(1,20,2), 4,5) a[c(1:2),c(2:4)]-0 a[a==0]-NA - Original Message - From: Robert Kinley kinley_rob...@lilly.com To: r-help@r-project.org Sent: Friday, June 12, 2009 11:59 AM Subject: [R] replacing zeros by NAs something like ... x-c(1,2,3,0,5,6,0)

Re: [R] Comparing model fits for NLME when models are not nested

2009-06-12 Thread Peter Flom
Lindsay Banin l.bani...@leeds.ac.uk wrote Hi there, I am looking to compare nonlinear mixed effects models that have different nonlinear functions (different types of growth curve)embedded. Most of the literature I can find focuses on comparing nested models with likelihood ratios and AIC. Is

Re: [R] Installing Rmpi on Fedora Linux [was: Re: help installing Rmpi]

2009-06-12 Thread Allan Engelhardt
For future reference, I put up the instructions here: http://www.cybaea.net/Blogs/Data/R-tips-Installing-Rmpi-on-Fedora-Linux.html Allan On 12/06/09 10:59, Allan Engelhardt wrote: On 11/06/09 22:46, ALAN SMITH wrote: Hello R users and developers, I would like to install Rmpi so that I may

Re: [R] Optimization Question

2009-06-12 Thread Paul Smith
On Thu, Jun 11, 2009 at 9:56 PM, Brecknock, Peterpeter.breckn...@bp.com wrote: Apologies if this is not the correct list for this question. The Rglpk package offers the following example in its documentation library(Rglpk) ## Simple mixed integer linear program. ## maximize: 3 x_1 + 1 x_2 +

Re: [R] R 2.9.0 on AIX 5.3: Error: Invalid DESCRIPTION file

2009-06-12 Thread Dr. Loris Bennett
loris.benn...@fu-berlin.de (Loris Bennett) writes: Hi, I am trying to install R 2.9.0 on AIX 5.3. During the 'make' run I get the following error: Error: Invalid DESCRIPTION file Invalid Priority field. Packages with priorities 'base' or 'recommended' or 'defunct-base' must

Re: [R] GRASS raster data processing

2009-06-12 Thread Roger Bivand
Perhaps reading ?readRAST6 would help? It does say: vname: A vector of GRASS 6.0 raster file names so you could write: Kar - readRAST6(c(Incis_Kar, DEM_Kar), plugin=FALSE) and plot(Incis_Kar ~ DEM_Kar, data=Kar) should get you there - in spearfish: sp - readRAST6(c(erosion1,

[R] fix for RMate (TextMate/E-Texteditor bundle)

2009-06-12 Thread Hans-Peter Suter
Arg, I already needed to fix the bundle. If anyone downloaded it yesterday, please update, the help index building was broken (on Macs). Should work now. Repo/Infos: http://github.com/swissr/rmate.tmbundle/tree/master -- Regards, Hans-Peter __

Re: [R] replacing zeros by NAs

2009-06-12 Thread Henrique Dallazuanna
Try this also: is.na(x) - x == 0 On Fri, Jun 12, 2009 at 6:59 AM, Robert Kinley kinley_rob...@lilly.comwrote: something like ... x-c(1,2,3,0,5,6,0) is.na(x[x==0])-T x [1] 1 2 3 NA 5 6 NA Robert Kinley [[alternative HTML version

[R] Comparing nonlinear regressions for different subsets of data

2009-06-12 Thread Martin Kellner
I have a dataset with four different treatments and two different values for each sample. I need to compare the subsets(the different treatments) somehow. The data look suspiciously much like some kind of e-function to me, or maybe michaelis-menten so they are not linear. With linear models it's

[R] Squaring one column of data

2009-06-12 Thread Kenny Larsen
Hi, A fairly basic problem I think, here although searching the inetrnet doesn't seem to reveal a solution. I have a dataset with two columns of real numbers. It is read in via read.table. I simply need to square the data in the second column and then plot it. I have tried extracting the second

[R] Multinomial logistic regression in an ANOVA-like framework

2009-06-12 Thread Stats Wolf
Dear all, I have a problem for multinomial logistic regression: the response variable is multinomial (score 1-5) and the two predictors are categorical; all that comes from panelists (it's a kind of preference study), which I treat as a block and include in the model (is it correct?). I would

Re: [R] Squaring one column of data

2009-06-12 Thread Kenny Larsen
Have sorted it, it was simple, for anyone else who needs it: z[2] - z[2]*z[2] squares the second column of a data table and writes it back to the second column Kenny Kenny Larsen wrote: Hi, A fairly basic problem I think, here although searching the inetrnet doesn't seem to reveal a

Re: [R] Squaring one column of data

2009-06-12 Thread baptiste auguie
Kenny Larsen wrote: Hi, A fairly basic problem I think, here although searching the inetrnet doesn't seem to reveal a solution. I have a dataset with two columns of real numbers. It is read in via read.table. I simply need to square the data in the second column and then plot it. I have tried

[R] Snap axes to origin rather than around it

2009-06-12 Thread Paul Chatfield
I'm trying to plot a graph where the axes go through 0,0, rather than around it combined with a box round the graph, so x-0:10;y-0:10 plot(x,y) gives me a box but doesn't go through the point 0,0, but stays at a distance. In trying to circumvent this problem, I wrote plot(x,y) axis(1,

[R] External signal in ODE written in C (using deSolve and approx1?)

2009-06-12 Thread Glenn Woodart
Dear list The deSolve package allows you to specify the model code in C or Fortran. Thanks to the excellent vignette this works fine. However I have not yet managed to use forcing functions in C code. In pure R code this works very well with approxfun() specified outside the model:

Re: [R] Snap axes to origin rather than around it

2009-06-12 Thread Marc Schwartz
On Jun 12, 2009, at 7:18 AM, Paul Chatfield wrote: I'm trying to plot a graph where the axes go through 0,0, rather than around it combined with a box round the graph, so x-0:10;y-0:10 plot(x,y) gives me a box but doesn't go through the point 0,0, but stays at a distance. In trying to

Re: [R] Tables without names

2009-06-12 Thread Martin Maechler
DM == Duncan Murdoch murd...@stats.uwo.ca on Fri, 12 Jun 2009 06:09:14 -0400 writes: DM On 11/06/2009 5:35 PM, Stavros Macrakis wrote: A table without names displays like a vector: unname(table(2:3)) [1] 1 1 1 and preserves the table class (as with unname in

[R] Slicing an array

2009-06-12 Thread Jim Lemon
Hi all, I've been trying to work out how to slice an array of arbitrary dimension. I found a message showing how to stick two arrays together, but so far have been unable to transform that into what I need. Assume that I have a four dimensional array for example: array4d , , 1, 1 [,1]

[R] Programmatically copying a graphic to the clipboard

2009-06-12 Thread Hadley Wickham
Hi all, Is there a cross-platform way to do this? On the mac, I cando this by saving an eps file, and then using pbcopy. Is it possible on other platforms? Hadley -- http://had.co.nz/ __ R-help@r-project.org mailing list

Re: [R] Function for AIC or logLIK for nlsList object

2009-06-12 Thread Ben Bolker
Lindsay Banin wrote: Dear R users, Does anybody have a function to calculate logLik or AIC for nlsList objects? After receiving error messages, another user helped me ascertain that this function is not currently written into R. how about: library(nlme) example(nlsList)

[R] Automate a data load and merge

2009-06-12 Thread Jon Loehrke
Hi R list, I would like to automate, or speed up the process from which I take several separate datasets, stored in .csv formate, import and merge them by a common variable. So far I have greatly sped up the loading process but cannot think of a way to automate the merger of all

Re: [R] how to trigger variable creation?

2009-06-12 Thread Thomas Liebig
well, for sure, one option is to trace the garbage collector gc() by a function that enumerates the list of known objects and compares this with its successor. But that's not reliable, as i can't really control when to call the garbage collector. i also don't like to enumerate objects and to

Re: [R] Optimization Question

2009-06-12 Thread spencerg
The 1L, etc., forces the number to be integer: is.integer(1) [1] FALSE is.integer(1L) [1] TRUE Hope this helps. Spencer Paul Smith wrote: On Thu, Jun 11, 2009 at 9:56 PM, Brecknock, Peterpeter.breckn...@bp.com wrote: Apologies if this is not the correct list for this

[R] Gtk objects disappears

2009-06-12 Thread Olivier Nuñez
Dear John, I have a question. When I run a RGtk code in my terminal (without using the R GUI) R --vanilla EOF source(myRGtkcode.R) EOF the GTK objects do not remain on the screen. Until now, I bypass this problem using the following commands: require(tcltk) tkmessageBox(Press to exit) But

Re: [R] triangular plot

2009-06-12 Thread David Carlson
You may have more luck with the triangle plot functions available in other R libraries. In addition to triangle.plot in ade4, you have other options (this may not be an exhaustive list): plot.acomp in compositions tri in cwhmisc.cwhtool triax in plotrix ternary in StatDA ternaryplot in vcd

[R] Sweave recode(car) and Lyx, compiling but not executing on Mac

2009-06-12 Thread Graham Smith
I am just beginning to use Sweave with Lyx on a Mac (R2.8.1). I have 12 chunks of Sweave code that work fine, but this piece: = library(car)

[R] glm binomial logit - removing extra computations

2009-06-12 Thread utkarshsinghal
Hi all, I am using glm function with family binomial(logit) to fit logistic regression model. My data is very big and the algorithm is such that it has to run glm function hundreds of times. Now *I need only the **estimates of the coefficients and std. error in my output, *but apparently

Re: [R] Slicing an array

2009-06-12 Thread Gabor Grothendieck
See the abind package. On Fri, Jun 12, 2009 at 8:36 AM, Jim Lemonj...@bitwrit.com.au wrote: Hi all, I've been trying to work out how to slice an array of arbitrary dimension. I found a message showing how to stick two arrays together, but so far have been unable to transform that into what I

[R] Creating this vector, any suggetions?

2009-06-12 Thread njhuang86
Suppose I have the first vector: c(1, 6, 8, 9) I will like to create a second vector of size 10 composed of 0 and 1's. The second vector will be composed of four 1's and six 0's. The position of the 1's will be specificed by the first vector. So essentially, I want a second vector in the form:

[R] coupled ODE population model

2009-06-12 Thread Justin Frank
I'm fairly new to R, and I'm trying to write out a population model that satisfies the following; the system consists of s species, i= 1, 2,...,s network of interactions between species is specified by a (s x s) real matrix, C[i,j] x[i] being the relative population of the ith species (0 =

Re: [R] Creating this vector, any suggetions?

2009-06-12 Thread Ben Bolker
njhuang86 wrote: Suppose I have the first vector: c(1, 6, 8, 9) I will like to create a second vector of size 10 composed of 0 and 1's. The second vector will be composed of four 1's and six 0's. The position of the 1's will be specificed by the first vector. So essentially, I want a

Re: [R] Creating this vector, any suggetions?

2009-06-12 Thread Henrique Dallazuanna
Try this: x - c(1, 6, 8, 9) tabulate(x, nbins = max(x) + 1) On Fri, Jun 12, 2009 at 11:45 AM, njhuang86 njhuan...@yahoo.com wrote: Suppose I have the first vector: c(1, 6, 8, 9) I will like to create a second vector of size 10 composed of 0 and 1's. The second vector will be composed of

[R] R: Creating this vector, any suggetions?

2009-06-12 Thread Guazzetti Stefano
try this a-c(1, 6, 8, 9) 1*(1:10 %in% a) [1] 1 0 0 0 0 1 0 1 1 0 Stefano -Messaggio originale- Da: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]per conto di njhuang86 Inviato: Friday, June 12, 2009 4:45 PM A: r-help@r-project.org Oggetto: [R] Creating this

Re: [R] Tables without names

2009-06-12 Thread Stavros Macrakis
On Fri, Jun 12, 2009 at 6:09 AM, Duncan Murdoch murd...@stats.uwo.cawrote: On 11/06/2009 5:35 PM, Stavros Macrakis wrote: A table without names displays like a vector: unname(table(2:3)) [1] 1 1 1 and preserves the table class (as with unname in general):

Re: [R] Slicing an array

2009-06-12 Thread Charles C. Berry
Jim, Is do.call( '[', list( array4d,TRUE,TRUE,TRUE,1 ) ) what you want? HTH, Chuck On Fri, 12 Jun 2009, Jim Lemon wrote: Hi all, I've been trying to work out how to slice an array of arbitrary dimension. I found a message showing how to stick two arrays together, but so far

Re: [R] Tables without names

2009-06-12 Thread Gabor Grothendieck
On Fri, Jun 12, 2009 at 10:57 AM, Stavros Macrakismacra...@alum.mit.edu wrote: On Fri, Jun 12, 2009 at 6:09 AM, Duncan Murdoch murd...@stats.uwo.cawrote: On 11/06/2009 5:35 PM, Stavros Macrakis wrote: A table without names displays like a vector:     unname(table(2:3))    [1] 1 1 1 and

Re: [R] triangular plot

2009-06-12 Thread David Winsemius
On Jun 12, 2009, at 10:13 AM, David Carlson wrote: You may have more luck with the triangle plot functions available in other R libraries. In addition to triangle.plot in ade4, you have other options (this may not be an exhaustive list): plot.acomp in compositions tri in cwhmisc.cwhtool

[R] R course in Italy

2009-06-12 Thread r...@quantide.com
Quantide is pleased to announce the above course in Milan: -- Introduction to the R language 6-7th July 2009 Milano Italy -- * Who Should Attend ?

[R] Studentized intervals

2009-06-12 Thread Van Wyk, Jaap
I am trying to find studentized bootstrap intervals for the skewness of a data set. I have tried the following (nerve.dat is a set of data containing observations on one variable) (using Windows XP): x - scan(e:/Flashbackup2009/Nonparametrics/nerve.dat) n - length(x) library(e1071) skewness(x)

Re: [R] Sweave recode(car) and Lyx, compiling but not executing on Mac

2009-06-12 Thread John Fox
Dear Graham, I just tried a similar recode() command using Sweave on a Windows system (not through LyX) and it worked fine. I hope this helps, John -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of Graham Smith Sent: June-12-09

Re: [R] Automate a data load and merge

2009-06-12 Thread jim holtman
See if this works for you: # read into a list and then rbind to single data frame input - do.call(rbind, lapply(files, function(.file){ X - read.csv(.file) X$label - gsub('.csv$', '', .file) # add name X })) # use the reshape package require(reshape) i.melt - melt(input, id=c(label,

Re: [R] Automate a data load and merge

2009-06-12 Thread jim holtman
I think the last should be: output - cast(i.melt, Item_name ~ label, sum) On Fri, Jun 12, 2009 at 9:27 AM, Jon Loehrke jloeh...@umassd.edu wrote: Hi R list, I would like to automate, or speed up the process from which I take several separate datasets, stored in .csv formate, import

Re: [R] Studentized intervals

2009-06-12 Thread Prof Brian Ripley
The help page ?boot.ci says Variance estimates are required for studentized intervals. (and the warning you got repeated the point). Package 'boot' is support software for a book by Davison Hinkley which explains how to used boot.ci() for studentized

Re: [R] Sweave recode(car) and Lyx, compiling but not executing on Mac

2009-06-12 Thread Graham Smith
John, Thanks, its difficult when you don't know where the problem is. The code works fine directly in R on the Mac, and from whta you say it works with Sweave, so it seems to narrow it down to Lyx/Sweave/Mac interaction. Graham 2009/6/12 John Fox j...@mcmaster.ca: Dear Graham, I just tried a

Re: [R] Comparing model fits for NLME when models are not nested

2009-06-12 Thread Robert A LaBudde
At 05:42 AM 6/12/2009, Lindsay Banin wrote: Hi there, I am looking to compare nonlinear mixed effects models that have different nonlinear functions (different types of growth curve)embedded. Most of the literature I can find focuses on comparing nested models with likelihood ratios and AIC.

[R] package Rgraphviz or similar

2009-06-12 Thread Robbie Morrison
Hello R users I am looking for a package to visualize relatively planar directed graphs, with say 100 nodes and specified using an adjacency list. 'Rgraphviz', currently listed on the R-FAQ, seemed suitable (FAQ version 2.9.2009-06-05) But when I looked for the package, I found it had been

Re: [R] package Rgraphviz or similar

2009-06-12 Thread Martin Morgan
Robbie Morrison wrote: Hello R users I am looking for a package to visualize relatively planar directed graphs, with say 100 nodes and specified using an adjacency list. 'Rgraphviz', currently listed on the R-FAQ, seemed suitable (FAQ version 2.9.2009-06-05) But when I looked for the

[R] FBI Homicide data?

2009-06-12 Thread Mario Valle
Dear all, do you know if it's available and where the FBI Homicide dataset? It has at least the following columns: victim age, homicide age. A scatterplot of this data is visible here: http://www.uml.edu/gallery/main.php?g2_itemId=6016 Thanks for your help! mario

[R] using lattice dotplot with two equal data points

2009-06-12 Thread Chosid, David (FWE)
I'm wondering if I am dealing with a limitation in lattice. It's probably due to my own limitations though. I'm working with a lattice dotplot. The x-axis is set at free. In one panel, there are only two data points that have equal x-axis values. Since no range exists, lattice isn't plotting

Re: [R] Sweave recode(car) and Lyx, compiling but not executing on Mac

2009-06-12 Thread Graham Smith
Just to follow this up. Changing the document encoding in Lyx from the default (whatever that was) to utf8 (with some help from Jay) allowed some samplerecode code to run (it wouldn't run initially), but my original code still won't run. Strangely looking at the Latex code window in Lyx shows

Re: [R] Mixture of normals

2009-06-12 Thread Jim Silverton
Can anyone send me the R code for fitting a mixture of normal distributions. Or in fact any'combination' of mixtures of distributions. I looke dta mix but it is still not clear to me. Jim [[alternative HTML version deleted]] __

Re: [R] Mixture of normals

2009-06-12 Thread David Winsemius
The package mixtools appears a more appropriate place to look. On Jun 12, 2009, at 2:57 PM, Jim Silverton wrote: Can anyone send me the R code for fitting a mixture of normal distributions. Or in fact any'combination' of mixtures of distributions. I looke dta mix but it is still not clear

Re: [R] Sweave recode(car) and Lyx, compiling but not executing on Mac

2009-06-12 Thread Graham Smith
While this is a bit embarrassing , it seems I had two problems, one was that the recode command seems to need utf8 coding rather than the Lyx default (which is fine), plus I had typing error in the data set, which is not fine :-(. I rewrote my code using the with command which allowed it to run,

Re: [R] Mixture of normals

2009-06-12 Thread David Winsemius
On Jun 12, 2009, at 3:13 PM, David Winsemius wrote: The package mixtools appears a more appropriate place to look. ... as well as: http://cran.r-project.org/web/views/Cluster.html On Jun 12, 2009, at 2:57 PM, Jim Silverton wrote: Can anyone send me the R code for fitting a mixture of

[R] xtable for plm objects

2009-06-12 Thread Stephen J. Barr
Hello, I am trying to use Sweave to write up a report, and I have used the plm package to do some panel models. I am trying to use xtable to make a nice table for my regression objects (returned by the plm command), but I am getting the error: Error in UseMethod(xtable) : no applicable method for

[R] funnel plots

2009-06-12 Thread deanj2k
for the function funnelplot(), how do I include 95% confidence intervals for the effect estimate ( ie. / \ )? -- View this message in context: http://www.nabble.com/funnel-plots-tp24003106p24003106.html Sent from the R help mailing list archive at Nabble.com.

[R] Order data frame

2009-06-12 Thread MarcioRibeiro
Hi listers, I have a data frame with 5 variables... And I want reorder the data frame according a specific variable X... I checked the sort and order functions... In my case I think that the ORDER function is applicable... But I did not understand at all... The idea is simple... Data order by

Re: [R] Market Basket Analysis / Link Analysis

2009-06-12 Thread THEMARKETINGANALYSTS
The concept behind http://themarketinganalysts.com/en/pages/market-basket-analysis/ Market Basket Analysis is relatively simple but it requires a huge server and lots of processing power. If you run into problems and need to run your data on larger machine, please keep us in mind. We would be

Re: [R] Mixture of normals

2009-06-12 Thread Bert Gunter
.. and package mixdist. Google on R mixture models or similar. Bert Gunter Genentech Nonclinical Biostatistics -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of David Winsemius Sent: Friday, June 12, 2009 12:14 PM To: Jim Silverton

Re: [R] xtable for plm objects

2009-06-12 Thread Achim Zeileis
On Fri, 12 Jun 2009, Stephen J. Barr wrote: Hello, I am trying to use Sweave to write up a report, and I have used the plm package to do some panel models. I am trying to use xtable to make a nice table for my regression objects (returned by the plm command), but I am getting the error: Error

Re: [R] Order data frame

2009-06-12 Thread Henrique Dallazuanna
Try this: DF - data.frame(ID = sample(5), v = rnorm(5)) DF[order(DF$ID),] On Fri, Jun 12, 2009 at 3:54 PM, MarcioRibeiro mes...@pop.com.br wrote: Hi listers, I have a data frame with 5 variables... And I want reorder the data frame according a specific variable X... I checked the sort and

Re: [R] Competing risks Kalbfleisch Prentice method

2009-06-12 Thread Ravi Varadhan
Dear Terry, Eleni Heinz, Please forgive me for imposing on your time, but since we have had similar discussions before on this topic, I thought that it would be nice to get your feedback on this problem. I have written a function to compute the cumulative incidence, for a given covariate

[R] R and Sound

2009-06-12 Thread Mike McGonagle
Hello, I recently have started to learn about R, and am interested in using it to generate data that would then get used to produce audio. Basically, I am envisioning using R to create the data, based on probability functions (and fractal data), which then gets output as a text data file, and

[R] Referencing data frames

2009-06-12 Thread Payam Minoofar
Hi, How do I use the string content of a string variable to reference a data frame of the same name? I want to do the typical tasks of 1) building a name with a string variable and using the string variable to create a data frame (or any object) whose name is the string value of the variable

Re: [R] Referencing data frames

2009-06-12 Thread Duncan Murdoch
On 12/06/2009 6:00 PM, Payam Minoofar wrote: Hi, How do I use the string content of a string variable to reference a data frame of the same name? I want to do the typical tasks of 1) building a name with a string variable and using the string variable to create a data frame (or any object)

[R] Fast JSON - R converter?

2009-06-12 Thread Kynn Jones
Is there a *fast* converter between JSON and R? I'm aware of the rjson package, but it is implemented in R, and it is too slow for my purposes. TIA! kynn [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

Re: [R] Fast JSON - R converter?

2009-06-12 Thread Duncan Temple Lang
It is not so much that rjson is implemented in R that makes it slow, just that it does not use vectorized operations. The package RJSONIO http://www.omegahat.org/RJSONIO can be used as a drop-in replacement for rjson and was written to be faster (by using vectorized operations) and

[R] Extracting the name of an object

2009-06-12 Thread Payam Minoofar
With apologies if I missed the answer in the response given to my previous question. How do I extract the name of an object and assign it to a string variable? For example, I have a dataframe named comnoglyc How do I assign this name to a variable dfname such that print(dfname) returns

Re: [R] Extracting the name of an object

2009-06-12 Thread Duncan Murdoch
On 12/06/2009 7:53 PM, Payam Minoofar wrote: With apologies if I missed the answer in the response given to my previous question. How do I extract the name of an object and assign it to a string variable? For example, I have a dataframe named comnoglyc How do I assign this name to a variable

Re: [R] formatting numbers along axes as percents for perspective plot

2009-06-12 Thread David Winsemius
Have you considered multiplying all values by 100? On Jun 12, 2009, at 7:56 PM, Stephen Samaha wrote: Hello, I'm producing a 3D plot using the persp function. All my values for X, Y, and Z are decimals ranging from 0 to 1. I'd like to be able format the three axes so that the tick values

Re: [R] Referencing data frames

2009-06-12 Thread Steven McKinney
Hi Payam, Here's a basic example using pointless data frames and an otherwise useless function to illustrate the issues you want ## Fresh R session with nothing yet defined foo - data.frame(matrix(1:12, ncol = 3)) bar - data.frame(matrix(101:112, ncol = 3)) objects() [1] bar foo

[R] Insignificant variable improves AIC (multinom)?

2009-06-12 Thread Werner Wernersen
Hi, I am trying to specify a multinomial logit model using the multinom function from the nnet package. Now I add another independent variable and it halves the AIC as given by summary(multinom()). But when I call Anova(multinom()) from the car package, it tells me that this added variable is

Re: [R] Sending a function as an argument to C code.

2009-06-12 Thread Ian Fiske
Christophe Genolini wrote: In order to optimize the code, I would like to write myFunc in C. Is it possible, in the C code, to call a function define in R (dist1 or dist2) that will be send to myFunc as an argument ? Christophe You want to read section 5.11: Evaluating R

Re: [R] standard error beta glm

2009-06-12 Thread Ian Fiske
Ricardo Arias Brito wrote: Dear All, Is posible calculate Std. Error for glm as lm, using cov(hat beta) = phi * solve(t(X) %*% hat W %*% X)^-1 on R? Who is hat W and phi output glm? y=rpois(20,4) fit.glm - glm(y ~ x, family=poisson summary(fit.glm) Fitted to a model glm using

Re: [R] [R-help] how to install own R withour root?

2009-06-12 Thread Daofeng Li
Hi, i had intstalled R in my home directory and i can run the new install R from /path_of_my_home/R/bin/R but when i type R, it runs the system installed older R 2.4 can i just type an R command and it runs my new installed R? Thanks! On Tue, Jun 9, 2009 at 4:00 PM, Paul Hiemstra

Re: [R] [R-help] how to install own R withour root?

2009-06-12 Thread Bill.Venables
You need to adjust your PATH environment variable so that the /path_of_my_home/R/bin comes ahead of the system R/bin directory. (Or you can simply remove the system R/bin and substitute your own R/bin. W. From: r-help-boun...@r-project.org