Re: [R] Plotting Numeric Values with Non-Numeric Values

2015-09-14 Thread William Dunlap
d <- data.frame( # data to make a self-contained example gender=rep(c("Female","Male"),c(4,6)), bmi=c(seq(24,25,len=4), seq(25,27,len=6)), age=c("Young","Old")[c(1,1,2,2,1,1,1,1,2,2)]) boxplot(bmi ~ gender, data=d) lattice::bwplot(bmi ~ gender, data=d) lattice::bwplot(bmi ~ gender | age

Re: [R] Plotting Numeric Values with Non-Numeric Values

2015-09-14 Thread Mark Sharp
Try ?boxplot Mark R. Mark Sharp, Ph.D. Director of Primate Records Database Southwest National Primate Research Center Texas Biomedical Research Institute P.O. Box 760549 San Antonio, TX 78245-0549 Telephone: (210)258-9476 e-mail: msh...@txbiomed.org > On Sep 14, 2015, at 1:49 PM, mtilley3

[R] Plotting Numeric Values with Non-Numeric Values

2015-09-14 Thread mtilley3
I have looked for quite a long time and can't quite find the answer for what I'm looking for. I want to graph bmi vs gender, with male/female on the x-axis and the bmi numerical value on the y-axis. Can anyone explain how to do this? Thanks! -- View this message in context: http://r.789695.n4.n