s-news
[Top] [All Lists]

Need two y's in a trellis panel function

To: "snews" <s-news@wubios.wustl.edu>
Subject: Need two y's in a trellis panel function
From: "David Parkhurst" <parkhurs@indiana.edu>
Date: Sun, 29 Jul 2001 20:57:45 -0500
I have a dataframe, df, of this general form (f is a factor;  x, y1, and y2
are numeric):

f x y1 y2
1 1 4  6
1 3 2  3
1 5 7  1
2 1 6  2
2 2 3  3
2 4 1  6
3 1 2  4
3 4 3  2
3 5 6  7

I'd like to write a trellis panel function that would yield a plot with 
three panels (one for each factor level), and in each panel would plot
arrows (using the arrow function) from y1 to y2, with each arrow being
above the corresponding x value.

How would I accomplish that?  My problem lies in how to get more than 
one y vector into the panel function, which requires arguments (x,y).

Thanks much.

Dave Parkhurst


<Prev in Thread] Current Thread [Next in Thread>