[R] about R square

2007-04-22 Thread Nitish Kumar Mishra
Hi, I am simply asking about coefficient od determination(R square), is its value more than 1 also posiible. Because it ranges from 0-1. So I want to know that R squre may be more than one. If yes what is its interpretation. Thanking to all of You(R help group). -- Nitish Kumar Mishra Junior

[R] about R square value

2007-04-22 Thread Nitish Kumar Mishra
Hi, I am simply asking about coefficient od determination(R square), is its value more than 1 also posiible. Because it ranges from 0-1. So I want to know that R squre may be more than one. If yes what is its interpretation. Thanking to all of You(R help group). -- Nitish Kumar Mishra Junior

[R] about R square value

2007-04-22 Thread Nitish Kumar Mishra
Hi, I am simply asking about coefficient od determination(R square), is its value more than 1 also posiible. Because it ranges from 0-1. So I want to know that R squre may be more than one. If yes what is its interpretation. Thanking to all of You(R help group). -- Nitish Kumar Mishra Junior

[R] queries

2007-04-22 Thread Nima Tehrani
Dear Help Desk, Is there any way to change some of the labels on R diagrams? Specifically in histograms, I would like to: 1. change the word frequency to count. 2. Make the font of the title (Histogram of …) smaller. 3. Have a different

[R] LaTeX, Sweave, Lattice and Computer Modern fonts

2007-04-22 Thread David Lindelof
Dear useRs, I am pretty sure the answer to my question is out there if I would just take the time to cross-correlate information that's scattered among different email exchanges, useR! presentations, Paul Murrel's website and assorted posters, but would some charitable soul be so kind as to

[R] extracting the mode of a vector

2007-04-22 Thread Benoît Lété
Hello, I have an elementary question (for which I couldn't find the answer on the web or the help): how can I extract the mode (modal score) of a vector? Thanks in advance for your help. [[alternative HTML version deleted]] __

[R] exemple pour l'AFD

2007-04-22 Thread guessoum graba
Bonjours monsieurs Je suis un étudient en 4eme année informatique a l’universite djilali liabes SBA ALGERIE. Je suis entrain de préparer un exposé sur l’AFD et j’ai besoin d’un exemple sous R pour bien présenter mon travail. __

[R] Hola

2007-04-22 Thread Guillermo Valdés
Ey! Tienes q echarle un ojo a mi nuevo vicio en internet...estoy tan seguro de q te va a gustar q te he registrado...sólo falta tu confirmación! ya me cuentas! ;) http://eu1.badoo.com/01738976/in/82997 Esta invitación ha sido enviada con fecha 22/04/07 16:09 a r-help@stat.math.ethz.ch; a

Re: [R] queries

2007-04-22 Thread Ranjan Maitra
First of all, this is not a Help Desk. Second, please make sure that you put an informative subject line: I thought this was spam and was going to delete it. Thanks, Ranjan On Sat, 21 Apr 2007 12:03:24 -0700 (PDT) Nima Tehrani [EMAIL PROTECTED] wrote: Dear Help Desk, Is there any

[R] rmultinom

2007-04-22 Thread woozles48
Hi Can anyone help me? I am not an experienced R user (or statistician!). If I use rmultinom to generate random outcomes of a multinomial distribution, how do i use these in a way to help conduct an exact chi-squared test? woozles48 -- View this message in context:

[R] distance method in kmeans

2007-04-22 Thread Ranga Chandra Gudivada
I am trying to cluster some binary data using k-means . As the regular kmeans available from stats package in R does'nt provide the option to change the distance method. I was wondering there is any package available to specify type of distance measure to be used in k means clustering in R.

Re: [R] distance method in kmeans

2007-04-22 Thread paulandpen
Chandra You could try clustan graphics, cheap and awesome with plenty of preprocessing capabilities of matrices. Given this is one of R's strengths (matrix programming) I would imagine there is code out there that would enable you to generate a matrix for use in k-means. Typically, what I

[R] How to add e.g. lines to a zoo plot?

2007-04-22 Thread Oliver Faulhaber
Hi all, a problem I encounter again and again: I plot a zoo object using plot and then want to add lines or points to this plot. I usually circumvent this problem by adding artificial coloumns to the zoo object before plotting, but I am sure there's a better solution. To be specific: Assume I

Re: [R] How to add e.g. lines to a zoo plot?

2007-04-22 Thread Gabor Grothendieck
You need to use the panel= argument. There are examples in ?plot.zoo For your example its like this (make sure you are using the latest version of zoo, 1.3-0, for this): x - as.Date(c(2002-01-01,2003-01-01,2004-01-01)) y.zoo - zoo(cbind(y1 = c(1,2,3),y2=c(3,4,3)),order.by=x) pnl - function(x,

Re: [R] queries

2007-04-22 Thread Gavin Simpson
On Sat, 2007-04-21 at 12:03 -0700, Nima Tehrani wrote: Dear Help Desk, Is there any way to change some of the labels on R diagrams? Specifically in histograms, I would like to: 1. change the word frequency to count. 2. Make the font of the

[R] Descision boundary in MASS LDA

2007-04-22 Thread Rob Campbell
Hi, Is anyone able to give me references or explain how the decision boundary is calculated by the LDA function in MASS. e.g. p 335-336 of MASS 4th Ed. Since it's curved I'm assuming they're doing something like fitting 2-D Gaussians to the groups and plotting the contour line describing the

[R] labels

2007-04-22 Thread croero
Hello, I would like to add to axis labels special caracters. Instead of writing :plot(simul, xlab=beta, ylab=sigma11) It would be great if I could write something as in LaTeX :plot(simul, xlab=\beta, ylab=\sigma_{11}) Is there a way to do that ? Thank you

Re: [R] labels

2007-04-22 Thread Henrique Dallazuanna
Hi, try this: plot(simul, ylab=expression(beta), xlab=expression(sigma)) -- Henrique Dallazuanna Curitiba-Paraná-Brasil 25° 25' 40 S 49° 16' 22 Ohttp://maps.google.com/maps?f=qhl=enq=Curitiba,+Brazillayer=ie=UTF8z=18ll=-25.448315,-49.276916spn=0.002054,0.005407t=kom=1 On 4/22/07, [EMAIL

Re: [R] queries

2007-04-22 Thread Stephen Tucker
hist(rnorm(100),xlab=Data,ylab=Count,main=) title(main=Histogram of ...,cex=0.5) see ?par for details on xlab, ylab, main, and cex arguments. You can call these from title() or include them in hist(). I called title(main=..) separately to control its size separately from the rest of the text

[R] Open source community help-desks

2007-04-22 Thread Jeffrey Miller
I read the reply earlier in which Nima was naughty-naughty'd for calling us a Help Desk. And, I have to admit that I agree. But then, an open-source listserv is, in essence, a help deskwell, maybe not a desk, but we do help each other. My conflicting feelings about this are better left for a

[R] Intro and a Question

2007-04-22 Thread Daniel J McGoldrick
Hello r-help! My name is Dan McGoldrick, I am a statistical geneticist and I work with ontologies, AI and general genetic data analysis. I was wondering aabout the tryCatch function -- don't really understand the implimentation... What I would like to do is within an R API, test a mysql

Re: [R] Using R to create pdf's from each file in a directory

2007-04-22 Thread Patrick Connolly
On Fri, 20-Apr-2007 at 11:10PM -0500, Jeffrey Horner wrote: | workdir - '/tmp/data' | for (x in dir(workdir,pattern='.csv$')){ |d - read.table(paste(workdir,'/',x,sep=''), sep=\t, header=TRUE) If they're CSV files, I don't think sep = \t will be correct. Try , best --

Re: [R] queries

2007-04-22 Thread Stephen Tucker
My apologies. Second line should be title(main=Histogram of ...,cex.main=0.5) Actually I just realized you can also do hist(rnorm(100),xlab=Data,ylab=Count,cex.main=0.5) ...this way you don't have to call title() separately. --- Stephen Tucker [EMAIL PROTECTED] wrote:

[R] names( d$columnname )

2007-04-22 Thread ivo welch
dear R wizards --- would it make sense for names(d$columnname) to be columnname? I can preserve the columnname through x=subset(dataset, select=columnname), of course, but it would seem that x=d$columnname could also do this. No? Sincerely, /iaw __

Re: [R] names( d$columnname )

2007-04-22 Thread Duncan Murdoch
On 4/22/2007 5:46 PM, ivo welch wrote: dear R wizards --- would it make sense for names(d$columnname) to be columnname? I can preserve the columnname through x=subset(dataset, select=columnname), of course, but it would seem that x=d$columnname could also do this. No? Sincerely, /iaw If

[R] Random Forest

2007-04-22 Thread Ruben Feldman
Hi, I am trying to print out my confusion matrix after having created my random forest. I have put in this command: fit-randomForest(MMS_ENABLED_HANDSET~.,data=dat,ntree=500,mtry=14, na.action=na.omit,confusion=TRUE) but I can't get it to give me the confusion matrix, anyone know how this works?

Re: [R] names( d$columnname )

2007-04-22 Thread ivo welch
yes, this was what I was asking for. I had the notion that one could tag almost anything with a name, and did not appreciate the scope for confusion. thank you for the explanation. regards, /ivo On 4/22/07, Duncan Murdoch [EMAIL PROTECTED] wrote: On 4/22/2007 5:46 PM, ivo welch wrote: dear

[R] Help on manipulating a data frame

2007-04-22 Thread Alfonso Sammassimo
Hi R-experts, I have a large set of weekly data in this format: 2007-01-05 -1.52377151 2007-01-12 1.04787390 2007-01-19 0.61647047 2007-01-26 1.87864283 2007-02-02 0.54992405 2007-02-09 1.96850069 2007-02-16 0.26850159 2007-02-23 1.56305144 2007-03-02 -4.19500573 2007-03-09

Re: [R] names( d$columnname )

2007-04-22 Thread Charles C. Berry
On Sun, 22 Apr 2007, ivo welch wrote: yes, this was what I was asking for. I had the notion that one could tag almost anything with a name, and did not appreciate the scope for confusion. thank you for the explanation. regards, /ivo You haven't told us why you want this behavior. If what

[R] Problem with dgamma ?

2007-04-22 Thread Tong Wang
Hi All, Here 's what I got using dgamma function : nu-.2 nu*log(nu)-log(gamma(nu))+(nu-1)*log(1)-nu*(1) [1] -2.045951 dgamma(1,nu,nu,1) [1] 0.0801333 dgamma(1,nu,nu,0) [1] NaN Warning message: NaNs produced in: dgamma(x, shape, scale, log) Could anyone tell me what is wrong here ?

[R] Estimates at each iteration of optim()?

2007-04-22 Thread DEEPANKAR BASU
I am trying to maximise a complicated loglikelihood function with the optim command. Is there some way to get to know the estiamtes at each iteration? When I put control=list(trace=TRUE) as an option in optim, I just got the initial and final values of the loglikelihood, number of iterations

Re: [R] Help on manipulating a data frame

2007-04-22 Thread Gabor Grothendieck
Do you mean you want to return the first row for each mont for which the value 0? In that case try this. The first group of lines recreates your data frame and calls it DF. by causes f to operate on a subset of rows comprising one month extracting the first row for which the value is positive

Re: [R] Problem with dgamma ?

2007-04-22 Thread ecatchpole
dgamma(x=1, shape=nu, rate=nu, log=TRUE) [1] -2.045951 This is a good example of why you should call parameters by name. Ted. Tong Wang wrote on 04/23/2007 01:59 PM: Hi All, Here 's what I got using dgamma function : nu-.2 nu*log(nu)-log(gamma(nu))+(nu-1)*log(1)-nu*(1)

Re: [R] Using R to create pdf's from each file in a directory

2007-04-22 Thread gecko951
Jeff's code works beautifully with a couple changes to my dataset. I must change my data column MB/s to MBs. R seems to think that the s is another column if I try to use MB/s. Is there a way that I can make R allow special characters in the column names? The second step to getting this to

Re: [R] Random Forest

2007-04-22 Thread Jim Porzak
Rubin, just type fit or print(fit). confusion = TRUE will not be recognized by randomForest. If you are not seeing the confusion matrix, MMS_ENABLED_HANDSET is not a factor and, thus, a regression fit is being done, not classification as you apparently desire. On 4/22/07, Ruben Feldman [EMAIL

[R] Extracing Interval of Time in seconds in R

2007-04-22 Thread Mohammad Ehsanul Karim
Dear List, I want to let R calculate the time (run-time) it requires to run a self-written simulation function. I tried as follows: it enables me to see the starting and finishing time points. # sim.result - function(nsim, ...){ Starting - date() ... #