See http://cran.r-project.org/bin/macosx/RMacOSX-FAQ.html#I-see-no-text-in-a-Quartz-plot_0021

And the default font is not serif ... that FAQ says it is Arial, but I do not know if that is current.

Mac-specific questions to R-sig-mac please. (This must be Mac-specific as the default device, quartz(), is.)

On 07/08/2014 23:24, David Winsemius wrote:

On Aug 7, 2014, at 12:59 PM, Tim Blass wrote:

Hello,

I am using R 3.1.1 on a (four year old) MacBook, running OSX 10.9.4.

I just tried making and labeling a plot as follows:

x<-rnorm(10)
y<-rnorm(10)
plot(x,y)
title(main="random points")

which produces a scatter plot of the random points, but without the title
and without any numbers along the axes. If I then run

par(family="sans")
plot(x,y,main="plot title")

the plot has the title and the numbers on the axes (also and 'x' and 'y'
appear as default labels for the axes).

I do not know what is going on, but maybe there is some problem in the
default font settings (I don't know if that could be an R issue or an issue
specific to my Mac)?

It hasn't happened to me recently (since updating from Leopard and SnowLeapard 
to Lion)  but it used to happen pretty frequently that I would get a duplicate 
font that printed empty square boxes. (I wasn't the only one. It got reported 
several times on R-SIG-Mac.)  One could fix that sort of problem by deleting 
the offending duplicate entry using Font Book.app

Since this is happening with the default serif font,  you would probably find 
the duplicate in Times. (It used to be happening to me with Symbol.)

quartzFonts()$serif
[1] "Times-Roman"      "Times-Bold"       "Times-Italic"     "Times-BoldItalic"




This is clearly not a big problem (at least for now) since I can put labels
on plots by running par(), but if it is indicative of a larger underlying
problem (or if there is a simple fix) I would like to know.

Thank you!

David Winsemius
Alameda, CA, USA


--
Brian D. Ripley,                  rip...@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

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to