[Seqan-dev] finding mates in fragment store
- From: Mat <matthias.dodt@mdc-berlin.de>
- To: seqan-dev@lists.fu-berlin.de
- Date: Tue, 07 Dec 2010 11:53:30 +0100
- Reply-to: SeqAn Development <seqan-dev@lists.fu-berlin.de>
- Subject: [Seqan-dev] finding mates in fragment store
Hi Guys! I am loading a SAM file into a fragment store and would like to enter all the reads which have a mate into a graph, if the mate's were aligned to different contigs. I am not sure how to search the FragmentStore for a certain read id. I got: ... unsigned int nrAlignments = length(fragStore.alignedReadStore),mateCounter=0; for (unsigned int n=0;n<nrAlignments;++n){ unsigned int mate_id = fragStore.alignedReadStore[n].pairMatchId; if(mate_id!=TReadStoreElement::INVALID_ID){ ++mateCounter; std::cout << "read-id: " << n << ","<<fragStore.alignedReadStore[n].readId << std::endl; std::cout << "pair-id: " << fragStore.alignedReadStore[n].pairMatchId << std::endl; std::cout << "contig-id: " << fragStore.alignedReadStore[n].contigId << std::endl; //get mate contig-id >>> the Fragment store is not indexed by the read_id... std::cout << "read-id: " << fragStore.alignedReadStore[mate_id].readId << std::endl; std::cout << "pair-id: " << fragStore.alignedReadStore[mate_id].pairMatchId << std::endl; std::cout << "contig-id: " << fragStore.alignedReadStore[mate_id].contigId << std::endl; <<<< //ceck if congtig-ids are unequal... //insert into graph... break; } } ... Thanks! Best, mat |
-
seqan-dev - December 2010 - Archives indexes sorted by:
[ thread ] [ subject ] [ author ] [ date ] - Complete archive of the seqan-dev mailing list
- More info on this list...