objects::CScope& scope);
78 TDimGetDim(
void)
const;
83 constobjects::CSeq_id&
GetSeqId(TNumrow
row)
const;
86TRng GetAlnRange(
void)
const;
89 constTAlnRngColl& GetAlignCollection(TNumrow
row);
97 returnm_Aln->GetAnchorRow();
101TSignedRange GetSeqAlnRange(TNumrow
row)
const;
111 boolIsPositiveStrand(TNumrow
row)
const;
112 boolIsNegativeStrand(TNumrow
row)
const;
127ESearchDirection dir =
eNone,
128 booltry_reverse_dir =
true)
const;
130ESearchDirection dir =
eNone,
131 booltry_reverse_dir =
true)
const;
156 string& GetSeqString(TNumrow
row,
160 boolforce_translation =
false)
const;
173 string& GetSeqString(TNumrow
row,
175 const TRange& rq_seq_rng,
176 boolforce_translation =
false)
const;
190 string& GetAlnSeqString(TNumrow
row,
192 constTSignedRange& rq_aln_rng,
193 boolforce_translation =
false)
const;
197 constobjects::CBioseq_Handle& GetBioseqHandle(TNumrow
row)
const;
209CreateSegmentIterator(TNumrow
row,
210 constTSignedRange& range,
214 boolIsTranslated(
void)
const;
221 static voidTranslateNAToAA(
const string& na,
string& aa,
222 intgen_code = kDefaultGenCode);
228 intw = m_Aln->GetPairwiseAlns()[
row]->GetSecondBaseWidth();
237 returnaln_pos/GetBaseWidth(
row);
244 intw = GetBaseWidth(
row);
245 return(w == 3) ? aln_pos % 3 + 1 : 0;
254 intw = GetBaseWidth(
row);
256 if(w == 3 && frame) ret += frame - 1;
264 template<
class_TRange>
267 if(aln_range.Empty() || aln_range.IsWhole())
returnaln_range;
268 intw = GetBaseWidth(
row);
269 return_TRange(aln_range.GetFrom()/w, aln_range.GetToOpen()/w - 1);
276 template<
class_TRange>
279 if(aln_range.Empty() || aln_range.IsWhole())
return TFrames(0, 0);
280 intw = GetBaseWidth(
row);
281 if(w == 1)
return TFrames(0, 0);
282 return TFrames(aln_range.GetFrom() % w + 1, aln_range.GetTo() % w + 1);
289 template<
class_TRange>
294 if(seq_range.Empty() || seq_range.IsWhole())
returnseq_range;
295 intw = GetBaseWidth(
row);
296 intfrom_frame = frames.first ? frames.first - 1 : 0;
297 intto_frame = frames.second ? frames.second - 1 : 0;
298 return_TRange(seq_range.GetFrom()*w + from_frame, seq_range.GetToOpen()*w + to_frame - 1);
class CAlignRangeCollectionList<TAlignRange> represent a sorted collection of TAlignRange.
CAlignRange Represents an element of pairwise alignment of two sequences.
Query-anchored alignment can be 2 or multi-dimentional.
vector< CRef< CPairwiseAln > > TPairwiseAlnVector
CPairwiseAln::TAlnRng TAlnRng
CSeq_data::E_Choice TCoding
bool IsSetAnchor(void) const
Check if anchor is set - always true for sparse alignments.
TNumrow GetNumRows(void) const
Synonym of the above.
CAnchoredAln::TPairwiseAlnVector TPairwiseAlnVector
int GetBaseWidth(TNumrow row) const
Get base width for the sequence (1 for nucleotides, 3 for proteins).
TCoding GetNaCoding(void) const
Get sequence coding for nucleotides.
pair< int, int > TFrames
Get start and stop frames for the selected row/range.
CAnchoredAln::TDim TDim
Synonym of TNumrow.
CPairwiseAln::TAlnRngColl TAlnRngColl
CRef< CAnchoredAln > m_Aln
_TRange AlnRangeToNativeSeqRange(TNumrow row, _TRange aln_range) const
Convert alignment range (genomic coordinates) on the selected row to real sequence range.
TCoding GetAaCoding(void) const
Get sequence coding for proteins.
TSignedSeqPos AlnPosToNativeSeqPos(TNumrow row, TSignedSeqPos aln_pos) const
Convert alignment (genomic) coordinate on the selected row to real sequence position.
void SetNaCoding(TCoding coding)
Set sequence coding for nucleotides. If not set, Iupacna coding is used.
TFrames AlnRangeToNativeFrames(TNumrow row, _TRange aln_range) const
vector< objects::CBioseq_Handle > m_BioseqHandles
vector< TRng > m_SecondRanges
void SetAaCoding(TCoding coding)
Set sequence coding for proteins. If not set, Iupacaa coding is used.
CRef< objects::CScope > m_Scope
TNumrow GetAnchor(void) const
Get anchor row index.
_TRange NativeSeqRangeToAlnRange(TNumrow row, _TRange seq_range, TFrames frames=TFrames(0, 0)) const
Convert sequence range to alignment range (genomic coordinates).
int AlnPosToNativeFrame(TNumrow row, TSignedSeqPos aln_pos) const
For protein sequences get frame for the specified coordinated.
vector< CRef< CSeqVector > > m_SeqVectors
TSignedSeqPos NativeSeqPosToAlnPos(TNumrow row, TSignedSeqPos seq_pos, int frame=0) const
Convert sequence position to alignment (genomic) coordinate.
Implementation of IAlnSegmentIterator for CSparseAln.
Alignment explorer interface.
objects::CSeqVector::TResidue TResidue
Alignment segment iterator interface.
Include a standard set of the NCBI C++ Toolkit most basic headers.
unsigned int TSeqPos
Type for sequence locations and lengths.
int TSignedSeqPos
Type for signed sequence position.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define NCBI_XALNMGR_EXPORT
E_Choice
Choice variants.
Portable reference counted smart and weak pointers using CWeakRef, CRef, CObject and CObjectEx.
static bool GetSeqId(const T &d, set< string > &labels, const string name="", bool detect=false, bool found=false)
#define row(bind, expected)
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