[R] lattice dotplot labelling median and mean values for each panel

2013-02-18 Thread maxbre
By considering this reproducible example #start code library(lattice) dotplot(variety ~ yield | site, data = barley, layout = c(1,6), index.cond= function(x,y){median(x)}, panel = function(x,y,...) { panel.dotplot(x,y,...) median.values - median(x)

Re: [R] lattice dotplot labelling median and mean values for each panel

2013-02-18 Thread maxbre
sorry, I've managed to find a (partial) solution to my problem (even not much elegant); now what is left out is the proper tweaking of labels... any better solutions? dotplot(variety ~ yield | site, data = barley, layout = c(1,6), index.cond= function(x,y){median(x)},

Re: [R] lattice dotplot labelling median and mean values for each panel

2013-02-18 Thread maxbre
sorry again, there is something more to consider... in case I need to plot x axis in logarithmic scale the above solution is not working: so now my further question is how to do that when I set scales=list(x=list(log=TRUE)) I've been trying to simplify my original example to the bare bone (for