Skip to content
Prev 275196 / 398503 Next

Help w/an old R program I've rediscovered and want to make work

On Sat, Oct 22, 2011 at 8:41 PM, pce369 <pce369 at hotmail.com> wrote:
R will only look in the current working directory if you don't
specify a full path to read.table. That's the directory you start R
from, or any directory set with setwd("some/path") in an R session.
Suggest you get hunting for your data set...
You get that if you mistakenly try subsetting a function. I suspect
this is because you try to call your data 'data' and that gets
confused with the data function because the read.table fails. If you
start a fresh R session and do:

 data$something

 you'll get that message.

 R is smart enough though, that if you do create a data frame with the
name 'data' it will go for that if you do data$something...

Barry