[R] r-help[Q]: use of `expression' in annotation

Alex Buerkle (cbuerkle@bio.indiana.edu)
Tue, 19 Jan 1999 10:04:31 -0500 (EST)

Date: Tue, 19 Jan 1999 10:04:31 -0500 (EST)
From: Alex Buerkle <cbuerkle@bio.indiana.edu>
To: r-help@stat.math.ethz.ch
Subject: [R] r-help[Q]: use of `expression' in annotation

Dear r-helpers,

I have some multiplot figures that I would like to annotate. To each plot
frame I would like to add the associated correlation coefficients. To do
so, I believe I need to understand the usage of `expression' better.

The following is a good start.

petstring <- expression(paste(r[rho*p],"=" ))
mtext(petstring, line=0.3, adj=0.1, cex=0.8)

My question is, how can I interpolate a variable into this expression?

I would like petstring to contain r[rho*p] = peti, where peti is the corr.
coefficient that would vary across panes in the figure. I have tried
various combinations of paste and expression and have not hit on the right
combination (instead I usually get peti as a literal rather than a
variable).

Thanks, Alex Buerkle

~^^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^
C. Alex Buerkle Ph: 812-855-9018
Jordan Hall 142 Fax: 812-855-6705
Department of Biology
Indiana University
Bloomington, IN 47405 cbuerkle@bio.indiana.edu

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


This archive was generated by hypermail 1.02.