Hi:

Try
X <- rnorm(100)
hist(X, main = bquote('[Ca'^'2+'*']i'~'onsets'), xlab = 'sec')

or
hist(X, main = bquote('[Ca*]'*i^'2+' ~'onsets'), xlab = 'sec')

I'm not sure which one you want, though.

HTH,
Dennis

On Fri, Oct 22, 2010 at 4:01 AM, DrCJones <matthias.godd...@gmail.com>wrote:

>
> Hi,
>
> How can I get the '2+' into superscript in the following title:
>
> '[Ca2+]i onsets'
>
> I tried the command below, but it doesn't work. What am I missing?
>
> hist(X, main=expression(([Ca*]i^2+) 'onsets'),  xlab = 'sec')
>
>
>
>
> --
> View this message in context:
> http://r.789695.n4.nabble.com/superscript-characters-in-title-with-tp3006981p3006981.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> 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.

Reply via email to