Re: [R] Importing a CSV file

2012-09-19 Thread Heramb Gadgil
dear. Somebody had to do it... ;-) > > > >> Sarah > >> > >>> -----Oorspronkelijk bericht- > >>> Van: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org > ] > >>> Namens Sarah Goslee > >>> Verzonden: woensdag

Re: [R] Importing a CSV file

2012-09-19 Thread Marc Schwartz
>> >>> -Oorspronkelijk bericht- >>> Van: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] >>> Namens Sarah Goslee >>> Verzonden: woensdag 19 september 2012 15:44 >>> Aan: Anthi Oikonomou >>> CC: r-h...@stat.math.eth

Re: [R] Importing a CSV file

2012-09-19 Thread Rui Barradas
such thing as c: ---> c:\\). Rui Barradas Sarah -Oorspronkelijk bericht- Van: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Namens Sarah Goslee Verzonden: woensdag 19 september 2012 15:44 Aan: Anthi Oikonomou CC: r-h...@stat.math.ethz.ch Onderwerp: Re: [R]

Re: [R] Importing a CSV file

2012-09-19 Thread Sarah Goslee
zonden: woensdag 19 september 2012 15:44 > Aan: Anthi Oikonomou > CC: r-h...@stat.math.ethz.ch > Onderwerp: Re: [R] Importing a CSV file > > Hi, > > load() is for R's binary data files. You need to use read.csv(), as you > tried, but probably with the complete path. >

Re: [R] Importing a CSV file

2012-09-19 Thread Frans Marcelissen
h Goslee Verzonden: woensdag 19 september 2012 15:44 Aan: Anthi Oikonomou CC: r-h...@stat.math.ethz.ch Onderwerp: Re: [R] Importing a CSV file Hi, load() is for R's binary data files. You need to use read.csv(), as you tried, but probably with the complete path. A <- read.csv("C:\\

Re: [R] Importing a CSV file

2012-09-19 Thread Rui Barradas
Hello, Try ?read.csv. dat <- read.csv("C:\\Users\\Anthi\\Desktop\\R\\A.csv") Note that unlike what happens with load() you'll need an explicit assignment. Hope this helps, Rui Barradas Em 19-09-2012 09:54, Anthi Oikonomou escreveu: > Hi, > I am trying to import csv file in R console > I have

Re: [R] Importing a CSV file

2012-09-19 Thread Sarah Goslee
Hi, load() is for R's binary data files. You need to use read.csv(), as you tried, but probably with the complete path. A <- read.csv("C:\\Users\\Anthi\\Desktop\\R\\A.csv", header=TRUE) Sarah On Wed, Sep 19, 2012 at 4:54 AM, Anthi Oikonomou wrote: > Hi, > I am trying to import csv file in R co

[R] Importing a CSV file

2012-09-19 Thread Anthi Oikonomou
Hi, I am trying to import csv file in R console I have saved my data in a file on the desktop named R and here is my problematic script > load("C:\\Users\\Anthi\\Desktop\\R\\A.csv") Error: bad restore file magic number (file may be corrupted) -- no data loaded In addition: Warning message: file ‘A

Re: [R] Importing a CSV file

2012-02-10 Thread MacQueen, Don
I think you must have given the path to the file wrong. Assuming you are using R.app, try infile <- file.choose() And then give infile to the read.csv() function. Then print the value of infile to find out what the path really is. Probably, you wanted '/Users/sezginozcan/Downloads/beer.dat

Re: [R] Importing a CSV file

2012-02-10 Thread David L Carlson
-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of sezgin ozcan Sent: Thursday, February 09, 2012 9:21 PM To: r-h...@stat.math.ethz.ch Subject: [R] Importing a CSV file I have been trying to import a csv file to r. but I get the same message everytime. the message is Error in file(fil

Re: [R] Importing a CSV file

2012-02-10 Thread peter dalgaard
On Feb 10, 2012, at 04:20 , sezgin ozcan wrote: > I use mac. > I tried this command also > a<-read.table("clipboard",sep=”\t”,row.names=1,header=T) Something is wrong with those quotes around \t... Also, last I needed this, using file="clipboard" to read from the clipboard didn't work on Mac,

Re: [R] Importing a CSV file

2012-02-09 Thread Jorge I Velez
Hi Sezgin, An alternative option If you do not know the path to your file, is to use file.choose() within read.table() to locate it in your machine: a <- read.table(file.choose(), sep = "\t", rownames = 1, header = TRUE) # a window will pop up! head(a) However, in my experience, it is always be

Re: [R] Importing a CSV file

2012-02-09 Thread R. Michael Weylandt
There's not usually a colon in Mac file paths. I would have expected "/Users/sezginozcan/Downloads.beer.data.csv" instead. Did you check that? More generally, type dir(PATHWHEREYOUTHINKFILEIS) and see if it really is there. Michael On Thu, Feb 9, 2012 at 10:20 PM, sezgin ozcan wrote: > I have b

[R] Importing a CSV file

2012-02-09 Thread sezgin ozcan
I have been trying to import a csv file to r. but I get the same message everytime. the message is Error in file(file, "rt") : cannot open the connection In addition: Warning message: In file(file, "rt") : cannot open file 'Users:/sezginozcan/Downloads/beer.data.csv': No such file or directory