I am reading lines in a file, where each line (length of 16000 characters) is delimited items by '\30', which can have 4500 items. I'm looking items that begin with the feature feat "hr:pos:" The mat is the match and I will identify characters after the match before the next '\30' delimiter.
feat <- "hr:pos:"
inst <- ffile[i,]
feats <- strsplit(inst,"\30")
mat <- grep(feat,feats[[1]])
While almost all lines will have the match, there are some that don't. This is actually the beginning of the line that has 22,000 characters (this goes really fast). I get a message
a la.p.oec.2(1a).4\302(1a)\30:af:ev:\30af:ah:abstract_entity\30h:ah:abstraction\30
Error in grep(feat, feats[[1]]) : object 'feat' not found
This is okay. I merely want to recognize this, so I can go to the next line.