Re: [R] How to Import Data

From: Ben Bolker <>
Date: Wed 22 Feb 2006 - 01:08:58 EST

Carl Klarner <cklarner <at>> writes:

> I would imagine I'm not putting my csv file in the right location for R
> to be able to read it. If that's the case, where should I put it? Or
> is there something else I need to do to it first?
> Thanks for your help,
> Carl

  You're probably right. R opens by default in its installation directory (usually somewhere in Program Files\R\... on Windows) The easiest thing is to change the working directory to wherever you have the files using setwd() or (in a GUI) some menu option ("Change dir" in the File menu under Windows).

   Useful functions for working directory, file selection etc.: list.files() [list files in current directory], file.choose() [interactive file chooser], file.exists() [whether or not a file exists], getwd() [print current working directory], setwd() [set current working directory].

  The other common problem, which you probably *aren't* having, is hidden file extensions under Windows.

   good luck
     Ben Bolker mailing list PLEASE do read the posting guide! Received on Wed Feb 22 01:22:04 2006

This archive was generated by hypermail 2.1.8 : Wed 22 Feb 2006 - 09:27:43 EST