Re: [R] xyplot and lsegments

2008-02-08 Thread Deepayan Sarkar
On 2/8/08, Alex Brown <[EMAIL PROTECTED]> wrote: > Hi, > > How might I use xyplot to plot segments where the segments are in the > input data? (ie a directed acyclic forest). > > Here's an example in base graphics: > > n = data.frame(id = c(1,2,3,4), parent = c(0,1,2,2), value = > c

Re: [R] xyplot and lsegments

2008-02-08 Thread hadley wickham
On Feb 8, 2008 9:36 AM, Alex Brown <[EMAIL PROTECTED]> wrote: > Hi, > > How might I use xyplot to plot segments where the segments are in the > input data? (ie a directed acyclic forest). > > Here's an example in base graphics: > > n = data.frame(id = c(1,2,3,4), parent = c(0,1,2,2)

[R] xyplot and lsegments

2008-02-08 Thread Alex Brown
Hi, How might I use xyplot to plot segments where the segments are in the input data? (ie a directed acyclic forest). Here's an example in base graphics: n = data.frame(id = c(1,2,3,4), parent = c(0,1,2,2), value = c(5,5.5,7,3), date = c(1,2,3,3.5)) plot(n$date, n$value) do