Re: [R] Import help (neophyte)

From: Duncan Murdoch <murdoch_at_stats.uwo.ca>
Date: Tue 01 Nov 2005 - 05:51:10 EST

On 10/31/2005 1:31 PM, Jeffrey Stratford wrote:
> Hi, I have no experience with R and I'm finding the manuals a bit obtuse
> and written as if I already understood R.
>
> I'm trying to import a csv file from a floppy and it's not working. The
> code I'm using is
>
> read.table("F:\GEORGIA\species_richness\SR_use.csv", sep=",", header =
> TRUE, row.names = 1)
>
> I'm assuming that this command is case sensitive so everything matches.
> Is there something I'm missing?

In R (as in C) the backslash is an escape character. To have a backslash appear in your pathname, you need to double it.

Alternatively, just use a forward slash:

  read.table("F:/GEORGIA/species_richness/SR_use.csv", sep=",", header =   TRUE, row.names = 1)

Duncan Murdoch



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Tue Nov 01 06:17:22 2005

This archive was generated by hypermail 2.1.8 : Tue 01 Nov 2005 - 09:46:16 EST