Re: [R] \n and italic() in legend()

2016-12-29 Thread William Michels via R-help
n("based on > "*italic("t")*"-test")) > v2 <- c(expression(italic("w")*"-value for A"), expression("and B identical > models")) > legend("topright", legend=c(v1, v2), lty=c(1, 0, 1, 0), y.intersp = 1, > bty="

Re: [R] \n and italic() in legend()

2016-12-29 Thread Duncan Mackay
t;, 0.25,0.25) popViewport(0) Regards Duncan -Original Message- From: Marc Girondot [mailto:marc_...@yahoo.fr] Sent: Friday, 30 December 2016 08:46 To: Duncan Mackay; w...@caa.columbia.edu; R-help Mailing List Subject: Re: [R] \n and italic() in legend() Hi, Thanks a lot to Duncan Mackay

Re: [R] \n and italic() in legend()

2016-12-29 Thread Marc Girondot via R-help
51 Email: home: mac...@northnet.com.au -Original Message- From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Marc Girondot via R-help Sent: Thursday, 29 December 2016 20:35 To: R-help Mailing List Subject: [R] \n and italic() in legend() Hi everyone, Could someone help me to g

Re: [R] \n and italic() in legend()

2016-12-29 Thread William Michels via R-help
Hi Marc, I can't seem to get "\n" to work, but simply using c() and "y.intersp = 1" looks fine: > plot(1, 1) > v1 <- c(expression(italic("p")*"-value"), expression("based on > "*italic("t")*"-test")) > legend("topright", legend=v1, y.intersp = 1, bty="n") Hope this helps, Bill William Mich

Re: [R] \n and italic() in legend()

2016-12-29 Thread Duncan Mackay
Soil Science University of New England Armidale NSW 2351 Email: home: mac...@northnet.com.au -Original Message- From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Marc Girondot via R-help Sent: Thursday, 29 December 2016 20:35 To: R-help Mailing List Subject: [R] \n and italic() in

[R] \n and italic() in legend()

2016-12-29 Thread Marc Girondot via R-help
Hi everyone, Could someone help me to get both \n (return) and italic() in a legend. Here is a little example showing what I would like (but without the italic) and second what I get: plot(1, 1) v1 <- "p-value\nbased on t-test" legend("topright", legend=v1, y.intersp = 3, bty="n") plot(1, 1)