I am just starting with R and trying to understand some of the built-in functions. I am trying to organize a main FASTA text file that looks like this:
>ID1
AGAATAGCCAGAACCGTTTCTCTGAGGCTTCC
>ID2
TCCAATTAAGTCCCTATCCAGGCGCTCCG
>ID3
GAACCGGAGAACGCTTCAGACCAGCCCGGAC
In a table that will look something like this:
ID Sequence
ID1 AGAATAGCCAGAACCGTTTCTCTGAGGCTTCC
ID2 TCCAATTAAGTCCCTATCCAGGCGCTCCG
ID3 GAACCGGAGAACGCTTCAGACCAGCCCGGAC
Or at least something organized in a similar way. Unfortunately, whenever I try to use read.table, I am forced to install fill = TRUEin order to avoid the following error:
> read.table("ReadingText.txt", header=F, fill=F, sep=">")
Error in scan(file, what, nmax, sep, dec, quote, skip, nlines, na.strings, :
line 2 did not have 2 elements
fill = TRUE , . , , R , , " > " .
, ? read.table , , - ? , , ! R.
, , , - , . , - .