Re: [R] How to add a new plot in the same graph using add=T at the command plot?

From: Petr PIKAL <petr.pikal_at_precheza.cz>
Date: Thu, 10 Jun 2010 10:19:11 +0200

Hi

Peter Ehlers <ehlers_at_ucalgary.ca> napsal dne 09.06.2010 19:05:24:

> Soapbox:
> Well, if you're just starting out with R it would be
> a VERY good idea to learn right away that T is not TRUE
> and F is not FALSE, at least not always. Sooner or
> later you WILL have problems. So do yourself a favour
> and get into the habit of using TRUE/FALSE instead of T/F.
>
> (I know that Petr knows better.)

Yes good point. However when I work interactively with command prompt I often (well almost exclusively :-) use T/F instead of TRUE/FALSE as I am lazy to type. It is necessary to keep habit not to use T/F/c/matrix/vector/... as names for objects. So T can be used as abbreviation for TRUE like

mean(x, na.rm=T)

as long as you do not define

T <- "Title"
mean(x, na.rm=T)
Error in if (na.rm) x <- x[!is.na(x)] :   argument is not interpretable as logical

at least until T/F is removed from such use by R developers

You can even try

?"T"

and you can read help page for that.

Regards
Petr

>
> -Peter Ehlers
>
> On 2010-06-09 9:08, Larissa Lucena wrote:
> > Thanks so much!!! I'm using R for the first time, and so, I have many
stupid
> > doubts! Sorry and thanks again!
> >
> > Regards!
> >
> > 2010/6/9 Petr PIKAL<petr.pikal_at_precheza.cz>
> >
> >> Hi
> >>
> >> where did you find parameter add=T.
> >>
> >> You can use
> >>
> >> par(new=T)
> >> before using new plot command
> >>
> >> or use
> >>
> >> points, lines
> >>
> >> Regards
> >> Petr
> >>



R-help_at_r-project.org 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 commented, minimal, self-contained, reproducible code. Received on Thu 10 Jun 2010 - 08:22:31 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 10 Jun 2010 - 08:50:28 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive