On Mon, Oct 10, 2011 at 6:31 PM, Allan Sikk <a.s...@ucl.ac.uk> wrote: > Here's the code. The problem seems to be specific for lattice as I can > easily use a vector with pos in "plot".
lattice::panel.text() does not support vector 'pos'. (Not very difficult to fix, and I'll put it on my TODO list). For now, you will need to use separate calls for different 'pos' values. -Deepayan > trellis.device(,width=600, height = 400) > xyplot(Npop~Narea, > scales=list(x=list(log=TRUE, at=my.at,labels = formatC(my.at, big.mark = > ",", format="d")), > y=list(log=TRUE, at=c(1,10,100,1000,10000,100000,1000000))), > panel=function(...) { > panel.xyplot(..., type="p", col="black", cex=.5, pch=20) > panel.text(x=log10(Narea), y=log10(Npop), lab=t, cex=.5, pos=c(4,2)) > } > > ) ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.