& productInsertionSize,
70 int& genomicInsertionSize)
73 switch(chunk.
Which()) {
124 const auto& exonList = splicedSeg.
GetExons();
125 for(
autopExon: exonList) {
126 for(
autopPart: pExon->GetParts()) {
129 if(pPart->IsProduct_ins()) {
132 else if(pPart->IsGenomic_ins()) {
139 intlastExonBoundT = -1;
141 for(
autopExon: exonList) {
142 if(lastExonBoundT == -1) {
143lastExonBoundT = pExon->GetGenomic_end() + 1;
146 intexonStart = pExon->GetGenomic_start();
147 if(exonStart > lastExonBoundT) {
150lastExonBoundT = pExon->GetGenomic_end() + 1;
154 for(
autopExon: exonList) {
155 if(lastExonBoundT == -1) {
156lastExonBoundT = pExon->GetGenomic_start();
159 intexonEnd = pExon->GetGenomic_end() + 1;
160 if(exonEnd < lastExonBoundT) {
163lastExonBoundT = pExon->GetGenomic_start();
166 mNumInsertT+=
static_cast<int>((exonList.size() - 1));
179 if(!querySeqHandle) {
181 "Unable to resolve given query id",
eDiag_Error);
183 mSizeQ= querySeqHandle.GetInst_Length();
190 if(!targetSeqHandle) {
192 "Unable to resolve given target id",
eDiag_Error);
194 mSizeT= targetSeqHandle.GetInst_Length();
206 const auto& exonList = splicedSeg.
GetExons();
209 for(
autopExon: exonList) {
211 intexonStartQ =
static_cast<int>(pExon->GetProduct_start().AsSeqPos());
212 intexonStartT =
static_cast<int>(pExon->GetGenomic_start());
216 intproductInsertionPending = 0;
217 intgenomicInsertionPending = 0;
218 for(
autopPart: pExon->GetParts()) {
219 if(productInsertionPending || genomicInsertionPending) {
222 mBlockStartsQ.push_back(exonStartQ + blockSize + productInsertionPending);
224exonStartT + blockSize + genomicInsertionPending);
225exonStartQ += blockSize + productInsertionPending;
226exonStartT += blockSize + genomicInsertionPending;
228productInsertionPending = 0;
229genomicInsertionPending = 0;
232*pPart, blockSize, blockSize, productInsertionPending, genomicInsertionPending);
235exonStartQ += blockSize;
236exonStartT += blockSize;
247 const auto& exonList = splicedSeg.
GetExons();
250 for(
autopExon: exonList) {
251 intexonEndT =
static_cast<int>(pExon->GetGenomic_end() + 1);
252 intexonEndQ =
mSizeQ-
static_cast<int>(pExon->GetProduct_end().AsSeqPos() + 1);
254 intproductInsertionPending = 0;
255 intgenomicInsertionPending = 0;
256 for(
autopPart: pExon->GetParts()) {
257 if(productInsertionPending || genomicInsertionPending) {
262exonEndQ -= (blockSize + productInsertionPending);
263exonEndT -= (blockSize + genomicInsertionPending);
265productInsertionPending = 0;
266genomicInsertionPending = 0;
269*pPart, blockSize, blockSize, productInsertionPending, genomicInsertionPending);
271exonEndT -= blockSize;
274exonEndQ -= blockSize;
297 const auto& exonList = splicedSeg.
GetExons();
319 "Unsupported alignment product type \"protein\"",
eDiag_Error);
322 const auto& exonList = splicedSeg.
GetExons();
323 for(
autopExon: exonList) {
324 if(!pExon->CanGetProduct_start() || !pExon->CanGetProduct_end()) {
326 "Mandatory product information missing",
eDiag_Error);
328 if(!pExon->CanGetGenomic_start() || !pExon->CanGetGenomic_end()) {
330 "Mandatory target information missing",
eDiag_Error);
357 for(
const auto& pScore: scores) {
358 if(!pScore->CanGetId() || !pScore->GetId().IsStr()) {
361 if(!pScore->CanGetValue()) {
364 const auto&
key= pScore->GetId().GetStr();
365 const auto&
value= pScore->GetValue();
396 if(denseSeg.
GetDim() != 2) {
398 "PSL supports only pairwaise alignments",
eDiag_Error);
423 mSizeQ= seqHandleQ.GetInst_Length();
430 mSizeT= seqHandleT.GetInst_Length();
443 for(
autolength: denseSeg.
GetLens()) {
448 autolens = denseSeg.
GetLens();
450 if(starts[2*
i] != -1 && starts[2*
i+1] != -1) {
479 if(startOfThisQ - endOfLastQ != 0) {
489 if(startOfThisT - endOfLastT != 0) {
516 const string& message,
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
const CSeq_id & GetSeq_id(TDim row) const
ENa_strand GetSeqStrand(TDim row) const
TSeqPos GetSeqStop(TDim row) const
TSeqPos GetSeqStart(TDim row) const
bool GetBestId(CSeq_id_Handle, CScope &, string &) const
vector< int > mBlockSizes
void xInitializeSequenceInfo(CScope &, const CSpliced_seg &)
void xInitializeBlocksStrandNegative(CScope &, const CSpliced_seg &)
void xInitializeStatsAndBlocks(CScope &, const CDense_seg &)
CGenbankIdResolve & mIdResolve
void Initialize(CScope &scope, const CSpliced_seg &splicedSeg)
CWriterListener * mpMessageListener
vector< int > mBlockStartsQ
void xInitializeStrands(CScope &, const CSpliced_seg &)
void xInitializeStats(CScope &, const CSpliced_seg &)
void xValidateSegment(CScope &, const CSpliced_seg &)
void xInitializeBlocksStrandPositive(CScope &, const CSpliced_seg &)
vector< int > mBlockStartsT
void xPutMessage(const string &message, EDiagSev severity)
void xInitializeBlocks(CScope &, const CSpliced_seg &)
TSeqPos GetSeqStop(TDim row) const
TSeqPos GetSeqStart(TDim row) const
EDiagSev
Severity level for the posted diagnostics.
@ eDiag_Error
Error message.
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
CBioseq_Handle GetBioseqHandle(const CSeq_id &id)
Get bioseq handle by seq-id.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
const TGenomic_id & GetGenomic_id(void) const
Get the Genomic_id member data.
vector< CRef< CScore > > TScore
TMatch GetMatch(void) const
Get the variant data.
const TStarts & GetStarts(void) const
Get the Starts member data.
const TProduct_id & GetProduct_id(void) const
Get the Product_id member data.
const TLens & GetLens(void) const
Get the Lens member data.
bool CanGetProduct_type(void) const
Check if it is safe to call GetProduct_type method.
TProduct_type GetProduct_type(void) const
Get the Product_type member data.
TMismatch GetMismatch(void) const
Get the variant data.
TGenomic_strand GetGenomic_strand(void) const
Get the Genomic_strand member data.
bool CanGetProduct_strand(void) const
Check if it is safe to call GetProduct_strand method.
TDim GetDim(void) const
Get the Dim member data.
TGenomic_ins GetGenomic_ins(void) const
Get the variant data.
const TExons & GetExons(void) const
Get the Exons member data.
TProduct_strand GetProduct_strand(void) const
Get the Product_strand member data.
TProduct_ins GetProduct_ins(void) const
Get the variant data.
bool CanGetGenomic_strand(void) const
Check if it is safe to call GetGenomic_strand method.
E_Choice Which(void) const
Which variant is currently selected.
@ e_Product_ins
insertion in product sequence (i.e. gap in the genomic sequence)
@ e_Genomic_ins
insertion in genomic sequence (i.e. gap in the product sequence)
@ e_Match
both sequences represented, product and genomic sequences match
@ e_Mismatch
both sequences represented, product and genomic sequences do not match
const struct ncbi::grid::netcache::search::fields::KEY key
const GenericPointer< typename T::ValueType > T2 value
static void sExonChunkAppendStats(const CSpliced_exon_chunk &chunk, int &matchSize, int &misMatchSize, int &productInsertionSize, int &genomicInsertionSize)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4