PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Andrew Clausen
Sent: Sunday, March 16, 2008 12:05 AM
To: Duncan Murdoch
Cc: R-devel@r-project.org
Subject: Re: [Rd] [patch] add=TRUE in plot.default()
Hi Duncan,
On Mon, Mar 10, 2008 at 08:51:23AM -0400, Duncan Murdoch wrote:
The add
On 3/9/2008 5:58 PM, Andrew Clausen wrote:
On Sun, Mar 09, 2008 at 04:04:08PM -0400, Duncan Murdoch wrote:
Part of the reason I didn't like your patch is that it was incomplete:
it didn't patch the plot.default.Rd file.
Fair enough -- I wasn't sure whether I was fixing a bug or not. (...
I think you can use par(new = T) here:
f - function(x) x^2
X - seq(0, 1, by=1/4)
plot(f, col=blue)
par(new = T)
plot(X, f(X), col=red, type=l, xlab=, ylab=)
On 09/03/2008, Andrew Clausen [EMAIL PROTECTED] wrote:
Hi all,
As long as I've used R, add=TRUE hasn't worked in contexts like this:
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.
On 09/03/2008 12:46 PM, Andrew Clausen wrote:
Hi Duncan,
On Sun, Mar 09, 2008 at 12:11:45PM -0400, Duncan Murdoch wrote:
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)
On Sun, Mar 09, 2008 at 04:04:08PM -0400, Duncan Murdoch wrote:
Part of the reason I didn't like your patch is that it was incomplete:
it didn't patch the plot.default.Rd file.
Fair enough -- I wasn't sure whether I was fixing a bug or not. (...
spreads the documentation around a bit.)
That
On Sun, Mar 9, 2008 at 6:27 PM, hadley wickham [EMAIL PROTECTED] wrote:
Yes. The ability to plot things on top of each other is important.
The simplicity created by having a single interface for adding to plots
outweighs the complexity of yet another parameter.
The add parameter
But what about when the new data is outside the range of the current
plot?
plot/lines/points already works that way so this is just an interface issue.
That may be the way it is, but I don't see how you could argue that
it's desirable behaviour.
Hadley
--
http://had.co.nz/
Its not a matter of desirable or not -- its a matter that its a different point.
The par(new= ) to get an old graph is completely confusing
and its annoying that one has to suddenly switch to lines and points
and cannot consistently use plot.
That remains true whether or not there is auto
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.
Cheers,
Andrew
diff --git
10 matches
Mail list logo