Re: [R] populating an array

2009-10-15 Thread Charles C. Berry
On Wed, 14 Oct 2009, tdm wrote: Hi, Can someone please give me a pointer as to how I can set values of an array? See ?Subscript and study the examples. What do you suppose array( 1:4, dim=c(2, 2) )[1][2] is? R is not C. HTH, Chuck Why does the code below not

Re: [R] RPostgreSQL: unable to load shared library

2009-10-15 Thread Uwe Ligges
Prof Brian Ripley wrote: On Wed, 14 Oct 2009, Fanfaar wrote: Hello list, I'm using R 2.9.2 on a WinXP system, and I installed the RPostgreSQL library using the package installer. When trying to load it, I get the following error: library('RPostgreSQL') Error in inDL(x, as.logical(local),

[R] Removing Embedded Null characters from text/html

2009-10-15 Thread David Young
Hi, I'm trying to download some data from the web and am running into problems with 'embedded null' characters. These seem to indicate to R that it should stop processing the page so I'd like to remove them. I've been looking around and can't seem to identify exactly what the character is and

Re: [R] performing function on lists where each element is a data frame

2009-10-15 Thread Phil Spector
Are you saying that sapply(xx,function(x)weighted.mean(x$H,x$N)) assuming the list of data frames was called xx, doesn't give the result you want? Could you please elaborate as to why sapply doesn't give the correct result? - Phil Spector

Re: [R] Plot overview xy plots from data frame?

2009-10-15 Thread Jim Lemon
On 10/15/2009 07:40 AM, Joel Fürstenberg-Hägg wrote: Hi, I've got a data frame (556 rows and 36 columns) from which I need to create several xy plots and print to pdf, in order to detect outliers and trends in the data. 16 of the columns contains numerical values, and I would like to create

Re: [R] populating an array

2009-10-15 Thread Kenn Konstabel
Could you possibly consider reading An Introduction to R, especially the first few pages of chapter 5, and also a bit about vectors from chapter 2, and maybe eventually even some other parts... You have x[i][j] where length(i)==1, so x[i] will be a single element. Having [j] there makes no sense

Re: [R] Understanding hclust and dendrogram

2009-10-15 Thread Fearghas MacGregor
I'd recommend The Elements of Statistical Learning by Hastie, Tibshirani, and Friedman. There's a lot of good information on clustering, as well as a wealth of info on many other apsects of classification, machine learning, etc. I can be downoaded, free of charge, in PDF format, from:

[R] hardcoded paths hamper running R on heterogeneous grid

2009-10-15 Thread Philip Kensche
Hi, if I got it right, the --disable-rpath configuration option for R should prevent that library paths are hardcoded in R. Nevertheless, the path to the installation on R on the machine on which I originally installed R *is* hardcoded in the R startup script and also in Rscript. Is this a

Re: [R] Discriminant plot

2009-10-15 Thread Alain Guillet
Hi Alejo, According to my knowledge the two plots are different because in the first one a point belongs to a group depending on its group in the data whereas in the second plot a point belongs to the group predicted by the linear discriminant analysis. I hope somebody will correct me if I am

[R] Estimation in a changepoint regression with R

2009-10-15 Thread FMH
Dear All, I'm trying to do the estimation in a changepoint regression problem via R, but never found any suitable function which might help me to do this. Could someone give me a hand on this matter? Thank you. __ R-help@r-project.org mailing

Re: [R] packaging R

2009-10-15 Thread H Rao
I can license the application under GPL On Wed, Oct 14, 2009 at 6:47 PM, Duncan Murdoch murd...@stats.uwo.cawrote: On 14/10/2009 6:35 PM, H Rao wrote: Hi, I am planning to use R as the backend in my application and VB as the front end. I want to be able to distribute it as a stand alone

Re: [R] sort dates within a factor

2009-10-15 Thread Stefan Uhmann
Hi, late, but here is the feedback. plyr was the way to go, but given my large df, plyr crashed when I applied it to the whole df. So I just took the part of the df to sort, applied plyr to it and then merged it with the original df. Thank you, Xavier Hadley! Stefan xavier.char...@free.fr

Re: [R] change order of bar plot categories

2009-10-15 Thread Wade Wall
Hi Tobias and Felipe, Both of your methods changed to the labels (L,M,H), but not the corresponding values. The methods graph L as H, M as L, and M and H. I have had display problems using ggplot2 before, but it seemed as if it was because I was using Windows XP. I ran the current code using

Re: [R] Estimation in a changepoint regression with R

2009-10-15 Thread Vito Muggeo (UniPa)
There are at least two R packages dealing with changepoint estimation, segmented and strucchange. Two possible relevant papers are available: 1)Journal of Statistical Software for strucchange (2002, Vol.7, Issue2) 2)Rnews for segmented (2008, 8/1: 20-25) Hope this helps you vito FMH ha

Re: [R] scatterplot3d bug??

2009-10-15 Thread Uwe Ligges
Uwe Ligges wrote: I finally found some time to look at it: Yes, it does not work properly for angles 180 degrees. Will try to find a fix and make a new release soon. Late, but finally the fixed version is on its way to CRAN. Best wishes, Uwe Ligges Best wishes, Uwe Ligges Vivek

Re: [R] packaging R

2009-10-15 Thread Duncan Murdoch
On 15/10/2009 7:00 AM, H Rao wrote: I can license the application under GPL On Wed, Oct 14, 2009 at 6:47 PM, Duncan Murdoch murd...@stats.uwo.ca mailto:murd...@stats.uwo.ca wrote: On 14/10/2009 6:35 PM, H Rao wrote: Hi, I am planning to use R as the backend in my

[R] help: combine multiple 'pairs plots'

2009-10-15 Thread Jesse Poland
I would like to combine multiple pairs plots (each one being a matrix of correlation plots) into a single graphic. I have tried the par() function, which works well to combine several simple graphs. However, the pairs() graph seems to override the par() function and produce an new plot, rather

Re: [R] plotting/examining residuals of a mixed generalised linear model

2009-10-15 Thread Ben Bolker
kath_oreilly wrote: Dear R users, I'm hoping that more experienced users will be able to assist me in examining the model fit of a mixed generalised linear model. The example using the data 'bacteria' within the MASS package will hopefully illustrate what I would like to acheive;

Re: [R] ltm package error for grm (IRT)

2009-10-15 Thread Tom Fletcher
Ben, This is because you do not have all the possible response options represented for each item. For example, in your data below, item 2 has no '1's. I don't know if there is a workaround for this (other than deleting an item or faking a response), or if this is a function of IRT itself?

[R] LondonR Meeting - Free event

2009-10-15 Thread Sarah Lewis
Hi all, The LondonR meeting is finally approaching and I am pleased to say that the venue and agenda have been finalised. Thank you to everyone who has already confirmed their places, and a little reminder to those who have yet to do so. I really hope you can all make it, and I look

Re: [R] RPostgreSQL: unable to load shared library

2009-10-15 Thread Fanfaar
Thanks, Brian and Joe, for the explanations. The libpq DLL was indeed the problem. FYI, it seems to load fine using the PostgreSQL 8.4 libpq.gll, if further testing reveals problems I'll report it back. Arnout On Wed, Oct 14, 2009 at 4:33 PM, Fanfaar fanf...@gmail.com wrote: Hello list, I'm

[R] Complex? import of pdf files (criminal records) into R table

2009-10-15 Thread Biedermann, Jürgen
Hi there, I'm facing the decision if it would be possible to transform several more or less complex pdf files into an R Table-Format or if it has to be done manually. I think it would be a impudent to expect a complete solution, but I would be grateful if anyone could give me an advice on

[R] plotting/examining residuals of a mixed generalised linear model

2009-10-15 Thread kath_oreilly
Dear R users, I'm hoping that more experienced users will be able to assist me in examining the model fit of a mixed generalised linear model. The example using the data 'bacteria' within the MASS package will hopefully illustrate what I would like to acheive; library(MASS) library(nlme)

Re: [R] Handle lot of variables - Regression

2009-10-15 Thread anna0102
Thank you very much! Now it works! I'm aware of the fact, that practically seen it's maybe nonsense to do something like this. But I have to do a Monte Carlo simulation where I want to determine some aspects... It's a complicated story, but a logistic regression (stepwise or not) is a basis for

Re: [R] help: combine multiple 'pairs plots'

2009-10-15 Thread joris meys
Don't know if it will work, but did you try ?layout ? Cheers Joris On Thu, Oct 15, 2009 at 2:39 PM, Jesse Poland jap...@cornell.edu wrote: I would like to combine multiple pairs plots (each one being a matrix of correlation plots) into a single graphic. I have tried the par() function, which

Re: [R] help: combine multiple 'pairs plots'

2009-10-15 Thread joris meys
Don't know if it will work, but did you try ?layout ? Otherwise you can take a look at ?split.screen too. Cheers Joris On Thu, Oct 15, 2009 at 2:39 PM, Jesse Poland jap...@cornell.edu wrote: I would like to combine multiple pairs plots (each one being a matrix of correlation plots) into a

[R] Lattice package - Trellis

2009-10-15 Thread Paul Evans
Hi, I was trying to make a graph using trellis, and my code is: - library(lattice) makeGraph - function(){ trellis.device() tbg - trellis.par.get(background) tbg$col - white trellis.par.set(background,tbg) # Test Data

[R] Sampling procedure

2009-10-15 Thread Marcio Resende
I would like to divide a vector in 9 groups in a way that each number is present in only one group. In a vector of 783 I would like to divide in 9 different groups of 87 Example - matrix(c(1:783),ncol = 1) s1 - as.matrix(sample(Example,87, re = FALSE)) Example - Example[-s1] s2 -

Re: [R] Complex? import of pdf files (criminal records) into R table

2009-10-15 Thread Marc Schwartz
On Oct 15, 2009, at 3:43 AM, Biedermann, Jürgen wrote: Hi there, I'm facing the decision if it would be possible to transform several more or less complex pdf files into an R Table-Format or if it has to be done manually. I think it would be a impudent to expect a complete solution, but

Re: [R] Lattice package - Trellis

2009-10-15 Thread David Winsemius
Perhaps you've not read FAQ: http://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-do-lattice_002ftrellis-graphics-not-work_003f -- David On Oct 15, 2009, at 10:18 AM, Paul Evans wrote: Hi, I was trying to make a graph using trellis, and my code is:

Re: [R] Sampling procedure

2009-10-15 Thread David Winsemius
On Oct 15, 2009, at 10:19 AM, Marcio Resende wrote: I would like to divide a vector in 9 groups in a way that each number is present in only one group. In a vector of 783 I would like to divide in 9 different groups of 87 Example - matrix(c(1:783),ncol = 1) Example -

[R] Best way to get stock quotes

2009-10-15 Thread keifer
What is preferred/better, get.hit.quote, priceIts, or other? -- View this message in context: http://www.nabble.com/Best-way-to-get-stock-quotes-tp25903585p25903585.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org

[R] converting to data.frame

2009-10-15 Thread ms.com
dear allI have a data set with three types (Tree, Sapling, Seedling). I have estimated the correlation values. now i need to bring all the correlation values in a table like the one i have shown in attached file with R codes.could you please give me idea on this problem thanking you MSNepal

Re: [R] Complex? import of pdf files (criminal records) into R table

2009-10-15 Thread Barry Rowlingson
On Thu, Oct 15, 2009 at 3:28 PM, Marc Schwartz marc_schwa...@me.com wrote: On Oct 15, 2009, at 3:43 AM, Biedermann, Jürgen wrote: You don't indicate the OS you are on, but you will want to get a hold of 'pdftotext', which is a command line application that can extract the textual content from

Re: [R] Can R do specific factor analysis?

2009-10-15 Thread Ista Zahn
On Wed, Oct 14, 2009 at 7:00 PM, Tiger Guo tigerguou...@gmail.com wrote: Hello, Can R do factor analysis using eigenvalue greater than one to automatically determine the number of factors to extract? You could write code automate this, but it's easy enough to look at the scree plot and use

Re: [R] Sampling procedure

2009-10-15 Thread Bert Gunter
If I understand what is wanted correctly, this can be a one-liner! -- think whole objects: splitup - function(x,n.groups) #split x into n.groups mutually exclusive sets { lx - length(x) if(n.groups = lx) stop(Number of groups greater than vector length) x - x[sample(lx,lx)]

Re: [R] Complex? import of pdf files (criminal records) into R table

2009-10-15 Thread Marc Schwartz
On Oct 15, 2009, at 10:10 AM, Barry Rowlingson wrote: On Thu, Oct 15, 2009 at 3:28 PM, Marc Schwartz marc_schwa...@me.com wrote: On Oct 15, 2009, at 3:43 AM, Biedermann, Jürgen wrote: You don't indicate the OS you are on, but you will want to get a hold of 'pdftotext', which is a command

Re: [R] help: combine multiple 'pairs plots'

2009-10-15 Thread Jesse Poland
Thanks. However, for each function [ par(mfrow=..); layout(); and split.screen()] the pairs() graphic function creates an new graphic rather than combining into a single graphic. joris meys wrote: Don't know if it will work, but did you try ?layout ? Otherwise you can take a look at

[R] Subset returning unexpected result

2009-10-15 Thread Steve Murray
Dear all, I am attempting to subset a data frame based on a range of latitude values. I want to extract the values of 'interception' where latitude ranges between 50 and 60. I am doing this using the following code, yet it doesn't return the results I expected: test - subset(int1901,

[R] changing a matrix from class data.frame to class dist

2009-10-15 Thread Maxime Pauwels
Dear, I have a data frame object (FSTc) which is in fact a matrix of class data.frame but created from a txt file using the command FSTc-read.table(FSTcmatrix.txt, header=T) I would like to transform it in a distance matrix of class dist to use it with the ade4 package. I'm quite sure this

[R] Bug in cut.POSIXt

2009-10-15 Thread Vitalie S.
Hello Everyone, Before reporting decided to post here first: tt - structure(c(1254238817, 1254238859, 1254238969, 1254239080), class = c(POSIXt, POSIXct), tzone = ) cut.POSIXt(tt, 2) #Error in `levels-.factor`(`*tmp*`, value =

Re: [R] Sampling procedure

2009-10-15 Thread David Winsemius
If parsimony is needed, then define a 9-row matrix and send a randomized indexed version of Example to it: s-matrix(NA, nrow=9, ncol=length(Example)/9) s[,] - Example[sample(Example, length(Example) )] str(s) int [1:9, 1:87] 503 731 708 23 255 675 163 381 361 412 ... Or even:

[R] Two way anova repeated measures and post hoc testing - several questions

2009-10-15 Thread Michael Schacht Hansen
Hi, I am fairly new to R and still trying to figure out how it all works, and I have run into a few issues. I apologize in advance if my questions are a bit basic, I'm also no statistics wizard, so part of my problem my be a more fundamental lack of knowledge in the field. I have a dataset that

Re: [R] Sampling procedure

2009-10-15 Thread Bert Gunter
... except the matrix approach doesn't work if the length of the vector is not exactly divisible by the number of groups. That's why I used split. Cheers, Bert Gunter Genentech Nonclinical Biostatistics -Original Message- From: David Winsemius [mailto:dwinsem...@comcast.net] Sent:

[R] ImageMagick not seen by movie3d function from rgl package

2009-10-15 Thread eugen pircalabelu
Hello R-users, I have downloaded and installed a binary version for Windows OS of ImageMagick (ImageMagick6.5.6-10-q16-windows-dll.exe), I have installed the rgl package and i've tried running the following example from ?movie3d() library(rgl) open3d() plot3d( cube3d(col=green) ) M -

Re: [R] Best way to get stock quotes

2009-10-15 Thread Mark Knecht
Don't know about preferred but I believe the QuantMod package has a command for getting them from Yahoo finance. - Mark On Wed, Oct 14, 2009 at 11:24 PM, keifer jonathan.keith.hagan...@gmail.com wrote: What is preferred/better, get.hit.quote, priceIts, or other? -- View this message in

Re: [R] Sampling procedure

2009-10-15 Thread David Winsemius
OK, you're right. I thought it might be simple fix to increase the number of columns to accommodate, but the recycling conventions trips up that strategy. Thanks; David. On Oct 15, 2009, at 11:55 AM, Bert Gunter wrote: ... except the matrix approach doesn't work if the length of the

Re: [R] Subset returning unexpected result

2009-10-15 Thread Steve Murray
77eb52c6dd32ba4d87471dcd70c8d70001f11...@na-pa-vbe03.na.tibco.com Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Dear Bill and all=2C Yep you were right - for some strange reason (I'm not sure how...)=2C the l= atitude data were of

Re: [R] Subset returning unexpected result

2009-10-15 Thread jim holtman
It would be useful to also post the 'str(int1901)' so that we could see the structure of the dataframe. Is Latitude by chance a 'factor'? You could also put a subset with the data by doing: dput(int1901) On Thu, Oct 15, 2009 at 11:39 AM, Steve Murray smurray...@hotmail.com wrote: Dear all,

Re: [R] Subset returning unexpected result

2009-10-15 Thread David Winsemius
On Oct 15, 2009, at 11:39 AM, Steve Murray wrote: Dear all, I am attempting to subset a data frame based on a range of latitude values. I want to extract the values of 'interception' where latitude ranges between 50 and 60. I am doing this using the following code, yet it doesn't

Re: [R] Clustering for Ordinal data

2009-10-15 Thread Dylan Beaudette
On Wednesday 14 October 2009, Paul Evans wrote: Hi, I just wanted to check whether there is a clustering package available for ordinal data. My data looks something like: #1 #2 #3 #4. A B C D... D B C A... D C A A... where each column represents a sample, and each row some ordinal

Re: [R] Subset returning unexpected result

2009-10-15 Thread Steve Murray
fa3c85ac-06ab-4635-9642-8909552c0...@comcast.net Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Bill=2C It seems to be 'character' - odd...! str(int1901$Latitude) =A0chr [1:61537] 5.75 6.25 6.75 7.25 7.75 8.25 ... Thanks again=2C

Re: [R] Announcement: New R book--50% off today only

2009-10-15 Thread Bert Gunter
I believe this post violates the standards of this list. It's an advertisement. -- Bert Gunter -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of Steven Hong Sent: Wednesday, October 14, 2009 11:45 AM To: r-help@r-project.org

Re: [R] changing a matrix from class data.frame to class dist

2009-10-15 Thread David Winsemius
On Oct 15, 2009, at 11:34 AM, Maxime Pauwels wrote: Dear, I have a data frame object (FSTc) which is in fact a matrix of class data.frame Not sure that is possible (in R terminology anyway.). Dataframes are lists. but created from a txt file using the command

Re: [R] ImageMagick not seen by movie3d function from rgl package

2009-10-15 Thread Duncan Murdoch
On 10/15/2009 12:01 PM, eugen pircalabelu wrote: Hello R-users, I have downloaded and installed a binary version for Windows OS of ImageMagick (ImageMagick6.5.6-10-q16-windows-dll.exe), I have installed the rgl package and i've tried running the following example from ?movie3d() library(rgl)

Re: [R] plotting/examining residuals of a mixed generalised linear model

2009-10-15 Thread kath_oreilly
Thanks Ben, that was what I was looking for. I look forward to the lmer book (Pinheiro and Bates 2000 is very good and has already been helpful) -- View this message in context: http://www.nabble.com/plotting-examining-residuals-of-a-mixed-generalised-linear-model-tp25905522p25911559.html

Re: [R] Announcement: New R book--50% off today only

2009-10-15 Thread Steven Hong
Bert, I'm sorry if it violates the terms. I was careful to read through the posting guidelines here. I was initially thinking of posting to the R- announce list, but the description says that that list is for major announcements. So I saw that the R-help list is for discussion about

[R] calculating p-values by row for data frames

2009-10-15 Thread Christoph Heuck
Hello R-users, I am looking for an elegant way to calculate p-values for each row of a data frame. My situation is as follows: I have a gene expression results from a microarray with 64 samples looking at 25626 genes. The results are in a data frame with the dimensions 64 by 25626 I want to create

[R] QQ-Plot using GAP but no 95% Confidence Bands...

2009-10-15 Thread mister_bluesman
Hi everyone, I have recently installed the gap library in order to create QQ plots. The library works well but was wondering if anyone knew how to create the 95% confidence bands at the top of the QQ plot? Many thanks. Sam. -- View this message in context:

Re: [R] currency conversion function?

2009-10-15 Thread Henrique Dallazuanna
Hi Liviu, Try this function now: foo - function(from, to, date){ url - http://www.oanda.com/convert/classic?script=..%2Fconvert%2Fclassiclanguage=envalue=1; params - sprintf(%sdate=%sexch=%sexch2=margin_fixed=0expr=%sexpr2=SUBMIT=Convert+Nowlang=endate_fmt=us, url,

Re: [R] ImageMagick not seen by movie3d function from rgl package --SOLVED

2009-10-15 Thread eugen pircalabelu
Hello, Thank you Duncan! Actually Sys.getenv(PATH) said the same thing: ImageMagick is in my path (and convert.exe is where it is supposed to be), but after i opened R (to see the actual path in R, as you said), loaded rgl, and run again the example, it worked. I guess that after the software

Re: [R] ImageMagick not seen by movie3d function from rgl package --SOLVED

2009-10-15 Thread Duncan Murdoch
On 10/15/2009 1:01 PM, eugen pircalabelu wrote: Hello, Thank you Duncan! Actually Sys.getenv(PATH) said the same thing: ImageMagick is in my path (and convert.exe is where it is supposed to be), but after i opened R (to see the actual path in R, as you said), loaded rgl, and run again the

Re: [R] help: combine multiple 'pairs plots'

2009-10-15 Thread Greg Snow
What are you trying to accomplish with this? Pairs sets up the device to make the multiple plots and overrides previous splitting. If you tell us what you want to accomplish, then maybe we can tell you a different way to get the result you want. -- Gregory (Greg) L. Snow Ph.D.

Re: [R] currency conversion function?

2009-10-15 Thread Jeff Ryan
OandA now limits fills to 500 days (as indicated by the error). You can of course just request 500 days at a time. The function itself will not automatically do that as that would be clearly abusing the rules that OandA have established. Of course what you do with your own code is your own

Re: [R] help: combine multiple 'pairs plots'

2009-10-15 Thread Richard M. Heiberger
Jesse Poland wrote: I would like to combine multiple pairs plots (each one being a matrix of correlation plots) into a single graphic. I have tried the par() function, which works well to combine several simple graphs. However, the pairs() graph seems to override the par() function and produce

[R] Setting random effects within a category using nlme

2009-10-15 Thread Michael A. Gilchrist
Hello, I will start out with the caveat that I'm not a statistician by training, but have a fairly decent understanding of probability and likelihood. Nevertheless, I'm trying to fit a nonlinear model to a dataset which has two main factors using nlme. Within the dataset there are two Type

Re: [R] SPSS long variable names

2009-10-15 Thread Robert Baer
The problem is the limit of 8 characters long on variable names.[in read.spss??] I just created a file in SPSS 17 and saved it in standard format (.sav) The file had four unique variable NAMES which were much longer than 8 characters (although not 64). I entered two rows of data and saved

[R] Proper syntax for using varConstPower in nlme

2009-10-15 Thread Michael A. Gilchrist
Hello, Excuse me for posting two questions in one day, but I figured it would be better to ask my questions in separate emails. I will again give the caveat that I'm not a statistician by training, but have a fairly decent understanding of probability and likelihood. As before, I'm trying

[R] Problems with rJava and tm packages

2009-10-15 Thread PDXRugger
I am looking to do some text analysis using R and have run into some issues with some of the packages. Im not sure if its my goofy Vista OS or what but using R 2.8.1 i s relatively successful loading the text but the rJava package was messed up somehow: library(tm) library(rJava) Error in if

[R] Warning messages: Reached total allocation of 1023Mb: see help(memory.size)

2009-10-15 Thread Fayanna
Hi there, I run the following code in R and got the warning like that, how can I change the memory.size? Or anything else? Thanks a lot! Faye temp-apply(Idd4.perms$permstats[-stratum1,], + 2,sort) Error: cannot allocate vector of size 47.5 Mb In addition: Warning messages: 1: In

Re: [R] SPSS long variable names

2009-10-15 Thread Orvalho Augusto
Impressive! PSPP produces the sav fine. The sav file produced by the PSPP is seen by SPSS (16) with the long names. I attach my sav produced by the PSPP. And I start to suspect my foreign package version: I am using 0.8.26-1 from the r-cran-foreign a Ubuntu 8.10 package. Can you tell me your

Re: [R] Warning messages: Reached total allocation of 1023Mb: see help(memory.size)

2009-10-15 Thread Steve Lianoglou
Hi, On Oct 15, 2009, at 1:06 PM, Fayanna wrote: Hi there, I run the following code in R and got the warning like that, how can I change the memory.size? Or anything else? Thanks a lot! You haven't told us what type of machine you're on, or how much ram you have (it might very well be that

Re: [R] SPSS long variable names

2009-10-15 Thread Orvalho Augusto
Robert you are right. I updated the foreign package and I can read long names now I have checked the changelog and I found that long names reading were introduced after 0.8.29 while I were using 0.8.26-1. So I am really sorry guys for this mess. R can read long names. Caveman On Thu, Oct

[R] multiple comparison of means with glm model

2009-10-15 Thread Wade Wall
Hi all, I have a data set that I am analyzing and I am trying to do a multiple comparison of means under a glm model. The factors are 2 light treatments and 3 temperature treatments in a complete block design analyzed using a glm. My question is how do I do a multiple comparison of means using

[R] reference on fisher.test()

2009-10-15 Thread Peng Yu
Can somebody point me a book on Fisher's exact test? I looked a few webpages. But the descriptions on the webpages are not very complete. Is there a book on that covers all the aspect of Fisher's exact test that is implemented in R? __

Re: [R] reference on fisher.test()

2009-10-15 Thread RICHARD M. HEIBERGER
On Thu, Oct 15, 2009 at 4:56 PM, Peng Yu pengyu...@gmail.com wrote: Can somebody point me a book on Fisher's exact test? I looked a few webpages. But the descriptions on the webpages are not very complete. Is there a book on that covers all the aspect of Fisher's exact test that is implemented

[R] Trying get away from the for loop

2009-10-15 Thread Jason Rupert
Argh... I just realized the inefficiency of one of my loops so I am trying to get rid of it. I have two data frames: names(SubdivisionHouses) BuildYear, SqrFootage, Exterior names(BuildingCodes) Year, Codes I am trying to add on the the Codes column to according to the BuildYear

Re: [R] Trying get away from the for loop

2009-10-15 Thread David Winsemius
You do not offer a workable example, but it appears you might be doing a merge operation. ?merge merge(SubdivisionHouses, BuildingCodes, by.x=BuildYear, by.y=Year) -- David On Oct 15, 2009, at 5:27 PM, Jason Rupert wrote: Argh... I just realized the inefficiency of one of my loops so I

Re: [R] reference on fisher.test()

2009-10-15 Thread Peng Yu
On Thu, Oct 15, 2009 at 4:19 PM, RICHARD M. HEIBERGER r...@temple.edu wrote: On Thu, Oct 15, 2009 at 4:56 PM, Peng Yu pengyu...@gmail.com wrote: Can somebody point me a book on Fisher's exact test? I looked a few webpages. But the descriptions on the webpages are not very complete. Is there a

[R] tapply() and using factor() on a factor

2009-10-15 Thread Alexander Peterhansl
Dear List, Shouldn't result1 and result2 be equal in the following case? Note that log$RequestID is a factor. That is, is.factor(log$RequestID) yields TRUE. result1 - tapply(log$Flag,factor(log$RequestID),sum) result2 - tapply(log$Flag,log$RequestID,sum) Yet, when I summarize the

[R] information

2009-10-15 Thread rolmedo
Hi!!, i'm Leonardo Olmedo, i'm student of master in Applied Mathematics in UAM and profesor in UNAM from Mexico. My thesis is a Proposal to test a central composite null hypothesis and alternative hypotheses bilateral in normal distribution. I did a program in R for obtain the significance level

[R] Solving an equation in R (and using a loop)

2009-10-15 Thread leohearn
Hi So, I have a dataset and I'm trying to solve for a parameter in an equation using the dataset. Before applying more sophisticated statistical techniques, I want to tell R to solve it out for each observation. I know I have to use a loop for it (and I have done that before, but am a bit rusty),

Re: [R] Solving an equation in R (and using a loop)

2009-10-15 Thread David Winsemius
On Oct 15, 2009, at 5:18 PM, leohearn wrote: So, I have a dataset and I'm trying to solve for a parameter in an equation using the dataset. Before applying more sophisticated statistical techniques, I want to tell R to solve it out for each observation. I know I have to use a loop for it

Re: [R] Solving an equation in R (and using a loop)

2009-10-15 Thread joris meys
I tried : test - 0:1 test2 - f(0:1) plot(test,test2) plot(test,log(test2)) and test - seq(0,1,by=0.1) test2 - sapply(test,f) plot(test,log(test2)) plot(test,test2) with the values you gave. And according to this result, you did nothing wrong. Zero is the only root of

Re: [R] Trying get away from the for loop

2009-10-15 Thread Jason Rupert
Thank you again for the suggestions to use merge: merge(SubdivisionHouses, BuildingCodes, by.x=BuildYear, by.y=Year) It appears to work perfectly for the example shown below: BuildYear-c(1980, 1985, 1975, 1990, 1980) SqrFootage-c(1500, 1650, 1500, 2000, 1450) Exterior-c(Brick, Stone, Siding,

[R] how to install JGR manually?

2009-10-15 Thread Carl Witthoft
Here's the problem: on Windows, the 'jgr.exe' tool starts up by checking for a connecting to the 'net in order to grab the support packages. Well, we have machines at work that are not and never will be connected to the Internet. I tried manually installing all the packages (JGR, Rjava,

Re: [R] Generating a stochastic matrix with a specified second dominant eigenvalue

2009-10-15 Thread Albyn Jones
I just tried the following shot in the dark: generate an N by N stochastic matrix, M. I used M = matrix(runif(9),nrow=3) M = M/apply(M,1,sum) e=eigen(M) e$values[2]= .7 (pick your favorite lambda, you may need to fiddle with the others to guarantee this is second

[R] How to right-align labels in dotchart

2009-10-15 Thread Sean Carmody
I have only just discovered the joys of the dotchart (since I am reading William Cleveland's -- Sean Carmody The Stubborn Mule http://www.stubbornmule.net http://twitter.com/seancarmody [[alternative HTML version deleted]] __

Re: [R] How to right-align labels in dotchart

2009-10-15 Thread Sean Carmody
Pressed send too soon (apologies). Meant to say I have only just discovered the joys of the dotchart (since I am reading William Cleveland's The Elements of Graphing Data). However, I cannot work out how to change the alignment of the text labels from left to right. Regards, Sean. On Fri, Oct

[R] Data frame search and remove questions

2009-10-15 Thread Douglas M. Hultstrand
Hello, I have a couple questions about removing rows from a data frame and creating a new data frame with the removed values. I provided an example data frame (d) below. Questions: 1) How can I search for -999.000 and remove the entire row from data frame d? (all -999 values will be in

Re: [R] Data frame search and remove questions

2009-10-15 Thread David Winsemius
On Oct 15, 2009, at 1:17 PM, Douglas M. Hultstrand wrote: Hello, I have a couple questions about removing rows from a data frame and creating a new data frame with the removed values. I provided an example data frame (d) below. Questions: 1) How can I search for -999.000 and remove the

Re: [R] Solving an equation in R (and using a loop)

2009-10-15 Thread leohearn
Thank you both for your help. I'll ask my advisor for help on the issue tomorrow as perhaps I've made a specification error or I'm taking the wrong approach entirely. I'm a master's student in economics; the equation is a CARA utility function, and the r represents the corresponding individual's

[R] converting to data.frame

2009-10-15 Thread ms.com
dear all I have a data set with three types (Tree, Sapling, Seedling). I have estimated the correlation values. now i need to bring all the correlation values in a table like the one i have shown in attached file with R codes.could you please give me idea on this problem thanking you MS

Re: [R] converting to data.frame

2009-10-15 Thread stephen sefick
Make the example reproducible. Us dput() or make up data that illustrates the problem. The nice folks on this list volunteer their time, so try and make the the help easier to give. And please read the posting guide if you haven't. commented, minimal, self-contained, reproducible code... like

Re: [R] converting to data.frame

2009-10-15 Thread David Winsemius
You probably could have saved some time by installing Hmisc and using rcorr: ---something like: require(Hmisc) typecors - tapply(c.df[ , c(age_obs, Ht_cm, BD_mm, CDA_cm, CDB_cm) ], c.df$type, rcorr ) The upper or lower triangle of those results could have populated most of your table

Re: [R] tapply() and using factor() on a factor

2009-10-15 Thread William Dunlap
-Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of Alexander Peterhansl Sent: Thursday, October 15, 2009 2:50 PM To: r-help@r-project.org Subject: [R] tapply() and using factor() on a factor Dear List, Shouldn't