This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Convert Wiggle Track To Bed Format

Hello all,

I know there is a similar post here about converting wig2bed but the solutions didn't seem to fit for the particular wiggle track I am using. Trying to convert this fixed step wiggle track http://genome.ucsc.edu/goldenPath/help/phastCons.html into a format that gives the genomic position on each line. The goal is to get the conservation score for a list of positions in a VCF file. As the wiggle track does not explicitly give the genome position without some conversion it seems the simplest solution is to convert it to bed.

The wig2bed python script I found doesnt seem to work for this bed file. Here are some example lines from the wiggle track to clarify:

fixedStep chrom=chr20 start=775 step=1 0.000
0.000
0.000
0.000
0.001
0.001
0.001

The values are conservation scores for each position.

Any help greatly appreciated!

Best regards

Rubal

deleted-post

The answer given there using the python script at http://code.google.com/p/chip-seq/source/browse/branches/formatconvert/wig2bed.py outputs windows eg chr20 55252139 55252557 when what I need is individual positions and the conservation score for these positions. It seems the most important data, the conservation score, is lost in the conversion. Therefore I do not think the duplicate question solves my problem.

if you have a solution you should post it as an answer rather than a comment.

0 answers

No answers yet.

Log in to answer this question.