[R] Plotting female and male signs

Torsten Hothorn Torsten.Hothorn at rzmail.uni-erlangen.de
Thu Jun 8 12:44:39 CEST 2006



On Thu, 8 Jun 2006, Hans Gardfjell wrote:

> Dear R-users,
>
> Just like other users (as seen from previous posts on the list), I would
> like to use female and male signs in plots. I found B. Ripley's post
> about using Unicode characters. However, it doesn't works for me.
>
> > text(locator(1),"\u2640")  produces the following error:
> Error: invalid \uxxxx sequence
>
> But I can specify other Unicode characters as long I don't exceed 00FF,
> so this works
>
> > text(locator(1),"\u00FF") or
> > text(locator(1),"\u00E6") and also without preceeding 00
> > text(locator(1),"\uE6")
>
> Can someone give me a hint?
> I'm using a Swedish locale on WindowsXP and my R version is 2.3.1
> Patched (2006-06-04 r38279)

Hans,

R> edit(vignette("Ch_logistic_regression_glm", package = "HSAUR"))

(you need to install package `HSAUR') has an example, specifically the 
line

text(womensrole$education, y, ifelse(f, "\\VE", "\\MA"), vfont =
      c("serif", "plain"), cex = 1.25)

uses Hershey fonts, see ?Hershey

Torsten

>
> Thanks,
>
> Hans Gardfjell
>
> -- 
>
> *********************************
> Hans Gardfjell
> Ecology and Environmental Science
> Umeå University
> 90187 Umeå, Sweden
> email: hans.gardfjell at emg.umu.se
> phone:  +46 907865267
> mobile: +46 705984464
>
> ______________________________________________
> 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
>
>


More information about the R-help mailing list