From murdoch at stats.uwo.ca  Sun Mar  9 17:11:45 2008
From: murdoch at stats.uwo.ca (Duncan Murdoch)
Date: Sun, 09 Mar 2008 12:11:45 -0400
Subject: [Rd] [patch] add=TRUE in plot.default()
In-Reply-To: <20080309031119.GC23544@econ.upenn.edu>
References: <20080309031119.GC23544@econ.upenn.edu>
Message-ID: <47D40C41.1000202@stats.uwo.ca>

On 08/03/2008 10:11 PM, Andrew Clausen wrote:
> Hi all,
> 
> As long as I've used R, add=TRUE hasn't worked in contexts like this:
> 
> 	f <- function(x) x^2
> 	X <- seq(0, 1, by=1/4)
> 	plot(f, col="blue")
> 	plot(X, f(X), col="red", type="l", add=TRUE)
> 
> I attached a fix for version 2.6.2.

It has never been claimed that it would work, and as far as I can see, 
it doesn't make anything easier:  the last line could be replaced by

lines(X, f(X), col="red")

for more clarity from less typing.  So why would you want add=TRUE in 
plot.default?

Duncan Murdoch



[Rd] [patch] add=TRUE in plot.default()
Duncan Murdoch