In Version 0.64.1 (May 8, 1999), Solaris 2.5.1, expression(theta^{-}) and expression(theta^{+}) (and the equivalent subscripts) give syntax errors. (Superscript or subscripts of numbers, letters, or "+1" or "-1" all work.) Anyone have a workaround or a patch? Or should I just use psfrag as god intended? Ben Benjamin Bolker Dep't of Ecology and Evolutionary Biology, ben@eno.princeton.edu Princeton University tel: (609) 258-6886, fax: (609) 258-1334 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel 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-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Ben Bolker <ben@eno.princeton.edu> writes:> In Version 0.64.1 (May 8, 1999), Solaris 2.5.1, > > expression(theta^{-}) > > and > > expression(theta^{+}) > > (and the equivalent subscripts) give syntax errors. > > (Superscript or subscripts of numbers, letters, or "+1" or "-1" all > work.) > > Anyone have a workaround or a patch? > Or should I just use psfrag as god intended? >Both theta^"+" and theta^+{} seem to work ok. The thing to remember is that + is an operator so if it is used in an expression, it needs to have something to operate on, or you need to explicitly use it as a character. -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard@biostat.ku.dk) FAX: (+45) 35327907 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel 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-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Ben> In Version 0.64.1 (May 8, 1999), Solaris 2.5.1, Ben> expression(theta^{-}) Ben> and Ben> expression(theta^{+}) Ben> (and the equivalent subscripts) give syntax errors. Ben> (Superscript or subscripts of numbers, letters, or "+1" or "-1" Ben> all work.) Ben> Anyone have a workaround or a patch? Or should I just use Ben> psfrag as god intended? The following works: plot(1,type='n', axes=F) text(1,1, expression(theta^"-")) text(1,1.1,expression(theta["+"])) and is probably the most concise here. The following would have worked as well : text(1.1,1, expression(tau^{-{}})) text(1.1,1.1,expression(tau[ +{}])) You see that `expression' needs to be an expression, i.e. the "-" operator needs at least one argument, but that one can be empty. ----- BTW, Ben, I think it's not desired to post both to R-help and R-devel... {{R-devel'ers are supposed to also get R-help -- even though this is not ensured as is the case with R-help and R-announce}}. Martin Maechler <maechler at stat.math.ethz.ch> http://stat.ethz.ch/~maechler/ Seminar fuer Statistik, ETH-Zentrum SOL G1; Sonneggstr.33 ETH (Federal Inst. Technology) 8092 Zurich SWITZERLAND phone: x-41-1-632-3408 fax: ...-1086 <>< -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._