[R] characters, mathematical expressions and computed values
S Ellison
S.Ellison at LGCGroup.com
Fri Oct 12 14:35:38 CEST 2012
> [mailto:r-help-bounces at r-project.org] On Behalf Of William Dunlap
> Subject: Re: [R] characters, mathematical expressions and computed values
>
> I think that bquote, with its .() operator, suffices for
> [almost?] any single title;
> ...
> E.g.,
> hist(new, main=bquote("Heart Attack (" * bar(X)==.(mean(new)) * ")"))
In this instance, using
hist(new, main=bquote( "Heart Attack " * (bar(X) ==.( mean(new) )) ) )
improves the parentheses slightly, as it uses plotmath parentheses instead of forcing text parentheses.
Otherwise I agree completely; bquote is a neat way of doing the job.
S Ellison
*******************************************************************
This email and any attachments are confidential. Any use...{{dropped:8}}
More information about the R-help
mailing list