Sometimes it is easiest to open a file using a file selection widget. I keep this in my .Rprofile:
getOpenFile <- function(...){ require(tcltk) return(tclvalue(tkgetOpenFile())) } With this you can find your file and open it with rel <- read.table(getOpenFile(), quote="", header=FALSE, sep="", col.names=c("id","orel","nrel")) or filename <- getOpenFile() rel <- read.table(filename, quote="", header=FALSE, sep="", col.names=c("id","orel","nrel")) Mike P.S. I keep a couple functions on hand for choosing writable files and directories too... getSaveFile <- function(...){ require(tcltk) return(tclvalue(tkgetSaveFile())) } chooseDir <- function(...){ require(tcltk) return(tclvalue(tkchooseDirectory())) } ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.