Entering edit mode
9.1 years ago
fuhsuyuan
•
0
Hi,
I have a list of genome position, e.g.
scaffold 1 [tab] position 1 [tab] reads1
scaffold 1 [tab] position 2 [tab] reads2
.
.
.
scaffold 2 [tab] positionN [tab] readsN
And my annotation file could be like
scaffold 1 [tab] exon_start [tab] exon_end [tab] annotation1
scaffold 1 [tab] exon_start [tab] exon_end [tab] annotation2
scaffold 1 [tab] exon_start [tab] exon_end [tab] annotation3
.
.
scaffold N [tab] exon_start [tab] exon_end [tab] annotationN
How do I make a output file programmatically like
output.txt
scaffold 1 [tab] position1 [tab] reads1 [tab] intron [tab] annotation
scaffold 1 [tab] position2 [tab] reads2 [tab] exon [tab] annotation
.
.
scaffold N [tab] positionN [tab] readsN [tab] intergenic_region [tab] neighbor gene annotation
Thanks.
Go through bedtools or bedops. You may have to reformat your tables a little otherwise both of them work wonders.
Thank you. I will try it.