[R] Adding data to existing plot with new=TRUE does not appear to work

2007-07-04 Thread Paul Lemmens
before or immediately after the first plot statement (the type='n' one) in the above code fragment, the resulting graph still only shows one column of data. Have I misinterpreted the instructions or the functionality of new=TRUE? Thank you, Paul Lemmens

Re: [R] Adding data to existing plot with new=TRUE does not appear to work

2007-07-04 Thread Paul Lemmens
similar result with using points Yes I new that, but I wanted to try and go without an if() for deciding between the first and consecutive columns. Thnx for helping out! Paul Lemmens __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman

[R] cmdscale(eurodist)

2007-06-27 Thread Paul Lemmens
I always use -loc for the y-axis of a similar plot for a completely different data set. Kind regards, Paul Lemmens __ 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] Reading multiple txt files into one data frame

2006-07-31 Thread Paul Lemmens
On 7/30/06, Kartik Pappu [EMAIL PROTECTED] wrote: Hello All, I have a device that spews out experimental data as a series of text files each of which contains one column with several rows of numeric data. My problem is that for each trial it gives me one text file (and I run between 30 to

[R] Finding ties in data (be)for(e) BradleyTerry

2006-05-04 Thread Paul Lemmens
Dear all, I have carried out a pairwise comparison study that I want to analyze using the BradleyTerry package to establish a rank order of my stimuli. However, BT does not handle ties between stimuli, so I need to find those in my data before I can use that model. The code below goes from the

Re: [R] Reading multiple files into R

2004-10-01 Thread Paul Lemmens
, sep=), skip=1))) rm(datafiles) -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.05)Against HTML Mail \ / NL-6525 HR Nijmegen X The Netherlands

Re: [R] Conditionally swap two columns of a data.frame?

2004-09-16 Thread Paul Lemmens
Hoi Dan, --On donderdag 16 september 2004 13:55 +0100 Dan Bolser [EMAIL PROTECTED] wrote: Is there an R cookbook? Yes there is (sort of): StatsRus http://www.ku.edu/~pauljohn/R/Rtips.html kind regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign

[R] library(car) Anova() and Error-term in aov()

2004-08-26 Thread Paul Lemmens
for Anova Phrased differently, ?Anova says Calculates type-II or type-III analysis-of-variance tables for model objects produced by 'lm' and 'glm', so it's not suitable for the aovlist that aov() with Error()-term returns. How can I compute Type III SS for such objects? kind regards, Paul -- Paul

Re: [R] basic questions: any place for them

2004-08-04 Thread Paul Lemmens
, that several online communities have dedicated discussion groups for R. One of them is Orkut.com. The name of the other one slips my mind, but if you search the archives for my name and orkut, then you'll probably find those emails quickly. regards, Paul -- Paul Lemmens NICI, University

Re: [R] How to select a whole column? Thanks!

2004-08-03 Thread Paul Lemmens
-0.018 I mean how to select the first four columns. subset(df, select=-c(V3,V4,V5,V6)) -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.05)Against HTML Mail \ / NL-6525 HR Nijmegen

Re: [R] How to sort TWO columns ?

2004-07-21 Thread Paul Lemmens
, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.05)Against HTML Mail \ / NL-6525 HR Nijmegen X The Netherlands / \ Phonenumber

Re: [R] subset(..., drop=TRUE) doesn't seem to work.

2004-06-17 Thread Paul Lemmens
toolbox.r now contains: my.subset - function(x, drop.unused.levels=FALSE, ...) { subsetted - subset(x, ...) if (drop.unused.levels) { subsetted[] - lapply(subsetted, function(x) if (is.factor(x)) factor(x) else x) } subsetted } Thnx for all the help! -- Paul Lemmens NICI

Re: [R] subset and lme

2004-06-16 Thread Paul Lemmens
numbers) for which positions in dat Diagnosis==0. cdat - dat[dat$Diagnosis==0,] This OTOH, uses the above vector to index the rows of dat, indeed selecting those rows from dat that have Diagnosis==0. This is assigned to cdat. You could have done cdat - dat[csubset,] as well HTH -- Paul

[R] subset(..., drop=TRUE) doesn't seem to work.

2004-06-16 Thread Paul Lemmens
- subset(dd, c==1, drop=TRUE) table(dd$c) 1 2 5 0 So to lose the second level of dd$c, in method B I still need to 'dd$c - dd$c[, drop=TRUE]', while the manual seems to imply that with the drop argument to subset() this would not be necessary. Could you comment? kind regards, Paul -- Paul Lemmens

Re: [R] subset(..., drop=TRUE) doesn't seem to work.

2004-06-16 Thread Paul Lemmens
Dear Peter, --On woensdag 16 juni 2004 17:06 +0200 Peter Dalgaard [EMAIL PROTECTED] wrote: Paul Lemmens [EMAIL PROTECTED] writes: Hello! If I read ?subset, the workings of the argument drop (to me) seem to imply equivalence of A and B (R 1.9.0): # A dd - data.frame(rt=rnorm(10), c=factor(gl(2,5

Re: [R] Informal discussion group about R

2004-06-11 Thread Paul Lemmens
/will function as the low-entry level help that was discussed around a year ago. kind regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.05)Against HTML Mail \ / NL-6525 HR Nijmegen

Re: [R] Accessing data

2004-05-17 Thread Paul Lemmens
[,!Besch] attach(x) x[-Besch] ... Try x2 - subset(x, select=-Besch) kind regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.05)Against HTML Mail \ / NL-6525 HR Nijmegen

[R] Sum Sq of SPSS and R different for repeated measures Anova

2004-04-23 Thread Paul Lemmens
on (if it were the type I/III difference then the exp interactions would have been different as well, right?). I cannot deduce the reason of the difference. Can anybody help with this? thank you for your time, regards, Paul Lemmens -- Paul Lemmens NICI, University of Nijmegen ASCII

[R] Accessing columns in data.frame using formula

2004-02-24 Thread Paul Lemmens
$facts[2]) # This won't work here. How do I continu? # Or perhaps also # data.tmp - data$resp[data$facts[1] == 'i'] } thank you, Paul Lemmens P.S: str(wery) `data.frame': 150 obs. of 11 variables: $ V1 : int 1 1 1 1 1 1 1 1 1 1 ... $ V2 : int 1 2 3 4 5 6 7 8 9 10 ... $ V3 : int 960 1060

Re: [R] Doubt about pattern

2004-01-29 Thread Paul Lemmens
extension regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.03)Against HTML Mail \ / NL-6525 HR Nijmegen X The Netherlands

Re: [R] Problem with parser and if/else

2003-11-14 Thread Paul Lemmens
) that the only way to have if() know that an else will be present is to put it on the same line as the closing curly brace of the if() (compound) statement. But if I look at some code from, e.g., aov and lm, I see plenty violations of that rule. regards, Paul -- Paul Lemmens NICI, University

[R] Cbind warning message

2003-10-16 Thread Paul Lemmens
) is a multiple of 5. kind regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.03)Against HTML Mail \ / NL-6525 HR Nijmegen X The Netherlands

RE: is.na(v)-b (was: Re: [R] Beginner's query - segmentation fault)

2003-10-15 Thread Paul Lemmens
summary. I've already memorized the is.na() construct, so I should be safe for the time being : kind regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.03)Against HTML Mail \ / NL-6525 HR Nijmegen

Re: [R] Subseting in a 3D array

2003-10-15 Thread Paul Lemmens
the Introduction to R (p21) helpfull? regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.03)Against HTML Mail \ / NL-6525 HR Nijmegen X The Netherlands

RE: is.na(v)-b (was: Re: [R] Beginner's query - segmentation fault)

2003-10-14 Thread Paul Lemmens
(*) Such a remark will probably lead to some kind of reprimand because it's probably somewhere within the 10e6 manual pages but I'm trying my luck here. -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.03)Against HTML Mail \ / NL-6525 HR

Unit of legend() coordinates (was: Re: [R] lines and legend)

2003-07-02 Thread Paul Lemmens
the plot region? When I am trying to put a legend on a plot where I am using lines, R just ignores it. I can do it with boxplot or plot, but just not with lines. Am I doing something wrong? Maybe I am just making a mistake? -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon

Re: [R] simple matrix question

2003-06-05 Thread Paul Lemmens
as values? xbar1 - tapply(as.vector(x), gl(2,4), mean); -- Paul Lemmens NICI, University of Nijmegen ASCII Ribbon Campaign /\ Montessorilaan 3 (B.01.03)Against HTML Mail \ / NL-6525 HR Nijmegen X The Netherlands

Re: [R] (no subject)

2003-06-04 Thread Paul Lemmens
it off and print() calls display immediately. Lengthy output becomes slower, though. If you don't want to depend on you (or other people) turning of the buffering, use something like cat(this or that); flush.console. regards, Paul -- Paul Lemmens NICI, University of Nijmegen ASCII

Re: [R] Numbers that look equal, should be equal, but if() doesn'tsee as equal (repost with code included)

2003-05-29 Thread Paul Lemmens
Hoi Thomas, --On woensdag 28 mei 2003 7:16 -0700 Thomas Lumley [EMAIL PROTECTED] wrote: On Wed, 28 May 2003, Paul Lemmens wrote: Hi! Apologies for sending the mail without any code. Apparently somewhere along the way the .R attachments got filtered out. I have included the code below as clean

[R] Numbers that look equal, should be equal, but if() doesn't seeas equal (repost with code included)

2003-05-28 Thread Paul Lemmens
number of means calculated.); } else { subject.bin.means } } -- Forwarded Message -- Date: dinsdag 27 mei 2003 14:53 +0200 From: Paul Lemmens [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: [R] Numbers that look equal, should be equal