Creating a bed file from a de novo fasta file
0
0
Entering edit mode
3.9 years ago
c.e.chong ▴ 60

Hi all,

I need to create a bed file from my fasta files (from de novo assembled Metagenomic samples). I want the contig name in one column, then the start position and end position.

Does anyone have any advice on how to do this?

Thanks in advance!

assembly bedtools metagenomics • 1.2k views
ADD COMMENT
0
Entering edit mode

By start position and end position, do you mean 1 and length(sequence) for each contig? You should be able to use bioawk to get that information.

ADD REPLY
0
Entering edit mode

I don't want the length of the contig just the bp number where they start and end

ADD REPLY
0
Entering edit mode

Where is that information stored in the FASTA file?

ADD REPLY
0
Entering edit mode

I’m not sure, that’s why I’m asking if it’s possible to do this as I was told this was the file I needed!

I’m not clear on what you mean by 1 and length(sequence)?

Thanks

ADD REPLY
0
Entering edit mode

as I was told this was the file I needed

There lies the problem. I think you need to spend a little more time understanding the problem. Talk to the person who told you this and ask them for more information.

ADD REPLY
0
Entering edit mode

Thanks for your help I have a bio python script to do this now.

ADD REPLY
0
Entering edit mode

Perhaps this would have helped with the names and lengths somewhat faster. Then adapt to BED format

samtools faidx your.fasta
cat your.fasta.fai
ADD REPLY

Login before adding your answer.

Traffic: 1970 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6