You probably want to use substitute() to construct your formula and be
careful of the distinction between character strings and names
> substitute(foo ~ bar, list(foo = as.name("y"), bar = as.name("x")))
y ~ x
On Fri, Apr 9, 2010 at 2:06 PM, Nic Rivers wrote:
> Dear R-users:
>
> I would like to
Dear R-users:
I would like to create a system of regression equations of length n,
where the variables are drawn from a data frame. The result I would
like is given by the variable named "system" in the code below.
However, when I use a loop to create the system of equations, I cannot
s
Hi Mark,
Try also:
plot(1:10)
text(2, 5, "Some text", font = 2)
HTH,
Jorge
On Sun, Feb 14, 2010 at 11:36 AM, Mark Heckmann <> wrote:
> # I want to plot bold text. The text should depend on a variable
> containing a character string.
>
> plot.new()
> text(.5, .5, expression(bold("Some text"))
Try
text(.5, .5, bquote(bold(.(myText
-Peter Ehlers
Mark Heckmann wrote:
# I want to plot bold text. The text should depend on a variable
containing a character string.
plot.new()
text(.5, .5, expression(bold("Some text")))
# now I would like to do the same replacing "some text" by a
Hi,
Try with bquote,
plot.new()
myText <- "some text"
text(.5, .5, bquote(bold(.(myText
basically, bquote( .(myText) ) performs the substitution before
applying bold() (see ?bquote).
HTH,
baptiste
On 14 February 2010 17:36, Mark Heckmann wrote:
> # I want to plot bold text. The text sh
# I want to plot bold text. The text should depend on a variable
containing a character string.
plot.new()
text(.5, .5, expression(bold("Some text")))
# now I would like to do the same replacing "some text" by a variable.
plot.new()
myText <- "some text"
text(.5, .5, expression(bold(myText)))
6 matches
Mail list logo