Hello:
I am playing with the dotplot command (in preparation for
teaching an EDA course). I do not understand the following
behaviour of dotplot when x is a vector. These examples
have been tried on both Linux version 0.63 and guido's
Windows version 0.63 running under Windows 95.
I searched the bug reporting system, but found no mention
of any report concerning dotplot.
x <- 1:26
names(x) <- letters
# y has 10 zeros, 10 ones, and 6 twos.
y <- c(rep(0,10), rep(1,10), rep(2,6))
y <- factor(y, labels = c("G1","G2", "G3"))
# lcolor="black" since dotted gray lines don't display
# properly in my Windows version.
dotplot(x,groups=y, lcolor="black")
--------------------------------------------------------
The dotplot groups the a-f components of x and labels them
G1, groups the g-p components of x and labels them G2, and
groups the q-z components of x and labels them G3. I would
have expected the first 10 components of x to be grouped
together with the G1 label, followed by the next 10
components with label G2, then the last 6 components with
label G3.
---------------------------------------------------------
# z has 5 zeros, then 10 ones, then 5 zeros, then 6 ones.
z <- c(rep(0,5), rep(1,10), rep(0,5), rep(1,6))
z <- factor(z, labels = c("G1", "G2"))
dotplot(x,groups=z, lcolor="black")
----------------------------------------------------------
This groups components a,b,c,d,e,p, then a break, then
components q,r,s,t, then a break, then f to o, then a break,
then u to z. The G1 label is aligned at the same level as
the d entry, and the G2 label is aligned with the m entry.
Does this make sense?
Thank you.
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at
stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._