I am trying to import a series of text files generated by stimulus presentation software. The problem that I am having is that the number of rows I need to skip is not fixed (depending on subject's pretest behavior) nor is the first row of the data I want always the same (the stimuli were presented in random order). So I need to bring in the .txt file (using readLines?), look for the row containing the text "Begin Main" (see exact row below) and start reading data to a table from that point.
[13] "Main Group\t1000\tBegin Main\tBegin Main\tBegin Main\t\t \tPressed\t(any response)\tC\t25860\t\t\t\t\t" I would also like it to ignore the row: [173] "Main Group\t1000\tBreak\tBreak\ tpause3\t\t \tPressed\t(any response)\tC\t47610\t\t\t\t\t" which will always be the same number of rows after the "Begin Main" row. Thanks, Kevin Burnham [[alternative HTML version deleted]] ______________________________________________ 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.