Bedtools -Sorted Genome File
1
0
Entering edit mode
5.8 years ago
gtasource ▴ 60

Bedtools coverage says to use the -sorted option for bedtools coverage, I need to provide a genome file that:

Defines the expected chromosome order in the input files for use with the -sorted option.

How is the file supposed to look? I included one that listed out all of the chromosomes, but received an error that genome file has no valid entries.

bedtools • 2.4k views
ADD COMMENT
4
Entering edit mode
5.8 years ago

Hello gtasource,

this file needs the chromosome name and the length of the chromosomes. You can extract these information from your alignment file as the information are in the header:

$ samtools view -H file.bam|grep @SQ|sed 's/@SQ\tSN:\|LN://g'' > genome.txt

fin swimmer

ADD COMMENT

Login before adding your answer.

Traffic: 3199 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