[R] grid.locator

Gabor Grothendieck ggrothendieck at gmail.com
Sun Sep 25 21:27:41 CEST 2005

If I do:

x <- 1:10
xyplot(x ~ x)

and click on 2,2 say the I get this:

> grid.locator()
[1] 201native

[1] 476native

How do I get the user coordinates of the graph?

(If I did not use lattice/grid I could have just done:

plot(x ~ x)

and it would have worked as expected.)

More information about the R-help mailing list