Re: [R] Finding and removing non-printable ascii characters in a file

2009-05-26 Thread jim holtman
You can use readLines to read the data in and then gsub to remove the characters you don't want and the textConnection to 'read' in the processed data. > x <- readLines("/tempxx.txt") > # show data > x [1] "al;skdjf a;lskdjf s;aldkfj asd;lfkj " "_)(*)(*&*(&^ &*(^%*&^%" [3] "a;lskdfj z,xmcvn -129

[R] Finding and removing non-printable ascii characters in a file

2009-05-26 Thread Daniel Bradley
Hi! I'm completely confusing myself attempting to solve this one. Is there a simple way of removing particular ASCII characters from a CSV file using R. Hopefully something simpler and faster than cycling through each individual character and comparing them to a list of characters to remove then