Re: [R] main= bquote(paste("Results for ", beta, "3", ==.(b1)))) doesn't work.

From: Peter Dalgaard <p.dalgaard_at_biostat.ku.dk>
Date: Mon 31 Jul 2006 - 07:40:47 EST

"Marco Boks" <marco.boks@inter.nl.net> writes:

> Hi,
>
> I need to plot the beta as the symbol, followed by the index 3 as the title of a graph.
>
> This code works> main= bquote(paste("Results for ", beta ==.(b1))
>
> but I also need the index 3.
> I tried (simplified):
>
> >plot(x,y, main= bquote(paste("Results for ", beta, "3", ==.(b1))))
>
> and a few other versions, but I can not get it to run properly.
>
> Any help would be greatly appreciated,

Are you looking for

 plot(0,0, main= bquote(paste("Results for ", beta[3] ==.(b1))))

?

Your fundamental problem is that expressions need to be syntactically complete, so "==.(b1)" with no left hand side gets you a syntax error. However, you can supply a dummy, and

 plot(0,0, main= bquote(paste("Results for ", beta, 3, {} ==.(b1))))

does work (although possibly not with your desired output).

-- 
   O__  ---- Peter Dalgaard             ุster Farimagsgade 5, Entr.B
  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
 (*) \(*) -- University of Copenhagen   Denmark          Ph:  (+45) 35327918
~~~~~~~~~~ - (p.dalgaard@biostat.ku.dk)                  FAX: (+45) 35327907

______________________________________________
R-help@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
and provide commented, minimal, self-contained, reproducible code.
Received on Mon Jul 31 08:50:10 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Mon 31 Jul 2006 - 10:17:04 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.