R: [R] How to plot this
Hi, looking at ?plot.density you will find a zero.line argument: set it to FALSE and no gray lines will appear in the plot. plot(density(y), zero.line = F, main= , ann = F, xlim = c(0, 4), ylim = c(0, 1), lty = 2, col = 4, axes = F) #and the add mtext(side = 1, line = 0, text = Environmental gradient ) mtext(side = 2, line = 0, text = Abundance of species ) arrows(0, 0, 4, 0, angle = 15, length = 0.1, lwd=2) arrows(0, 0, 0, 1, angle = 15, length = 0.1, lwd=2) Hope this helps Stefano -Messaggio originale- Da: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] conto di [EMAIL PROTECTED] Inviato: mercoledì 17 novembre 2004 7.39 A: [EMAIL PROTECTED] Oggetto: [R] How to plot this Hi there, I produced a plot using the following codes: y-rnorm(1000, 2, 0) x0-c(0, 0) y0-c(0, 0) y1-c(0, 1) x1-c(0, 4) plot(density(y), ylab=Abundance of species, xlab=Environmental gradient, main= , xlim=c(0, 4), ylim=c(0, 1), lty=2, col=4, xaxt=n, yaxt=n, frame.plot=F) lines(x0, y1) # add an axis lines(x1, y0) # add an axis arrows(3.95, 0, 4, 0, angle = 15, length = 0.1) arrows(0, 0.98, 0, 1, angle = 15, length = 0.1) Please help me to remove the grey horizontal line and put the axis labels closer to the axes. And also appreciate any suggestions on how to make those arrows look nicer, e.g. a filled small arrow for each axis, like what from points(0, 1, pch=17), but a slightly narrowed one. Thanks. Regards, Jin Li Jin Li, PhD Climate Impacts Modeller CSIRO Sustainable Ecosystems Atherton, QLD 4883, Australia [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R 2.0.0 Installation Problem
David Rocke wrote: I and my students have been having an odd problem with this release, which is that packages are disappearing. After installation the package is found with the library command, but later in the same session or in a later session, the library command returns a not found error. Then later it is back. Happening on both Windows and OS X, mostly but not entirely with Bioconductor packages. Please tell us more details. It never happened to anybody else that packages dissapear. Are the files still at the correct location? Have you instaled into another library tree? Uwe Ligges David --- | David M. Rocke, Professor Phone: (530) 752-0510 | | Division of Biostatistics (Medicine) and(530) 752-7368 | | Department of Applied Science (Engineering) | | Co-Director of IDAV FAX:(530) 752-8894 | | University of California, Davis E-mail: [EMAIL PROTECTED] | | Davis, CA 95616-8553 www.cipic.ucdavis.edu/~dmrocke | __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] CDs for R?
I note similar discussions re. 'linux live' distributions, and another key point made there is that, with a moving target (ie. several significant upgrades a year), one shouldn't contribute to the vast mountain of landfill CDRs already represent. Which makes me wonder about changing the model a bit ie. folks who want it on CD send a CDRW or USB key with a stamped, self-addressed enveloped to somewhere (central, or the 'buddy list' already suggested) where the requested files will be burnt on. The 'cost' of burning these could be seen as one consequence of the GPL! That way, most of the 'manufacture distribution' costs stay where they should ie. with the person who wants the CD, and we aren't generating more rapidly-useless CDs... Stuart - Original Message - From: Jari Oksanen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Wednesday, November 17, 2004 6:25 AM Subject: Re: [R] CDs for R? On 16 Nov 2004, at 23:39, (Ted Harding) wrote: Some of us are on narrow bandwidth dialup connections, so downloading large quantities of stuff is out of the question (e.g. at approx. 5min/MB, it would take over 2 days to download a single CD). The meat of CRAN (including contributed packages and documentation) is enough to fill 5 CDs, though one individual probably wouldn't be interested in all of that. 5 CDs sounds 4 too many. I once burnt CDs for my students, and they fitted nicely in one CD (Windows binaries, all packages as Windows binaries and sources, contributed documents). I guess you can fit Windows, Mac and some Linux binaries all in one CD. Now comes my suggestion to CRAN maintainer: this all would be easier, if you would produce a CD image file ('iso') that would contain a snapshot of the latest version: main binaries, all contributed packages, and docs. Getting somebody to help downloading this iso would be much easier than trying to collect all first and then make up your own cd image. Actually, only Windows and Mac users need binary versions of packages. The former because they don't have tools to install from source, the latter because they don't know that they have the tools (being command line challenged). To Dirk Eddelbuettel: Yes indeed, Ubuntu gives human face to Debian and is a much more pleasant experience. However, changing OS for R may be asking too much. Further, Ubuntu/Debian comes with a tiny and biased selection of packages, and if that's not your kind of bias, you have got to go to the Internet again. Further, Ubuntu (and other Linuxes) lag behind R. The current Ubuntu release comes with R 1.9.1, and it won't be upgraded but in the next release scheduled for April 2005 (and just in the same time as the next R, so that Ubuntu will be one R version off again). I guess the lag is even worse in packages. cheers, jari oksanen -- Jari Oksanen, Oulu, Finland __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html This message has been scanned but we cannot guarantee that it and any attachments are free from viruses or other damaging content: you are advised to perform your own checks. Email communications with the University of Nottingham may be monitored as permitted by UK legislation. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] how to estimate conditional density
On 17-Nov-04 Yulei He wrote: Hi, there. Suppose I have a bivariate data set y1 and y2. Can anybody tell me how to estimate the conditional density of f(y1|y2) and vice versa? Thanks. Yulei In the absence of a parametric model for the distribution, a simple-minded approach could be the following: 1. Use 'f-kde2d(...)' from the MASS library to generate a kernel density estimate of the bivariate distribution, ensuring that your (y1,y2) grid includes the value of y2 at which you want to get f(y1|y2). Suppose that different values of y2 correspond to different rows of the matrix f$z in the returned result (see ?kde2d). 2. For the row [i] corresponding to the conditioning value of y2, normalise the values so that sum(f$z[i,]*dy1)=1, where dy1 is the step between different values of y1 in the grid used in (1). The resulting normalised row of values is then an estimate of f(y1|y2), for each such value of y2. Similarly, applying (2) to the columns of f$z, you can get an estimate of f(y2|y1). [Note: for each single value of y2, you don't need to estimate the density of y2, i.e. for this purpose you can forget about the definition f(y1,y2)/f(y2) of f(y1|y2).] Hoping this helps, Ted. E-Mail: (Ted Harding) [EMAIL PROTECTED] Fax-to-email: +44 (0)870 094 0861 [NB: New number!] Date: 17-Nov-04 Time: 09:37:20 -- XFMail -- __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] The hidden costs of GPL software?
Hello, In the latest 'Scientific Computing World' magazine (issue 78, p. 22), there is a review on free statistical software by Felix Grant (doesn't have to pay good money to obtain good statistics software). As far as I know, this is the first time that R is even mentioned in this magazine, given that it usually discuss commercial products. In this article, the analysis of R is interesting. It is admitted that R is a great software with lots of potentials, but: All in all, R was a good lesson in the price that may have to be paid for free software: I spent many hours relearning some quite basic things taken for granted in the commercial package. Those basic things are releated with data import, obtention of basic plots, etc... with a claim for a missing more intuitive GUI in order to smooth a little bit the learning curve. There are several R GUI projects ongoing, but these are progressing very slowly. The main reason is, I believe, that a relatively low number of programmers working on R are interested by this field. Most people wanting such a GUI are basic user that do not (cannot) contribute... And if they eventually become more knowledgeable, they tend to have other interests. So, is this analysis correct: are there hidden costs for free software like R in the time required to learn it? At least currently, for the people I know (biologists, ecologists, oceanographers, ...), this is perfectly true. This is even an insurmountable barrier for many of them I know, and they have given up (they come back to Statistica, Systat, or S-PLUS using exclusively functions they can reach through menus/dialog boxes). Of course, the solution is to have a decent GUI for R, but this is a lot of work, and I wonder if the intrinsic mechanism of GPL is not working against such a development (leading to a very low pool of programmers actively involved in the elaboration of such a GUI, in comparison to the very large pool of competent developers working on R itself). Do not misunderstand me: I don't give up with my GUI project, I am just wondering if there is a general, ineluctable mechanism that leads to the current R / R GUI situation as it stands,... and consequently to a general rule that there are indeed most of the time hidden costs in free software, due to the larger time required to learn it. I am sure there are counter-examples, however, my feeling is that, for Linux, Apache, etc... the GUI (if there is one) is often a way back in comparison to the potentials in the software, leading to a steep learning curve in order to use all these features. I would be interested by your impressions and ideas on this topic. Best regards, Philippe Grosjean ..°})) ) ) ) ) ) ( ( ( ( (Prof. Philippe Grosjean ) ) ) ) ) ( ( ( ( (Numerical Ecology of Aquatic Systems ) ) ) ) ) Mons-Hainaut University, Pentagone ( ( ( ( (Academie Universitaire Wallonie-Bruxelles ) ) ) ) ) 6, av du Champ de Mars, 7000 Mons, Belgium ( ( ( ( ( ) ) ) ) ) phone: + 32.65.37.34.97, fax: + 32.65.37.33.12 ( ( ( ( (email: [EMAIL PROTECTED] ) ) ) ) ) ( ( ( ( (web: http://www.umh.ac.be/~econum ) ) ) ) ) .. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] violinplot options
Tanja Zseby wrote: Hi, I am using the function vioplot() to generate violin plots. Now I would like to add a label to the y axix and a title to the diagram. Just setting ylab didnt work. Is it possible to set such options for the function ? I tried also with the function simple.violinplot, but also with this I couldnt set the options. Kind Regards Tanja Looks like nobody else has responded so far. If you are talking about the function in the package also called vioplot: The function is not very well designed. But since there is not much code in it, it is quite easy to add additional functionality yourself by adapting the whole function. Uwe Ligges __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] R/S-related projects on Sourceforge? Trove Categorization
Hi R-Users and Developers, Several months ago I made a request on Sourceforge to add the R/S - programming language to the _Trove_ categorization. (The Trove is a means to convey basic metainformation about your project.) Today I got the following response of one of the sourceforge admins. SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP If anyone of you knew about R-packages, or projects using the R/S programming language, which are hosted on sourceforge, please reply to this thread. I hope that your answers will enable me to give more then 5 examples of R projects hosted on Sourceforge. Yours Eryk Ps. The ID of my original feature request on Sourceforge is 967697. https://sourceforge.net/tracker/?func=detailatid=350001aid=967697group_id=1 -- Dipl. bio-chem. Witold Eryk Wolski MPI-Moleculare Genetic Ihnestrasse 63-73 14195 Berlin tel: 0049-30-83875219 __(_ http://www.molgen.mpg.de/~wolski \__/'v' http://r4proteomics.sourceforge.net||/ \ mail: [EMAIL PROTECTED]^^ m m [EMAIL PROTECTED] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] persp grid
Joel Bremson wrote: I've got a 4x4 matrix of points from a 2-way ANOVA I'd like to plot. The x,y correspond to the treatment groups and look like this ((1,1),(1,2),(1,3),(1,4),(2,1),...). The z is the 4x4 matrix. How can I get persp to grid the x,y axis with only the numbers 1-4 on both? The first question is whether it will be nice to have a surface by just 4x4 points (of probably non-continous variables), the second point is that it is very hard to have a fixed number of tick marks in persp(). I think it is almost impossible without changing internal code. As an ugly workaround, you can add text add the corresponding positions along the axes using the transformation matrix given in the examples of ?persp. Uwe Ligges Regards, Joel Bremson UC Davis Statistics Dept. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] changing character to a vector name
Laura Holt wrote: Dear R People: I would like to generate a vector/variable name from within a loop to be passed to a table function. This is what I have so far: assign(p1,paste(raw3.df$,rw2$V1[3],sep=)) p1 [1] raw3.df$CITIZEN Life is much easier: Consider to use raw3.df[[rw2$V1[3]]] instead. Uwe Ligges Essentially, I want to use the raw3.df$CITIZEN along with another value to generate a table. However, I'm stuck here. I know this is incredibly stupid. Thanks in advance. Sincerely Laura Holt mailto: [EMAIL PROTECTED] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R/S-related projects on Sourceforge? Trove Categorization
Hi, I have 2 _small_ projects hosted in sf.net that use R FLR :: R for fisheries science (http://flr.sf.net) fsap: fish stock assessment for R (http://sf.net/projects/fsap) The first one is getting some hip and the second is dying ... Hope it helps. Regards EJ On Wed, 2004-11-17 at 09:09, Witold Eryk Wolski wrote: Hi R-Users and Developers, Several months ago I made a request on Sourceforge to add the R/S - programming language to the _Trove_ categorization. (The Trove is a means to convey basic metainformation about your project.) Today I got the following response of one of the sourceforge admins. SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP If anyone of you knew about R-packages, or projects using the R/S programming language, which are hosted on sourceforge, please reply to this thread. I hope that your answers will enable me to give more then 5 examples of R projects hosted on Sourceforge. Yours Eryk Ps. The ID of my original feature request on Sourceforge is 967697. https://sourceforge.net/tracker/?func=detailatid=350001aid=967697group_id=1 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] The hidden costs of GPL software?
So, is this analysis correct: are there hidden costs for free software like R in the time required to learn it? At least currently, for the people I know (biologists, ecologists, oceanographers, ...), this is perfectly true. This is even an insurmountable barrier for many of them I know, and they have given up (they come back to Statistica, Systat, or S-PLUS using exclusively functions they can reach through menus/dialog boxes). I guess you are right, in that the steep initial learning curve could be smoothed for beginners. On the other hand I do not see how a GUI for R could cover more than the bare essentials because the available functionality is so vast. We also have S-Plus at our research institution and even there, I see, that people who do not know about the underlying code have difficulties in using the GUI. I personally believe that it is more a question how one is used to do statistics. Click and drag is the norm. (And I guess it is usually also the norm of how people/scientists use other Software.) In my eyes, using code instead, means that one is able to repeat the steps of an evaluation easily and to document at the same time what has been done. Very soon evaluations (and data handling) can be done far more efficiently than with click and drag. All these advantages outweigh the initial costs by several orders of magnitude. Thus, in my opinion it is more a question of education such that people might realize how they can work efficiently and cleanly. Perhaps one could even say that such an approach is more scientific because, in principal, it can be easily communicated and reproduced. It is, of course, easy for me to make these statements, as in the meantime I have been using S (S-Plus and R) for - gosh - over 10 years. But I see in some projects that I supervise that people get started easily with a snippet of code that I provide and the insight of the usefulness of such a work approach is usually easily within reach. Lorenz - Lorenz Gygax, Dr. sc. nat. Tel: +41 (0)52 368 33 84 / [EMAIL PROTECTED] Centre for proper housing of ruminants and pigs Swiss Federal Veterinary Office __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] beginner's problem in displaying large data
You can also try : ab - matrix(rnorm(1),nc=5) edit(ab) Hope this helps. Spencer Graves a écrit : 1. Did you try dim(sample.data)? Is it actually 2200 by 15? Or are you reading in just some subset of the data? If it is 2200 by 15, could you also please do class(sample.data)? 2. I just got a full listing from the following: (tst - data.frame(array(rnorm(2200), dim=c(2200, 15 You might try this. With R 2.0.0patched under Windows 2000, I got rows 1:2200 flying by 3 times, each with 5 columns. 3. Have you considered doing plots (including qqnorm) of numeric variables and tables of character variables? These can often reveal problems I might never see in a simple scan of numbers. 4. PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html;. At minimum, please tell us which version of R under which operating system, and specifically what you did to get it into R and how you know it's 2200 by 15. hope this helps. spencer graves Terry Mu wrote: I got a sample data (let's call it sample.data), which is about 2200 by 15. I tried to take a look of all data sample.data It shows only a part of data that I thought was a corner. It does not really affect my job, but I thought it is nice to have a look of all data. I can see individual records and they are fine. Is this normal because of buffer size or some reasons? Can I use other commands or change some settings to display all data? Thanks, Terry __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Romain François 25, avenue Guy Moquet 94 400 Vitry sur seine FRANCE ___ ___ [EMAIL PROTECTED] 01 46 80 65 60 06 18 39 14 69 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
Dear Phillippe, Very interesting. The URL of the article is http://www.scientific-computing.com/scwsepoct04free_statistics.html. Best regards, Jan Smit Philippe Grosjean wrote: Hello, In the latest 'Scientific Computing World' magazine (issue 78, p. 22), there is a review on free statistical software by Felix Grant (doesn't have to pay good money to obtain good statistics software). As far as I know, this is the first time that R is even mentioned in this magazine, given that it usually discuss commercial products. In this article, the analysis of R is interesting. It is admitted that R is a great software with lots of potentials, but: All in all, R was a good lesson in the price that may have to be paid for free software: I spent many hours relearning some quite basic things taken for granted in the commercial package. Those basic things are releated with data import, obtention of basic plots, etc... with a claim for a missing more intuitive GUI in order to smooth a little bit the learning curve. There are several R GUI projects ongoing, but these are progressing very slowly. The main reason is, I believe, that a relatively low number of programmers working on R are interested by this field. Most people wanting such a GUI are basic user that do not (cannot) contribute... And if they eventually become more knowledgeable, they tend to have other interests. So, is this analysis correct: are there hidden costs for free software like R in the time required to learn it? At least currently, for the people I know (biologists, ecologists, oceanographers, ...), this is perfectly true. This is even an insurmountable barrier for many of them I know, and they have given up (they come back to Statistica, Systat, or S-PLUS using exclusively functions they can reach through menus/dialog boxes). Of course, the solution is to have a decent GUI for R, but this is a lot of work, and I wonder if the intrinsic mechanism of GPL is not working against such a development (leading to a very low pool of programmers actively involved in the elaboration of such a GUI, in comparison to the very large pool of competent developers working on R itself). Do not misunderstand me: I don't give up with my GUI project, I am just wondering if there is a general, ineluctable mechanism that leads to the current R / R GUI situation as it stands,... and consequently to a general rule that there are indeed most of the time hidden costs in free software, due to the larger time required to learn it. I am sure there are counter-examples, however, my feeling is that, for Linux, Apache, etc... the GUI (if there is one) is often a way back in comparison to the potentials in the software, leading to a steep learning curve in order to use all these features. I would be interested by your impressions and ideas on this topic. Best regards, Philippe Grosjean ..°})) ) ) ) ) ) ( ( ( ( (Prof. Philippe Grosjean ) ) ) ) ) ( ( ( ( (Numerical Ecology of Aquatic Systems ) ) ) ) ) Mons-Hainaut University, Pentagone ( ( ( ( (Academie Universitaire Wallonie-Bruxelles ) ) ) ) ) 6, av du Champ de Mars, 7000 Mons, Belgium ( ( ( ( ( ) ) ) ) ) phone: + 32.65.37.34.97, fax: + 32.65.37.33.12 ( ( ( ( (email: [EMAIL PROTECTED] ) ) ) ) ) ( ( ( ( (web: http://www.umh.ac.be/~econum ) ) ) ) ) .. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] RPMS for Fedora/RedHat
An RPM for R 2.0.1 on Fedora Core 3/i386 should now be available on a CRAN mirror near you. Unfortunately, I am temporarily unable to build RPMS for previous versions of Fedora and Red Hat Linux due to problems with the mach chroot system on FC3. I expect this situation will be resolved soon and I will let you know. Thank you for your patience. (NB This is not a call for volunteers to contribute RPMS). Prof. Brian Ripley has contributed RPMS for Fedora Core 3/x86_64 and these will soon be available on CRAN. Martyn __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] violinplot options
At 10:55 2004-11-17 +0100, Uwe Ligges wrote: Looks like nobody else has responded so far. I actually wrote something, but forgot to send it... If you are talking about the function in the package also called vioplot: The function is not very well designed. But since there is not much code in it, it is quite easy to add additional functionality yourself by adapting the whole function. That's the ambitious approach! Tanja: If you just want to add the title and y axis label, the title function suffices. E.g. library(vioplot) vioplot(runif(10)) title(main = A title, ylab = The y label) HTH, Henric __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] log-normal distribution and shapiro test
Hello: Yes I know that sort of questions comes up quite often. But with all due respect I din't find how to perform what I want. I am searching archives and bowsing manuals but it isn't there, though, it is a ridiculous simple task for the experienced R user. I have data and can do the following with them: == hist(y, prob=TRUE) lines(density(y,bw=0.03) == The result actually is a nice histogram superimposed by a line plot. The histogram is a bit skewed to the left. My assumption actually is that a log-normal transformation would cure the problem. But how the hell can one plot such a density function or Gaussian function which has logarithmic scales on x axis. For example I tried: == plot(hist(y),log=x) or plot(hist(log10(y)),log=x) == But with no avail. I want my axis like: 1,10,100 What would be other methods to test whether the data are logaritmically distributed. A last question to the Shapiro-Wilk test. Were can I get critical parameters? I mean I get for my distribution: W=0.9686, p-value=6.887e-07. What does that mean? Yes I have got some books about statics, but none of them says what one should do with the values then. The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. Sorry for disturbing you. Although, it is really no homework. I need it for my Phd in physics; after a lengthy computation on the computer I would like to go to see whether the outputs are log-normal or normal distributed. Regards, Siegfried Gonzi == University of Graz Institute for Physics Tel.: ++43-316-380-8620 == __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] The hidden costs of GPL software?
On 17-Nov-04 Philippe Grosjean wrote: Hello, In the latest 'Scientific Computing World' magazine (issue 78, p. 22), there is a review on free statistical software by Felix Grant (doesn't have to pay good money to obtain good statistics software). As far as I know, this is the first time that R is even mentioned in this magazine, given that it usually discuss commercial products. Hi Philippe, Thanks for a most interesting post on this question. Further comments below. Felix Grant's article is excellent, and well balanced. In this article, the analysis of R is interesting. It is admitted that R is a great software with lots of potentials, but: All in all, R was a good lesson in the price that may have to be paid for free software: I spent many hours relearning some quite basic things taken for granted in the commercial package. Those basic things are releated with data import, obtention of basic plots, etc... with a claim for a missing more intuitive GUI in order to smooth a little bit the learning curve. It would better represent the balanced view of the article to further quote: In fact, the whole file menu in R looks either elegantly uncluttered of frightenly obscure, depending on your point of view. It [the effort of learning] is the price paid, just as the dollars or euros for a commercial package would be. For that price, I've learned a great deal -- and nor only about R. And I shall remember it when I next have to find a heavyweight solution for a big problem presented by a small charitable client with an invisible budget. It's a huge, awe-inspiring package -- easier to perceive as such because the power is not hidden beneath a cosmetic veneer. This last remark is, in my view, particularly significant. See below. There are several R GUI projects ongoing, but these are progressing very slowly. The main reason is, I believe, that a relatively low number of programmers working on R are interested by this field. Most people wanting such a GUI are basic user that do not (cannot) contribute... And if they eventually become more knowledgeable, they tend to have other interests. So, is this analysis correct: are there hidden costs for free software like R in the time required to learn it? At least currently, for the people I know (biologists, ecologists, oceanographers, ...), this is perfectly true. This is even an insurmountable barrier for many of them I know, and they have given up (they come back to Statistica, Systat, or S-PLUS using exclusively functions they can reach through menus/dialog boxes). Non-GUI vs GUI is not intrinsically linked to Free Software as such. There are well-known FS programs which are essentially GUI-based -- as an easy example, consider all the FS Web Browsers such as Netscape, Mozilla, ... . If you want the graphics experiences offered by the Web, you're in a graphics screen anyway, and so it may as well be programmed around a GUI. Others, such as OpenOffice, have deliberately built on a GUI approach in order to emulate The Other Thing. There are a lot of FS programs which offer a GUI, usually somewhat on the basic side, which nonetheless encapsulates the entire functionality of the program and saves the user the task of composing a possibly complex command-line or even a script. The comment hidden beneath a cosmetic veneer is, in my view, somewhat directly linked to commercial software. If you sell software, you want a big market. So you want to include the people who will never learn how to work software from a command line; and the sweeter the taste of the eye candy, the more such people will feel enjoyment in using the software. The fact that their usage is limited to what has been pre-programmed into the menus is not going to affect many such people, since typically their useage is limited to a very small subset of what is in fact possible. This in turn leads, of course, to the phenomenon of software-driven analysis, where people only do what the GUI allows (or, more precisely, easily allows); and this leads on in turn to a culture in which people tend to believe that Statistics is what they can do with a particular software package. S-Plus does its best to compromise: as well as GUI access to a pretty wide range of functions, there is the Command Line Window where the user can explicitly type in commands. (I dare say many R users, in S-Plus, may tend to work in the latter since they are already used to it.) But, as always in a GUI, one can tend to get lost in the ramifications. Also, things like the big arrays of tiny icons you get when you click on the 2D Plots or 3D Plots buttons in the S-Plus toolbar can be trying on the eyes and time-consuming to pick through. Of course, the solution is to have a decent GUI for R, but this is a lot of work, and I wonder if the intrinsic mechanism of GPL is not working against such a development (leading to a very low pool of programmers actively
Re: [R] The hidden costs of GPL software?
Philippe Grosjean wrote: I would be interested by your impressions and ideas on this topic. I have found that user friendly packages make a lot of assumptions and take a lot of decisions for the user. This makes things easy, but you do not really know what is going on, and I'd say this is a hidden cost of commercial software. I wrote to the list in February asking how to reproduce some results previously obtained with Statistica. It turned out that Statistica does some data manipulation without telling the user, with poor documentation and no options or choice. Do you trust results obtained this way? I don't. So I'd argue that the lack of a GUI is a good thing, because it forces the users to think a bit more about what they want to do, and gives more control on what is going on. Best, Federico Calboli -- Federico C. F. Calboli Dipartimento di Biologia Evoluzionistica Sperimentale Università di Bologna Via Selmi, 3 40126 Bologna - ITALY Tel - +39 051 2094187 Fax - +39 051 2094286 f.calboli at ucl.ac.uk fcalboli at alma.unibo.it __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R 2.0.0 Installation Problem
On 17 Nov 2004, at 9:00 am, Uwe Ligges wrote: David Rocke wrote: I and my students have been having an odd problem with this release, which is that packages are disappearing. After installation the package is found with the library command, but later in the same session or in a later session, the library command returns a not found error. Then later it is back. Happening on both Windows and OS X, mostly but not entirely with Bioconductor packages. Please tell us more details. It never happened to anybody else that packages dissapear. Are the files still at the correct location? Have you instaled into another library tree? Have you installed them on a network volume? I've seen this sort of behaviour with overloaded NFS servers in the past. Tim -- Dr Tim Cutts Informatics Systems Group, Wellcome Trust Sanger Institute GPG: 1024D/E3134233 FE3D 6C73 BBD6 726A A3F5 860B 3CDD 3F56 E313 4233 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] frailty and time-dependent covariate
Hello, I'm trying to estimate a cox model with a frailty variable and time-dependent covariate (below there is the statement I use and the error message). It's seems to be impossible, because every time I add the time-dependent covariate the model doesn't converge. Instead, if I estimate the same model without the time-dependent covariate it's converge. I'd like knowing if it's a statistical problem due to the model formula or if it could be a problem related to my data. Thanks a lot Emanuela Rossi fit_19_1-coxph(Surv(DATA_INI1,DATA_FIN1,EVENT1)~ V1+V2+alt1+alt2+strata(autocorr1)+cap1+SP+SP2+SP3+SP3:log(DATA_FIN1)+D1500+D3000+D4500+frailty.gaussian(ID),data=SURV1) Warning messages: 1: Inner loop failed to coverge for iterations 1 3 in: coxpenal.fit(X, Y, strats, offset, init = init, control, weights = weights, 2: longer object length is not a multiple of shorter object length in: offset + coxfit$fcoef[x[, fcol]] 3: X matrix deemed to be singular; variable 8 in: coxph(Surv(DATA_INI1, DATA_FIN1, EVENT1) ~ V1 + V2 + alt1 + alt2 + [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] R: log-normal distribution and shapiro test
Hi, from what you're writing: The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. it seems the log-values are not distributed normally and so original data are not distributed like a log-normal: the p-value is extremally small! Other tests for normality are available in package: nortest compare the log-transformation of your ecdf with normal cdf: see ? ecdf use qqnorm and qqplot did you calculate skewness and kurtosis? see in package fBasics. I remember to you that the log-normal distribution as three parameters: shape parameter, location parameter and scale parameter. Transfroming by the simple log, you are missing the location parameter, or implicitely you assuming is =0. See: http://www.itl.nist.gov/div898/handbook/eda/section3/eda3669.htm for more news about log-normal distribution. I hope I give you a little help. Best Vito you wrote: Hello: Yes I know that sort of questions comes up quite often. But with all due respect I din't find how to perform what I want. I am searching archives and bowsing manuals but it isn't there, though, it is a ridiculous simple task for the experienced R user. I have data and can do the following with them: == hist(y, prob=TRUE) lines(density(y,bw=0.03) == The result actually is a nice histogram superimposed by a line plot. The histogram is a bit skewed to the left. My assumption actually is that a log-normal transformation would cure the problem. But how the hell can one plot such a density function or Gaussian function which has logarithmic scales on x axis. For example I tried: == plot(hist(y),log=x) or plot(hist(log10(y)),log=x) == But with no avail. I want my axis like: 1,10,100 What would be other methods to test whether the data are logaritmically distributed. A last question to the Shapiro-Wilk test. Were can I get critical parameters? I mean I get for my distribution: W=0.9686, p-value=6.887e-07. What does that mean? Yes I have got some books about statics, but none of them says what one should do with the values then. The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. Sorry for disturbing you. Although, it is really no homework. I need it for my Phd in physics; after a lengthy computation on the computer I would like to go to see whether the outputs are log-normal or normal distributed. Regards, Siegfried Gonzi == University of Graz Institute for Physics Tel.: ++43-316-380-8620 = Diventare costruttori di soluzioni Became solutions' constructors The business of the statistician is to catalyze the scientific learning process. George E. P. Box Visitate il portale http://www.modugno.it/ e in particolare la sezione su Palese http://www.modugno.it/archivio/cat_palese.shtml __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] R package installation
Dear Marco, I was given an excerpt with your problem about installing package on a MAC, such as Hmisc. I had the same problems and found a work around. I have not had any trouble loading in source packages since, include Hmisc and Design, acepack and vgam. First, I downloaded and installed the g77 compiler. I use a progam named FINK to find, download and intall g77 (so first I installed FINK then from within FINK I downloaded/installed the g77 compiler.) Do a Google search for FINK, it is easy to find and install. After g77 was installed I had to make a symbolic link so R could find it: ln -s \sw\bin\g77 \usr\bin\g77 (I think I had to make a link to my gcc compiler also) \n -s \sw\bin\gcc \usr\bin\g77 It looks like you already have the g77 compiler from the message. the next mesage you can also remedy by symbolic links. Try ln -s /sw/lib/gcc /usr/local/lib/gcc ln -s /sw/lib/gcc/powerpc-apple-darwin7.5.0 \usr\local\lib\gcc\powerpc-apple-darwin6.8 ln -s /sw/lib/gcc/powerpc-apple-darwin7.5.0/3.4.1 \usr\local\lib\gcc\powerpc-apple-darwin6.8\3.4.2 The first directory path in each of the above may be specific to your configuration for gcc. But this did work for me, and if you find the correct location for gcc/ powerpc-apple-darwinX.Y.Z/U.V.W, you should have no trouble either. Good luck. Sincerely Tim Johnson Adjunct Asst. Professor University of Michigan __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Non-Linear Regression on a Matrix
[EMAIL PROTECTED] wrote: If your non-linear function (A, B) is parametric nls should do it for you. If you have R version 2 (perhaps even 1.9) do ?nls to see the help page. Older versions of R require library(nls) first. Hope this helps, Andy __ Andy Jaworski 518-1-01 Process Laboratory 3M Corporate Research Laboratory - E-mail: [EMAIL PROTECTED] Tel: (651) 733-6092 Fax: (651) 736-3122 Diana Abdueva [EMAIL PROTECTED] ail.com To Sent by: [EMAIL PROTECTED] [EMAIL PROTECTED] cc at.math.ethz.ch Subject [R] Non-Linear Regression on a 11/16/2004 08:33 Matrix PM Please respond to Diana Abdueva [EMAIL PROTECTED] ail.com Hi, I'm terribly sorry for submitting my primitive question, I'm a beginner in R and was hoping to get some help re: non-linear fit. I have a 2D data with the following structure: A BC 1 1 111 1 2 121 1 3 131 2 1 141 2 2 151 2 3 161 3 1 171 3 2 181 3 3 191 I'm trying to fit C = non-linear function (A,B). I was wondering if there's a package that would save my time of doing direct least square estimation. Thank you, Diana By non-linear do you mean something like a response surface model that has quadratic terms in A and B and an interaction term? If so, you can fit the model using the lm function, as in rs - read.table(/tmp/rs.dat, header = TRUE) rs A B C 1 1 1 111 2 1 2 121 3 1 3 131 4 2 1 141 5 2 2 151 6 2 3 161 7 3 1 171 8 3 2 181 9 3 3 191 fm - lm(C ~ A * B + I(A^2) + I(B^2), rs) fm Call: lm(formula = C ~ A * B + I(A^2) + I(B^2), data = rs) Coefficients: (Intercept)AB I(A^2) I(B^2) A:B 7.100e+013.000e+011.000e+01 -1.174e-157.217e-16 -4.008e-15 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Impossible to run error message when using Sweave
Dear List: I have a large dataset of multiple schools. My goal is to produce a separate tex file for each school that plots some of the student achievement scores. Essentially, the aim is to develop a custom report for each school. To accomplish this, I have code for a loop that gets sourced into R and then Sweaves the multiple files to create the individual school reports. Here is the code for the loop schnum.list - as.vector(unique(cmu$schid)) for(current.school in schnum.list) { school.df - subset(cmu, cmu$schid==current.school) school.grades - as.vector(unique(school.df$grade)) sname - paste(paste(read, current.school, sep=),Rnw,sep=.) system(paste(schoolread.Rnw, paste(Reading/, sname, sep=), sep= )) Sweave(file= paste(Reading/, sname, sep=)) } However, this begins to work and then produces the following errors Writing to file read151-496-2982.tex Processing code chunks ... Error in file(con, r) : unable to open connection In addition: Warning messages: 1: Impossible to run 'G:\SWEAVE~1\SCHOOL~2.RNW Reading/read151-496-2982.Rnw 2: cannot open file `Reading/read151-496-2982.Rnw' I'm not sure exactly what the impossible to run error is. I think this is on the verge of running correctly, but could use a little help. Thanks, Harold Ver 1.9.0, Windows XP [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
On 11/17/04 12:34, Ted Harding wrote: This, though, still fails for information in packages which you have not installed. Perhaps I'm about to reveal my own culpable ignorance here, but I'm not aware of a full R info package which would be installed as part of R-base, being a database of info about R-base itself and also every current additional package, such that a help.search would show all resources -- including those not installed -- which match a query (and flag the non-installed ones as such so that the user knows what to install for a particular purpose). This is one of the purpose of my R search page. I have all packages installed. You can also search the help list, etc., in the same search. Some people have bookmarks for it. Of course you need to be connected to the internet. I think that any attempt to replicate this for a single user, or even the packages, would be difficult. BUT, it might help to install just the help pages for all packages, without the packages themselves. Then help.search() would find things. (I have no interest in figuring out how to do this, but maybe someone else does.) Jon -- Jonathan Baron, Professor of Psychology, University of Pennsylvania Home page: http://www.sas.upenn.edu/~baron R search page: http://finzi.psych.upenn.edu/ __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] R 2.0.0 Installation Problem
Long time no see I'm not sure I can help but I will make a couple of suggestions: (1) Start R clean, install the new package, exit R normally, restart R and then try to find the package. I am adding a couple of extra, undocumented, and generally unnecessary steps in case the programs you are running change the R environment in an unexpected fashion. (2) Document specific code that reliably reproduces the error condition. I understand this may be difficult but I think you will attract interest from more capable programmers if you can do it. Chuck Charles E. White, Senior Biostatistician, MS Walter Reed Army Institute of Research 503 Robert Grant Ave., Room 1w102 Silver Spring, MD 20910-1557 301 319-9781 Personal/Professional Site: http://users.starpower.net/cwhite571/professional/ -Original Message- Subject: [R] R 2.0.0 Installation Problem To: [EMAIL PROTECTED] (R Help) Message-ID: [EMAIL PROTECTED] Content-Type: text/plain; charset=us-ascii I and my students have been having an odd problem with this release, which is that packages are disappearing. After installation the package is found with the library command, but later in the same session or in a later session, the library command returns a not found error. Then later it is back. Happening on both Windows and OS X, mostly but not entirely with Bioconductor packages. David --- | David M. Rocke, Professor Phone: (530) 752-0510 | | Division of Biostatistics (Medicine) and(530) 752-7368 | | Department of Applied Science (Engineering) | | Co-Director of IDAV FAX:(530) 752-8894 | | University of California, Davis E-mail: [EMAIL PROTECTED] | | Davis, CA 95616-8553 www.cipic.ucdavis.edu/~dmrocke | [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Re: R: log-normal distribution and shapiro test
Hi: Thanks for your answer. Do you know how to test whether the data would fit to a gamma-distribution? How can I call fBasics? Note: I installed R-language on my Macintosh today; I have used the binary -- pre compiled -- package. Some of the R-help facilties do not function on my Mac. Again to my data: How can I compute the skew? I think I lack some basic packages - right? The curious things actually is that the median and the mean are quite similar, e.g. 0.19 and 0.2 respectively; the skew is about 1.0 (I calculated the skew by my own computer code in Bigloo). The problem actually is: my boss expects from me that I make some tests; personally I am a bit generous and everything is a Gaussian or log-Gaussian distribution, because how can I be sure that the underlying data to not have any serious flaws? Statistics is black art - right? Regards, S. Gonzi Vito Ricci wrote: Hi, from what you're writing: The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. it seems the log-values are not distributed normally and so original data are not distributed like a log-normal: the p-value is extremally small! Other tests for normality are available in package: nortest compare the log-transformation of your ecdf with normal cdf: see ? ecdf use qqnorm and qqplot did you calculate skewness and kurtosis? see in package fBasics. I remember to you that the log-normal distribution as three parameters: shape parameter, location parameter and scale parameter. Transfroming by the simple log, you are missing the location parameter, or implicitely you assuming is =0. See: http://www.itl.nist.gov/div898/handbook/eda/section3/eda3669.htm for more news about log-normal distribution. I hope I give you a little help. Best Vito you wrote: Hello: Yes I know that sort of questions comes up quite often. But with all due respect I din't find how to perform what I want. I am searching archives and bowsing manuals but it isn't there, though, it is a ridiculous simple task for the experienced R user. I have data and can do the following with them: == hist(y, prob=TRUE) lines(density(y,bw=0.03) == The result actually is a nice histogram superimposed by a line plot. The histogram is a bit skewed to the left. My assumption actually is that a log-normal transformation would cure the problem. But how the hell can one plot such a density function or Gaussian function which has logarithmic scales on x axis. For example I tried: == plot(hist(y),log=x) or plot(hist(log10(y)),log=x) == But with no avail. I want my axis like: 1,10,100 What would be other methods to test whether the data are logaritmically distributed. A last question to the Shapiro-Wilk test. Were can I get critical parameters? I mean I get for my distribution: W=0.9686, p-value=6.887e-07. What does that mean? Yes I have got some books about statics, but none of them says what one should do with the values then. The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. Sorry for disturbing you. Although, it is really no homework. I need it for my Phd in physics; after a lengthy computation on the computer I would like to go to see whether the outputs are log-normal or normal distributed. Regards, Siegfried Gonzi == University of Graz Institute for Physics Tel.: ++43-316-380-8620 = Diventare costruttori di soluzioni Became solutions' constructors The business of the statistician is to catalyze the scientific learning process. George E. P. Box Visitate il portale http://www.modugno.it/ e in particolare la sezione su Palese http://www.modugno.it/archivio/cat_palese.shtml ___ Nuovo Yahoo! Messenger: E' molto più divertente: Audibles, Avatar, Webcam, Giochi, Rubrica... Scaricalo ora! http://it.messenger.yahoo.it __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Re: R: log-normal distribution and shapiro test
Dear Siegfried, you could find fBasics at this web address: http://cran.at.r-project.org/src/contrib/Descriptions/fBasics.html it includes skewness() and kurtosis() function. I usually run R on WIN 2000 and I don't know MAC! I can suggest to use Kolgomorov-Smirnov test to test whether the data would fit to a gamma-distribution ? ks.test and this web page for theory about ks test: http://www.itl.nist.gov/div898/handbook/eda/section3/eda35g.htm Having mean and median quite similar don't mean it's a normal distribution, but, maybe, could be only a simmetric distribution! Best Vito --- Siegfried Gonzi [EMAIL PROTECTED] ha scritto: Hi: Thanks for your answer. Do you know how to test whether the data would fit to a gamma-distribution? How can I call fBasics? Note: I installed R-language on my Macintosh today; I have used the binary -- pre compiled -- package. Some of the R-help facilties do not function on my Mac. Again to my data: How can I compute the skew? I think I lack some basic packages - right? The curious things actually is that the median and the mean are quite similar, e.g. 0.19 and 0.2 respectively; the skew is about 1.0 (I calculated the skew by my own computer code in Bigloo). The problem actually is: my boss expects from me that I make some tests; personally I am a bit generous and everything is a Gaussian or log-Gaussian distribution, because how can I be sure that the underlying data to not have any serious flaws? Statistics is black art - right? Regards, S. Gonzi Vito Ricci wrote: Hi, from what you're writing: The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. it seems the log-values are not distributed normally and so original data are not distributed like a log-normal: the p-value is extremally small! Other tests for normality are available in package: nortest compare the log-transformation of your ecdf with normal cdf: see ? ecdf use qqnorm and qqplot did you calculate skewness and kurtosis? see in package fBasics. I remember to you that the log-normal distribution as three parameters: shape parameter, location parameter and scale parameter. Transfroming by the simple log, you are missing the location parameter, or implicitely you assuming is =0. See: http://www.itl.nist.gov/div898/handbook/eda/section3/eda3669.htm for more news about log-normal distribution. I hope I give you a little help. Best Vito you wrote: Hello: Yes I know that sort of questions comes up quite often. But with all due respect I din't find how to perform what I want. I am searching archives and bowsing manuals but it isn't there, though, it is a ridiculous simple task for the experienced R user. I have data and can do the following with them: == hist(y, prob=TRUE) lines(density(y,bw=0.03) == The result actually is a nice histogram superimposed by a line plot. The histogram is a bit skewed to the left. My assumption actually is that a log-normal transformation would cure the problem. But how the hell can one plot such a density function or Gaussian function which has logarithmic scales on x axis. For example I tried: == plot(hist(y),log=x) or plot(hist(log10(y)),log=x) == But with no avail. I want my axis like: 1,10,100 What would be other methods to test whether the data are logaritmically distributed. A last question to the Shapiro-Wilk test. Were can I get critical parameters? I mean I get for my distribution: W=0.9686, p-value=6.887e-07. What does that mean? Yes I have got some books about statics, but none of them says what one should do with the values then. The logaritmic transformation shapiro.test(log10(y)) says: W=0.9773, p-value= 2.512e-05. Sorry for disturbing you. Although, it is really no homework. I need it for my Phd in physics; after a lengthy computation on the computer I would like to go to see whether the outputs are log-normal or normal distributed. Regards, Siegfried Gonzi == University of Graz Institute for Physics Tel.: ++43-316-380-8620 = Diventare costruttori di soluzioni Became solutions' constructors The business of the statistician is to catalyze the scientific learning process. George E. P. Box Visitate il portale http://www.modugno.it/ e in particolare la sezione su Palese http://www.modugno.it/archivio/cat_palese.shtml ___ Audibles, Avatar, Webcam, Giochi, Rubrica... Scaricalo ora! http://it.messenger.yahoo.it = Diventare costruttori di soluzioni Became solutions' constructors The business of the statistician is to catalyze the scientific learning process. George E. P. Box Visitate il portale http://www.modugno.it/ e in particolare la sezione su Palese http://www.modugno.it/archivio/cat_palese.shtml
Re: [R] R package installation
On Wed, 17 Nov 2004, Timothy D. Johnson wrote: I was given an excerpt with your problem about installing package on a MAC, such as Hmisc. I had the same problems and found a work around. I have not had any trouble loading in source packages since, include Hmisc and Design, acepack and vgam. First, I downloaded and installed the g77 compiler. I use a progam named FINK to find, download and intall g77 (so first I installed FINK then from within FINK I downloaded/installed the g77 compiler.) [SNIP details] Still seems like simply installing this from this link would be simpler; FINK is unnecessary. Of course, this is already covered in the OS X FAQ http://cran.r-project.org/bin/macosx/RAqua-FAQ.html although some explanation could be added that a Fortran77 compiler might also be needed for linking other packages. http://hpc.sf.net/g77v3.4-bin.tar.gz -- SIGSIG -- signature too long (core dumped) __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
I'm a big advocate -- perhaps even fanatic -- of making R easier for novices in order to spread its use, but I'm not convinced that a GUI (at least in the traditional form) is the most valuable approach. Perhaps an overly harsh summary of some of Ted Harding's statements is: You can make a truck easier to get into by taking off the wheels, but that doesn't make it more useful. In terms of GUIs, I think what R should focus on is the ability for user's to make their own specialized GUI. So that a knowledgeable programmer at an installation can create a system that is easy for unsophisticated users for the limited number of tasks that are to be done. The ultimate users may not even need to know that R exists. I think Ted Harding was on the mark when he said that it is the help system that needs enhancement. I can imagine a system that gets the user to the right function and then helps fill in the arguments; all of the time pointing them towards the command line rather than away from it. The author of the referenced article highlighted some hidden costs of R, but did not highlight the hidden benefits (because they were hidden from him). A big benefit of R is all of the bugs that aren't in it (which may or may not be due to its free status). Patrick Burns Burns Statistics [EMAIL PROTECTED] +44 (0)20 8525 0696 http://www.burns-stat.com (home of S Poetry and A Guide for the Unwilling S User) Jan P. Smit wrote: Dear Phillippe, Very interesting. The URL of the article is http://www.scientific-computing.com/scwsepoct04free_statistics.html. Best regards, Jan Smit Philippe Grosjean wrote: Hello, In the latest 'Scientific Computing World' magazine (issue 78, p. 22), there is a review on free statistical software by Felix Grant (doesn't have to pay good money to obtain good statistics software). As far as I know, this is the first time that R is even mentioned in this magazine, given that it usually discuss commercial products. [ ...] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] summary.lme() vs. anova.lme()
Dear R list: I modelled changes in a variable (mconc) over time (d) for individuals (replicate) given one of three treatments (treatment) using: mconc.lme - lme(mconc~treatment*poly(d,2), random=~poly(d,2)|replicate, data=my.data) summary(mconc.lme) shows that the linear coefficient of one of the treatments is significantly different to zero, viz. Value Std.Error DF t-value p-value ... ... ... ... ... treatmentf:poly(d, 2)1 1.3058562 0.5072409 315 2.574430 0.0105 But anova(mconc.lme) gives a non-significant result for the treatment*time interaction, viz. numDF denDF F-value p-value (Intercept) 1 315 159.17267 .0001 treatment239 0.51364 0.6023 poly(d, 2) 2 315 17.43810 .0001 treatment:poly(d, 2) 4 315 2.01592 0.0920 Pinheiro Bates (2000) only discusses anova() for single arguments briefly on p.90. I would like to know whether these results indicate that the significant effect found in summary(mconc.lme) is spurious (perhaps due to multiplicity). Many thanks, Dan Bebber Department of Plant Sciences University of Oxford South Parks Road Oxford OX1 3RB UK Tel. 01865 275000 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] CDs for R?
On Wed, Nov 17, 2004 at 08:25:54AM +0200, Jari Oksanen wrote: On 16 Nov 2004, at 23:39, (Ted Harding) wrote: Now comes my suggestion to CRAN maintainer: this all would be easier, if you would produce a CD image file ('iso') that would contain a snapshot of the latest version: main binaries, all contributed packages, and docs. Getting somebody to help downloading this iso would be much easier than trying to collect all first and then make up your own cd image. It's volunteer effort, so someone actually has to do this. Can you help? Actually, only Windows and Mac users need binary versions of packages. The former because they don't have tools to install from source, the latter because they don't know that they have the tools (being command line challenged). To Dirk Eddelbuettel: Yes indeed, Ubuntu gives human face to Debian and is a much more pleasant experience. However, changing OS for R may be asking too much. Further, Ubuntu/Debian comes with a tiny and biased selection of packages, and if that's not your kind of bias, you have got to go to the Internet again. Further, Ubuntu (and other Linuxes) Again, it reflects the interests of the volunteers involved. If you want to see other things done, come join in and do them. lag behind R. The current Ubuntu release comes with R 1.9.1, and it won't be upgraded but in the next release scheduled for April 2005 (and just in the same time as the next R, so that Ubuntu will be one R version off again). I guess the lag is even worse in packages. This actually requires a response. Here is a quick log (from my mail folder) about what new packages (of mine, can't speak for others) got uploaded recently -- in most cases, this is on the day of the source release, so the lag would be close to zero. 575 Nov 08 Debian Installe ( 20) rpy_0.4.0-1_i386.changes ACCEPTED 576 Nov 09 Debian Installe ( 14) strucchange_1.2.7-1_i386.changes ACCEPTED 577 Nov 11 Debian Installe ( 12) cluster_1.9.6-3_i386.changes ACCEPTED 578 Nov 11 Debian Installe ( 12) survival_2.15-2_i386.changes ACCEPTED 579 Nov 12 Debian Installe ( 26) octave2.1_2.1.62-1_i386.changes ACCEPTED 580 Nov 12 Debian Installe ( 12) cluster_1.9.6-4_i386.changes ACCEPTED 581 Nov 12 Debian Installe ( 14) mgcv_1.1.8-1_i386.changes ACCEPTED 582 Nov 12 Debian Installe ( 14) tseries_0.9.24-1_i386.changes ACCEPTED 583 Nov 12 Debian Installe ( 14) lattice_0.10.14-1_i386.changes ACCEPTED 584 Nov 12 Debian Installe ( 12) mgcv_1.1.8-2_i386.changes ACCEPTED 585 Nov 13 Debian Installe ( 14) dbd-odbc_1.13-1_i386.changes ACCEPTED 586 Nov 13 Debian Installe ( 14) ole-storage-lite_0.14-1_i386.changes ACCEPTED 587 Nov 13 Debian Installe ( 12) semidef-oct_2.2-21_i386.changes ACCEPTED 588 Nov 14 Debian Installe ( 15) wajig_2.0.13-1_i386.changes ACCEPTED 589 Nov 14 Debian Installe ( 14) sm_2.0.13-1_i386.changes ACCEPTED 590 Nov 14 Debian Installe ( 12) vr_7.2.10-2_i386.changes ACCEPTED 591 Nov 15 Debian Installe ( 34) r-base_2.0.1-1_i386.changes ACCEPTED 592 Nov 15 Debian Installe ( 24) gretl_1.3.0-1_i386.changes ACCEPTED 593 Nov 16 Debian Installe ( 14) survival_2.16-1_i386.changes ACCEPTED 594 Nov 17 Debian Installe ( 14) wajig_2.0.14-1_i386.changes ACCEPTED I could go back further if you want. Now, if and when these get pressed into a release by Debian or Ubuntu I do not control. Which is, I guess, why we're discussing archive snapshots in this thread. Hth, Dirk -- If your hair is standing up, then you are in extreme danger. -- http://www.usafa.af.mil/dfp/cockpit-phys/fp1ex3.htm __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] summary.lme() vs. anova.lme()
Hi Dan, check the `type' argument of `anova.lme()' which defaults to sequential. This is also discussed in Pinheiro and Bates but I don't have the book with me now to trace the page. I hope it helps. Best, Dimitris Dimitris Rizopoulos Ph.D. Student Biostatistical Centre School of Public Health Catholic University of Leuven Address: Kapucijnenvoer 35, Leuven, Belgium Tel: +32/16/396887 Fax: +32/16/337015 Web: http://www.med.kuleuven.ac.be/biostat http://www.student.kuleuven.ac.be/~m0390867/dimitris.htm - Original Message - From: Dan Bebber [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, November 17, 2004 3:35 PM Subject: [R] summary.lme() vs. anova.lme() Dear R list: I modelled changes in a variable (mconc) over time (d) for individuals (replicate) given one of three treatments (treatment) using: mconc.lme - lme(mconc~treatment*poly(d,2), random=~poly(d,2)|replicate, data=my.data) summary(mconc.lme) shows that the linear coefficient of one of the treatments is significantly different to zero, viz. Value Std.Error DF t-value p-value ... ... ... ... ... treatmentf:poly(d, 2)1 1.3058562 0.5072409 315 2.574430 0.0105 But anova(mconc.lme) gives a non-significant result for the treatment*time interaction, viz. numDF denDF F-value p-value (Intercept) 1 315 159.17267 .0001 treatment239 0.51364 0.6023 poly(d, 2) 2 315 17.43810 .0001 treatment:poly(d, 2) 4 315 2.01592 0.0920 Pinheiro Bates (2000) only discusses anova() for single arguments briefly on p.90. I would like to know whether these results indicate that the significant effect found in summary(mconc.lme) is spurious (perhaps due to multiplicity). Many thanks, Dan Bebber Department of Plant Sciences University of Oxford South Parks Road Oxford OX1 3RB UK Tel. 01865 275000 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Multi-way tables
Hello, can someone tell me how to extract a partial table from a multiway table? Something else: I tried to do basic operations on cross-tables, like subtracting two cross tables with same dimensions and i was unable to do so. Is there another way? thanks! __ Email gratuito com 2 000 MB Espaço para guardar 20 anos de correio http://www.portugalmail.pt/2000mb __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Impossible to run error message when using Sweave
Doran, Harold wrote: Dear List: I have a large dataset of multiple schools. My goal is to produce a separate tex file for each school that plots some of the student achievement scores. Essentially, the aim is to develop a custom report for each school. To accomplish this, I have code for a loop that gets sourced into R and then Sweaves the multiple files to create the individual school reports. Here is the code for the loop schnum.list - as.vector(unique(cmu$schid)) for(current.school in schnum.list) { school.df - subset(cmu, cmu$schid==current.school) school.grades - as.vector(unique(school.df$grade)) sname - paste(paste(read, current.school, sep=),Rnw,sep=.) system(paste(schoolread.Rnw, paste(Reading/, sname, sep=), sep= )) Sweave(file= paste(Reading/, sname, sep=)) } However, this begins to work and then produces the following errors Writing to file read151-496-2982.tex Processing code chunks ... Error in file(con, r) : unable to open connection In addition: Warning messages: 1: Impossible to run 'G:\SWEAVE~1\SCHOOL~2.RNW Reading/read151-496-2982.Rnw 2: cannot open file `Reading/read151-496-2982.Rnw' I'm not sure exactly what the impossible to run error is. I think this is on the verge of running correctly, but could use a little help. Thanks, Harold Ver 1.9.0, Windows XP [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html It appears that you don't have the full path name for the input file correctly stated. Rather than using paste to construct names, I would suggest using file.path. You may also find it helpful to use getwd() to get the current working directory. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Time difference in months? (difftime, units)
Is there a way to calculate the number of months between dates? StartDate - strptime(01 March 1950, %d %B %Y) EventDates - strptime(c(01 April 1955, 01 July 1980), %d %B %Y) difftime(EventDates, StartDate) So, there are 61 months between 01 March 1950 and 01 April 1955. There are 364 months between 01 March 1950 and 01 July 1980. What I want is for there to be a months argument to units in difftime. Anybody have a bright idea? Is there a better way to approach this than difftime? Thanks in advance, Andy version _ platform i386-pc-mingw32 arch i386 os mingw32 system i386, mingw32 status major2 minor0.0 year 2004 month10 day 04 language R __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] CDs for R?
On Wed, 2004-11-17 at 16:54, Dirk Eddelbuettel wrote: On Wed, Nov 17, 2004 at 08:25:54AM +0200, Jari Oksanen wrote: On 16 Nov 2004, at 23:39, (Ted Harding) wrote: Now comes my suggestion to CRAN maintainer: this all would be easier, if you would produce a CD image file ('iso') that would contain a snapshot of the latest version: main binaries, all contributed packages, and docs. Getting somebody to help downloading this iso would be much easier than trying to collect all first and then make up your own cd image. It's volunteer effort, so someone actually has to do this. Can you help? Probably not. Not because I wouldn't be willing, but I may not be able... I have done this a couple of time using wget to build a local subtree of selected parts of CRAN. Then running mkisofs was pretty simple. I guess this could be automated pretty easily if you have the repository already at hand: all you need is mkisofs + info of its targets. However, I am not that kind of guru. All this would require that people think this is worthwhile. I think that the general feeling has been that there is no need for a R-current.iso snapshot (or the same as a valid Windows name). So this is an academic issue (suits me). To Dirk Eddelbuettel: Yes indeed, Ubuntu gives human face to Debian and is a much more pleasant experience. However, changing OS for R may be asking too much. Further, Ubuntu/Debian comes with a tiny and biased selection of packages, and if that's not your kind of bias, you have got to go to the Internet again. Further, Ubuntu (and other Linuxes) Again, it reflects the interests of the volunteers involved. If you want to see other things done, come join in and do them. I know this is volunteer work, and I do appreciate this volunteer work. It is all biased -- hence the formulation of your kind of bias. At the moment I have no idea how to build a deb package of R packages, so I don't know what to say. lag behind R. The current Ubuntu release comes with R 1.9.1, and it won't be upgraded but in the next release scheduled for April 2005 (and just in the same time as the next R, so that Ubuntu will be one R version off again). I guess the lag is even worse in packages. This actually requires a response. Here is a quick log (from my mail folder) about what new packages (of mine, can't speak for others) got uploaded recently -- in most cases, this is on the day of the source release, so the lag would be close to zero. Now, if and when these get pressed into a release by Debian or Ubuntu I do not control. Which is, I guess, why we're discussing archive snapshots in this thread. They go, I guess, through a testing period in Debian, and if they don't wait for anybody else, they may appear in some version of Debian after that. In Debian repository you typically see much older versions. As to Ubuntu (that I know a bit better), they will go into next release which is nearly six months ahead (they are not upgraded in between). Actually, Ubuntu is a bad choice if you just want to have R, since R is not among the core packages, but it is unsupported. Moreover, Ubuntu is a bad choice for the original problem of slow wires: Even for an ordinary install you need internet connection, if you want to get beyond a very rudimentary system. I just forgot this in my previous message: when you're wired, you think it's natural to be wired. So forget Ubuntu if you want to have R without fast internet connection. I have Ubuntu since it was about the only easily managed powerpc system I found. At the moment, I have R 2.0.0 built from source distribution there. Packages are from source files, too. Thanks for the good work with Debian! cheers, jari oksanen -- Jari Oksanen [EMAIL PROTECTED] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] summary.lme() vs. anova.lme()
On Wed, 17 Nov 2004, Dan Bebber wrote: I modelled changes in a variable (mconc) over time (d) for individuals (replicate) given one of three treatments (treatment) using: mconc.lme - lme(mconc~treatment*poly(d,2), random=~poly(d,2)|replicate, data=my.data) summary(mconc.lme) shows that the linear coefficient of one of the treatments is significantly different to zero, viz. Value Std.Error DF t-value p-value ... ... ... ... ... treatmentf:poly(d, 2)1 1.3058562 0.5072409 315 2.574430 0.0105 But anova(mconc.lme) gives a non-significant result for the treatment*time interaction, viz. numDF denDF F-value p-value (Intercept) 1 315 159.17267 .0001 treatment239 0.51364 0.6023 poly(d, 2) 2 315 17.43810 .0001 treatment:poly(d, 2) 4 315 2.01592 0.0920 Pinheiro Bates (2000) only discusses anova() for single arguments briefly on p.90. I would like to know whether these results indicate that the significant effect found in summary(mconc.lme) is spurious (perhaps due to multiplicity). Probably yes (but p values of 9% and 1% are not that different, and in both cases you are looking at a few p values). But since both summary.lme and anova.lme use Wald tests, I would use a LRT, using anova on two fits (and I would use ML fits to get a genuine LRT but that is perhaps being cautious). To Dimitris Rizopoulos: as this is the last term in the sequential anova, it is the correct Wald test. -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] R/S-related projects on Sourceforge? Trove Categorization
SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. Gretl Allin Cottrell, USA Gnu Regression, Econometrics and Time-series Library Gretl is hosted on SourceForge. http://gretl.sourceforge.net/ Gretl is not written in R, but interfaces to R. http://gretl.sourceforge.net/gretl_and_R.html gretl ... is designed as a very user-friendly econometrics package. While it is also reasonably sophisticated, it lacks some of the specialized statistical methods that a working econometrician might desire.As a way around this limitation, gretl offers an interface to the comprehensive free-software statistical package, GNU R. Both RPAd and RMetrics are open-source projects using (and acknowledging using) R. As far as I know, neither is listed on SourceForge. RPadEPRI (Electric Power Research Institute), USA http://www.Rpad.org/Rpad/ Rpad is an interactive, web-based analysis program. Rpad pages are interactive workbook-type sheets based on R, an open-source implementation of the S language. Rpad is an analysis package, a web-page designer, and a gui designer all wrapped in one. Rpad makes it easy to develop powerful data analysis applications that can be shared with others (most likely on an intranet). The user doesn't have to install anything--everything's done through a browser. RMetricsDiethelm Wuertz, ETH Zurich, Switzerland http://www.itp.phys.ethz.ch/econophysics/R/ Rmetrics is the premier open source solution for financial market analysis and valuation of financial instruments. With hundreds of functions build on modern and powerful methods Rmetrics combines explorative data analysis and statistical modeling with object oriented rapid prototyping. Rmetrics is embedded in R, My impression is that many projects on SourceForge have links to home pages hosted on other sites -- so I suppose if the project authors are willing -- they could be cross listed on SourceForge. Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. On the other hand, SourceForge's criteria for inclusion appears to be very arbitrary. Objective criteria that would be more relevant to R include: - R has several active mailing lists (archived for verification) - The R Project is archived on CRAN (Comprehensive R Archive Network) which has more than 20 mirrors on 6 continents: Africa Asia Australia Europe North America South America - More than a dozen books have been published with either R or S mentioned in the title (R is an open-source implementation of S). For example, Introductory Statistics with R is available from major booksellers including Amazon.com, BarnesandNoble.com and even Wal-mart.com! Subjective criteria for inclusion on SourceForge - R is an implementation of S a language developed at Bell Labs -- the organization that developed the C programming language and the Unix operating system. Open source implementations of C include the GNU Complier Collection (GCC) and open source implementations of Unix include GNU Linux. So why not include, the open source implementation of S, GNU R? - R is respected in the statistical community. There are awards and articles that could be cited. A personal story -- in the early 1990s I attended an American Statistical Association meeting in San Francisco. I saw then that the topnotch statisticians, people like Frank Harrell -- whose short course on Regression I attended, were maxing out SAS and switching to S. I heard about StatLib at Carnegie Mellon and contributed code. At the time, the institution I was working for was committed to SAS and SPSS and would not have been open to spending more on S. But, years latter I was delighted to learn that there was an open source implementation S, R and that it was available at StatLib, which now is a mirror for the worldwide CRAN mirror sites. On Wed, 2004-11-17 at 09:09, Witold Eryk Wolski wrote: Hi R-Users and Developers, Several months ago I made a request on Sourceforge to add the R/S - programming language to the _Trove_ categorization. (The Trove is a means to convey basic metainformation about your project.) Today I got the following response of one of the sourceforge admins. SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP If anyone of you knew about R-packages, or projects using the R/S programming language, which are hosted on sourceforge, please reply to this thread. I hope that your answers will enable me to give more then 5 examples of R projects hosted on
Re: [R] Time difference in months? (difftime, units)
On Wed, 17 Nov 2004, Andy Bunn wrote: Is there a way to calculate the number of months between dates? StartDate - strptime(01 March 1950, %d %B %Y) EventDates - strptime(c(01 April 1955, 01 July 1980), %d %B %Y) difftime(EventDates, StartDate) So, there are 61 months between 01 March 1950 and 01 April 1955. There are 364 months between 01 March 1950 and 01 July 1980. What I want is for there to be a months argument to units in difftime. Anybody have a bright idea? Ah, but months are of variable length. Is there a better way to approach this than difftime? Pretty easy: convert to POSIXlt, then use something like 12*x$year + x$month and subtract those. You could set up a class for months and have as.months and a `-' method Thanks in advance, Andy version _ platform i386-pc-mingw32 arch i386 os mingw32 system i386, mingw32 status major2 minor0.0 year 2004 month10 day 04 language R __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Re: variations on the theme of survSplit
On Wed, 17 Nov 2004, David Duffy wrote: Danardono [EMAIL PROTECTED] wrote: While waiting for 2.1, for those who need function[s] for this survival-splitting business, as I do, this 'survcut' function below might be helpful. You don't need to wait for 2.1. survival_2.16 is available on CRAN. -thomas It is not an elegant nor efficient function but it works, at least for some examples below. Ditto the following, for the case where there are multiple time-varying (irreversible) binary covariates, here slicing as coarsely as possible. # # Create dataset for survival analysis with time-dependent covariate # Gill-Anderson model # x - data.frame(onset=c(46, 32, 53, 76, 64, 43), case=c(1,1,1,0,0,0), ooph=c(NA, 30, 38, 50, NA, NA), ocp=c(1,1,0,0,1,0), parity=c(2,0,1,3,3,2), age.preg=c(28,NA,27,20,22,23)) make.dep - function(onset, case, time.dep, covs=NULL) { if (is.null(n.time.dep - ncol(time.dep))) { if (!is.null(time.dep)) { n.time.dep - 1 time.dep - as.matrix(time.dep) }else{ n.time.dep - 0 warning(No time dependent covariates) } } if (is.null(n.covs - ncol(covs))) { if (!is.null(covs)) { n.covs - 1 covs - as.matrix(covs) }else{ n.covs - 0 } } ordered.t - t(apply(cbind(onset,time.dep),1,sort,na.last=TRUE)) tot.time.dep - apply(ordered.t,1,function(x) sum(!is.na(x))) ordered.t - cbind(rep(0, nrow(ordered.t)), ordered.t) npars - 4+n.time.dep+n.covs nrecs - sum(tot.time.dep) new.x - as.data.frame(matrix(nr=nrecs, nc=npars)) names(new.x) - c(start, stop, event, names(time.dep),names(covs),episode) this.rec-0 for(i in 1:length(onset)) { for(j in 1:tot.time.dep[i]) { this.rec - this.rec+1 new.x[this.rec,1] - ordered.t[i, j] new.x[this.rec,2] - ordered.t[i, j+1] new.x[this.rec,3] - 0 new.x[this.rec,4:(3+n.time.dep)] - (ordered.t[i,j]=time.dep[i,]) missing - is.na(new.x[this.rec,]) new.x[this.rec,missing] - 0 if (n.covs0) { new.x[this.rec, (4+n.time.dep):(4+n.time.dep+n.covs)] - covs[i,] } new.x[this.rec, npars]-paste(i,j,sep=.) } new.x[this.rec,3]-case[i] } new.x } David Duffy. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Thomas Lumley Assoc. Professor, Biostatistics [EMAIL PROTECTED] University of Washington, Seattle __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] referencing values of strings
Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? DISCLAIMER: This e-mail message and any attachments are inte...{{dropped}} __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] violinplot options
Uwe is right. You can add titles quite easily. Specifically, you can use title(main=...,ylab=...) and that will do the trick after you have used vioplot to do the plot. Tim Liao Original message Date: Wed, 17 Nov 2004 10:55:33 +0100 From: Uwe Ligges [EMAIL PROTECTED] Subject: Re: [R] violinplot options To: Tanja Zseby [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Tanja Zseby wrote: Hi, I am using the function vioplot() to generate violin plots. Now I would like to add a label to the y axix and a title to the diagram. Just setting ylab didnt work. Is it possible to set such options for the function ? I tried also with the function simple.violinplot, but also with this I couldnt set the options. Kind Regards Tanja Looks like nobody else has responded so far. If you are talking about the function in the package also called vioplot: The function is not very well designed. But since there is not much code in it, it is quite easy to add additional functionality yourself by adapting the whole function. Uwe Ligges __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R- project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Time difference in months? (difftime, units)
Andy Bunn abunn at whrc.org writes: : : Is there a way to calculate the number of months between dates? : : StartDate - strptime(01 March 1950, %d %B %Y) : EventDates - strptime(c(01 April 1955, 01 July 1980), %d %B %Y) : difftime(EventDates, StartDate) : : So, there are 61 months between 01 March 1950 and 01 April 1955. There are : 364 months between 01 March 1950 and 01 July 1980. What I want is for there : to be a months argument to units in difftime. Anybody have a bright idea? : Is there a better way to approach this than difftime? 1. There are an average of 365.25/12 days per month so the following expression gives the number of months between d1 and d2: # test data d1 - as.Date(01 March 1950, %d %B %Y) d2 - as.Date(c(01 April 1955, 01 July 1980), %d %B %Y) # calculation round((d2 - d1)/(365.25/12)) 2. Another possibility is to get the length of seq.Dates like this: as.Date.numeric - function(x) structure(floor(x+.001), class = Date) sapply(d2, function(d2) length(seq(d1, as.Date(d2), by = month)))-1 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] The hidden costs of GPL software?
All: I have much enjoyed the discussion. Thanks to all who have contibuted. Two quick comments: 1. The problem of designing a GUI to make R's functionality more accessible is, I believe just one component of the larger issue of making statistical/data analysis functionality available to those who need to use it but do not have sufficient understanding and background to do so properly. I certainly include myself in this category in many circumstances. A willingness and commitment to learning ( = hard work!) is the only rational solution here, and saying that one doesn't have the time really doesn't cut it for me. Ditto for R language functionality? 2. However, R has many attractive features for data manipulation and graphics that make it attractive for common tasks that are now done most frequently with (ugh!) Excel (NOT Statistica, Systat, et. al.). For this subset of R's functionality a GUI would be attractive. However, writing a good GUI for graphing that even begins to take advantage of R's flexibility and power in this arena is an enormous -- perhaps an impossible -- task. Witness the S-Plus graphics GUI, which I think is truly awful (and appears to thwart more than it helps, at least from many of the queries one sees on that news list). So I'm not sanguine. Again, thanks to all for a thoughful and enjoyable discussion. -- Bert Gunter Genentech Non-Clinical Statistics South San Francisco, CA The business of the statistician is to catalyze the scientific learning process. - George E. P. Box -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Patrick Burns Sent: Wednesday, November 17, 2004 6:28 AM To: Jan P. Smit Cc: [EMAIL PROTECTED]; Philippe Grosjean; [EMAIL PROTECTED] Subject: Re: [R] The hidden costs of GPL software? I'm a big advocate -- perhaps even fanatic -- of making R easier for novices in order to spread its use, but I'm not convinced that a GUI (at least in the traditional form) is the most valuable approach. Perhaps an overly harsh summary of some of Ted Harding's statements is: You can make a truck easier to get into by taking off the wheels, but that doesn't make it more useful. In terms of GUIs, I think what R should focus on is the ability for user's to make their own specialized GUI. So that a knowledgeable programmer at an installation can create a system that is easy for unsophisticated users for the limited number of tasks that are to be done. The ultimate users may not even need to know that R exists. I think Ted Harding was on the mark when he said that it is the help system that needs enhancement. I can imagine a system that gets the user to the right function and then helps fill in the arguments; all of the time pointing them towards the command line rather than away from it. The author of the referenced article highlighted some hidden costs of R, but did not highlight the hidden benefits (because they were hidden from him). A big benefit of R is all of the bugs that aren't in it (which may or may not be due to its free status). Patrick Burns Burns Statistics [EMAIL PROTECTED] +44 (0)20 8525 0696 http://www.burns-stat.com (home of S Poetry and A Guide for the Unwilling S User) Jan P. Smit wrote: Dear Phillippe, Very interesting. The URL of the article is http://www.scientific-computing.com/scwsepoct04free_statistics.html. Best regards, Jan Smit Philippe Grosjean wrote: Hello, In the latest 'Scientific Computing World' magazine (issue 78, p. 22), there is a review on free statistical software by Felix Grant (doesn't have to pay good money to obtain good statistics software). As far as I know, this is the first time that R is even mentioned in this magazine, given that it usually discuss commercial products. [ ...] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] frailty and time-dependent covariate
On Wed, 17 Nov 2004, Emanuela Rossi wrote: Hello, I'm trying to estimate a cox model with a frailty variable and time-dependent covariate (below there is the statement I use and the error message). It's seems to be impossible, because every time I add the time-dependent covariate the model doesn't converge. Instead, if I estimate the same model without the time-dependent covariate it's converge. I'd like knowing if it's a statistical problem due to the model formula or if it could be a problem related to my data. The message you quote probably does not indicate a convergence problem, since it is only in iterations 1 3. Howver, there does seem to be a bug with interactions of any sort in frailty models, something connected with reordering terms. You could try defining a variable by hand for your interaction term and fitting the model that way. Incidentally, I am not nearly as enthusiastic about the frailty models as many users seem to be. For most multivariate survival problems I wouldn't want to fit a frailty model, and I'm not sure that I would trust the penalised likelihood approximation if I did. The exception would be situations where I was actually interested in the variance components, as in Dr Therneau's new kinship package for linkage analysis with survival data. -thomas Thanks a lot Emanuela Rossi fit_19_1-coxph(Surv(DATA_INI1,DATA_FIN1,EVENT1)~ V1+V2+alt1+alt2+strata(autocorr1)+cap1+SP+SP2+SP3+SP3:log(DATA_FIN1)+D1500+D3000+D4500+frailty.gaussian(ID),data=SURV1) Warning messages: 1: Inner loop failed to coverge for iterations 1 3 in: coxpenal.fit(X, Y, strats, offset, init = init, control, weights = weights, 2: longer object length is not a multiple of shorter object length in: offset + coxfit$fcoef[x[, fcol]] 3: X matrix deemed to be singular; variable 8 in: coxph(Surv(DATA_INI1, DATA_FIN1, EVENT1) ~ V1 + V2 + alt1 + alt2 + [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Thomas Lumley Assoc. Professor, Biostatistics [EMAIL PROTECTED] University of Washington, Seattle __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Re: referencing values of strings
Hi, see ? as.numeric as.numeric(c(-.1, 2.7 ,-1.5)) [1] -0.1 2.7 -1.5 you wrote: Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? = Diventare costruttori di soluzioni Became solutions' constructors The business of the statistician is to catalyze the scientific learning process. George E. P. Box Visitate il portale http://www.modugno.it/ e in particolare la sezione su Palese http://www.modugno.it/archivio/cat_palese.shtml __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Importing data from SPSS
Message: 35 Date: Tue, 16 Nov 2004 09:49:45 -0800 (PST) From: gauri [EMAIL PROTECTED] Subject: [R] R help To: [EMAIL PROTECTED] Message-ID: [EMAIL PROTECTED] Content-Type: text/plain Hi, I was wondering as to how I could convert SPSS data imported to R into tabular form. In the sense, direct usage of read.table( ) doesnt help. Thanks Hi Gauri: There are several ways of doing that. Easiest in my opinion is to save the SPSS data into txt, or csv file and read it directly into R using read.table() function to read the txt or csv data. See ?read.table for more information, or read the data input output section of the user manual. The second way is to use library(foreign) and then read the data directly using read.spss. For more information, do library(foreign) and then ?read.spss Hope this helps, Arin Basu [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] referencing values of strings
get(x) see also r-FAQ 7.21 Best, Dimitris Dimitris Rizopoulos Ph.D. Student Biostatistical Centre School of Public Health Catholic University of Leuven Address: Kapucijnenvoer 35, Leuven, Belgium Tel: +32/16/396887 Fax: +32/16/337015 Web: http://www.med.kuleuven.ac.be/biostat http://www.student.kuleuven.ac.be/~m0390867/dimitris.htm - Original Message - From: Apoian, Zack [EMAIL PROTECTED] To: '[EMAIL PROTECTED]' [EMAIL PROTECTED] Sent: Wednesday, November 17, 2004 4:48 PM Subject: [R] referencing values of strings Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? DISCLAIMER: This e-mail message and any attachments are inte...{{dropped}} __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] referencing values of strings
get is your friend: R x - c( 1, 2, 3 ) R get( x ) [1] 1 2 3 All the best, Arne On Wednesday 17 November 2004 16:48, Apoian, Zack wrote: Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? DISCLAIMER: This e-mail message and any attachments are inte...{{dropped}} __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Arne Henningsen Department of Agricultural Economics University of Kiel Olshausenstr. 40 D-24098 Kiel (Germany) Tel: +49-431-880 4445 Fax: +49-431-880 1397 [EMAIL PROTECTED] http://www.uni-kiel.de/agrarpol/ahenningsen/ __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] R/S-related projects on Sourceforge? Trove Categorization - GDAL
GDAL Package for R http://sourceforge.net/projects/rgdal The R GDAL package is an interface for accessing Frank Warmerdam's Geographic Data Abstraction Library from within R. GDAL is capable of reading and writing a wide range of geographic data formats including ESRI grid format and geotiff. On Wed, 2004-11-17 at 09:09, Witold Eryk Wolski wrote: SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. GDAL Package for R, makes six. Jim Callahan Management, Budget Accounting City of Orlando (407) 246-3039 office (407) 234-3744 cell phone [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] referencing values of strings
On Wed, Nov 17, 2004 at 10:48:46AM -0500, Apoian, Zack wrote: Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? get(x) See ?get. You may also be interested in ?assign. + seth __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] R/S-related projects on Sourceforge? Trove Categorization - GDAL
Just a small correction. FLR and FSAp are not _my_ packages :-) For FLR there's a team working on its development. Regards EJ ps: my fault anyway, the first message was not clear. On Wed, 2004-11-17 at 16:52, [EMAIL PROTECTED] wrote: GDAL Package for R http://sourceforge.net/projects/rgdal The R GDAL package is an interface for accessing Frank Warmerdam's Geographic Data Abstraction Library from within R. GDAL is capable of reading and writing a wide range of geographic data formats including ESRI grid format and geotiff. On Wed, 2004-11-17 at 09:09, Witold Eryk Wolski wrote: SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. GDAL Package for R, makes six. Jim Callahan Management, Budget Accounting City of Orlando (407) 246-3039 office (407) 234-3744 cell phone __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R/S-related projects on Sourceforge? Trove Categorization
[EMAIL PROTECTED] wrote: SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. Then you can also add nlmeODE: http://nlmeode.sourceforge.net/ Gretl Allin Cottrell, USA Gnu Regression, Econometrics and Time-series Library Gretl is hosted on SourceForge. http://gretl.sourceforge.net/ Gretl is not written in R, but interfaces to R. http://gretl.sourceforge.net/gretl_and_R.html gretl ... is designed as a very user-friendly econometrics package. While it is also reasonably sophisticated, it lacks some of the specialized statistical methods that a working econometrician might desire.As a way around this limitation, gretl offers an interface to the comprehensive free-software statistical package, GNU R. Both RPAd and RMetrics are open-source projects using (and acknowledging using) R. As far as I know, neither is listed on SourceForge. RPadEPRI (Electric Power Research Institute), USA http://www.Rpad.org/Rpad/ Rpad is an interactive, web-based analysis program. Rpad pages are interactive workbook-type sheets based on R, an open-source implementation of the S language. Rpad is an analysis package, a web-page designer, and a gui designer all wrapped in one. Rpad makes it easy to develop powerful data analysis applications that can be shared with others (most likely on an intranet). The user doesn't have to install anything--everything's done through a browser. RMetricsDiethelm Wuertz, ETH Zurich, Switzerland http://www.itp.phys.ethz.ch/econophysics/R/ Rmetrics is the premier open source solution for financial market analysis and valuation of financial instruments. With hundreds of functions build on modern and powerful methods Rmetrics combines explorative data analysis and statistical modeling with object oriented rapid prototyping. Rmetrics is embedded in R, My impression is that many projects on SourceForge have links to home pages hosted on other sites -- so I suppose if the project authors are willing -- they could be cross listed on SourceForge. Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. On the other hand, SourceForge's criteria for inclusion appears to be very arbitrary. Objective criteria that would be more relevant to R include: - R has several active mailing lists (archived for verification) - The R Project is archived on CRAN (Comprehensive R Archive Network) which has more than 20 mirrors on 6 continents: Africa Asia Australia Europe North America South America - More than a dozen books have been published with either R or S mentioned in the title (R is an open-source implementation of S). For example, Introductory Statistics with R is available from major booksellers including Amazon.com, BarnesandNoble.com and even Wal-mart.com! Subjective criteria for inclusion on SourceForge - R is an implementation of S a language developed at Bell Labs -- the organization that developed the C programming language and the Unix operating system. Open source implementations of C include the GNU Complier Collection (GCC) and open source implementations of Unix include GNU Linux. So why not include, the open source implementation of S, GNU R? - R is respected in the statistical community. There are awards and articles that could be cited. A personal story -- in the early 1990s I attended an American Statistical Association meeting in San Francisco. I saw then that the topnotch statisticians, people like Frank Harrell -- whose short course on Regression I attended, were maxing out SAS and switching to S. I heard about StatLib at Carnegie Mellon and contributed code. At the time, the institution I was working for was committed to SAS and SPSS and would not have been open to spending more on S. But, years latter I was delighted to learn that there was an open source implementation S, R and that it was available at StatLib, which now is a mirror for the worldwide CRAN mirror sites. On Wed, 2004-11-17 at 09:09, Witold Eryk Wolski wrote: Hi R-Users and Developers, Several months ago I made a request on Sourceforge to add the R/S - programming language to the _Trove_ categorization. (The Trove is a means to convey basic metainformation about your project.) Today I got the following response of one of the sourceforge admins. SNIP SourceForge.net will consider the inclusion of a programming language within the Trove system when we host at least 5 projects based on that language. Please advise: Do you know of 5 projects hosted on SourceForge.net based on this language? SNIP If anyone of you knew about R-packages, or projects using the R/S programming language, which are hosted on sourceforge, please reply to this thread. I hope that your answers
RE: [R] referencing values of strings
Can you give some hypothetical code on what you want to do? Does get() do what you want: dog - Spot f - function(x) get(x) f(dog) [1] Spot ? Andy From: Apoian, Zack Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? DISCLAIMER: This e-mail message and any attachments are inte...{{dropped}} __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] referencing values of strings
On Wed, 2004-11-17 at 10:48 -0500, Apoian, Zack wrote: Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? If I am understanding you correctly: x - 1:10 x [1] 1 2 3 4 5 6 7 8 9 10 x.char - x get(x.char) [1] 1 2 3 4 5 6 7 8 9 10 See ?get for more information. HTH, Marc Schwartz __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Re: referencing values of strings
Vito Ricci wrote: Hi, see ? as.numeric as.numeric(c(-.1, 2.7 ,-1.5)) [1] -0.1 2.7 -1.5 you wrote: Say you have a vector named x and a function which returns the character string x . How would I take x as an input and return the vector x? I think the question might have been about obtaining the value of the symbol x, in which case the answer is get(x) __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] dotchart background color
I'm creating a dotchart but the background color is gray. In fact, when ever I use the Lattice package the background is gray, which prints as black on my non-color printer. How do I change the background color to white? I'm also plotting two groups and would like to use circles and triangles as the plot characters. Thanks Dean __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] (no subject)
Good evening, I'm going to use R to calculate the P-value for Pearson coefficient. Does it exist an already defined function?How can I do?Thanks for helping me. Angela __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R/S-related projects on Sourceforge? Trove Categorization - GDAL
On Wed, Nov 17, 2004 at 11:52:57AM -0500, [EMAIL PROTECTED] wrote: Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. Isn't RMetrics at rmetrics.org at the ETH in Zuerich, CH? GDAL Package for R, makes six. Add RPy (rpy.sf.net) to make seven (or six, if remove RMetrics). Gretl is a tad marginal, though. Dirk -- If your hair is standing up, then you are in extreme danger. -- http://www.usafa.af.mil/dfp/cockpit-phys/fp1ex3.htm __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Multi-way tables
?apply hope this helps. spencer graves [EMAIL PROTECTED] wrote: Hello, can someone tell me how to extract a partial table from a multiway table? Something else: I tried to do basic operations on cross-tables, like subtracting two cross tables with same dimensions and i was unable to do so. Is there another way? thanks! __ Email gratuito com 2 000 MB Espaço para guardar 20 anos de correio http://www.portugalmail.pt/2000mb __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Spencer Graves, PhD, Senior Development Engineer O: (408)938-4420; mobile: (408)655-4567 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
I agree with Bert. Thanks to all who contributed. I'd like to add one comment I didn't see in the thread so far: The corporate legal where I work is deathly afraid of the GNU General Public License (GPL), because if we touch GPL software inappropriately with our commercial software, our copyrights are replaced by the GPL. This in turn means we can't charge royalties, which means we can't repay the investors who covered our initial development costs, and we file for bankruptcy. The rabid capitalists meet the rabid socialists and walk away, shaking their heads. (Sec. 2.b of the GPL: You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. We can get around this by packaging accesses to GPL software as separately installed add-on(s), because then only the add-on(s) would be covered by the GPL.) Our corporate legal is more concerned about a possible law suit from a possible competitor than from the R Foundation, but the threat is still real and still being adjudicated in other cases. If the GPL were not so tight on this point, someone could commercialize a GUI for R without having to offer their source code under the GPL. However, even without this change, R seems to be the platform of choice for new statistical algorithm development by a growing portion of the international scientific community. Moreover, from my experience with this listserve, the technical support here is far superior to anything I've experienced with any other software in the 40+ years since I wrote my first Fortran code. Best Wishes, spencer graves Berton Gunter wrote: All: I have much enjoyed the discussion. Thanks to all who have contibuted. Two quick comments: 1. The problem of designing a GUI to make R's functionality more accessible is, I believe just one component of the larger issue of making statistical/data analysis functionality available to those who need to use it but do not have sufficient understanding and background to do so properly. I certainly include myself in this category in many circumstances. A willingness and commitment to learning ( = hard work!) is the only rational solution here, and saying that one doesn't have the time really doesn't cut it for me. Ditto for R language functionality? 2. However, R has many attractive features for data manipulation and graphics that make it attractive for common tasks that are now done most frequently with (ugh!) Excel (NOT Statistica, Systat, et. al.). For this subset of R's functionality a GUI would be attractive. However, writing a good GUI for graphing that even begins to take advantage of R's flexibility and power in this arena is an enormous -- perhaps an impossible -- task. Witness the S-Plus graphics GUI, which I think is truly awful (and appears to thwart more than it helps, at least from many of the queries one sees on that news list). So I'm not sanguine. Again, thanks to all for a thoughful and enjoyable discussion. -- Bert Gunter Genentech Non-Clinical Statistics South San Francisco, CA The business of the statistician is to catalyze the scientific learning process. - George E. P. Box -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Patrick Burns Sent: Wednesday, November 17, 2004 6:28 AM To: Jan P. Smit Cc: [EMAIL PROTECTED]; Philippe Grosjean; [EMAIL PROTECTED] Subject: Re: [R] The hidden costs of GPL software? I'm a big advocate -- perhaps even fanatic -- of making R easier for novices in order to spread its use, but I'm not convinced that a GUI (at least in the traditional form) is the most valuable approach. Perhaps an overly harsh summary of some of Ted Harding's statements is: You can make a truck easier to get into by taking off the wheels, but that doesn't make it more useful. In terms of GUIs, I think what R should focus on is the ability for user's to make their own specialized GUI. So that a knowledgeable programmer at an installation can create a system that is easy for unsophisticated users for the limited number of tasks that are to be done. The ultimate users may not even need to know that R exists. I think Ted Harding was on the mark when he said that it is the help system that needs enhancement. I can imagine a system that gets the user to the right function and then helps fill in the arguments; all of the time pointing them towards the command line rather than away from it. The author of the referenced article highlighted some hidden costs of R, but did not highlight the hidden benefits (because they were hidden from him). A big benefit of R is all of the bugs that aren't in it (which may or may not be due to its free status). Patrick Burns Burns Statistics [EMAIL PROTECTED] +44 (0)20 8525 0696 http://www.burns-stat.com (home of S
Re: [R] beginner's problem in displaying large data
Are you sure you are only getting the last 5 columns, rows 1723:2200? There isn't a scroll bar some place? What do you get from the following? (tst - data.frame(array(rnorm(500), dim=c(500, 6 This should come in 2 sets of 500 rows, the first with 5 columns, the second with only 1. If what you said earlier is accurate, I would guess that when this is done, the screen would display rows 23:500 of column 6. Is this what you get? If you still have troubles, check ?sink, pipe the output to a text file file, and look at the file with some other application, e.g.: sink(huh.txt) (tst - data.frame(array(rnorm(500), dim=c(500, 6 sink() hope this helps. spencer graves Terry Mu wrote: Dear Spencer, Thank you for your comment. 1. Did you try dim(sample.data)? Is it actually 2200 by 15? Or are you reading in just some subset of the data? If it is 2200 by 15, could you also please do class(sample.data)? Yes, dim() gives the number. class(sample.data) gives data.frame 2. I just got a full listing from the following: (tst - data.frame(array(rnorm(2200), dim=c(2200, 15 You might try this. With R 2.0.0patched under Windows 2000, I got rows 1:2200 flying by 3 times, each with 5 columns. I tried this, did not get full listing. What I got was last 5 columns from 1723. I am using R 2.0.0 under Windows 2000. 3. Have you considered doing plots (including qqnorm) of numeric variables and tables of character variables? These can often reveal problems I might never see in a simple scan of numbers. They are all numbers. 4. PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html;. At minimum, please tell us which version of R under which operating system, and specifically what you did to get it into R and how you know it's 2200 by 15. Sorry about that. Thanks, Terry Mu Terry Mu wrote: I got a sample data (let's call it sample.data), which is about 2200 by 15. I tried to take a look of all data sample.data It shows only a part of data that I thought was a corner. It does not really affect my job, but I thought it is nice to have a look of all data. I can see individual records and they are fine. Is this normal because of buffer size or some reasons? Can I use other commands or change some settings to display all data? Thanks, Terry __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Spencer Graves, PhD, Senior Development Engineer O: (408)938-4420; mobile: (408)655-4567 -- Spencer Graves, PhD, Senior Development Engineer O: (408)938-4420; mobile: (408)655-4567 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] (no subject)
On Wed, 2004-11-17 at 19:20 +0100, Angela Re wrote: Good evening, I'm going to use R to calculate the P-value for Pearson coefficient. Does it exist an already defined function?How can I do?Thanks for helping me. Angela help.search(Pearson) shows you: ... cor.test(stats) Test for Association/Correlation Between Paired Samples ... See ?cor.test HTH, Marc Schwartz __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] dotchart background color
On Wednesday 17 November 2004 12:09, Dean Sonneborn wrote: I'm creating a dotchart but the background color is gray. In fact, when ever I use the Lattice package the background is gray, which prints as black on my non-color printer. How do I change the background color to white? See ?trellis.device. Note that if you want to print stuff, you should use the postscript or pdf device, in which case you should automatically get what you want. I'm also plotting two groups and would like to use circles and triangles as the plot characters. If you are unhappy with what you get after reading ?trellis.device, you could supply the pch, e.g. dotplot(..., pch = 1:2) Deepayan __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Pearson coefficient p value (was: no subject)
On Wed, 2004-11-17 at 13:12 -0600, Marc Schwartz wrote: On Wed, 2004-11-17 at 19:20 +0100, Angela Re wrote: Good evening, I'm going to use R to calculate the P-value for Pearson coefficient. Does it exist an already defined function?How can I do?Thanks for helping me. Angela help.search(Pearson) shows you: ... cor.test(stats) Test for Association/Correlation Between Paired Samples ... See ?cor.test HTH, Marc Schwartz Ack. Too quick on the send key. Please also use a sensible Subject for your posts. It helps others when searching the list archives, among other things. Marc __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Course R/S+ December 2004 in San Francisco
XLSolutions Corporation (www.xlsolutions-corp.com) is proud to announce our December-2004 2-day R/S-plus courses in San Francisco Washington, DC San Francisco -- December 16th-17th Washington, DC --- December 16th-17th Reserve your seat now at the early bird rates! Payment due AFTER the class. R/S-plus Fundamentals and Programming Techniques === Course Description: This two-day beginner to intermediate R/S-plus course focuses on a broad spectrum of topics, \ from reading raw data to a comparison of R and S. We will learn the essentials of data manipulation, graphical visualization and R/S-plus programming. We will explore statistical data analysis tools,including graphics with data sets. How to enhance your plots. We will perform basic statistics and fit linear regression models. Participants are encouraged to bring data for interactive sessions With the following outline: - An Overview of R and S - Data Manipulation and Graphics - Using Lattice Graphics - A Comparison of R and S-Plus - How can R Complement SAS? - Writing Functions - Avoiding Loops - Vectorization - Statistical Modeling - Project Management - Techniques for Effective use of R and S - Enhancing Plots - Using High-level Plotting Functions - Building and Distributing Packages (libraries) Email us for group discounts. Email Sue Turner: [EMAIL PROTECTED] Phone: 206-686-1578 Visit us: www.xlsolutions-corp.com/training.htm Please let us know if you and your colleagues are interested in this classto take advantage of group discount. Register now to secure your seat! Interested in R/Splus Advanced course? email us. Cheers, Elvis Miller, PhD Manager Training. XLSolutions Corporation 206 686 1578 www.xlsolutions-corp.com [EMAIL PROTECTED] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] need help on R
Hi, I am working on a modeling project for PMI-Australia and interested in using R, especially POLYMARS or PLYCLASS. I use SAS /PC on WINDOWS for the statistical analyses including Modeling. I got R downloaded to the system but can't figure out how to interface with SAS so that I could use SAS datasets already in place. Also I could not find POLYMARS on the library packages. I need to know which library has POLYMARS in it. Could you please help me with these issues?. I got your e-mail address from 'Other Resources' section and if I am not addressing the correct person could you please forward this to the right address and let me know?. I appreciate your support in this regard. Thanks Kamala Thomas The PMI Group, Inc. [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] 3d scatter plot with drop line
This is a follow up to my question from yesterday. I want to do in R what is called a 3d scatter plot with drop lines in S-PLUS. Basically, it's a 3dscatterplot with lines connecting the x-y grid to the z points. The lines give a better perspective on the shape of the data surface. How to? Joel Bremson UC Davis Statistics __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R/S-related projects on Sourceforge? Trove Categorization -GDAL
On Wed, 17 Nov 2004, Dirk Eddelbuettel wrote: On Wed, Nov 17, 2004 at 11:52:57AM -0500, [EMAIL PROTECTED] wrote: Gretl, RPad and RMetrics, plus Ernesto's FLR and fsap make five. Isn't RMetrics at rmetrics.org at the ETH in Zuerich, CH? GDAL Package for R, makes six. Add RPy (rpy.sf.net) to make seven (or six, if remove RMetrics). Gretl is a tad marginal, though. I'm losing count, rgdal was already mentioned, but I haven't seen: r-spatial: An R-package for dealing with spatial data in S (R or S-PLUS); this package should provide classes and methods for spatial data (points, lines, polygons, grids) that can be relied upon by other packages that use spatial data. rarcinfo: RArcInfo is a package for R (http://www.r-project.org) to import data from binary Arc/Info V7.X coverages and E00 files . This will allow R users to used it as a primary GIS tool. Roger Dirk -- Roger Bivand Economic Geography Section, Department of Economics, Norwegian School of Economics and Business Administration, Breiviksveien 40, N-5045 Bergen, Norway. voice: +47 55 95 93 55; fax +47 55 95 93 93 e-mail: [EMAIL PROTECTED] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] need help on R
On Wed, 17 Nov 2004, Kamala Thomas wrote: I am working on a modeling project for PMI-Australia and interested in using R, especially POLYMARS or PLYCLASS. I use SAS /PC on WINDOWS for the statistical analyses including Modeling. I got R downloaded to the system but can't figure out how to interface with SAS so that I could use SAS datasets already in place. Please read the `R Data Import/Export' manual. Also I could not find POLYMARS on the library packages. I need to know which library has POLYMARS in it. Unlike SAS, R does not SHOUT all the time. Function polymars is in package 'polspline', as is polyclass, both thanks to Dr Kooperberg. Could you please help me with these issues?. I got your e-mail address from 'Other Resources' section and if I am not addressing the correct person could you please forward this to the right address and let me know?. This is a list not a person, and it has a posting guide: PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] bioassay, excel
Dear all, iis there literature about application of R in bioassay and HTS around or does anybody experience using R in these areas. Is there any documentation on Excel XP/R interface around, where the use of the com server is described. My Rserver can not be started. Andreas Andreas Betz [EMAIL PROTECTED] Why Wait? Move to EarthLink. [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] CDs for R?
Thanks to everyone who joined in the discussion about this and made comments or suggestions. Special thanks too to those who mailed me off-list with further suggestions, and offers to help me privately. I'm appreciative of the latter, and may take up some offers, but I hope it was clear originally that I was raising the issue as one which might affect several people and perhaps justify making some special provision which would ease the situation. The most positive general suggestion, I thought, came from Jari Oksanen: On 17-Nov-04 Jari Oksanen wrote: [...] 5 CDs sounds 4 too many. I once burnt CDs for my students, and they fitted nicely in one CD (Windows binaries, all packages as Windows binaries and sources, contributed documents). I guess you can fit Windows, Mac and some Linux binaries all in one CD. Now comes my suggestion to CRAN maintainer: this all would be easier, if you would produce a CD image file ('iso') that would contain a snapshot of the latest version: main binaries, all contributed packages, and docs. Getting somebody to help downloading this iso would be much easier than trying to collect all first and then make up your own cd image. This would provide a ready target for people who need to ask someone else to do the job for them. It's much easier to specify download the ISO image from the following URL and burn me a CD then to hope that a possibly ill-specified 'wget' would produce the desired result (as happened when Linux Emporium did me a CD: it was mostly there, but there were gaps and some things I hadn't wanted). So I'd like to back Jari's proposal for an ISO image to be planted on CRAN as a separate file with its own unique URL. Exactly what its content should be may still be discussable, but I would be satisfied with full sources and documentation for R base and all contributed packages (maybe the Newsletter would also be handy). I was also interested in Dirk Edelbuettel's suggestion related to Quantian: On 17-Nov-04 Dirk Eddelbuettel wrote: I'll cc this reply to Mark Walker. His shop, budgetlinuxcds.com / blcds.com, is one of the resellers of my Quantian 'scientific / cluster-computing workstation on a bootable dvd' Linux distribution / environment (see http://dirk.eddelbuettel.com/quantian for more on this). Mark has been consistently responsive while offering a low-cost cd/dvd service (of which I receive no cut, in case you're wondering about disclaimers). I think he'd be happy to add regular snapshots of certain portions of http://cran.r-project.org/src/ , maybe for the sources and/or windows binaries, for his failry reasonable fees. Since Mark would need a specification of what to download and burn, this could pehaps be a convenient primary source of burned CDs derived from the proposed CRAN ISO. I also liked David Whiting's suggestion of R buddies who would be willing to provide CDs for cost + postage to people. Though I am (for obvious reasons) not in a position to download and burn the CD in the first place, I'd be happy to join in, and help coordinate and distribute (once someone has sent me a CD, it's then straightforward to produce more copies and mail these on, though like David I don't have industrial strength hardware and would only be able to do it on a small scale -- but that reinforces the case for a group of buddies who could share the load!): On 16-Nov-04 David Whiting wrote: [...] I have been in a similar situation a fair bit in the past and understand your position. Now I'm back in the UK and have a reasonably fast broadband connection at home I'd be willing to help out now and then. I guess that to make this work more generally we would need to work out how to make sure that only the CDs get burned and not the prospective customer or supplier. As for charges, I think I'd only be interested in covering costs of the CDs and postage. I don't have industrial strength hardware so I could not get into mass production. Perhaps we could establish informal groups of R buddies where, for example, I help you and a small number of other people out each time there is an update and we establish some kind of trust between ourselves, rather than new people coming to me each time. People could sign up to be suppliers and be allocated or choose a group of people they provide the service to. I would feel comfortable with something like this working for people who have been on the R-help list for a while and have some recgonised identity, and something to lose in terms of reputation if they take advantage. But, it is possible that new users might need it the most and, by definition, we might not feel comfortable dealing with new people. This suggestion could conveniently be linked with the suggestion for ISO on CRAN. On a final point: On 16-Nov-04 Adaikalavan Ramasamy wrote: [...] But the real question is that if there are enough people on slow connection that are interested in obtaining R. Well,
RE: [R] (no subject)
On 17-Nov-04 Angela Re wrote: Good evening, I'm going to use R to calculate the P-value for Pearson coefficient. Does it exist an already defined function?How can I do?Thanks for helping me. Angela cor.test is what you need (according to your statement). The Pearson correlation is the default coefficient. Example: u-rnorm(10);v-rnorm(10);X-u+v;Y-v; cor.test(X,Y) Pearson's product-moment correlation data: X and Y t = 2.9483, df = 8, p-value = 0.01847 alternative hypothesis: true correlation is not equal to 0 95 percent confidence interval: 0.1686027 0.9291072 sample estimates: cor 0.7216238 enter ?cor.test for details of the various different ways of using this function. Hoping this helps, Ted. E-Mail: (Ted Harding) [EMAIL PROTECTED] Fax-to-email: +44 (0)870 094 0861 [NB: New number!] Date: 17-Nov-04 Time: 19:28:43 -- XFMail -- __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] AYUDA
Hola, necesito informacion sobre como aplicar un modelo espacio estado y filtro de kalman en R. Soy nuevo en R. Gracias _ Información de Estados Unidos y América Latina, en Yahoo! Noticias. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
This has been an interesting discussion. I make the following comment with hesitation, since I have neither the time nor the ability to implement it myself. Using CLI software, an infrequent user has trouble remembering the known functions needed and trouble finding new ones (especially as that user gets older). What might help is an added help facility more oriented towards tasks, rather than structured around functions or packages. Such a help facility might have a tree structure. Want help? Are you looking for information on (1) data manipulation or (2) analysis? If (1), do you want to to (3) import or export data, (4) transform data, (5) reshape data, or (6) select data? If (2), do you want to (7) fit a model or (8) make a graph? And so on Once appropriate function(s) are located, the user would be directed (by hyperlinks) to the existing help framework. That could help the problem of knowing what you want to do, but not what it is called. I think that Introductory Statistics with R is a step in that direction for the basics, as MASS is for more complex matters. The question is whether such material can be incorporated into a help system that will allow users to find, more easily, what they need. That largely depends, it seems to me, on a great deal of work by volunteers. I agree also with the suggestion that a dedicated editor (or add-in) that could supply arguments for functions might be considerable help. MHP -- Michael Prager, Ph.D. Population Dynamics Team, NMFS SE Fisheries Science Center NOAA Center for Coastal Fisheries and Habitat Research Beaufort, North Carolina 28516 http://shrimp.ccfhrb.noaa.gov/~mprager/ __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] bioassay, excel
It's not in R, but the system described in the pair of papers our group published in the Journal of Biomolecular Screening late last year: http://jbx.sagepub.com/cgi/content/refs/8/6/624 http://jbx.sagepub.com/cgi/content/refs/8/6/634 is based on S-PLUS and StatServer. It was also presented at the Insightful Tech. Conf. back in 2000. For Excel/R connection, look for the R-(D)COM server on CRAN, which has an RExcel plug-in for Excel. Andy From: Andreas Betz Dear all, iis there literature about application of R in bioassay and HTS around or does anybody experience using R in these areas. Is there any documentation on Excel XP/R interface around, where the use of the com server is described. My Rserver can not be started. Andreas Andreas Betz [EMAIL PROTECTED] Why Wait? Move to EarthLink. [[alternative HTML version deleted]] __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Power sampling
Hello, after a unsuccessful search in lists maliarchive I wonder how I could estimate the power of a sample size related to an unknown population. Given the following (fake))situation: I do have a database containing about 5 millions observations over 70 variables. I would like to compute (as epidemiologists are used to) the required size of a sample to do some test on a test sample (test data), later doing some subsequent analysis of a new sample to build a prediction model. Help facilities of R show some entries regarding power, but none of them seemed to be appropriate for my purpose (maybe I am wrong, but sometimes I have some difficulties to decipher the message of those tiny hints for available packages) I would appreciate somebody effort to point me to the right package/function to archieve this task! regards Thomas __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Power sampling(II)
Hmm, sorry for hitting the send button to quick, here is the version output: platform i386-pc-linux-gnu arch i386 os linux-gnu system i386, linux-gnu status major2 minor0.0 year 2004 month10 day 04 language R regards Thomas __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] 3d scatter plot with drop line
On Wed, 17 Nov 2004 12:03:54 -0800, Joel Bremson [EMAIL PROTECTED] wrote : This is a follow up to my question from yesterday. I want to do in R what is called a 3d scatter plot with drop lines in S-PLUS. Basically, it's a 3dscatterplot with lines connecting the x-y grid to the z points. The lines give a better perspective on the shape of the data surface. How to? The scatterplot3d package does this in one of its examples, using type='h'. Duncan Murdoch __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] CDs for R?
On Wed, 17 Nov 2004 [EMAIL PROTECTED] wrote: So I'd like to back Jari's proposal for an ISO image to be planted on CRAN as a separate file with its own unique URL. Exactly what its content should be may still be discussable, but I would be satisfied with full sources and documentation for R base and all contributed packages (maybe the Newsletter would also be handy). You do realize that this would change at least daily? So it really isn't something that one would want to be mirrored around the CRAN network. Even for the sources it is tricky, as those of us who rsync part of CRAN know -- for example src/contrib does not contain all the current packages, the orphaned ones being links. One would probably want recent R-patched and R-devel tarballs, and they are not actually on CRAN. For binaries (and I suspect that most `customers' would want binaries) it is trickier still, as to meet GPL some of the sources in the Archive area would need to be included (and we have not bothered to work out what). I suggest a suitable first step is for some interested party to write a script to prepare such an ISO image and to put it (the image) up for comment (modern OSes can mount such an image, allowing browsing). I suspect it would be worth producing only say monthly. -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] 3d scatter plot with drop line
On Wednesday 17 November 2004 14:03, Joel Bremson wrote: This is a follow up to my question from yesterday. I want to do in R what is called a 3d scatter plot with drop lines in S-PLUS. Basically, it's a 3dscatterplot with lines connecting the x-y grid to the z points. The lines give a better perspective on the shape of the data surface. How to? One possibility would be library(lattice) cloud(y ~ x * z, type = 'h') This actually tries to drop the lines to the X-Y plane (z = 0) (which is truncated on the 'x-y grid' if the z-limits don't include 0). Deepayan __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] State Space Modeling Kalman Filtering (was AYUDA)
Estimado Brian: 1. El ingles es la lengua oficial de esta lista. Muchas personas quienes pudieron haber contestado a su pregunta y para quienes el ingles no es su lengua materna no entienen el castellano. 2. Have you tried www.r-project.org - Search - R site search - Kalman? I just got 97 hits there, several of which may interest you. hope this helps. spencer graves Brian pfeng wrote: Hola, necesito informacion sobre como aplicar un modelo espacio estado y filtro de kalman en R. Soy nuevo en R. Gracias _ Información de Estados Unidos y América Latina, en Yahoo! Noticias. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Spencer Graves, PhD, Senior Development Engineer O: (408)938-4420; mobile: (408)655-4567 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] The hidden costs of GPL software?
Thank you all (+ a couple of offline comments) on this topic. To summarize your comments: - Hidden costs, may be better called indirect costs are not so easy to calculate. In the cited paper http://www.scientific-computing.com/scwsepoct04free_statistics.html, there is an interesting advice from a people used to test and wrote about commercial software. Indeed, the whole context around the use of a (statistical) software should be taken into account, which would reveil also indirect costs for commercial packages. Indeed, it is the Total Cost of Ownership (TCO) that should be better considered in this context. - This discussion is connected with the many discussions pro/cons for a R GUI, or any other tool that will facilitate use of R, but loosing one big advantage: currently, you have to know what you are doing to get a result with R... What kind of nonsenses would we get from naive people if they can obtain results with no, or little knowledge? - R is viewed by some as a statistical development platform, mainly for the scientific community. It excels there, but, is it even desirable to get it also used by the mass? - ***Many of you claim for a better help system to find a function more easily, than for a GUI***. I think this point is very important and should be placed somewhere high in the to do list in order to make R more accessible to beginners/occasional users! - There is no possibility to make a commercial GUI for R (thanks to the GPL), and volunteer R developers tend to work on a problem until they get the solution they need... And this rarely lead to the development of a GUI on top of it, conserning statistical analyses. In this way, yes, there is an intrinsic mechanism that makes R a program by experts, for experts. - A GUI could cover only the bare essentials, is rather unflexible, etc... For all these reasons, how would it help to learn such a feature-rich environment as R? This is not the solution to the problem. - It is more a question of education: it takes so much time to find a function in a menu/dialog box, than to consult help pages to find the right function. However, some categories of people are more accustomished to click and drag that to read help pages! - GUIs, by providing access to a limited amount of analyses in an inflexible way, lead to the phenomenon of software-driven analysis where the way data are analyzed is dependent on the software used. - Only commercial software care about eye candy stuffs to get clients more happy to use their software (and thus to sell more); hidden beneath a cosmetic veneer in the original paper. R does not care, because there is nothing to sell. So, as a consequence, you face the bare power, but sorry, no eye candy! - GUI work is slower and more error-prone... So, this should be considered in the hidden costs AFTER the learning stage... in favor of R! - User-friendly software tend to make a lot of assumptions (to present the analysis in an easier way), and does not tell about it. These could lead to nonsenses in some case, and the user even don't know, precisely because these assumptions are not explained! - The author of the paper talks about hidden costs, but he does not talk about hidden benefits, because he does even not notice them: ***all the bugs that aren't in it*** (I add: transparence in code + possibility for everyone to propose a patch = a big part of the success of Open Source software, especially for data analysis software)! That's all, I think, for the summary! Otherwise: Patrick Burns [EMAIL PROTECTED] wrote : [...] I think Ted Harding was on the mark when he said that it is the help system that needs enhancement. I can imagine a system that gets the user to the right function and then helps fill in the arguments; all of the time pointing them towards the command line rather than away from it. Duncan Murdoch [EMAIL PROTECTED] answered: That would be helpful, and the only really difficult part would be the first part: getting the user to the right function. help.search() sometimes works, but often people ask for the wrong thing. After that, R knows a lot about the structure of its help files, so it could display all of the arguments with their defaults and the help text that corresponds to each argument, as well as the help text for the rest of the help file. Probably the main obstacle to getting this is finding someone with the time and interest to do it. Humm, excuse me, but I think that SciViews and JGR *already* do that,... So it appears that at least two people already spend their time and got their interest focused on this topic. Also, functions for such purposes will be added to the R GUI API... Meaning they will be available for a wider use. And I am close to a solution under Windows where hitting a combination of keys in ANY program will display a function tip with arguments, or a contextual completion list for R code. Finally: It seems that a GUI for R is not just lacking, it is purposedly
Re: [R] Search engine for LINUX MOZILLA
Thanks for instructions, it works. here are a few simple steps which may be useful for others too. 1 GET SOURCE: Following the link http://www.MedAnalytics.com/INSTALL, go and download http://www.MedAnalytics.com/j2re-1_4_2_01-linux-i586-rpm.bin 2 INSTALL: chown 007 j2re-1_4_2_01-linux-i586-rpm.bin ./j2re-1_4_2_01-linux-i586-rpm.bin you will get j2re-1_4_2_01-linux-i586.rpm have root access rpm -Uh j2re-1_4_2_01-linux-i586.rpm 3 create a symbolic link eg cd /usr/local/mozilla/plugins ln -s /usr/java/j2re1.4.2_01/plugin/i386/ns610-gcc32/libjavaplugin_oji.so . 4 configure broswer to java enabled Edit = Preferences = Advanced, tick 'Enable Java' __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
Hopefully my experience with R may add something to this discussion. I majored in computer science in 1983, with minors in mathematics and statistics. As this was in the days when computers were largely big centralised boxes with remote terminals, I didn't get to use computers for stats while I was at uni. Fast forward to a couple of years ago, and I've got to start doing statistics on the computer for the type of work I now do. A friend pointed me to R, so off I went. Between 1983 and then, I did a lot of development, testing, documentation, management, troubleshooting, etc work, so I think it's fair to say that, while my statistics knowledge needed a top up, my computing background was very strong. As of today, after approx 2 years of using R for relatively ad-hoc tasks every few weeks, here's my thoughts about it: - it's extremely powerful and well-maintained; kudos to everyone involved - it's extremely concise; you can do a huge amount of work in very few lines of code - provided a particular task is close to one I've already done before, using R I can extract info from a set of data at an amazing rate. Tasks that would take me an hour or so with another programming language or toolset, may take me under a minute using R (obviously depending on the size of the dataset) Problems arise whenever I need to step outside my existing R knowledge base, and use a feature or function that I haven't used before: - the help documentation in general desperately needs work, particularly the examples. My thinking is that examples should pretty much lead you through a trivial exercise using the tool being discussed. This is very rarely the case with R, and the examples seem to assume you fully understand how e.g. a library works and just need a simple reminder of the syntax. For the purposes of comparison, compare the documentation that comes with the Perl language; even if you don't know what a function or keyword does, you can pretty much read through the given examples and work it out without difficulty - the GUI is pretty much just a working area on the screen; it's just not helpful. It would probably be reasonably simple to add menu or toolbar options to help a user identify how they can actually achieve a particular task in R (e.g. select a function from a drop-down list, and get one-liner documentation about what it does), but that hasn't been done. Many of the questions asked on this list (which are often answered with RTFM) are of the nature I've got this conceptually simple task to do, but I can't find out how to do it using R. Please help; this is gratifying to me personally, since I frequently encounter the same problem. These issues are extremely frustrating, as you often know the answer will be a one-liner but you may struggle for hours or days trying to find it As I said above, once you understand how to do a particular task in R, you can leverage that knowledge to do similar tasks amazingly quickly; the productivity that comes with using R in this context is incredible. However, that productivity tends to disappear when you need to take even a small step outside your existing R knowledge base. Now maybe I'm the only occasional R user out here, and everyone else is using it 8 hours a day and acquired my 2 years' worth of knowledge in their first week of use. I doubt that is actually the case, and the rest of us could really do with some help from the GUI. Finally, please don't think I don't appreciate the mass of effort required to get R to its current state. I do, and it's made my life a lot easier than it would otherwise have been. Regards Dave Mitchell __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R-gui] Re: [R] The hidden costs of GPL software?
Patrick Burns wrote: I'm a big advocate -- perhaps even fanatic -- of making R easier for novices in order to spread its use, but I'm not convinced that a GUI (at least in the traditional form) is the most valuable approach. Perhaps an overly harsh summary of some of Ted Harding's statements is: You can make a truck easier to get into by taking off the wheels, but that doesn't make it more useful. In terms of GUIs, I think what R should focus on is the ability for user's to make their own specialized GUI. So that a knowledgeable programmer at an installation can create a system that is easy for unsophisticated users for the limited number of tasks that are to be done. The ultimate users may not even need to know that R exists. I think Ted Harding was on the mark when he said that it is the help system that needs enhancement. I can imagine a system that gets the user to the right function and then helps fill in the arguments; all of the time pointing them towards the command line rather than away from it. The author of the referenced article highlighted some hidden costs of R, but did not highlight the hidden benefits (because they were hidden from him). A big benefit of R is all of the bugs that aren't in it (which may or may not be due to its free status). Patrick Burns Burns Statistics [EMAIL PROTECTED] +44 (0)20 8525 0696 http://www.burns-stat.com (home of S Poetry and A Guide for the Unwilling S User) Jan P. Smit wrote: Dear Phillippe, Very interesting. The URL of the article is http://www.scientific-computing.com/scwsepoct04free_statistics.html. Best regards, Jan Smit Philippe Grosjean wrote: Hello, In the latest 'Scientific Computing World' magazine (issue 78, p. 22), there is a review on free statistical software by Felix Grant (doesn't have to pay good money to obtain good statistics software). As far as I know, this is the first time that R is even mentioned in this magazine, given that it usually discuss commercial products. [ ...] I really agree with you Patrick. To me the keys are having better help search capabilities, linking help files to case studies or at least detailed examples, having a navigator by keywords (a rudimentary one is at http://biostat.mc.vanderbilt.edu/s/finder/finder.html), having a great library of examples keyed by statistical goals (a la BUGS examples guides), and having a menu-driven skeleton code generator that gives beginners a starting script to edit to use their variable names, etc. Also I think we need a discussion board that has a better memory for new users, like some of the user forums currently on the web, or using a wiki. Frank -- Frank E Harrell Jr Professor and Chair School of Medicine Department of Biostatistics Vanderbilt University __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] OOP pkg compilation failure
Hi all, I'm trying to install the OOP package (http://www.omegahat.org/OOP) but having difficulty in resolving the errors generated during compilation. Googling doesn't seem to be giving much help. Can anyone please help. Below is the transcript of what I get from my command prompt. (I'm running on rw_2.0.0 WIN XP SP2 platform). Thanks in advance ---transcript Microsoft Windows XP [Version 5.1.2600] (C) Copyright 1985-2001 Microsoft Corp. C:\...\R CMD INSTALL OOP.tar.gz -- Making package OOP adding build stamp to DESCRIPTION making DLL ... making treeApply.d from treeApply.c gcc -Ic:/R/rw2000/include -Wall -O2 -c treeApply.c -o treeApply.o ar cr OOP.a treeApply.o ranlib OOP.a windres --include-dir c:/R/rw2000/include -i OOP_res.rc -o OOP_res.o gcc --shared -s -o OOP.dll OOP.def OOP.a OOP_res.o -Lc:/R/rw2000/src/gnuwin32 -lg2c -lR ... DLL made installing DLL installing R files save image [1] TRUE Initializing OOP objects in database 1 execution of package source for 'OOP' failed make[2]: *** [c:/R/rw2000/library/OOP/R/OOP] Error 1 make[1]: *** [all] Error 2 make: *** [pkg-OOP] Error 2*** Installation of OOP failed *** Removing 'c:/R/rw2000/library/OOP' ---end transcript __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] changing (core) function argument defaults?
gt;From: Patrick Connolly lt;[EMAIL PROTECTED]gt; gt;To: quot;RenE J.V. Bertinquot; lt;[EMAIL PROTECTED]gt; gt;Subject: Re: [R] changing (core) function argument defaults? gt;Date: Thu, 18 Nov 2004 11:43:10 +1300 gt; gt;On Wed, 20-Oct-2004 at 07:48PM +0200, RenE J.V. Bertin wrote: gt; gt;|gt; Hello, gt;|gt; gt; gt;|gt; Is it possible to change the defaults for the arguments to a gt;|gt; function, without changing the function code itself? I'm asking gt;|gt; because I'd like to override the default dimensions and font family gt;|gt; for a graphics device. Before 2.0.0, I'd just do that with a small gt;|gt; edit in the appropriate .R file containing the device function gt;|gt; definition. I appears to be possible no longer. So rather than gt;|gt; copying the definition into my own .Rprofile, it would be nice if gt;|gt; just the defaults could be modified... gt; gt;I didn't notice a response to this question. I'd like to do something gt;similar and haven't been able to work out how to do it. gt; gt; gt;best gt; gt;-- gt;Patrick Connolly gt;HortResearch gt;Mt Albert gt;Auckland gt;New Zealand gt;Ph: +64-9 815 4200 x 7188 No, I haven't noticed a reply to this question neither. Best, René Bertin __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] Changing graphics defaults [was: changing (core) function argument defaults?]
Under the S3 standard, you could make a local copy of any function and change the defaults in that local copy. That may not always work under the S4 standard methods dispatch going to code hidden in namespaces. In any event, it should be easy (and safer) to write a function with a slightly different name, e.g., adding a dot . to the end of the name, that would have different defaults and would do nothing but call the function of interest. This might be safer I don't have any suggestions about changing graphics defaults other than to ask for that specifically -- e.g., by changing the subject line to this email. hope this helps. spencer graves RenE J.V. Bertin wrote: gt;From: Patrick Connolly lt;[EMAIL PROTECTED]gt; gt;To: quot;RenE J.V. Bertinquot; lt;[EMAIL PROTECTED]gt; gt;Subject: Re: [R] changing (core) function argument defaults? gt;Date: Thu, 18 Nov 2004 11:43:10 +1300 gt; gt;On Wed, 20-Oct-2004 at 07:48PM +0200, RenE J.V. Bertin wrote: gt; gt;|gt; Hello, gt;|gt; gt; gt;|gt; Is it possible to change the defaults for the arguments to a gt;|gt; function, without changing the function code itself? I'm asking gt;|gt; because I'd like to override the default dimensions and font family gt;|gt; for a graphics device. Before 2.0.0, I'd just do that with a small gt;|gt; edit in the appropriate .R file containing the device function gt;|gt; definition. I appears to be possible no longer. So rather than gt;|gt; copying the definition into my own .Rprofile, it would be nice if gt;|gt; just the defaults could be modified... gt; gt;I didn't notice a response to this question. I'd like to do something gt;similar and haven't been able to work out how to do it. gt; gt; gt;best gt; gt;-- gt;Patrick Connolly gt;HortResearch gt;Mt Albert gt;Auckland gt;New Zealand gt;Ph: +64-9 815 4200 x 7188 No, I haven't noticed a reply to this question neither. Best, René Bertin __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Spencer Graves, PhD, Senior Development Engineer O: (408)938-4420; mobile: (408)655-4567 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
RE: [R] changing (core) function argument defaults?
Yes, I think for all practical purposes it (usually?) is. Here's an example. Suppose I wish to change the default constant argument of mad from 1.48 to 2. Then z-formals(mad) z$constant-2 mad-as.function(c(z,body(mad))) mad function (x, center = median(x), constant = 2, na.rm = FALSE, low = FALSE, high = FALSE) { if (na.rm) x - x[!is.na(x)] n - length(x) constant * if ((low || high) n%%2 == 0) { if (low high) stop(`low' and `high' can't be both TRUE) n2 - n%/%2 + as.integer(high) sort(abs(x - center), partial = n2)[n2] } else median(abs(x - center)) } If you now attach the workspace/environment containing this newly defined mad function to the search list before the stats package (which contains the original mad()) you have effectively changed the default argument without changing the function. I hope experts will let us know when this can't be done (perhaps with .internal functions or non-exported functions in namespaces, though it isn't clear to me that one couldn't manually export them and do this here, too). Of course, all the usual warnings about masking existing functions apply. Cheers, -- Bert Gunter Genentech Non-Clinical Statistics South San Francisco, CA The business of the statistician is to catalyze the scientific learning process. - George E. P. Box -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of RenE J.V. Bertin Sent: Wednesday, November 17, 2004 4:05 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: [R] changing (core) function argument defaults? gt;From: Patrick Connolly lt;[EMAIL PROTECTED]gt; gt;To: quot;RenE J.V. Bertinquot; lt;[EMAIL PROTECTED]gt; gt;Subject: Re: [R] changing (core) function argument defaults? gt;Date: Thu, 18 Nov 2004 11:43:10 +1300 gt; gt;On Wed, 20-Oct-2004 at 07:48PM +0200, RenE J.V. Bertin wrote: gt; gt;|gt; Hello, gt;|gt; gt; gt;|gt; Is it possible to change the defaults for the arguments to a gt;|gt; function, without changing the function code itself? I'm asking gt;|gt; because I'd like to override the default dimensions and font family gt;|gt; for a graphics device. Before 2.0.0, I'd just do that with a small gt;|gt; edit in the appropriate .R file containing the device function gt;|gt; definition. I appears to be possible no longer. So rather than gt;|gt; copying the definition into my own .Rprofile, it would be nice if gt;|gt; just the defaults could be modified... gt; gt;I didn't notice a response to this question. I'd like to do something gt;similar and haven't been able to work out how to do it. gt; gt; gt;best gt; gt;-- gt;Patrick Connolly gt;HortResearch gt;Mt Albert gt;Auckland gt;New Zealand gt;Ph: +64-9 815 4200 x 7188 No, I haven't noticed a reply to this question neither. Best, René Bertin __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
Hi All, GRETL, a Gnu Regression, Econometrics and Time-series Library is open-source, cross-platform, multi-language and fully GUI based. The website is http://gretl.sourceforge.net/ This is NOT a personal plug, simply posted to show what can be done. Andrew __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] R statistical Library download problem
Hello, I just download R 2.0.0 and R 2.0.1. After I tried to un-zip them , I got error message Error reading header after processing 0 entries for both of them. Could you help? Thanks! Sincerely, Piin-cherng Hwang __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Redirect standard input and output of R
Dear R-people! Im trying to write a C program that write to the standard input of R and read the standard output. I can perfectly read the R output, but Im not able of writing anything to R. This program really works with the cat UNIX command, but it does not work with R. What Im doing wrong??? It is possible to do it??? I want to start R once and use it thousands of times... thats why Im trying to use this system. pipe(fdW); pipe(fdR); pid = fork(); if (pid==-1) perror(Error fork); if (pid==0) { close(0); dup(fdW[0]); close(fdW[0]); close(fdW[1]); close(1); dup(fdR[1]); close(fdR[1]); close(fdR[0]); execlp(R,R,--slave,NULL); perror(Error exec); } else { close(fdW[0]); close(fdR[1]); write(fdW[1], 3+7, 3); total = 0; while (total3) { leidos = read(fdR[0], k, sizeof(k)); printf(leidos son %d \n,leidos); k[leidos]='\0'; if (leidos 0){ total = total + leidos; printf(%s\n,k); } } } exit(0); Best regards, Victor __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] Calling Rdqags doesn't produce correct result.
Does anyone has a clue what went wrong in the following attempt? I am trying to call the R built-in function Rdqags() from my C program for numerical integration. Following are the C program and the corresponding R program: C program - void test(double *a, double *b, double *epsabs, double *epsrel, double *result, double *abserr, int *neval, int *ier, int *limit, int *lenw, int *last, int *iwork, double *work, double *exx) { void *ex; ex = exx; Rdqags(tmpfun, ex, a, b, epsabs, epsrel, result, abserr, neval, ier, limit, lenw, last, iwork, work); } // User supplied function void tmpfun(double *x, int n, void *ex) { int i; double *tmp; tmp = (double *)ex; //for(i=1;i=n;i++) {x[i] = pow(x[i], *tmp);} for(i=1;i=n;i++) {x[i] = 2.0*x[i];} return; } R program - test - function(a, b, epsabs = .Machine$double.eps^0.25, epsrel = epsabs, limit = 100, lenw = 400, ex = -0.5) { val - .C(test, as.double(a), as.double(b), as.double(epsabs), as.double(epsrel), result = double(1), abserr = as.double(-1), neval = as.integer(-1), ier = as.integer(-1), as.integer(limit), as.integer(lenw), last = as.integer(-1), integer(limit+1), double(lenw+1), as.double(ex), NAOK=T, specialsok=T ) val } I followed the instructions in Writing R Extensions - The R API - Integration, and the program was complied and loaded into R successfully. However, calling R function test(0, 20)$result gives me 385.0554, not 400! The returned ier value of test(0, 20) is 0! But if I call integrate(function(x) 2 * x, lower = 0, upper = 20), I got the correct result of 400. Apparently, there must be something wrong in my programs. But I cannot see where is the mistake. Do I miss anything obvious here? The programs above were tested in R-1.9.0 for MS-Windows and the compiler is MSC++ V6. I have used similar calls to the built-in random generators and never had any problems. Paul. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] The hidden costs of GPL software?
Background: I'm a Computer Science lecturer, and I read the blue book cover to cover before ever setting finger to keyboard with R. Observation: I really only use R for very simple things, but there's practically *nothing* I've done with R since installing it could have been done via menus. I seem to need lots of little R functions, lots of little try this transformation plot that, fiddle with the other... I've had a student use it, I've introduced it to colleauges, and they would not have benefited one iota from a GUI interface. I'm glad that the effort put into R has gone into the things it has. __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] gdata package for genetics
Hi, I try to install genetics_1.1.1.tar.gz and get following errors. it looks for a package call 'gdata'. I looked and search r-project web, did not find any thing R CMD INSTALL src/contrib/genetics_1.1.1.tar.gz * Installing *source* package 'genetics' ... ** R ** data ** inst ** preparing package for lazy loading Error in loadNamespace(i[[1]], c(lib.loc, .libPaths()), keep.source) : There is no package called 'gdata' Execution halted ERROR: lazy loading failed for package 'genetics' ** Removing '/usr/local/lib/R/library/genetics' ** Restoring previous '/usr/local/lib/R/library/genetics' Can you help me out this? Yuandan __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] R statistical Library download problem
On Wed, 17 Nov 2004, Piin-cherng Hwang wrote: I just download R 2.0.0 and R 2.0.1. After I tried to un-zip them , I got error message Error reading header after processing 0 entries for both of them. No distribution of R is a zip file. The sources are .tar.gz files, gzipped tar archives. Could you help? Thanks! PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html The information you need is in the FAQs, which that points you too. It also explains why we have no idea how to help you as we have almost no idea what you did, for you have not told us. -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
[R] ROracle connection problem
Hi, I found the same question in the mailing list already a few months ago - but there was no answer to it - so I'll try it again Could somebody help me to solve this following problem? I just begin to learn how to connect my Oracle database with R. library(DBI) library(ROracle) Warning message: DLL attempted to change FPU control word from 8001f to 9001f ora=dbDriver(Oracle) Error in initialize(value, ...) : Invalid names for slots of class OraDriver: Id My system is: Windows 2000, Oracle 9.2 R1.9.0 Thank you very much andi Andreas Felber Swiss Federal Institute for Snow and Avalanche Research Flüelastrasse 11 CH-7260 Davos Dorf phone ++41 81 417 02 52 email: [EMAIL PROTECTED] personal homepage: http://www.slf.ch/staff/pers-home/felber/felber-en.html web www.slf.ch __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Re: [R] gdata package for genetics
From the description file Depends: combinat, gdata, MASS Now, gdata is part of the gregmisc bundle. install.packages(genetics, depend=TRUE) would have figured this out for you. On Thu, 18 Nov 2004, Yuandan Zhang wrote: Hi, I try to install genetics_1.1.1.tar.gz and get following errors. it looks for a package call 'gdata'. I looked and search r-project web, did not find any thing Really?: please search the list of packages at http://cran.r-project.org/src/contrib/PACKAGES.html again, for my browser finds `gdata' there. R CMD INSTALL src/contrib/genetics_1.1.1.tar.gz * Installing *source* package 'genetics' ... ** R ** data ** inst ** preparing package for lazy loading Error in loadNamespace(i[[1]], c(lib.loc, .libPaths()), keep.source) : There is no package called 'gdata' Execution halted ERROR: lazy loading failed for package 'genetics' ** Removing '/usr/local/lib/R/library/genetics' ** Restoring previous '/usr/local/lib/R/library/genetics' Can you help me out this? Yuandan __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html