Dear David, In fact just updating R seems to have fixed the problem. There's a lesson.
Thanks a lot, George On 3 July 2012 17:02, David Winsemius [via R] < ml-node+s789695n4635292...@n4.nabble.com> wrote: > > On Jul 3, 2012, at 4:01 AM, georgeshirreff wrote: > > > Dear all, > > > > I am trying to write figures directly to a file using the jpeg() > > function. > > > > this_ylab=expression(paste("P",sep="")~lambda) > > this_xlab=expression(rho) > > > > jpeg("file_name.jpeg",width=100,height=100,units="mm",res=300) > > Try instead something like: > > quartz(file="file_name.jpeg", type="jpeg", width=7,height=7) > > And follow-ups should go the R-SIG-Mac mailing list. And please update > your installation of R. > > -- > David. > > > > > plot > > (input_values > > ,output_values,pch=16,cex=cex_pt,xlab="",frame.plot=T,ann=F,axes=F) > > axis(side=2) > > axis(side=1,labels=T,xlab="") > > mtext(this_xlab,side=1,line=4,cex=2) > > mtext(this_ylab,side=2,line=3,cex=2) > > > > dev.off() > > > > > > However, I get the following error message: > > > > Error in mtext(this_xlab, side = 1, line = 4, cex = 2) : > > Metric information not available for this device > > > > I could put the argument specifying the x-label in the "plot" > > function but > > then I don't control where it goes. When I have used the tiff() > > function > > instead I don't have this problem. > > > > I am using R 2.11.1 on Mac OS X 10.7.3 > > > > > > Thanks, > > George > > > > > > -- > > View this message in context: > http://r.789695.n4.nabble.com/Problem-using-mtext-to-write-onto-a-jpeg-tp4635258.html > > Sent from the R help mailing list archive at Nabble.com. > > > > ______________________________________________ > > [hidden email] > > <http://user/SendEmail.jtp?type=node&node=4635292&i=0>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. > > David Winsemius, MD > West Hartford, CT > > ______________________________________________ > [hidden email] <http://user/SendEmail.jtp?type=node&node=4635292&i=1>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. > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://r.789695.n4.nabble.com/Problem-using-mtext-to-write-onto-a-jpeg-tp4635258p4635292.html > To unsubscribe from Problem using mtext to write onto a jpeg, click > here<http://r.789695.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=4635258&code=Z2Vvcmdlc2hpcnJlZmZAZ29vZ2xlbWFpbC5jb218NDYzNTI1OHw0ODcyNjczNjk=> > . > NAML<http://r.789695.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml> > -- View this message in context: http://r.789695.n4.nabble.com/Problem-using-mtext-to-write-onto-a-jpeg-tp4635258p4635297.html Sent from the R help mailing list archive at Nabble.com. [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org 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.