[R] Identify does sort the locations
Samuel GRANJEAUD IR/INSERM
samuel.granjeaud at inserm.fr
Thu Feb 15 18:58:21 CET 2018
Hi,
Using identify function, I think I should get the index of the selected
points in the order I clicked them. This is what I read in the help. But
I feel they are ordered. Please let me know what I missed.
In the following example, I clicked on the points labelled 7, 5 and 1,
but I get 1, 5, 7 as output.
> set.seed(0); x = rnorm(10); y = rnorm(10); plot(x,y); text(x, y,
> seq(x)); sel = identify(x,y); sel
[1] 1 5 7
Any help appreciated,
Samuel
R version 3.4.3 (2017-11-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
Matrix products: default
locale:
[1] LC_COLLATE=English_United Kingdom.1252 LC_CTYPE=English_United
Kingdom.1252
[3] LC_MONETARY=English_United Kingdom.1252 LC_NUMERIC=C
[5] LC_TIME=English_United Kingdom.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_3.4.3
More information about the R-help
mailing list