From gregory.r.warnes at pfizer.com  Mon Dec 20 22:13:33 2004
From: gregory.r.warnes at pfizer.com (Warnes, Gregory R)
Date: Mon Dec 20 22:14:00 2004
Subject: [Rd] RE: [R] SAS or R software
Message-ID: <915D2D65A9986440A277AC5C98AA466F3F668F@groamrexm02.amer.pfizer.com>


Yes, par(family="mono") would work, except that I get R segfaults from this
sequence:

> 
> plot.new()
> par(family="mono")
> par(cex=8)
> strheight("foo")

Process R segmentation fault (core dumped) at Mon Dec 20 16:07:56 2004

on R 2.0.1 (2004-11-15), Red Hat Enterprise Linux AS release 3 

In my code I call strheight and strwidth several times in order to find a
cex that makes the text best fit the display area.  Once the segfaulting is
fixed, I'll update my code to use par(family="mono").

-G


> -----Original Message-----
> From: Marc Schwartz [mailto:MSchwartz@MedAnalytics.com]
> Sent: Monday, December 20, 2004 3:57 PM
> To: Paul Murrell
> Cc: Warnes, Gregory R; R-Devel; Frank E Harrell Jr
> Subject: Re: [Rd] RE: [R] SAS or R software
> 
> 
> On Tue, 2004-12-21 at 08:40 +1300, Paul Murrell wrote:
> > Hi
> > 
> > 
> > Warnes, Gregory R wrote:
> > > 
> > >>-----Original Message-----
> > >>From: Frank E Harrell Jr [mailto:f.harrell@vanderbilt.edu]
> > > 
> > > ...
> > > 
> > >>This is neat Greg.  Just installed the latest gregmisc.  Do you 
> > >>automatically used fixed width fonts for this, for alignment 
> > >>of columns? 
> > > 
> > > 
> > > Unfortunately, I haven't found any way to select 
> fixed-width fonts, so I
> > > convert the character vector into a matrix of individual 
> characters so that
> > > they align properly.  Its pretty horrid.  
> > > 
> > > I hope that the R developers will provide a way of 
> selecting a fixed width
> > > font in the future so I can remove this ugly hack.
> > 
> > 
> > Does par(family="mono") do what you want?
> > 
> > Paul
> 
> 
> It works here using R 2.0.1 under FC3. I tried it to the display and
> with pdf() using sinkplot().
> 
> With postscript() one can use the 'family = "Courier' 
> argument as well.
> Seems to work here.
> 
> According to ONEWS, par("family") is new for 2.0.0.  Missed that one.
> 
> Thanks Paul.
> 
> Marc
> 
> 
> 


LEGAL NOTICE\ Unless expressly stated otherwise, this messag...{{dropped}}


[Rd] RE: [R] SAS or R software
Warnes, Gregory R