weng-lab/TEMP2

accessibility map

Closed this issue · 1 comments

jdaron commented

Dear Tianxiong Yu,

Thanks for making this tools, I have been using extensively lately with great success.

I am writing here because I would have like to report putative improvement of the tools I have been working with lately. I have been using TEMP2 for a population purpose recently. I genotype TE insertions polymorphisms (TIPs) in a whole set of individual and using bedtools merge I generate a presence/absence matrix for all TIPs across my population.

However, when a TIP is absence in a given individual, I don’t know if it is because the TIP is really absence or because the region is poorly covered (missing data). The lack of discrimination between those two categories could negatively impact bunch of downstream analysis. Consequently, I feel it could be cool to get an accessibility map of each bam file investigated by TEMP2. I personally have generated those accessibility file using the following command:

samtools view -bh -F 0X800 -f 0X2 myBAM | samtools depth - | awk '{if($3>=10){print $1"\t"$2-1"\t"$2}}' > depth.bed
bedtools merge -i depth.bed > accessibility.bed

Here I use a threshold of 10reads to assess the accessibility of the area but it could be customized.
Let me know if you feel this could be an improvement of TEMP2.

Best regard,
Josquin Daron