Re: [R] About infinite value

2007-07-23 Thread Mendiburu, Felipe \(CIP\)
I think that the best thing is to work in logarithmic way, to avoid the limitations of the CPU. If y = 10^400, to do y=400*log(10), to change all you formulate to the logarithmic way and the final result to apply the antilogarithm. Felipe de Mendiburu. Professor of statistic Agrarian

Re: [R] change text labels on a dendrogram

2007-07-23 Thread Mendiburu, Felipe \(CIP\)
Dear Marcela. In the data, if column 1 has the names: rownames(data) -data [, 1] data - date [, - 1] now, to make a dendrogram greetings. Felipe de Mendiburu. Professor of statistic Agrarian National University -La Molina - PERU De: [EMAIL

Re: [R] LSD, HSD,...

2007-07-17 Thread Mendiburu, Felipe \(CIP\)
Dear Adrain, You can see the library agricolae for the functions LSD.test, HSD.test, and Waller.test for Waller-Duncan. The criterion is that LSD is more used for few treatments and HSD for many treatments (more than 5) the test of Waller is Bayes and minimizes the two types of error (I or

Re: [R] type III ANOVA for a nested linear model

2007-07-12 Thread Mendiburu, Felipe \(CIP\)
Dear Carsten In this test, factor B would be representing to a factor of block or repetition according to as the levels of A, B, and C are in the data. Factor C this nested in A, then the model should include: B, A and C nested in A, the difference it is the error. Model: B 1 A 2

Re: [R] R's Spearman

2007-05-31 Thread Mendiburu, Felipe \(CIP\)
Dear Ray, The R's Spearman calculated by R is correct for ties or nonties, which is not correct is the probability for the case of ties. I send to you formulates it for the correlation with ties, that is equal to R. Regards, Felipe de Mendiburu Statistician # Spearman correlation rs with

Re: [R] creating a multivariate set of variables with givenintercorrelations

2007-05-19 Thread Mendiburu, Felipe \(CIP\)
Dear Dimitri, if you wish single the correlations, can use the following script: a-1:10 b- rnorm(10) c- rbinom(10,8,0.3) d- rpois(10,8) corr-cor( cbind(a,b,c,d) ) round(as.dist(corr),2) # or only as.dist(corr) a b c b 0.07 c 0.19 -0.26 d -0.16 -0.13 -0.41

Re: [R] 'substitute' question

2007-03-13 Thread Mendiburu, Felipe \(CIP\)
Dear Renko To modify the script plot(x,y) r2-summary(lm1)$r.squared*100 # label R2text - substitute(paste(R^2, = ,r2),list(r2=r2)) text(-1,1,R2text, col=red) # To see of the coordinates of the graph. Grettings Felipe -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]

Re: [R] Package RODBC

2007-03-07 Thread Mendiburu, Felipe \(CIP\)
- From: Wolfgang Raffelsberger [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 07, 2007 4:50 AM To: Mendiburu, Felipe (CIP) Cc: Alberto Monteiro; r-help@stat.math.ethz.ch Subject: Re: [R] Package RODBC Dear Alberto, please note that special characters (eg a space character) in the Excel

Re: [R] how to apply functions to unbalanced data in long format byfactors......cant get by or aggregate to work

2007-03-07 Thread Mendiburu, Felipe \(CIP\)
Dear Alan, I think that podria to be of utility the function tapply.stat () of the package agricolae. see ?tapply.stat Regards, Felipe. for example: library(agricolae) attach(mydata) set1-tapply.stat(mydata[,2:5],Y,median) set2-tapply.stat(time,Y,function(x) median(x))

Re: [R] Package RODBC

2007-03-06 Thread Mendiburu, Felipe \(CIP\)
Dear Alberto, channel - odbcConnectExcel(test.xls) name1 - tables[1, TABLE_NAME] # the name1 is Sheet1$ it must be: name1 - Sheet1 plan1 - sqlFetch(channel, name1) is ok or plan1 - sqlFetch(channel, Sheet1) Regards, Felipe -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL

Re: [R] lattice histogram

2007-03-04 Thread Mendiburu, Felipe \(CIP\)
Steve, it says resp - rnorm(200) must be resp - rnorm(100) regards Felipe -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of steve Sent: Sunday, March 04, 2007 8:58 AM To: r-help@stat.math.ethz.ch Subject: Re: [R] lattice histogram Hi, When I tried

Re: [R] significant anova but no distinct groups ?

2007-03-02 Thread Mendiburu, Felipe \(CIP\)
You can use the LSD.test or waller.test of the package agricolae that less conservatives than tukey. From: [EMAIL PROTECTED] on behalf of Frederic Jean Sent: Fri 3/2/2007 4:52 PM To: [EMAIL PROTECTED] Subject: [R] significant anova but no distinct groups ?

Re: [R] ordered matrix question

2007-02-27 Thread Mendiburu, Felipe \(CIP\)
Juan Pablo, X is data.frame or matrix X - X[order(X[,4]),] options see help(order) Felipe de Mendiburu -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Juan Pablo Fededa Sent: Tuesday, February 27, 2007 12:47 PM To: R-help@stat.math.ethz.ch Subject: [R]

Re: [R] Multiple conditional without if

2007-02-27 Thread Mendiburu, Felipe \(CIP\)
Dear matthias, newmatrix = oldmatrix[ (oldmatrix[,5]==4 oldmatrix[,6]==1) , ] Felipe -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of bunny , lautloscrew.com Sent: Tuesday, February 27, 2007 1:25 PM To: r-help@stat.math.ethz.ch Subject: [R] Multiple

Re: [R] Multiple conditional without if

2007-02-27 Thread Mendiburu, Felipe \(CIP\)
Matthias, According to the logic, New matrix which is basically the old one except for all entries which have a 4 in the 5 column AND a 1 in the 6th column newmatrix - oldmatrix[ (oldmatrix[,5]!=4 oldmatrix[,6]!=1) , ] --- newmatrix - oldmatrix[ !(oldmatrix[,5]==4 oldmatrix[,6]==1) , ] by,