On May 29, 2008, at 11:02 PM, [EMAIL PROTECTED] wrote:

Suppose I have a plot
plot(1:10, pch = "")

And I want some text to indicate a Normal distrubition.  I could do
this:

text(5, 6, substitute(X~~~~N(mu, sigma^2)), adj = 0)
text(5.35, 6, "~", adj = 0)

But that's clumsy, and depending on your plotting device, might not even look
sensible.  I'd prefer to be able to do it more directly and
simply the way these do:

text(5, 1, expression(X %~~% N(mu, sigma^2)), adj = 0)
text(5, 2, expression(X %prop% N(mu, sigma^2)), adj = 0)
text(5, 3, expression(X %=~% N(mu, sigma^2)), adj = 0)

They're easy, but they don't give a single tilde.  I know how to put a
tilde(X) or even a wide tilde, but there're not it either.

What did I miss?


Does this do it?

text(2, 3, expression(X *"~"* N(mu, sigma^2)), adj = 0)

Haris Skiadas
Department of Mathematics and Computer Science
Hanover College

______________________________________________
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