Skip to content
Back to formatted view

Raw Message

Message-ID: <4416DDA1.5060501@statistik.uni-dortmund.de>
Date: 2006-03-14T15:13:37Z
From: Uwe Ligges
Subject: newline in plotmath expressions
In-Reply-To: <200603141407.13233.pascal.niklaus@ipw.agrl.ethz.ch>

Pascal A. Niklaus wrote:

> Hi all,
> 
> When trying to amend a graphic with a text, I run into the following problem:
> 
>    text(10,10,"First line\nSecond line",pos=2)
> 
> works. However, because I have a plotmath expression, I tried:
> 
>    text(10,10,expression("First line with"[subscript]*"\nsecond line"),pos=2)
> 
> but \n does not lead to the result I wish. I considered the plotmath help page 
> but could not find how to insert a newline. 
> 
> Is there a possibility to insert linebreaks in plotmath expressions, or do I 
> have to print the individual lines with separete text commands?

The latter.

Uwe Ligges


> Thanks for you help
> 
> Pascal
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html