[R] Reading word by word in a dataset

Andy Bunn abunn at whrc.org
Mon Nov 1 20:17:42 CET 2004


Something like this should work:

foo <- read.table("text2read.txt", colClasses=c("character", "NULL",
"NULL"))$V1
foo <- gsub("i[0-9]-", "", foo)

HTH, Andy




More information about the R-help mailing list