tdf reader in python

692 views
Skip to first unread message

mbourgey

unread,
Oct 5, 2015, 3:45:57 PM10/5/15
to igv-help
Hi,

first of
I'm actually facing a problem of space in my analysis.
I was planning to put my bam on tape and only keep my vcf and tdf files live on disk.
I would like to be able in the future to read the tdf file to extract the coverage at a given position (if new samples bring new variants positions).

So actually I found the solution of using igvtools tdftobedgraph to generate a temporary bedgraph file and then being able to find the coverage of the position of interest.

So my question is: would it be possible to directly interrogate the tdf file in order to avoid creating temporary files ? and if possible I would have preferred doing it in python.

Thank you in advance

Jim Robinson

unread,
Oct 5, 2015, 4:13:07 PM10/5/15
to igv-...@googlegroups.com
Hi,

It would be possible to extend igvtools tdftobedgraph to accept a query string (e.g. chr1:1000-2000) and export just coverage for that, but it doesn't exist currently.     An alternative for  new files would be to compute coverage as a "wig" file (use a .wig extension for the output file, rather than .tdf),  then use UCSC utils to convert the wig -> bigWig.   I don't know for sure, but there are probably tools in python for querying a bigwig file.   IGV support bigwig and it is more or less equivalent to tdf.

For the tdf option, the query parameter would be input to tdftobedgraph, in the java igvtools program.   We do not have any python tools.

Jim


--

---
You received this message because you are subscribed to the Google Groups "igv-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/igv-help/c5368de9-55e9-49b3-976d-036faff82440%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

mbourgey

unread,
Oct 6, 2015, 9:04:43 AM10/6/15
to igv-help
Thank you Jim for your reply. I will explore these possibilities

Mathieu
Reply all
Reply to author
Forward
0 new messages