Open the terminal application in the Utilities folder. Select the file you want 
to use in R in a Finder window and drag it to the terminal applications command 
line prompt and then release the file. The absolute path of the file will be 
entered in the command line of the terminal’s window. Though this absolute path 
will work, relative paths are often preferred. 


Mark

R. Mark Sharp, Ph.D.
rmsh...@me.com

> On Jan 21, 2020, at 2:02 PM, Kevin Thorpe <kevin.tho...@utoronto.ca> wrote:
> 
> You would also need to drop the c: as that is a DOS/Windows thing.
> 
> -- 
> Kevin E. Thorpe
> Head of Biostatistics,  Applied Health Research Centre (AHRC)
> Li Ka Shing Knowledge Institute of St. Michael's
> Assistant Professor, Dalla Lana School of Public Health
> University of Toronto
> email: kevin.tho...@utoronto.ca  Tel: 416.864.5776  Fax: 416.864.3016
> 
> 
> On 2020-01-21, 1:26 PM, "R-help on behalf of James Spottiswoode" 
> <r-help-boun...@r-project.org on behalf of ja...@jsasoc.com> wrote:
> 
>    OSX is based on BSD UNIX so paths use the forward slash as separator, e.g.
> 
>    temps <- 
> read.table("c:/Users/DFP/Documents/ah/house/HouseTemps.txt",header=T,row.names=1)
> 
>    Best James
> 
>> On Jan 21, 2020, at 9:20 AM, David <parkh...@indiana.edu> wrote:
>> 
>> I moved to a mac a few months ago after years in windows, and I'm still 
>> learning basics.  I'm wanting to create a data frame based on a text file 
>> called HouseTemps.txt.  That's a file within one called house which is 
>> within one called ah.  That may further be in one called  Documents.  I 
>> tried various lines like:
>> 
>> temps <- 
>> read.table("c:\\Users\\DFP\\Documents\\ah\\house\\HouseTemps.txt",header=T,row.names=1)
>> 
>> based on my windows DOS experience, but nothing I try works.  So my question 
>> is, what do complete file names look like in a mac?
>> 
>> I tried Apple support, but they couldn't help me with R.
>> 
>> ______________________________________________
>> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> 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.
>> 
> 
> 
> 
>        [[alternative HTML version deleted]]
> 
>    ______________________________________________
>    R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>    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.
> 
> 
> ______________________________________________
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> 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.

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.

Reply via email to