Re: [R] text display using expression or not

From: Mark Difford <mark_difford_at_yahoo.co.uk>
Date: Fri, 15 Jun 2007 12:41:08 -0700 (PDT)

Hi Sarah,

You will kick yourself (perhaps?). Try:

?par ## sub: font.main (& font, just above)

## Example
par(mfrow=c(2,1))
plot(1:10, 1:10, main="Figure A", font.main=1) plot(1:10, 1:10, main=expression("Figure B"))

Regards,
Mark.

Sarah Goslee wrote:
>
> Hello,
>
> I imagine that I'm missing something straightforward, but a run thru
> the help files didn't turn up an answer.
>
> I noticed while formatting some figures for publication that text
> enclosed in expression() and used for a title displays differently
> than a string, regardless of the par options. On both postscript()
> and x11() devices, the regular text is heavier than the expression text.
>
> Here's an example. The "real thing" used expression() to
> produce superscripts, but I boiled this down to the simplest possible
> case.
>
> par(mfrow=c(2,1))
> plot(1:10, 1:10, main="Figure A")
> plot(1:10, 1:10, main=expression("Figure B"))
>
> Is there some straightforward way to make them match, other
> than putting expression() around all strings?
>
>
> I'm currently using R 2.5.0 on Fedora core 5.
>
> Thanks,
> Sarah
>
> --
> Sarah Goslee
> http://www.functionaldiversity.org
>
> ______________________________________________
> 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
> and provide commented, minimal, self-contained, reproducible code.
>
>

-- 
View this message in context: http://www.nabble.com/text-display-using-expression-or-not-tf3929372.html#a11146488
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
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
and provide commented, minimal, self-contained, reproducible code.
Received on Fri 15 Jun 2007 - 21:08:03 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 15 Jun 2007 - 22:32:22 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.