Re: [R] italic font for legend text when using expression function for symbols

2013-01-23 Thread ilai
plot(1)
legend('topleft',legend=expression(A,italic(A),bolditalic(A),Delta*italic(D)))

On Wed, Jan 23, 2013 at 9:45 AM, raz  wrote:

> Hello,
>
> I'm trying to add a symbol (Delta) to plot legend with text using
> "expression(paste())" but this disables the text.font that allows to use
> bold or italic text.
> as follows:
> x=c(1:10)
> y=c(1:10)
> plot(x,y)
> legend(1,10,legend=c("A","B","C",expression(paste(Delta, D))),
>pch=c(24,18,17,16),cex=2,text.font=3,bty="n")
>
> Any suggestion to how I can add the Delta symbol and have a italic font?
>
> Thanks
>
> --
> \m/
>
> [[alternative HTML version deleted]]
>
> __
> 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.
>

[[alternative HTML version deleted]]

__
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.


[R] italic font for legend text when using expression function for symbols

2013-01-23 Thread raz
Hello,

I'm trying to add a symbol (Delta) to plot legend with text using
"expression(paste())" but this disables the text.font that allows to use
bold or italic text.
as follows:
x=c(1:10)
y=c(1:10)
plot(x,y)
legend(1,10,legend=c("A","B","C",expression(paste(Delta, D))),
   pch=c(24,18,17,16),cex=2,text.font=3,bty="n")

Any suggestion to how I can add the Delta symbol and have a italic font?

Thanks

-- 
\m/

[[alternative HTML version deleted]]

__
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.