[R] Coplot Question (Unresolved)
Steve Arthur
sarthur at protogene.com
Fri Sep 15 19:42:10 CEST 2000
Rers,
I still have a question concerning the coplot function.
I have written some code using the coplot:
coplot(y ~ as.numeric(Base) | a * b)
Where Base is a factor.
And it works great! However, according to the way coplot works, Base is
converted by "as.numeric" from Base values, A, C, G, and T to 1, 2, 3,
and 4, which is not very helpful for data visualization and
interpretation for the people I work with.
Question: Is there a way to have the "coplot" work showing the original
A, C, G, T as values for Bases on the "coplot" axes?
coplot(y ~ as.factor(Base) | a * b ) does not work!
Also, it appears that "coplot" does not have a command for printing a
graph title, such as "main" as is in the "plot" function. Am I right or
am I wrong?
>> >indicates for the formula: y ~ x | a * b, x and y must be numeric, and a
>> >and b must be factor values, so when I try your suggestion, it appearsnot
>> >to work. I might instead try a plot statement with a
>> >par(mfrow=c(5,3)) etc... that's my next problem.
****
OK! I see! Well, I just tried to do plot some data where the variable on
the x-axis is a character, and R does not accept it. I do not know if this
may be the original problem. Did anybody give you other suggestions? It may
be worth asking on r-help about this.
****
And finally, the "plot" function has a form "plot(f,y)" which it is stated
on page 65 of "An Introduction to R" V1.0.1 that "...form produces
boxplots of y for each level of f." Where f is a factor and y is
numeric. Is there anyway to not plot the boxplots and just show the
points above the factors?
Thanks in advance,
steve
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list