Skip to content

Getting the panel location of a xyplot matrix using a mouse click in a GDCanvas

3 messages · Daniel Kornhauser, Deepayan Sarkar

#
On Thu, Oct 23, 2008 at 12:26 PM, Daniel Kornhauser
<dkor at northwestern.edu> wrote:
The approach in trellis.clickFocus should get you close. One important
point is that

clickLoc <- grid.locator("npc")

returns the location in NPC, whereas your e.getX() and e.getY() would
be in device coordinates. help(grconvertX) should tell you how to make
the conversion.

-Deepayan