[R-SIG-Mac].Rprofile in 1.3.1 (os 10.1)

David A Richmond richmond@saintmarys.edu
Sat, 10 Nov 2001 20:12:18 -0500 (EST)


to anyone interested in creating an .Rprofile file in os X:

	After having some problems getting the .Rprofile file to work in
under 10.1 I have discovered the following:

1) OS 10.1 doesn't let you name files that begin with a period '.' in the
Finder, or save them in programs such as BBedit. The only way to create a
file that begins with a period is to use the command line. (i.e. use
Terminal, and use the mv command: "mv filename .filename")

2) R 1.3.1 carbon for mac OS 10/9 requires that the line breaks be
Macintosh line breaks and not Unix line breaks. Thus, a file such as
.Rprofile created and saved using pico will not work, as the line breaks
are unix and not mac.

	Thus, in order to create a working .Rprofile command I had to
first create a file with mac line breaks in BBedit, and save it as
"Rprofile", and then use the Terminal to change the name: 
"mv Rprofile .Rprofile"

hope this helps someone avoid some frustration,
daver


> On Fri, 9 Nov 2001, Stefano Iacus wrote:
> 
> > apparently nothing wrong David,
> > 
> > you probably also converted line-endings that are different from OSX and 
> > old-MacOS. Can you check in some way, for example by using "less 
> > filename" from a shell ?
> > 
> > The R-devel version (and so the 1.4 release) should be ok with both 
> > line-endings.
> > 
> > One question: does the base package work ?
> > 
> > There is a problem with stuffit expander that uses to convert 
> > line-endings differently if you are using the MacOS or the MacOS X 
> > version.
> > 
> > 
> > Stefano
> > 
> > On Venerd́, novembre 9, 2001, at 12:04 , David A Richmond wrote:
> > 
> > > Hi,
> > > 	I recently switched to OS 10.1, and R1.3.1, from 8.6/1.3.0, where
> > > I had a .Rprofile file with a .First function:
> > >
> > > ..First <- function() {
> > > 	library(sna)
> > > 	etc...
> > > }
> > >
> > > This worked in R1.3.0 on 8.6.  Upon downloading 1.3.1 into osX I moved
> > > ..Rprofile to the new R folder, but when I run it I get the following 
> > > error
> > > on startup:
> > > Error: syntax error: evaluating expression 0
> > >
> > > it doesn't matter what's in the function, if I comment out everything
> > > inside .First I still get the error
> > >
> > > what am I doing wrong?
> > >
> > > daver
> > >
> > >
> > 
> 
> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
> |David Richmond                It works on a          |      
> + Dept. of Sociology          complex scientific      + 
> |Saint Mary's College          principle, known as    |  
> + Notre Dame, IN 46556               "pot luck."      +
> |219-284-4517                    - The Doctor         |
> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
> 
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac@stat.math.ethz.ch
> http://www.stat.math.ethz.ch/mailman/listinfo/r-sig-mac
> 

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|David Richmond                It works on a          |      
+ Dept. of Sociology          complex scientific      + 
|Saint Mary's College          principle, known as    |  
+ Notre Dame, IN 46556               "pot luck."      +
|219-284-4517                    - The Doctor         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+