This is a test version of Biostars. For the public version, visit https://www.biostars.org.
problem with bedtools getfasta

I am trying this code from bedtools getfasta manual:

 $ cat test.fa
    >chr1
    AAAAAAAACCCCCCCCCCCCCGCTACTGGGGGGGGGGGGGGGGGG

    $ cat test.bed
    chr1 5 10

    $ bedtools getfasta -fi test.fa -bed test.bed
    >chr1:5-10
    AAACC

    # optionally write to an output file
    $ $ cat test.fa
>chr1
AAAAAAAACCCCCCCCCCCCCGCTACTGGGGGGGGGGGGGGGGGG

$ cat test.bed
chr1 5 10

$ bedtools getfasta -fi test.fa -bed test.bed
>chr1:5-10
AAACC

# optionally write to an output file
$ bedtools getfasta -fi test.fa -bed test.bed -fo test.fa.out

But I got this error:

It looks as though you have less than 3 columns at line 1 in file test.bed.  Are you sure your files are tab-delimited?

How can I solve this?

getfasta bedtools

What does cat -vet test.bed show?

Its showing like this: pybed

Looks like you have an extra tab at the end of the line. Perhaps that is why you get that error.

how can I Correct it?

Well, is the bed file tab delimited?

I dont know what is tab delimited? How can I make that file?

0 answers

No answers yet.

Log in to answer this question.