Hello, One more question from the 'abusing R for blotting - particularly anally' department: How can I in the expression below make the '%~~%' show up as the aprrox-sign I want it to be? Thanks for any hint, Joh text( 500,1.5, cex=0.75, substitute( paste( OD[600][~nm], " of 1 at ", time1, " min ", "%~~%", time1h, "h" ), list( time1=round(time1,digits=0), time1h=round(time1/60,digits=1) ) ) )
Johannes Graumann wrote:> Hello, > > One more question from the 'abusing R for blotting - particularly > anally' department: > How can I in the expression below make the '%~~%' show up as the > aprrox-sign I want it to be? > > Thanks for any hint, > > Joh > > text( > 500,1.5, > cex=0.75, > substitute( > paste( > OD[600][~nm], > " of 1 at ", > time1, > " min ", > "%~~%", > time1h, > "h" > ), > list( > time1=round(time1,digits=0), > time1h=round(time1/60,digits=1) > ) > ) > )substitute(OD[600][~nm] * " of 1 at " * time1 * " min" %~~% time1h * h, list(time1=round(time1,digits=0), time1h=round(time1/60,digits=1)) ) Uwe Ligges> ______________________________________________ > 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
Johannes Graumann wrote:> Hello, > > One more question from the 'abusing R for blotting - particularly > anally' department: > How can I in the expression below make the '%~~%' show up as the > aprrox-sign I want it to be? > > Thanks for any hint,Your code does not work because "%~~%" is a character string and %~~% is an invalid mathematical expression. The operator (e.g. %~~%) must be between something, so it works if you use phantom(0)%~~%phantom(0), and I found that phantom() without 0 works too: See the following: plot(0, xlim=c(0,1000), ylim=c(0,2), type="n") time1=99 text( 500,1.5, cex=0.75, substitute( paste( OD[600][~nm], " of 1 at ", time1, " min ", phantom()%~~%phantom(), time1h, "h" ), list( time1=round(time1,digits=0), time1h=round(time1/60,digits=1) ) ) ) Hope it helps Thomas P.