Using Trellis, am successfully setting up a number of panels (25) in which I
have two box and violin plots.
I would like to colour - one plot as RED and the other as BLUE (in each
panel). I can do that with the box plots, but the violin density areas just
take on one colour.
My basic call is as follows:
bwplot(rmsd ~ file | code,
data=spread_data.filtered,
panel = function(..., box.ratio){
panel.violin(..., col = c("red", "blue"), cut = 1, varwidth = FALSE,
box.ratio = box.ratio)
panel.bwplot(..., fill = c("red", "blue"), box.ratio = .1, pch="|")
},
par.settings = list(plot.symbol = list(pch = 21, col = "gray"),
box.rectangle = list(col = "black"), box.umbrella = list(col = "black"))
)
The boxplots are actually coloured one in red and one in blue, but the
violin area for all my graphs is in red.
Any ideas?
[[alternative HTML version deleted]]
______________________________________________
[email protected] 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.