[R] Stripchart and Boxplots side-by-side

Dieter Wirz didi.wirz at gmail.com
Thu May 22 14:09:05 CEST 2008


Dear all -
With the following code I get Boxplots and Stripcharts in one Plot:

with(InsectSprays, boxplot(count ~ spray, boxwex = 0.3))
with(InsectSprays, stripchart(count ~ spray, col = "red", vertical =
TRUE, add = TRUE))

But the dots from the stripchart are plotted over the Boxes.
Is there any possibility to have Stripchart and Boxplots side-by-side,
i.e. to move boxplots and/or stripcharts a bit to the left or right?

(similar to the example "Comparing boxplot()s and non-robust mean +/-
SD" from help(boxplots)....)

Thanks for any help
Dieter



More information about the R-help mailing list