Does anyone have an idea of how one might plot male and female symbols on a graph using R? Thanks! .................................................................. George W. Gilchrist Email #1: gwgilc at wm.edu Department of Biology, Box 8795 Email #2: kitesci at cox.net College of William & Mary Phone: (757) 221-7751 Williamsburg, VA 23187-8795 Fax: (757) 221-6483 http://gwgilc.people.wm.edu/
demo(Hershey) On 10/22/05, George W. Gilchrist <gwgilc at wm.edu> wrote:> Does anyone have an idea of how one might plot male and female > symbols on a graph using R? Thanks! > > .................................................................. > George W. Gilchrist Email #1: gwgilc at wm.edu > Department of Biology, Box 8795 Email #2: kitesci at cox.net > College of William & Mary Phone: (757) 221-7751 > Williamsburg, VA 23187-8795 Fax: (757) 221-6483 > http://gwgilc.people.wm.edu/ > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html >
On 22-Oct-05 George W. Gilchrist wrote:> Does anyone have an idea of how one might plot male and female > symbols on a graph using R? Thanks!Groping for an answer to this, I was led to run demo(Hershey) and the screen "Special Escape Sequences" showed appropriate symbols at \\VE and \\MA Maybe you can develop this for your needs. (However, perhaps if you use these you should maintain a certain distance between the male and female symbols, or you might get a lot of noisy little subscripts ... ). George's query somewhat leads on to a more general question: Can one define one's own symbols for plotting? For example -- though I'm not seriously saying I need this -- in a population study of faxes and rabbits surveyed over several years, one might wish to plot the Rabbit population using tiny rabbits as points, and foxes' heads for the Fox population. (Given the data coordinates, I would have my own ways to do this; but not in R). Best wishes, Ted. -------------------------------------------------------------------- E-Mail: (Ted Harding) <Ted.Harding at nessie.mcc.ac.uk> Fax-to-email: +44 (0)870 094 0861 Date: 22-Oct-05 Time: 15:55:41 ------------------------------ XFMail ------------------------------
On Sat, 22 Oct 2005, George W. Gilchrist wrote:> Does anyone have an idea of how one might plot male and female > symbols on a graph using R? Thanks!You don't tell us your platform and the answer depends on the platform. They are Unicode points U+2642 and U+2640. So if your system supports it, something like text(x, y, "\u2642") will work, as will points(x, y, pch="\u2642"). Alternatively, look at the Hershey fonts, which have these and many other symbols (not necessarily of publication-quality though). -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
If you have image files of your plotting symbols (fox and rabbits) then one approach is to follow the example in the post at: http://tolstoy.newcastle.edu.au/~rking/R/help/05/08/10890.html hope this helps, Greg Snow, Ph.D. Statistical Data Center, LDS Hospital Intermountain Health Care greg.snow at ihc.com (801) 408-8111>>> Ted Harding <Ted.Harding at nessie.mcc.ac.uk> 10/22/05 08:58AM >>>George's query somewhat leads on to a more general question: Can one define one's own symbols for plotting? For example -- though I'm not seriously saying I need this -- in a population study of faxes and rabbits surveyed over several years, one might wish to plot the Rabbit population using tiny rabbits as points, and foxes' heads for the Fox population. (Given the data coordinates, I would have my own ways to do this; but not in R). Best wishes, Ted. -------------------------------------------------------------------- E-Mail: (Ted Harding) <Ted.Harding at nessie.mcc.ac.uk> Fax-to-email: +44 (0)870 094 0861 Date: 22-Oct-05 Time: 15:55:41 ------------------------------ XFMail ------------------------------ ______________________________________________ R-help at stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html