Re: [R] Can't there be a cd command?

From: Duncan Murdoch <murdoch_at_stats.uwo.ca>
Date: Thu 11 May 2006 - 00:26:20 EST

On 5/10/2006 9:29 AM, Paul Johnson wrote:
> It is a FAQ in our Linux lab. People start emacs and fire up R via
> ess, and then they have no idea 'where they are". For computer
> experts, it is not a problem, but for people who don't know much about
> computers, it is a pretty big problem. They have data in some
> subdirectory, but almost invariably they don't get emacs & R started
> from that same place.
>
> Unfortunately, for our users, it does not help to simply re-label
> setwd as cd. Both commands imply a deeper understanding of the OS
> than they have. Also, unfortunately, these are the same people who
> don't understand that FAQs exist and should be consulted. These people
> are so new/timid that asking in r-help would be the last thing to
> cross their mind.
>
> I've wondered if it would not help to have the R prompt include the
> directory name, as in an x terminal.

I think file system directories aren't as central in R as they are in a shell, so it would just be distracting. Most of the time I work in the R workspace, not in the file system.

To me the solution is to allow interactive file selection by default, i.e. the default on read.table and similar functions should be file.choose(), rather than having no default and throwing an error. This won't help you in the short run (because file.choose() on Linux isn't all that friendly to beginners), but perhaps it would encourage someone to make it better. file.choose() is quite nice in Windows (and I think on the Mac), so beginners there could be told

mydf <- read.table()

and they'd get something useful.

Martin Maechler has disagreed with me about this in the past, but hasn't convinced me that he's right, he's just convinced me that doing nothing is easier than arguing about it.

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 Thu May 11 00:30:35 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Thu 11 May 2006 - 02:10:07 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.