Re: [R] larger decimal numbers get rounded ....

2007-09-06 Thread Mark Wardle
visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff, UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo

Re: [R] Artifacts in pdf() of image() (w/o comments)

2007-08-13 Thread Mark Wardle
. __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research fellow

Re: [R] - round() strange behaviour

2007-08-05 Thread Mark Wardle
. __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research

Re: [R] bars' values on barplot

2007-08-05 Thread Mark Wardle
by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK

Re: [R] bars' values on barplot

2007-08-05 Thread Mark Wardle
Much better. Thanks! Mark On 05/08/07, Adrian Dusa [EMAIL PROTECTED] wrote: On Sunday 05 August 2007, Mark Wardle wrote: [...] So, try this for starters: my.values=1:5 x - barplot(my.values, ylim=c(0,7)) text(x, 0.4+my.values, wibble) Mark, you could use the pos argument from ?par

Re: [R] t-test

2007-08-05 Thread Mark Wardle
:100,each=4)), age = rep(round(rnorm(100, mean=50, sd=15)), each=4), class =rep(round(rnorm(100, mean=3, sd=1)), each=4)) # exclude duplicated d1.s - d1[!duplicated(d1$id),] t.test(d1.s[class==3,], d1.s[class==1,]) Mark -- Dr. Mark Wardle Clinical research fellow and specialist

Re: [R] Sourcing commands but delaying their execution

2007-08-03 Thread Mark Wardle
. __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology

Re: [R] R and Excel

2007-07-23 Thread Mark Wardle
merge(). It is a different way of thinking, but can effectively lookup corresponding values in one data frame into another. If you give a sample of data then I could be a bit more specific! Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff

[R] Binomial multi-level (hierarchical) modelling [partly stats question, not completely R related]

2007-07-21 Thread Mark Wardle
methods base other attached packages: lme4 Matrix latticeRODBC 0.99875-4 0.999375-00.15-11 1.2-1 -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK __ R-help@stat.math.ethz.ch

Re: [R] Neuman-Keuls

2007-07-18 Thread Mark Wardle
please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK __ R-help@stat.math.ethz.ch mailing list

Re: [R] R file via SSH

2007-07-13 Thread Mark Wardle
. For more information please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK __ R-help

Re: [R] \include-mechanism in Sweave?

2007-06-29 Thread Mark Wardle
by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK

Re: [R] Aggregation of data frame with calculations of proportions

2007-06-27 Thread Mark Wardle
over that beer I owe you! Many thanks, Best wishes, -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read

[R] Aggregation of data frame with calculations of proportions

2007-06-26 Thread Mark Wardle
anyone help? Many (many many) thanks! Best wishes, Mark P.S. this is enough to drive me to drink! -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology Cardiff, UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch

Re: [R] merging more than two data frames

2007-06-23 Thread Mark Wardle
On 22/06/07, Andrew Yee [EMAIL PROTECTED] wrote: I'm familiar with using merge() to merge two data frames. But is there functionality in R that will let you merge three or more data frames? I just perform multiple merge() operations iteratively. -- Dr. Mark Wardle Clinical research fellow

Re: [R] Manipulating the sizes of multiple screens

2007-05-23 Thread Mark Wardle
Judith Flores wrote: Hi, I used split.screen command to creaye 5 screens, 4 screens contain a plot each, the fifth screen is designated to a legend. I am having difficulties setting the dimensions of the screens in a way that would allow me to have the screen dedicated to the

Re: [R] substitute values

2007-04-03 Thread Mark Wardle
NA 0 7 67 0 8 NA 0 How about using ifelse(): year = c(1,2,3,4,5,NA,6,7,8) products = c(10,25,40,NA,35,23,NA,67,NA) ifelse(is.na(year) products20,1,0) = [1] 0 0 0 0 0 1 0 0 0 Mark -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff

Re: [R] (Newbie)Basic Basic global vs. local variables

2007-04-03 Thread Mark Wardle
And if you want to save the result, use g_Means = runIt() You can pass arbitrarily complex data structures from and to functions if you have the need - see list(). Hope this helps, Mark -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff, UK __ R

Re: [R] RODBC, sqlQuery with NA:s

2007-04-03 Thread Mark Wardle
those rows where the cells of var1 are empty. So, is there any possibility to tell R that it should convert these empty cells to NA:s (when importing)? You could use a SQL case statement to do some pre-processing so that RODBC can do the right thing. Best wishes, Mark -- Dr. Mark Wardle

Re: [R] substitute values

2007-04-03 Thread Mark Wardle
7 670 8 NA 0 NA NA *NA* NA NA *NA* When i hane NA in both columns the results of the procedure give me NA. I'd like to obtain 0. 2007/4/3, Mark Wardle [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]: Sergio

Re: [R] converting a list to a data.frame

2007-04-03 Thread Mark Wardle
= rbind(x, unlist(d)) } return(x) } fix.it(l) It works on the data you sent me: fix.it(A) Have fun, Mark -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff, UK __ R-help@stat.math.ethz.ch mailing list https

Re: [R] Referencing function name from within function

2007-04-03 Thread Mark Wardle
wishes, Mark -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff, UK __ 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 and provide

Re: [R] Subset

2007-03-23 Thread Mark Wardle
this? You've answered your own question! ?subset e.g., subset(my.data, cluster==1) You should also notice that many R functions support a subset= parameter, which is very useful! Mark -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff, UK

Re: [R] personalize regression printing?

2007-03-22 Thread Mark Wardle
custom summary function (my.summary()? Best wishes, Mark -- Dr. Mark Wardle Specialist registrar, Neurology Cardiff, UK __ 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

Re: [R] Density estimation graphs

2007-03-15 Thread Mark Wardle
Mark Wardle wrote: Dear all, I'm struggling with a plot and would value any help! ... Is there a better way? As always, I'm sure there's a one-liner rather than my crude technique! As always, I've spent ages trying to sort this, and then the minute after sending an email, I find

[R] Density estimation graphs

2007-03-15 Thread Mark Wardle
') Is there a better way? As always, I'm sure there's a one-liner rather than my crude technique! Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and specialist registrar, Neurology University Hospital Wales and Cardiff University, UK __ R-help

Re: [R] Start and Restart R over SSH

2007-02-19 Thread Mark Wardle
Nils Höller wrote: Hi, I have some big calculations in R to be done. Since I can use R on a server with ssh, i was wondering if I can reopen a R Shell after exiting ssh. I don't want to use the batch mode and nohup doesn't work. I want to use something like ssh [EMAIL PROTECTED] R

Re: [R] plotting

2007-02-16 Thread Mark Wardle
Azizi wrote: Hello, I use newly R! I'd like to plot several data set together in one output window! How can I do that? Best regards Hadi - Never miss an email again! [[alternative HTML version deleted]]

[R] as.Date() results depend on order of data within vector?

2007-01-07 Thread Mark Wardle
Dear all, The as.Date() function appears to give different results depending on the order of the vector passed into it. d1 = c(1900-01-01, 2007-01-01,,2001-05-03) d2 = c(, 1900-01-01, 2007-01-01,2001-05-03) as.Date(d1) # gives correct results as.Date(d2) # fails with error (* see below)

Re: [R] as.Date() results depend on order of data within vector?

2007-01-07 Thread Mark Wardle
Prof Brian Ripley wrote: The correct work-around is to get non-valid strings returned as NA, not . That is argument 'na.strings' in RODBC (and elsewhere: read.table behaves in the same way). Thanks for these replies. As I have mentioned before, my peculiar combination of PostgreSQL,

[R] Show number at risk on Kaplan Meier curve

2006-12-09 Thread Mark Wardle
Dear all, I'm using the survival package with R 2.4.0 on Mac OS X 10.4.8. I have two core statistics books (one of which is Altman's medical stats book) which suggest showing the number of individuals at risk at different time intervals on the Kaplan-Meier curve. My plot shows two curves that

Re: [R] R_WinEdt question

2006-11-30 Thread Mark Wardle
. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read

Re: [R] R_WinEdt question

2006-11-30 Thread Mark Wardle
effect. Hope this helps, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman

Re: [R] RODBC and NULL values

2006-11-15 Thread Mark Wardle
. Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help

Re: [R] RODBC and NULL values

2006-11-14 Thread Mark Wardle
this problem is limited to RODBC, and is not an ODBC driver problem? Any ideas? I'll be switching to RdbiPgSQL from now, but I thought it appropriate to flag this up as an unsolved problem. Many thanks, Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology

Re: [R] RODBC and NULL values

2006-11-14 Thread Mark Wardle
Mark Wardle wrote: Dear all, I'm afraid I'm still having trouble with RODBC and NULL values on Mac OS ... snip limited to RODBC, and is not an ODBC driver problem? Any ideas? I'll be switching to RdbiPgSQL from now, but I thought it appropriate to flag this up as an unsolved problem. Hmmm

Re: [R] query in R

2006-11-09 Thread Mark Wardle
-spreadsheets RODBC allows you to run arbitrary queries against Excel spreadsheets. I don't use Excel (well, try not to), so I can't vouch for it, but it should work. Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath

Re: [R] Sweave, R and complex latex projects

2006-11-09 Thread Mark Wardle
,$(RNWFILES)) -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE

Re: [R] query in R

2006-11-08 Thread Mark Wardle
at odbcConnect(), and sqlQuery(). It is quite straightforward; even I managed to use it! Otherwise try help.search(sql) which provides links to many other, database-specific packages. Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff

[R] Sweave and font problems

2006-11-08 Thread Mark Wardle
, the package directive is ignored. Has anyone had similar problems, or am I alone...? pdfeTeX 3.141592-1.21a-2.2 (Web2C 7.5.4) Installed via darwinports (macports as it is now). Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath

Re: [R] Sweave and font problems

2006-11-08 Thread Mark Wardle
Roger D. Peng wrote: Try \usepackage[noae]{Sweave} -roger Works perfectly - many thanks! Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK

[R] [Fwd: Re: Organisation of medium/large projects with multiple analyses]

2006-10-30 Thread Mark Wardle
important. Many thanks, Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http

[R] Organisation of medium/large projects with multiple analyses

2006-10-26 Thread Mark Wardle
of thing covered in any of the textbooks. Apologies for being so verbose! Best wishes, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK __ R-help

[R] RODBC and NULL values

2006-10-17 Thread Mark Wardle
to remove those datapoints afterwards? Looking in the archives, there are lots of people asking about how to convert NAs to numeric, but I want the NAs passed through unaltered! Many thanks in advance, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2

Re: [R] RODBC and NULL values

2006-10-17 Thread Mark Wardle
Mark Wardle wrote: ... Is this because my ODBC driver is not returning the correct values for RODBC to parse? Is there anyway of debugging this (the intricacies of ODBC are beyond my skill) and is my only alternative to store a non-valid number in the database (999?) and use my query or R

Re: [R] RODBC and NULL values

2006-10-17 Thread Mark Wardle
! -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read

Re: [R] Sweave, R and complex latex projects

2006-10-16 Thread Mark Wardle
Friedrich Leisch wrote: On Sat, 14 Oct 2006 23:00:27 +0100, Mark Wardle (MW) wrote: Hello all, ... Yes, simply set prefix.string to a path, not only a filename. E.g., ... Many thanks for everyone's help on this (both on and off list). Working perfectly now! Now I just need help

[R] Sweave, R and complex latex projects

2006-10-14 Thread Mark Wardle
/charts which are then \inputed, but I was rather attracted to the whole Sweave approach. Many thanks, Mark -- Dr. Mark Wardle Clinical research fellow and Specialist Registrar in Neurology, C2-B2 link, Cardiff University, Heath Park, CARDIFF, CF14 4XN. UK email: [EMAIL PROTECTED] [EMAIL PROTECTED