[R] (New subject) Mandrake X11 install problems
Could Mandrake users please examine this thread of make check failures? (Mandrake Linux 10.1 - fails graphics, possibly missing one of 100dpi or 75dpi font rpms) On Fri, 23 Sep 2005, [gb2312] Ö£ä¿ wrote: Dear Mr Bivand and all the authors, Glad to recieve your letter, and it seems that you catched the very bug this time! First of all, there isn't any file named graphics.Ex-rout in direction tests/Examples/ but there are graphics.Ex.R and graphics.Ex-Rout.fail files there, the latter of which looks like a good crue of my problem. So I tared this file and sent it as an attached file of this letter, wishing it won't be rejected by your server. The file seems to be empty, so the make check on graphics may have failed immediately. I also try demo(graphics) in a new R session and some errors occured as expected. The graphics demo can be displayed correctly until the third one. An mistake happened and braked down the command. The failing message is writed down below:( also some key words was translated into English by myself) Press 'Enter' for the next graphic : title(main = January Pie Sales, cex.main = 1.8, font.main = 1) error occurs in: title(main = January Pie Sales, cex.main = 1.8, font.main = 1) : cannot load X11 font size 22 So it seems that there are still some problems with my package X11, doesn't it? I see from postings on R-help that Mandrake 10.1 users are advised to install both 'xorg-x11-100dpi-fonts' and 'xorg-x11-75dpi-fonts': http://finzi.psych.upenn.edu/R/Rhelp02a/archive/54320.html and: http://finzi.psych.upenn.edu/R/Rhelp02a/archive/46407.html Could you please say whether you only have one of these font files installed now, and whether the problem is resolved by installing the missing one? All good luck! Yours sincerely, An Chinese -- Roger Bivand Economic Geography Section, Department of Economics, Norwegian School of Economics and Business Administration, Helleveien 30, N-5045 Bergen, Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43 e-mail: [EMAIL PROTECTED] __ R-help@stat.math.ethz.ch 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] Rf_initEmbeddedR in Windows
How to generate an import library for R.dll for Visual Studio is discussed in README.packages: please do read it. Do note the recommendation not to install R in a path with spaces - your tool is one of many that does not work with spaces. But you don't want a Borland import library (any more than the MinGW import library which we do provide). Note too the posting guide, and use the appropriate list. This is not an appropriate question for R-help (it is not even a question about R, but about an unsupported compiler system). On Thu, 22 Sep 2005 [EMAIL PROTECTED] wrote: Hi All My C++/linux program uses Rf_initEmbeddedR to start R and then calls some R functions. Now I try to port it to Windows. Give the fact that Rf_initEmbeddedR is missing in Windows, I try to use the implmentation in Rserve by Simon Urbanek. When I build in MS Visual Studio, I get the following linking error error LNK2019: unresolved external symbol __imp__putenv referenced in function _Rf_initEmbeddedR error LNK2019: unresolved external symbol __imp__UserBreak referenced in function _my_onintr error LNK2019: unresolved external symbol _getDLLVersion referenced in function _Rf_initEmbeddedR error LNK2019: unresolved external symbol _R_DefParams referenced in function _Rf_initEmbeddedR error LNK2019: unresolved external symbol _R_SetParams referenced in function _Rf_initEmbeddedR error LNK2019: unresolved external symbol _R_SizeFromEnv referenced in function _Rf_initEmbeddedR error LNK2019: unresolved external symbol _setup_Rmainloop referenced in function _Rf_initEmbeddedR error LNK2019: unresolved external symbol _setup_term_ui referenced in function _Rf_initEmbeddedR I think the error come from the following declaration of functions calling into R.dll and the missing of R.lib corresponding to R.dll. extern char *getDLLVersion(); extern void R_DefParams(Rstart); extern void R_SetParams(Rstart); extern void setup_term_ui(void); extern void ProcessEvents(void); extern void end_Rmainloop(void), R_ReplDLLinit(void); extern int R_ReplDLLdo1(); extern void run_Rmainloop(void); Then I google it, I find some solution of Borland C++ Builder, i.e. using implib to generate R.lib. The only place where I can find implib is at (http://www.geocities.com/SiliconValley/5806/download.htm#IMPLIB) and the commond generates a error as below C:\Program Files\R\rw2011\binIMPLIB32.EXE R.dll ImpLib32 Version 1.02 - ImpLib for Win32 Copyright (c) 1996-97 by Markus Seger ([EMAIL PROTECTED]) Creating R.lib... 'c:\Program' is not recognized as an internal or external command, operable program or batch file. 'c:\Program' is not recognized as an internal or external command, operable program or batch file. My questios are 1) Is it a right way to generate R.lib to remove the linking error. 2) If yes, how can I generate the R.lib valid for MS Visual Studio 3) If not, how can I call the functions directly in R.dll -- 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 __ R-help@stat.math.ethz.ch 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] books about MCMC to use MCMC R packages?
Dear list users, I need to learn about MCMC methods, and since there are several packages in R that deal with this subject, I want to use them. I want to buy a book (or more than one, if necessary) that satisfies the following requirements: - it teaches well MCMC methods; - it is easy to implement numerically the ideas of the book, and notation and concepts are similar to the corresponding R packages that deal with MCMC methods. I have done a search and 2 books seem to satisfy my requirements: - Markov Chain Monte Carlo In Practice, by W.R. Gilks and others. - Monte Carlo Statistical methods, Robert and Casella. What do people think about these books? Is there a suggestion of some other book that could satisfy better my requirements? Thank you very much in advance. The information contained herein is confidential and is inte...{{dropped}} __ R-help@stat.math.ethz.ch 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] as.character on OS X tiger
This is just a question of rounding error. You are computing 11/999, which is not exactly representable. Most computers use IEC60559 arithmetic, which gives a precision of .Machine$double.eps ~ 2e-16. So you can expect rounding error around 11/999 * .Machine$double.eps ~ 2e-18. However, as.character is documented to represent the number to 15 significant digits. On all of Linux (i686 and AMD64), Solaris and Windows boxes I get a - 11/999 b - as.numeric(as.character(a)) b [1] 0.01101101 a - b [1] 1.040834e-17 as.character(a) [1] 0.0110110110110110 as.character(b) [1] 0.011011011011011 and these are different representations of different numbers. So your claim to get different results on `linux' is not one I can reproduce. The fix is not to rely on the fine details of numerical (or character) representations of numbers: perhaps convert them back to numbers and use all.equal()? On Fri, 23 Sep 2005, Marcus Davy wrote: Hi, When I run this example code on a G5 the last digit is dropped off on a binary installation of R (R.app), whereas on a linux machine the digit is not removed. # Code: a - seq(0,1, length=1000)[12] a as.character(a) as.character(as.numeric(as.character(a))) # Results I get: a - seq(0,1, length=1000)[12] a [1] 0.01101101 as.character(a) [1] 0.0110110110110110 as.character(as.numeric(as.character(a))) [1] 0.011011011011011 Can anyone enlighten me on the subtle difference between OS's, its causing issues for me when I write to list elements with these characters strings and some occasionally have lost the last 0. -- 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 __ R-help@stat.math.ethz.ch 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-class histogram?
I am new to R, and I couldn't find the answers to my question in a faq. This could however be because I didn't know what to look for...:) I have three classes of data, data for bacteria, archaea and eukaryotes. I wish to display these in a histogram where all of the values are used to calculate each column. But, I want each column split in three, where the size of each coloured area represents the proportions of the values in that column that comes from each of the three classes. Do you have any tips on how I do this? Karin -- Karin Lagesen, PhD student [EMAIL PROTECTED] http://www.cmbn.no/rognes/ __ R-help@stat.math.ethz.ch 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-class histogram?
Hi Look at ?barplot and its parameter beside. HTH Petr On 23 Sep 2005 at 10:45, Karin Lagesen wrote: I am new to R, and I couldn't find the answers to my question in a faq. This could however be because I didn't know what to look for...:) I have three classes of data, data for bacteria, archaea and eukaryotes. I wish to display these in a histogram where all of the values are used to calculate each column. But, I want each column split in three, where the size of each coloured area represents the proportions of the values in that column that comes from each of the three classes. Do you have any tips on how I do this? Karin -- Karin Lagesen, PhD student [EMAIL PROTECTED] http://www.cmbn.no/rognes/ __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Petr Pikal [EMAIL PROTECTED] __ R-help@stat.math.ethz.ch 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] books about MCMC to use MCMC R packages?
Hello, I don't know yet of any book which presents MCMC methods with R examples so I can't answer to this part of your question. But I can suggest some general references (see the attached BibTeX file for details): My favorite starting point is Radford Neal review from 1993, you can download it from his web-site. Julian Besag's 2000 working paper is also a good starting point especially for statisticians (you can also download it). If you're not scared at seeing the minus log likelihood referred to as the energy you can take a look at the Physics literature (Sokal, 1996; Berg 2004 and 2004b). It's a good way to learn about tricks physicists use to get faster relaxation of their chains, like simulated annealing and the replica exchange method / parallel tempering method. These tricks were apparently first found by statisticians (Geyer, 1991; Geyer Thompson, 1995; Ogata, 1995; review by Iba, 2001) but don't seem to attract much attention in this community. In my experience they work spectacularly well. Robert and Casella, 2004 is a thorough reference with a bit too much on reversible jump techniques and not enough on physicians tricks (in my opinion of course). Liu, 2001 is a spectacular overview. He knows very well both the statistical and physical literatures. But it's often frustrating because not enough details are given (for slow guys like me at least). Fishman, 1996 is very comprehensive with much more than MCMC (that he calls random tours). Finally a note of caution about MCMC method can be useful, see Ripley, 1996. I hope that helps, Christophe. Molins, Jordi wrote: Dear list users, I need to learn about MCMC methods, and since there are several packages in R that deal with this subject, I want to use them. I want to buy a book (or more than one, if necessary) that satisfies the following requirements: - it teaches well MCMC methods; - it is easy to implement numerically the ideas of the book, and notation and concepts are similar to the corresponding R packages that deal with MCMC methods. I have done a search and 2 books seem to satisfy my requirements: - Markov Chain Monte Carlo In Practice, by W.R. Gilks and others. - Monte Carlo Statistical methods, Robert and Casella. What do people think about these books? Is there a suggestion of some other book that could satisfy better my requirements? Thank you very much in advance. The information contained herein is confidential and is inte...{{dropped}} __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- A Master Carpenter has many tools and is expert with most of them.If you only know how to use a hammer, every problem starts to look like a nail. Stay away from that trap. Richard B Johnson. -- Christophe Pouzat Laboratoire de Physiologie Cerebrale CNRS UMR 8118 UFR biomedicale de l'Universite Paris V 45, rue des Saints Peres 75006 PARIS France tel: +33 (0)1 42 86 38 28 fax: +33 (0)1 42 86 38 30 web: www.biomedicale.univ-paris5.fr/physcerv/C_Pouzat.html __ R-help@stat.math.ethz.ch 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] Good news about my problem
Greetings, Mr Bivand and all the other authors, I'm glad to say that there are some encouraging advances in my debugging progress. Thanks to Mr Brivand, I could check the packages installed on my oparation system. I have found that I have only one of the two font files installed-'xorg-x11-75dpi-fonts' installed and left the other one. So I have it ('xorg-x11-100dpi-fonts') installed and then do those checks again. Howerver, nothing is changed after installing. Inspired by your advice, I searched for any packages related to 'X11' and 'font', and have them all installed accompained with those that they related to. For details, I installed 'xorg-x11-cyrillic-fonts-6.7.0-3mdk','libxorg-x11-static-devel' whose name contains the word 'devel' and some other packages they related to. After doing all of these installation, I re-check the problem. Although I cannot pass the check command 'make check' nor can I find the file 'graphics-Ex.Rout', I can complete the demo command 'demo(graphics)' successfully! How happy I am! To ensure my conclusion, I will paste the last few lines of messages displayed after running the command 'demo(graphics)' below: Could try check it for me please? usr - par(usr) rect(usr[1], usr[3], usr[2], usr[4], col = green3) contour(x, y, volcano, levels = l, col = yellow, lty = solid, add = TRUE) box() title(A Topographic Map of Maunga Whau, font = 4) title(xlab = Meters North, ylab = Meters West, font = 3) mtext(10 Meter Contour Spacing, side = 3, line = 0.35, outer = FALSE, at = mean(par(usr)[1:2]), cex = 0.7, font = 3) par(bg = cornsilk) coplot(lat ~ long | depth, data = quakes, pch = 21, bg = green3) pressreturnfor next graphic: par(opar) Thanks to your advice, I can display graphics correctly. And I am waiting for your further advice or suggestion to dealing with my problems. Thank you very much! Best wishes to everone! Sincerely yours, An Chinese __ R-help@stat.math.ethz.ch 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] Smooth terms significance in GAM models
hi, i'm using gam() function from package mgcv with default option (edf estimated by GCV). G=gam(y ~ s(x0, k = 5) + s(x1) + s(x2, k = 3)) SG=summary(G) Formula: y ~ +s(x0, k = 5) + s(x1) + s(x2, k = 3) Parametric coefficients: Estimate std. err.t ratioPr(|t|) (Intercept) 3.462e+07 1.965e+05 176.2 2.22e-16 Approximate significance of smooth terms: edf chi.sq p-value s(x0) 2.858 70.629 1.3129e-07 s(x1) 8.922 390.39 2.6545e-13 s(x2) 1.571141.6 1.8150e-11 R-sq.(adj) = 0.955 Deviance explained = 97% GCV score = 2.4081e+12 Scale est. = 1.5441e+12 n = 40 -- I know i can estimate the significance of smooth terms with chi.sq p.value. With GCV, p-value are obtained by comparing the statistic to an F distribution,isn't it? help(summary.gam) says use at your own risk!.Does it mean i should only estimated signifiance of smooth terms by chi.sq?.Is there a way to link both information (p.value and chi.sq)? I have read an article where chi.sq was interpreted like residual deviance (reduction in deviance by each smooth). Can i do something like that in my case? How can i estimate numericaly the contribution of each smooth against the others. In others words, is there a way to quantify this significance like a percentage of how the model is improved by each of my smooth? Last question, using GAM with default, should i look at R-sq rather than Deviance explain, or both? I hope it's ~ clear thanks. Yves [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch 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] books about MCMC to use MCMC R packages?
This is the same mail as the previous one with a visible bibliography this time (sorry)... Hello, I don't know yet of any book which presents MCMC methods with R examples so I can't answer to this part of your question. But I can suggest some general references (see the attached BibTeX file for details): My favorite starting point is Radford Neal review from 1993, you can download it from his web-site. Julian Besag's 2000 working paper is also a good starting point especially for statisticians (you can also download it). If you're not scared at seeing the minus log likelihood referred to as the energy you can take a look at the Physics literature (Sokal, 1996; Berg 2004 and 2004b). It's a good way to learn about tricks physicists use to get faster relaxation of their chains, like simulated annealing and the replica exchange method / parallel tempering method. These tricks were apparently first found by statisticians (Geyer, 1991; Geyer Thompson, 1995; Ogata, 1995; review by Iba, 2001) but don't seem to attract much attention in this community. In my experience they work spectacularly well. Robert and Casella, 2004 is a thorough reference with a bit too much on reversible jump techniques and not enough on physicians tricks (in my opinion of course). Liu, 2001 is a spectacular overview. He knows very well both the statistical and physical literatures. But it's often frustrating because not enough details are given (for slow guys like me at least). Fishman, 1996 is very comprehensive with much more than MCMC (that he calls random tours). Finally a note of caution about MCMC method can be useful, see Ripley, 1996. I hope that helps, Christophe. PS: the bibliography @TechReport{Neal_1993, Author = {Neal, Radford M}, Title = {Probabilistic {I}nference {U}sing {M}arkov {C}hain {M}onte {C}arlo {M}ethods}, Institution= {Department of Computer Science. University of Toronto}, Number = {CRG-TR-91-1}, web= {http://www.cs.toronto.edu/~radford/papers-online.html}, year = 1993 } @TechReport{Besag_2000, Author = {Besag, Julian}, Title = {Markov {C}hain {M}onte {C}arlo for {S}tatistical {I}nference}, Type = {Working Paper}, Number = {9}, Abstract = {These notes provide an introduction to Markov chain Monte Carlo methods that are useful in both Bayesian and frequentist statistical inference. Such methods have revolutionized what can be achieved computationally, primarily but not only in the Bayesian paradigm. The account begins by describing ordinary Monte Carlo methods, which, in principle, have exactly the same goals as the Markov chain versions but can rarely be implemented. Subsequent sections describe basic Markov chain Monte Carlo, founded on the Hastings algorithm and including both the Metropolis method and the Gibbs sampler as special cases, and go on to discuss more recent developments. These include Markov chain Monte Carlo p-values, the Langevin-Hastings algorithm, auxiliary variables techniques, perfect Markov chain Monte Carlo via coupling from the past, and reversible jumps methods for target spaces of varying dimensions. Specimen applications, drawn from several different disciplines, are described throughout the notes. Several of these appear for the first time. All computations use APL as the programming language, though this is not necessarily a recommendation! The author welcomes comments and criticisms.}, eprint = {http://www.csss.washington.edu/Papers/wp9.pdf}, URL= {http://www.csss.washington.edu/Papers/}, month = sep, year = 2000 } @Book{Liu_2001, Author = {Liu, Jun S.}, Title = {Monte {C}arlo {S}trategies in {S}cientific {C}omputing}, Publisher = {Springer Verlag}, Series = {Springer Series in Statistics}, Edition= {First}, year = 2001 } @Book{RobertCasella_2004, Author = {Robert, Christian P. and Casella, George}, Title = {Monte {C}arlo statistical methods}, Publisher = {Springer-Verlag}, Series = {Springer Texts in Statistics}, Address= {New York}, Edition= {Second}, isbn = {0-387-21239-6}, year = 2004 } @InCollection{Sokal_1996, Author = {Sokal, A.}, Title = {Monte {C}arlo methods in statistical mechanics: foundations and new algorithms}, BookTitle = {Functional
[R] suggest some books or materials for matrices basics , its partitions, iterations, clusturing
Dear sir, Could anybody kindly suggest me some good e-books(which are available in the internet),or other materials in the web sites to refer examples ... in the following area matrices its basics partitioning of matrices... iterations of matrices Clusturing in matrices... thank you sir.. with kind regards, boopathy. __ R-help@stat.math.ethz.ch 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] books about MCMC to use MCMC R packages?
Hi Jordi, As far as implementions are concerned the book of Bernd Berg seems to be the closest to what you're looking for. You can find a link to the Fortran codes implementing the methods he describes from his web site: http://www.csit.fsu.edu/~berg/ There is also a nice reference for the analysis of the output of MCMC algorithm by Wolfhard Janke: Janke W (2002) Statistical Analysis of Simulations: Data Correlations and Error Estimation. In, Quantum Simulations of Complex Many-Body Systems: From Theory to Algorithms, Lecture Notes, J. Grotendorst, D. Marx, A. Muramatsu (Eds.), John von Neumann Institute for Computing, Jülich, NIC Series, Vol. *10*, pp. 423-445. http://www.fz-juelich.de/nic-series/volume10 Christophe. Molins, Jordi wrote: Hi Christophe, thank you very much for your detailed answer! I am not scared about physics literature, because I am a physicist myself, working in finance. So your suggestions suit me very well. What I would like is to implement numerically these methods. Is there some that goes closer into implementation? Thanks! Jordi -- A Master Carpenter has many tools and is expert with most of them.If you only know how to use a hammer, every problem starts to look like a nail. Stay away from that trap. Richard B Johnson. -- Christophe Pouzat Laboratoire de Physiologie Cerebrale CNRS UMR 8118 UFR biomedicale de l'Universite Paris V 45, rue des Saints Peres 75006 PARIS France tel: +33 (0)1 42 86 38 28 fax: +33 (0)1 42 86 38 30 web: www.biomedicale.univ-paris5.fr/physcerv/C_Pouzat.html __ R-help@stat.math.ethz.ch 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] warning.expression?
Thomas Friedrichsmeier wrote: Yes, thanks for pointing it out. However, I'm actually looking for a way to catch all warnings in a whole (interactive) session. Can warning.expression be used for that? I've just been nosing around the source code in errors.c, and it doesn't look good. In this function: static void vwarningcall_dflt(SEXP call, const char *format, va_list ap) the warning.expression 's' is called here: cptr = R_GlobalContext; while ( !(cptr-callflag CTXT_FUNCTION) cptr-callflag ) cptr = cptr-nextcontext; eval(s, cptr-cloenv); return; but when the expression is null/nil the code goes on to the default case, in which it gets the warning message from the 'call' parameter: dcall = CHAR(STRING_ELT(deparse1(call, 0, SIMPLEDEPARSE), 0)); REprintf(_(Warning in %s : ), dcall); So I don't see how this parameter can be available to the warning.expression call. There may be a way, but I don't see it. It seems a bit dumb that warning.expression functions can only say Hey, something a bit iffy may have ocurred, but I dont know what and I dont know where!. Maybe there's something in that cptr-cloenv that can tell you... Otherwise it requires patching. Baz __ R-help@stat.math.ethz.ch 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-pkgs] Reshape package: new version 0.5
Reshape version 0.5 === Reshape is an R package for flexibly restructuring and aggregating data. It's very much pivot table inspired, and it (hopefully) makes it very easy to view your data the way you want. You can find out more at http://had.co.nz/reshape The big news in this version of reshape is that I've renamed all the functions so they no longer conflict with any built in functions - deshape is now melt (think liquid data) and reshape is now cast (think solidifying data into the form you want). What else is new? * recast melts and casts your data in one step * column naming bugs fixed * easily display all margins with the argument margins=T in cast Please let me know what you think. Regards, Hadley ___ R-packages mailing list [EMAIL PROTECTED] https://stat.ethz.ch/mailman/listinfo/r-packages __ R-help@stat.math.ethz.ch 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] multifigure question
I would like to put three figures next to each other in a figure. I have been reading the introduction to R, section 12 several times now, and I still can't make heads or tails out of it. Lets say that I have three dataframes a, b, c, and I want to plot a$V1, b$V1 and c$V1 in separate plots simply using plot(), how do I put them next to each other? I am sorry if this is a FAQ, but I cannot understand what it says in the guide and the wonderful google couldn't turn up anything helpful either...:) Karin -- Karin Lagesen, PhD student [EMAIL PROTECTED] http://www.cmbn.no/rognes/ __ R-help@stat.math.ethz.ch 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] multifigure question
probably you need: par(mfrow = c(1, 3)) plot(a$V1) plot(b$V1) plot(c$V1) 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/(0)16/336899 Fax: +32/(0)16/337015 Web: http://www.med.kuleuven.be/biostat/ http://www.student.kuleuven.be/~m0390867/dimitris.htm - Original Message - From: Karin Lagesen [EMAIL PROTECTED] To: r-help@stat.math.ethz.ch Sent: Friday, September 23, 2005 2:14 PM Subject: [R] multifigure question I would like to put three figures next to each other in a figure. I have been reading the introduction to R, section 12 several times now, and I still can't make heads or tails out of it. Lets say that I have three dataframes a, b, c, and I want to plot a$V1, b$V1 and c$V1 in separate plots simply using plot(), how do I put them next to each other? I am sorry if this is a FAQ, but I cannot understand what it says in the guide and the wonderful google couldn't turn up anything helpful either...:) Karin -- Karin Lagesen, PhD student [EMAIL PROTECTED] http://www.cmbn.no/rognes/ __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm __ R-help@stat.math.ethz.ch 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] warning.expression?
Roger D. Peng wrote: You might be interested in 'tryCatch' to catch warnings. A warning here: tryCatch(expr, warning=...) will catch warnings and interrupt 'expr' (as if an error occured), whereas withCallingHandlers(expr, warning=...) does not do this. /Henrik -roger Thomas Friedrichsmeier wrote: Hi! I'm trying to catch all warning-messages for special handling. It seems options (warning.expression=myfunc ()) can be used for that. However, the question is: How can I get at the actual warning in myfunc ()? Apparently in S, you can use .C(get_last_message) for that. Is there a similar mechanism in R? Thanks for your help! Thomas __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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] multifigure question
There are actually several ways to do this in R. You probably want par with mfrow= or mfcol= as has already been mentioned but here are some possibilities: 1. par(mfrow=...) has already been mentioned with an example. 2. par(mfcol=...) is similar. See ?par 3. layout. See ?layout 4. split.screen. See ?split.screen 5. grid.layout using grid graphics. See: http://tolstoy.newcastle.edu.au/R/devel/05/06/1169.html for an example. 6. Some of graphics routines themselves can do this in one call. plot.ts will plot ts class time series in mulitiple plots (unless you specify plot.type = single. e.g. plot(ts(matrix(1:10,5))) plot.zoo from the zoo package is similar but also has an nc= argument for specifying the arrangement: library(zoo) plot(zoo(matrix(1:15,5)), nc = 3) Various lattice routines that support conditioning such as xyplot will automatically plot multiple plots. The layout= argument to xyplot can control this. library(lattice) xyplot(Sepal.Length ~ Sepal.Width | Species, data = iris, layout = c(3,1)) Try help with the various commands above. On 9/23/05, Karin Lagesen [EMAIL PROTECTED] wrote: I would like to put three figures next to each other in a figure. I have been reading the introduction to R, section 12 several times now, and I still can't make heads or tails out of it. Lets say that I have three dataframes a, b, c, and I want to plot a$V1, b$V1 and c$V1 in separate plots simply using plot(), how do I put them next to each other? I am sorry if this is a FAQ, but I cannot understand what it says in the guide and the wonderful google couldn't turn up anything helpful either...:) Karin -- Karin Lagesen, PhD student [EMAIL PROTECTED] http://www.cmbn.no/rognes/ __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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] Strange behaviour of as.Date function
Dear All, I'm happily extracting data of temperature from an oracle db under R via RODBC. After manipulating the extracted data I put them into a data.frame 'dati' which is as follows: dati DATA tm. UDINE/RIVOLTO tm.TORINO/CASELLE 1 2005-07-01 22.35 23.80 2 2005-07-0222.70 22.85 3 2005-07-0323.80 24.30 4 2005-07- 0423.80 25.40 .. and str(dati) `data.frame': 11 obs. of 3 variables: $ DATA :'POSIXct', format: chr 2005-07-01 2005-07-02 2005-07-03 2005-07-04 ... $ tm.UDINE/RIVOLTO : num 22.4 22.7 23.8 23.8 21.8 ... $ tm. TORINO/CASELLE: num 23.8 22.9 24.3 25.4 21.8 ... - attr(*, reshapeWide)=List of 5 ..$ v.names: NULL ..$ timevar: chr NOME ..$ idvar : chr DATA ..$ times : Factor w/ 2 levels TORINO/CASELLE,..: 2 1 ..$ varying: chr [1, 1:2] tm.UDINE/RIVOLTO tm.TORINO/CASELLE You see that the first field DATA is POSIXct Now dati[1,1] [1] 2005-07-01 ora solare Europa occidentale BUT as.Date(dati[1,1],%d%m%Y) [1] 2005-06-30 How come? What is wrong with it (or better with me)? Ciao Vittorio __ R-help@stat.math.ethz.ch 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] Strange behaviour of as.Date function
When it converts the time to Date it does it relative to the GMT time zone, not your time zone. When its July 1st in your time zone it can be June 30th in the GMT time zone. See the article in R News 4/1 Help Desk, and the table at the end of the article in particular, on ways to handle this. On 9/23/05, Vittorio [EMAIL PROTECTED] wrote: Dear All, I'm happily extracting data of temperature from an oracle db under R via RODBC. After manipulating the extracted data I put them into a data.frame 'dati' which is as follows: dati DATA tm. UDINE/RIVOLTO tm.TORINO/CASELLE 1 2005-07-01 22.35 23.80 2 2005-07-0222.70 22.85 3 2005-07-0323.80 24.30 4 2005-07- 0423.80 25.40 .. and str(dati) `data.frame': 11 obs. of 3 variables: $ DATA :'POSIXct', format: chr 2005-07-01 2005-07-02 2005-07-03 2005-07-04 ... $ tm.UDINE/RIVOLTO : num 22.4 22.7 23.8 23.8 21.8 ... $ tm. TORINO/CASELLE: num 23.8 22.9 24.3 25.4 21.8 ... - attr(*, reshapeWide)=List of 5 ..$ v.names: NULL ..$ timevar: chr NOME ..$ idvar : chr DATA ..$ times : Factor w/ 2 levels TORINO/CASELLE,..: 2 1 ..$ varying: chr [1, 1:2] tm.UDINE/RIVOLTO tm.TORINO/CASELLE You see that the first field DATA is POSIXct Now dati[1,1] [1] 2005-07-01 ora solare Europa occidentale BUT as.Date(dati[1,1],%d%m%Y) [1] 2005-06-30 How come? What is wrong with it (or better with me)? Ciao Vittorio __ R-help@stat.math.ethz.ch 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] FDR analyses: minimum number of features
Thanks. That is an excellent idea. Bill -Original Message- From: Spencer Graves [mailto:[EMAIL PROTECTED] Sent: Thursday, September 22, 2005 9:01 PM To: Dupont, William Cc: Kjetil Brinchmann Halvorsen; r-help@stat.math.ethz.ch Subject: Re: [R] FDR analyses: minimum number of features Have you considered Monte Carlo? From previous work, you could estimate a distribution for the differences to be detected and use that as input to a Monte Carlo, computing thereby a distribution for FDR as a function of distribution of differences and the number of features. From this, you could estimate probabilities for obtaining results that were bogus vs. marginal, barely useful vs. highly accurate and plot them vs. alternative budgets, etc. I hope this comment makes more sense than my earlier nonsense. spencer graves __ R-help@stat.math.ethz.ch 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-pkgs] Reshape package: new version 0.5
Hadley, On Thursday 22 September 2005 16:36, hadley wickham wrote: Reshape version 0.5 === Reshape is an R package for flexibly restructuring and aggregating data. It's very much pivot table inspired, and it (hopefully) makes it very easy to view your data the way you want. You can find out more at http://had.co.nz/reshape ... Please let me know what you think. Perhaps I'm dense, but I cannot find the software at the URL you mention. There are links to a paper and a PDF slide presentation, but no R package. There is also a dangling link (http://r-project.org/) in the first sentence. Regards, Hadley Randall Schulz __ R-help@stat.math.ethz.ch 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-pkgs] Reshape package: new version 0.5
Randall R Schulz wrote: Hadley, On Thursday 22 September 2005 16:36, hadley wickham wrote: Reshape version 0.5 === Reshape is an R package for flexibly restructuring and aggregating data. It's very much pivot table inspired, and it (hopefully) makes it very easy to view your data the way you want. You can find out more at http://had.co.nz/reshape ... Please let me know what you think. Perhaps I'm dense, but I cannot find the software at the URL you mention. There are links to a paper and a PDF slide presentation, but no R package. There is also a dangling link (http://r-project.org/) in the first sentence. Hi, Randall, The first section of the webpage says: quote How to install install.packages(reshape) /quote Try the latter call at the R prompt. HTH, --sundar __ R-help@stat.math.ethz.ch 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-pkgs] Reshape package: new version 0.5
Sundar, On Friday 23 September 2005 06:48, Sundar Dorai-Raj wrote: Randall R Schulz wrote: Hadley, ... Perhaps I'm dense, but I cannot find the software at the URL you mention. There are links to a paper and a PDF slide presentation, but no R package. There is also a dangling link (http://r-project.org/) in the first sentence. Hi, Randall, The first section of the webpage says: quote How to install install.packages(reshape) /quote Yes, of course I saw that. Try the latter call at the R prompt. Huh? All the other packages I've installed, and there have been several, I've downloaded from CRAN and used: % R CMD INSTALL packageName.tar.gz How am I to do that when I don't have the package. Where is going to come from? But now I see that there is a reshape package in CRAN. I figured (yes, assumed) that since no mention of CRAN was made at the author's Web page that this release was not distributed there. HTH, --sundar Randall Schulz __ R-help@stat.math.ethz.ch 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] Strange behaviour of as.Date function
datai[1,1] appears to be a 'POSIXct' object. Which date that is depends on the locale, and as.Date uses UTC (see ?as.Date). For me: d - as.POSIXct(2005-07-01) d [1] 2005-07-01 BST format(d, tz=GMT) [1] 2005-06-30 23:00:00 as.Date(d) [1] 2005-06-30 Use as.Date(d + 23.99*3600) to avoid this. On Fri, 23 Sep 2005, Vittorio wrote: Dear All, I'm happily extracting data of temperature from an oracle db under R via RODBC. After manipulating the extracted data I put them into a data.frame 'dati' which is as follows: dati DATA tm. UDINE/RIVOLTO tm.TORINO/CASELLE 1 2005-07-01 22.35 23.80 2 2005-07-0222.70 22.85 3 2005-07-0323.80 24.30 4 2005-07- 0423.80 25.40 .. and str(dati) `data.frame': 11 obs. of 3 variables: $ DATA :'POSIXct', format: chr 2005-07-01 2005-07-02 2005-07-03 2005-07-04 ... $ tm.UDINE/RIVOLTO : num 22.4 22.7 23.8 23.8 21.8 ... $ tm. TORINO/CASELLE: num 23.8 22.9 24.3 25.4 21.8 ... - attr(*, reshapeWide)=List of 5 ..$ v.names: NULL ..$ timevar: chr NOME ..$ idvar : chr DATA ..$ times : Factor w/ 2 levels TORINO/CASELLE,..: 2 1 ..$ varying: chr [1, 1:2] tm.UDINE/RIVOLTO tm.TORINO/CASELLE You see that the first field DATA is POSIXct Now dati[1,1] [1] 2005-07-01 ora solare Europa occidentale BUT as.Date(dati[1,1],%d%m%Y) [1] 2005-06-30 How come? What is wrong with it (or better with me)? Ciao Vittorio __ R-help@stat.math.ethz.ch 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 __ R-help@stat.math.ethz.ch 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] Are least-squares means useful or appropriate?
On 9/20/05, Felipe [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi. My question was just theoric. I was wondering if someone who were using SAS and R could give me their opinion on the topic. I was trying to use least-squares means for comparison in R, but then I found some indications against them, and I wanted to know if they had good basis (as I told earlier, they were not much detailed). Greetings. Felipe As Deepayan said in his reply, the concept of least squares means is associated with SAS and is not generally part of the theory of linear models in statistics. My vague understanding of these (I too am not a SAS user) is that they are an attempt to estimate the mean response for a particular level of a factor in a model in which that factor has a non-ignorable interaction with another factor. There is no clearly acceptable definition of such a thing. To understand why there should be an attempt to answer a question that doesn't make sense, remember the history of SAS, which was developed in the era of punched cards and magnetic tape. Beneath the surface of SAS with its GUI, etc. is the fundamental assumption that your data are on a reel of magnetic tape over in the Computer Center that houses an IBM Sytem/360 computer and that the way you are going to use this program is by keypunching a deck of punched cards, putting some mysterious JCL (the IBM Job Control Language which no one understood and you learned only by imitation) cards at the beginning and end, and submitting them at the I/O Window. The next day you will go to the computer center to pick up your output only to discover that you had a JCL error. You will spend most of the morning tracking down the one person on campus who can tell you that ERROR IEH92345 was caused by the blank between the DD and the * in the card that reads //SYSIN DD * so you change that and submit again. After two or three days of this you get the JCL right but discover that you have a syntax error in your SAS code. Another two or three cycles finally gets you to the point where you have a card deck that runs and produces output. At that point you don't really care if the output makes sense or not - all you want is some numbers for the report that is now a week overdue. You also want all the numbers that you might possibly need, which is why SAS PROCs always have the potential to produce tons of output if you ask for it. R is an interactive language where it is a simple matter to fit a series of models and base your analysis on a model that is appropriate. An approach of give me the answer to any possible question about this model, whether or not it make sense is unnecessary. In many ways statistical theory and practice has not caught up with statistical computing. There are concepts that are regarded as part of established statistical theory when they are, in fact, approximations or compromises motivated by the fact that you can't compute the answer you want - except now you can compute it. However, that won't stop people who were trained in the old system from assuming that things *must* be done in that way. In short, I agree with Deepayan - the best thing to do is to ask someone who uses SAS and least squares means to explain to you what they are. __ R-help@stat.math.ethz.ch 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-pkgs] Reshape package: new version 0.5
From: Randall R Schulz Sundar, On Friday 23 September 2005 06:48, Sundar Dorai-Raj wrote: Randall R Schulz wrote: Hadley, ... Perhaps I'm dense, but I cannot find the software at the URL you mention. There are links to a paper and a PDF slide presentation, but no R package. There is also a dangling link (http://r-project.org/) in the first sentence. Hi, Randall, The first section of the webpage says: quote How to install install.packages(reshape) /quote Yes, of course I saw that. Try the latter call at the R prompt. Huh? All the other packages I've installed, and there have been several, I've downloaded from CRAN and used: % R CMD INSTALL packageName.tar.gz How am I to do that when I don't have the package. Where is going to come from? If you do not know about the R function that is shown to you in response to your question, wouldn't it help to check out its help page on your own first? By default install.packages() does the download _and_ the rest for you automagically so you don't need to do that in steps outside of R. But now I see that there is a reshape package in CRAN. I figured (yes, assumed) that since no mention of CRAN was made at the author's Web page that this release was not distributed there. There's a short lag between package upload and its showing up on CRAN, and possibly longer lag for that to show up on various mirror sites. If and when I announcement, I'd wait til I see it show up at least on the master site before posting, or ask the users to check for availability. Andy HTH, --sundar Randall Schulz __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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 make file
I have downloaded from cran.r-progject.org/src/base/R-2 and unzipped R-2.1.1 into the directory /keith/r and run ./configure on my linux CentOS 3.5 platform and when I run make I get: make: *** No targets specified and no makefile found. Stop. any ideas on where the makefile is or why it's not there? Keith . [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch 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] Installing local packages in R for MacOSX 10.4.2
Dear all, I have been using R for Windows before but recently switched to Mac. Now I am confused about how to install local packages using R 2.1.1. on the Mac. I found the menu Packages and Data, and have used it succesfully to install CRAN and Bioconductor packages (all binaries) by selecting these repositories from the pull-down menu and clicking the Get List button. However there is one package from OmegaHat I want to install (Rcurl). Since this is not a listed repository in the Install Packages pull-down menu, I tried the Other Repository function and entered the URL for the OmegaHat page. This doesn't work as R tries to add /PACKAGES to the URL and this is apparently not how the OmegaHat site is set up (I tried the same with bioconductor's URL and that did work). SO I downloaded the .tar.gz file. I remember from my R for Windows there was an option Install Package From Local File. But in this version of R for MAC I can't find this. In the R FAQ for MAC OSX it says I should choose, in the Install Packages menu, the option Local Package from the pull-down menu. But then the Get List button is greyed out, and no packages appear in the list. I have tried putting the .tar.gz file in several places: in the working directory (/user/admin in this case), in the R-Framework/Resources/Library directory, but never is the file listed in the Install Packages menu. I must be doing something wrong but don't know what. This is the text from the R FAQ for OSX, which I followed: You can also download any other package from the Internet yourself and decide to install it from source. In such case select one of the local entries in the top left list. (The top left list being the pull-down menu I described and the local entries being Local Binary package, Local Source Package, and Local Package Directory). Could somebody please help me out? Best wishes, Marije De inhoud van dit bericht is vertrouwelijk en alleen bestemd voor de geadresseerde(n). Anderen dan de geadresseerde mogen geen gebruik maken van dit bericht, het openbaar maken of op enige wijze verspreiden of vermenigvuldigen. Het UMCG kan niet aansprakelijk gesteld worden voor een incomplete aankomst of vertraging van dit verzonden bericht. The contents of this message are confidential and only intended for the eyes of the addressee(s). Others than the addressee(s) are not allowed to use this message, to make it public or to distribute or multiply this message in any way. The UMCG cannot be held responsible for incomplete reception or delay of this transferred message. [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch 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 make file
keith stephenson wrote: I have downloaded from cran.r-progject.org/src/base/R-2 and unzipped R-2.1.1 into the directory /keith/r and run ./configure on my linux CentOS 3.5 platform and when I run make I get: make: *** No targets specified and no makefile found. Stop. any ideas on where the makefile is or why it's not there? Probably because of errors during ./configure ... and we do not know which errors came up ... Uwe Ligges Keith . [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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] CART for 0/1 data
Dear R-user, I tried to generate classification / regression tree with a absence/presence matrix of species (400) in different locations (50) to visualise species which are important for splitting up two locations. Rpart and tree did not work for more than 10 species which is logical due to the limited amount of locations (n=50). However the error prompt is a + and no specific message, but I am pretty sure that I did not enter a false sign by mistake. Is it allowed at all to use 0/1 data for this statistical technique and if yes is there a way or different method to use all 400 species entries? Otherwise I would apply a PCA beforehand but I would prefer to have the raw species informations. using R 2.1.1-1 (debian repos.) regards, Martin -- Martin Wegmann DLR - German Aerospace Center German Remote Sensing Data Center @ Dept.of Geography Remote Sensing and Biodiversity Unit Dept. of Animal Ecology and Tropical Biology University of Wuerzburg Am Hubland 97074 Würzburg phone: +49-(0)931 - 888 4797 mobile: +49-(0)175 2091725 fax: +49-(0)931 - 888 4961 http://www.biota-africa.org http://www.biogis.de __ R-help@stat.math.ethz.ch 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] Installing local packages in R for MacOSX 10.4.2
Hi Marije, When you select the Package Installer, select Local Source Package and press Install (which is now enabled). This will get you to a Finder window where you can select the source file to install. Hope this helps, Rob PS There is a R-SIG-Mac alias for questions specific to R on Mac OS. On Sep 23, 2005, at 7:24 AM, Booman, M wrote: Dear all, I have been using R for Windows before but recently switched to Mac. Now I am confused about how to install local packages using R 2.1.1. on the Mac. I found the menu Packages and Data, and have used it succesfully to install CRAN and Bioconductor packages (all binaries) by selecting these repositories from the pull-down menu and clicking the Get List button. However there is one package from OmegaHat I want to install (Rcurl). Since this is not a listed repository in the Install Packages pull-down menu, I tried the Other Repository function and entered the URL for the OmegaHat page. This doesn't work as R tries to add /PACKAGES to the URL and this is apparently not how the OmegaHat site is set up (I tried the same with bioconductor's URL and that did work). SO I downloaded the .tar.gz file. I remember from my R for Windows there was an option Install Package From Local File. But in this version of R for MAC I can't find this. In the R FAQ for MAC OSX it says I should choose, in the Install Packages menu, the option Local Package from the pull-down menu. But then the Get List button is greyed out, and no packages appear in the list. I have tried putting the .tar.gz file in several places: in the working directory (/user/ admin in this case), in the R-Framework/Resources/Library directory, but never is the file listed in the Install Packages menu. I must be doing something wrong but don't know what. This is the text from the R FAQ for OSX, which I followed: You can also download any other package from the Internet yourself and decide to install it from source. In such case select one of the local entries in the top left list. (The top left list being the pull- down menu I described and the local entries being Local Binary package, Local Source Package, and Local Package Directory). Could somebody please help me out? Best wishes, Marije De inhoud van dit bericht is vertrouwelijk en alleen bestemd voor de geadresseerde(n). Anderen dan de geadresseerde mogen geen gebruik maken van dit bericht, het openbaar maken of op enige wijze verspreiden of vermenigvuldigen. Het UMCG kan niet aansprakelijk gesteld worden voor een incomplete aankomst of vertraging van dit verzonden bericht. The contents of this message are confidential and only intended for the eyes of the addressee(s). Others than the addressee(s) are not allowed to use this message, to make it public or to distribute or multiply this message in any way. The UMCG cannot be held responsible for incomplete reception or delay of this transferred message. [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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] CART for 0/1 data
Martin, If the data are actually coded 0/1, the tree function would probably intepret them as integers and try a regression instead of a classification. If the dependent variable is called var, try x - tree(factor(var)~species) David W. Roberts office 406-994-4548 Professor and Head FAX 406-994-3190 Department of Ecology email [EMAIL PROTECTED] Montana State University Bozeman, MT 59717-3460 Martin Wegmann wrote: Dear R-user, I tried to generate classification / regression tree with a absence/presence matrix of species (400) in different locations (50) to visualise species which are important for splitting up two locations. Rpart and tree did not work for more than 10 species which is logical due to the limited amount of locations (n=50). However the error prompt is a + and no specific message, but I am pretty sure that I did not enter a false sign by mistake. Is it allowed at all to use 0/1 data for this statistical technique and if yes is there a way or different method to use all 400 species entries? Otherwise I would apply a PCA beforehand but I would prefer to have the raw species informations. using R 2.1.1-1 (debian repos.) regards, Martin __ R-help@stat.math.ethz.ch 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] Are least-squares means useful or appropriate?
Douglas Bates [EMAIL PROTECTED] writes: On 9/20/05, Felipe [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi. My question was just theoric. I was wondering if someone who were using SAS and R could give me their opinion on the topic. I was trying to use least-squares means for comparison in R, but then I found some indications against them, and I wanted to know if they had good basis (as I told earlier, they were not much detailed). Greetings. Felipe As Deepayan said in his reply, the concept of least squares means is associated with SAS and is not generally part of the theory of linear models in statistics. My vague understanding of these (I too am not a SAS user) is that they are an attempt to estimate the mean response for a particular level of a factor in a model in which that factor has a non-ignorable interaction with another factor. There is no clearly acceptable definition of such a thing. (PD goes and fetches the SAS manual) Well, yes. it'll do that too, although only if you ask for the lsmeans of A when an interaction like A*B is present in the model. This is related to the tests of main effects when an interaction is present using type III sums of squares, which has been beaten to death repeatedly on the list. In both cases, there seems to be an implicit assumption that categorical variables by nature comes from an underlying fully balanced design. If the interaction is absent from the model, the lsmeans are somewhat more sensible in that they at least reproduce the parameter estimates as contrasts between different groups. All continuous variables in the design will be set to their mean, but values for categorical design variables are weighted inversely as the number of groups. So if you're doing an lsmeans of lung function by smoking adjusted for age and sex you get estimates for the mean of a population of which everyone has the same age and half are male and half are female. This makes some sense, but if you do it for sex adjusting for smoking and age, you are not only forcing the sexes to smoke equally much, but actually adjusting to smoking rates of 50%, which could be quite far from reality. The whole operation really seems to revolve around 2 things: (1) pairwise comparisons between factor levels. This can alternatively be done fairly easily using parameter estimates for the relevant variable and associated covariances. You don't really need all the mumbo-jumbo of adjusting to particular values of other variables. (2) plotting effects of a factor with error bars as if they were simple group means. This has some merit since the standard parametrizations are misleading at times (e.g. if you choose the group with the least data as the reference level, std. err. for the other groups will seem high). However, it seems to me that concepts like floating variances (see float() in the Epi package) are more to the point. R is an interactive language where it is a simple matter to fit a series of models and base your analysis on a model that is appropriate. An approach of give me the answer to any possible question about this model, whether or not it make sense is unnecessary. In many ways statistical theory and practice has not caught up with statistical computing. There are concepts that are regarded as part of established statistical theory when they are, in fact, approximations or compromises motivated by the fact that you can't compute the answer you want - except now you can compute it. However, that won't stop people who were trained in the old system from assuming that things *must* be done in that way. In short, I agree with Deepayan - the best thing to do is to ask someone who uses SAS and least squares means to explain to you what they are. __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- O__ Peter Dalgaard Øster Farimagsgade 5, Entr.B c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~ - ([EMAIL PROTECTED]) FAX: (+45) 35327907 __ R-help@stat.math.ethz.ch 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] CART for 0/1 data
On Friday 23 September 2005 17:08, Dave Roberts wrote: Martin, If the data are actually coded 0/1, the tree function would probably intepret them as integers and try a regression instead of a classification. If the dependent variable is called var, try thanks, but I think I provided too less informations. My dependent variable are the locations which are names (I could transform them to numbers from 1 - n). The independent variables consist of 0/1 data (species). If I do tree(locations~factor(species1)+factor(species2)+.+factor(speciesn), sp_data) I receive the same results as without the factor() part. BTW just a subset of the locations are displayed what is pretty weird considering that I included all locations in the analysis. Martin x - tree(factor(var)~species) David W. Roberts office 406-994-4548 Professor and Head FAX 406-994-3190 Department of Ecology email [EMAIL PROTECTED] Montana State University Bozeman, MT 59717-3460 Martin Wegmann wrote: Dear R-user, I tried to generate classification / regression tree with a absence/presence matrix of species (400) in different locations (50) to visualise species which are important for splitting up two locations. Rpart and tree did not work for more than 10 species which is logical due to the limited amount of locations (n=50). However the error prompt is a + and no specific message, but I am pretty sure that I did not enter a false sign by mistake. Is it allowed at all to use 0/1 data for this statistical technique and if yes is there a way or different method to use all 400 species entries? Otherwise I would apply a PCA beforehand but I would prefer to have the raw species informations. using R 2.1.1-1 (debian repos.) regards, Martin __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- Martin Wegmann DLR - German Aerospace Center German Remote Sensing Data Center @ Dept.of Geography Remote Sensing and Biodiversity Unit Dept. of Animal Ecology and Tropical Biology University of Wuerzburg Am Hubland 97074 Würzburg phone: +49-(0)931 - 888 4797 mobile: +49-(0)175 2091725 fax: +49-(0)931 - 888 4961 http://www.biota-africa.org http://www.biogis.de __ R-help@stat.math.ethz.ch 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] your subscribe request
Re: your subscribe request subscribe Sorry, this email address is not allowed to subscribe to 'rachel'. __ R-help@stat.math.ethz.ch 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] panel.linejoin groups
Dear R community, I am still new to R, but I am attempting to use it for (hopefully) all my plotting needs. I have been using lattice and Hmisc for most plots so far successfully, but I need help creating a plot I desire for some new data I have. This data frame consists of the same type of measurement (Eh) for 27 different locations. I have 8000+ measurements for each location, and my datalogger organizes the output like this: DateA1L A2L A3L 2005-07-14 22:00208.1 -178.5 196.8 2005-07-14 22:10207.9 -184.3 200.0 Now I'm having trouble plotting A1L, A2L, A3L on the same plot as a function of Date. I thought I would try panel.linejoin, like so: xyplot(data=redox2, A1L + A2L + A3L ~ Date, panel=function(x,y,...){panel.linejoin(x,y,horizontal=F,col=1,...)}, scales=list(x=list(tick.number=10))) But of course, what I get is the mean of the measurements from those three columns plotted as one line, when what I want is a separate line for each column of data. Do I need to define groups somehow to get separate lines? If so, how do I define groups based on membership in different columns? Or do I just need to reorganize my data to make it work, like this: DateLocationEh 2005-07-14 22:00A1L 208.1 2005-07-14 22:00A2L -178.5 Then I can define groups=Location, and it would work. But it would be good to know if I can make the data work as is - because I have many many more datasets that are structured this way. Thank you, Erin Erin M. Berryman Graduate Research Assistant Department of Soil, Water, and Climate University of Minnesota 439 Borlaug Hall 1991 Upper Buford Circle St. Paul, MN 55104 612.625.9747 [EMAIL PROTECTED] __ R-help@stat.math.ethz.ch 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] CART for 0/1 data
Martin, Sorry, I don't think I read your message carefully enough. When you say the error message is +, that woudl seem to indicate that you still had an unclosed parenthesis and that the function was looking for more input. Using a smaller data set (160 samples, 169 rows, only 5 classes) it did work fine for me. pa = presence/absence dataframe, opt.5$clustering = cluster IDs. * test - tree(factor(opt.5$clustering)~pa) test node), split, n, deviance, yval, (yprob) * denotes terminal node 1) root 160 371.000 3 ( 0.23750 0.08750 0.57500 0.07500 0.02500 ) 2) pa.symore 0.5 79 216.500 1 ( 0.48101 0.17722 0.15190 0.13924 0.05063 ) 4) pa.artarb 0.5 42 123.600 2 ( 0.07143 0.3 0.26190 0.23810 0.09524 ) 8) pa.macgri 0.5 31 75.280 2 ( 0.09677 0.45161 0.0 0.32258 0.12903 ) .. . .. . .. . 3) pa.symore 0.5 81 10.780 3 ( 0.0 0.0 0.98765 0.01235 0.0 ) 6) pa.carrss 0.5 11 6.702 3 ( 0.0 0.0 0.90909 0.09091 0.0 ) * 7) pa.carrss 0.5 70 0.000 3 ( 0.0 0.0 1.0 0.0 0.0 ) * I'll try agin with a larger dataset and see if it's a memory limitation. Dave Roberts Martin Wegmann wrote: On Friday 23 September 2005 17:08, Dave Roberts wrote: Martin, If the data are actually coded 0/1, the tree function would probably intepret them as integers and try a regression instead of a classification. If the dependent variable is called var, try thanks, but I think I provided too less informations. My dependent variable are the locations which are names (I could transform them to numbers from 1 - n). The independent variables consist of 0/1 data (species). If I do tree(locations~factor(species1)+factor(species2)+.+factor(speciesn), sp_data) I receive the same results as without the factor() part. BTW just a subset of the locations are displayed what is pretty weird considering that I included all locations in the analysis. Martin x - tree(factor(var)~species) David W. Roberts office 406-994-4548 Professor and Head FAX 406-994-3190 Department of Ecology email [EMAIL PROTECTED] Montana State University Bozeman, MT 59717-3460 Martin Wegmann wrote: Dear R-user, I tried to generate classification / regression tree with a absence/presence matrix of species (400) in different locations (50) to visualise species which are important for splitting up two locations. Rpart and tree did not work for more than 10 species which is logical due to the limited amount of locations (n=50). However the error prompt is a + and no specific message, but I am pretty sure that I did not enter a false sign by mistake. Is it allowed at all to use 0/1 data for this statistical technique and if yes is there a way or different method to use all 400 species entries? Otherwise I would apply a PCA beforehand but I would prefer to have the raw species informations. using R 2.1.1-1 (debian repos.) regards, Martin __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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] CART for 0/1 data
Martin, I should have tried before the last post to save postings, but on my machine I tried samples = 1224, species = 962, clusters = 10 with no problems at all. summary(test) Classification tree: tree(formula = factor(opt.10$clustering) ~ pa) Variables actually used in tree construction: [1] pa.PICENG pa.ARTTSV pa.PSEMEN pa.AGRSPI pa.DESCES pa.ABILAS [7] pa.FESIDA pa.POLBIS pa.CAREXX pa.PINCON pa.GEUMAC Number of terminal nodes: 16 Residual mean deviance: 1.551 = 1873 / 1208 Misclassification error rate: 0.2435 = 298 / 1224 You may want to reclassify to fewer than 50 locations, but I think it should work. Good luck, Dave Roberts Martin Wegmann wrote: On Friday 23 September 2005 17:08, Dave Roberts wrote: Martin, If the data are actually coded 0/1, the tree function would probably intepret them as integers and try a regression instead of a classification. If the dependent variable is called var, try thanks, but I think I provided too less informations. My dependent variable are the locations which are names (I could transform them to numbers from 1 - n). The independent variables consist of 0/1 data (species). If I do tree(locations~factor(species1)+factor(species2)+.+factor(speciesn), sp_data) I receive the same results as without the factor() part. BTW just a subset of the locations are displayed what is pretty weird considering that I included all locations in the analysis. Martin x - tree(factor(var)~species) David W. Roberts office 406-994-4548 Professor and Head FAX 406-994-3190 Department of Ecology email [EMAIL PROTECTED] Montana State University Bozeman, MT 59717-3460 Martin Wegmann wrote: Dear R-user, I tried to generate classification / regression tree with a absence/presence matrix of species (400) in different locations (50) to visualise species which are important for splitting up two locations. Rpart and tree did not work for more than 10 species which is logical due to the limited amount of locations (n=50). However the error prompt is a + and no specific message, but I am pretty sure that I did not enter a false sign by mistake. Is it allowed at all to use 0/1 data for this statistical technique and if yes is there a way or different method to use all 400 species entries? Otherwise I would apply a PCA beforehand but I would prefer to have the raw species informations. using R 2.1.1-1 (debian repos.) regards, Martin __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html -- David W. Roberts office 406-994-4548 Professor and Head FAX 406-994-3190 Department of Ecology email [EMAIL PROTECTED] Montana State University Bozeman, MT 59717-3460 __ R-help@stat.math.ethz.ch 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] books about MCMC to use MCMC R packages?
I've found Bayesian Data Analysis by Gelman, Carlin, Stern Rubin (2nd ed) to be quite useful for understanding how MCMC can be used for Bayesian models. It has a little bit of R code in it too. -- Tony Plate Molins, Jordi wrote: Dear list users, I need to learn about MCMC methods, and since there are several packages in R that deal with this subject, I want to use them. I want to buy a book (or more than one, if necessary) that satisfies the following requirements: - it teaches well MCMC methods; - it is easy to implement numerically the ideas of the book, and notation and concepts are similar to the corresponding R packages that deal with MCMC methods. I have done a search and 2 books seem to satisfy my requirements: - Markov Chain Monte Carlo In Practice, by W.R. Gilks and others. - Monte Carlo Statistical methods, Robert and Casella. What do people think about these books? Is there a suggestion of some other book that could satisfy better my requirements? Thank you very much in advance. The information contained herein is confidential and is inte...{{dropped}} __ R-help@stat.math.ethz.ch 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-help@stat.math.ethz.ch 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] panel.linejoin groups
On 9/23/05, Erin Berryman [EMAIL PROTECTED] wrote: Dear R community, I am still new to R, but I am attempting to use it for (hopefully) all my plotting needs. I have been using lattice and Hmisc for most plots so far successfully, but I need help creating a plot I desire for some new data I have. This data frame consists of the same type of measurement (Eh) for 27 different locations. I have 8000+ measurements for each location, and my datalogger organizes the output like this: DateA1L A2L A3L 2005-07-14 22:00208.1 -178.5 196.8 2005-07-14 22:10207.9 -184.3 200.0 Now I'm having trouble plotting A1L, A2L, A3L on the same plot as a function of Date. I thought I would try panel.linejoin, like so: xyplot(data=redox2, A1L + A2L + A3L ~ Date, panel=function(x,y,...){panel.linejoin(x,y,horizontal=F,col=1,...)}, scales=list(x=list(tick.number=10))) But of course, what I get is the mean of the measurements from those three columns plotted as one line, when what I want is a separate line for each column of data. Do I need to define groups somehow to get separate lines? If so, how do I define groups based on membership in different columns? Or do I just need to reorganize my data to make it work, like this: DateLocationEh 2005-07-14 22:00A1L 208.1 2005-07-14 22:00A2L -178.5 Then I can define groups=Location, and it would work. But it would be good to know if I can make the data work as is - because I have many many more datasets that are structured this way. Yes, simply supply 'panel.groups' instead of 'panel' panel.groups = function(x,y,...) { panel.linejoin(x,y,horizontal=F,col=1,...) }, panel.linejoin doesn't know anything about groups, and has to be used through panel.superpose (which does). However, the more obvious approach seems to be xyplot(A1L + A2L + A3L ~ Date, data=redox2, type = 'l', scales=list(x=list(tick.number=10))) Does that not work? panel.linejoin is meant for cases where several observations need to be summarized by a single number (mean, median, etc). BTW, it's not a good idea to have anything other than the formula as the first argument to xyplot etc. Deepayan __ R-help@stat.math.ethz.ch 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] panel.linejoin groups
Both methods you listed do work, but type='l' is what I want, thank you for pointing that out to me. Incidentally, xyplot(type='l') printed much faster on the display than the panel.groups=() method. I was captivated by linejoin before I ever had a case to use xyplot(type='l'), which would explain why I tried to use it for this type of plot! On Sep 23, 2005, at 1:01 PM, Deepayan Sarkar wrote: On 9/23/05, Erin Berryman [EMAIL PROTECTED] wrote: Dear R community, I am still new to R, but I am attempting to use it for (hopefully) all my plotting needs. I have been using lattice and Hmisc for most plots so far successfully, but I need help creating a plot I desire for some new data I have. This data frame consists of the same type of measurement (Eh) for 27 different locations. I have 8000+ measurements for each location, and my datalogger organizes the output like this: DateA1L A2L A3L 2005-07-14 22:00208.1 -178.5 196.8 2005-07-14 22:10207.9 -184.3 200.0 Now I'm having trouble plotting A1L, A2L, A3L on the same plot as a function of Date. I thought I would try panel.linejoin, like so: xyplot(data=redox2, A1L + A2L + A3L ~ Date, panel=function(x,y,...){panel.linejoin(x,y,horizontal=F,col=1,...)}, scales=list(x=list(tick.number=10))) But of course, what I get is the mean of the measurements from those three columns plotted as one line, when what I want is a separate line for each column of data. Do I need to define groups somehow to get separate lines? If so, how do I define groups based on membership in different columns? Or do I just need to reorganize my data to make it work, like this: DateLocationEh 2005-07-14 22:00A1L 208.1 2005-07-14 22:00A2L -178.5 Then I can define groups=Location, and it would work. But it would be good to know if I can make the data work as is - because I have many many more datasets that are structured this way. Yes, simply supply 'panel.groups' instead of 'panel' panel.groups = function(x,y,...) { panel.linejoin(x,y,horizontal=F,col=1,...) }, panel.linejoin doesn't know anything about groups, and has to be used through panel.superpose (which does). However, the more obvious approach seems to be xyplot(A1L + A2L + A3L ~ Date, data=redox2, type = 'l', scales=list(x=list(tick.number=10))) Does that not work? panel.linejoin is meant for cases where several observations need to be summarized by a single number (mean, median, etc). BTW, it's not a good idea to have anything other than the formula as the first argument to xyplot etc. Deepayan Erin M. Berryman Graduate Research Assistant Department of Soil, Water, and Climate University of Minnesota 612.625.9747 __ R-help@stat.math.ethz.ch 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] panel.linejoin groups
On 9/23/05, Erin Berryman [EMAIL PROTECTED] wrote: Both methods you listed do work, but type='l' is what I want, thank you for pointing that out to me. Incidentally, xyplot(type='l') printed much faster on the display than the panel.groups=() method. Not surprising if you have many values of 'Date', since panel.linejoin will try to compute the mean (of a length-1 vector) for each combination of Date and groups. Deepayan __ R-help@stat.math.ethz.ch 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] Alternative to nlm()
Greetings, I am using the nlm function in a minimization exercise but have consistently received the code: last global step failed to locate a point lower than 'estimate' So it seems that this function is only finding a local minimum, not necessarily a global minimum. Does anyone have a suggestion or recommendation for an alternative package or function within R that will perform this minimization task more globally? Thank you, Marion Wittmann [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch 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] Problem with read.spss() and as.data.frame(), or: alternative to subset()?
On Wed, 21 Sep 2005, Martin Maechler wrote: Dirk == Dirk Enzmann [EMAIL PROTECTED] on Wed, 21 Sep 2005 13:18:32 +0200 writes: Dirk The selection problem can be solved by Dirk dr2000=read.spss('myfile') Dirk d=lapply(dr2000,subset,dr2000$RBINZ99 0) Dirk however, there is still the problem that R crashes when using Dirk d = as.data.frame(dr2000) which is bug in a R, or at least in your R installation. However we can't do anything about it at the moment, because we can't even try to do reproduce it... I suspect this is the same stack overflow in coerce.c:substituteList that was reported in PR#8141 -thomas So dr2000 is a list; what length() does it have?, what names() ? what does str(dr2000) look like? What does happen for as.data.frame(dr2000[1:10]) ? and '100' or '1000' instead of '10'? Maybe try to find a small version of 'dr2000' which still has the problem, and show us that one, e.g. by making it available via http://... if it is still large, otherwise (if it's small), maybe even posting the result of dump(..). Regards, Martin __ R-help@stat.math.ethz.ch 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 __ R-help@stat.math.ethz.ch 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] SAX Parser best practise
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Jan Hummel wrote: Thank you Seth and Duncan for your input! BTW, do you have a schema for the XML document you are working on? Yes, a schema is available here http://psidev.sourceforge.net/ms/xml/mzdata/mzdata.xsd Informations around mzData xml format are available here http://psidev.sourceforge.net/ms/#mzdata Thanks. Next question I want to come up with: is there a way to validate xml again a schema or a dtd while parsing using xmlEventParse()? I dug around in the libxml code and the Web to verify that validation is indeed only possible in libxml when one uses DOM (i.e. xmlTreeParse()). Do you really need to validate the input? Given the size of the source, it must be created automatically and so I tend to think it is either correct or not, but that errors will be found with the creation mechanism. BTW, there is a new version of the XML package on the Omegahat web site. It has several new features, including a function to find nodes via XPath expressions, SAX2 support, recursive support for xmlElementsByTagName(). cheers Jan - -- Duncan Temple Lang[EMAIL PROTECTED] Department of Statistics work: (530) 752-4782 371 Kerr Hall fax: (530) 752-7099 One Shields Ave. University of California at Davis Davis, CA 95616, USA -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.2 (Darwin) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFDNLVK9p/Jzwa2QP4RAqNvAJ97+XW1B1AO6zl8ZN2qtVHCcPuu4ACfXnR9 572gL8pD2eMHj/tUSRomZwQ= =SXBQ -END PGP SIGNATURE- __ R-help@stat.math.ethz.ch 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] Cluster and Tree Conversion
hi, i'm looking for some help w/ Antoine Lucas's package for Cluster and Tree Conversion (from r to Xcluster). the r2dct functions includes 2 parameters not discussed in the .pdf. if i've deciphered them correctly the hr is the labels and the hc is the Hclust object. i can properly run the function with larger data matrix and only receive a warning msg: Warning message: number of items to replace is not a multiple of replacement length However smaller matrices fail: Error in [.data.frame(data[, 5:m], hc$order) : undefined columns selected as anyone had to work around this? thanks, kt __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html