& annot_name_base,
71 if( !tax_id_tag.empty() ) {
75org_ref->GetLabel(&tax_id_tag);
77tax_id_tag +=
"unknown";
85 stringname(annot_name_base);
86 if( !name.empty() ) {
91annot->
SetData().SetAlign().swap(iter->second);
92align_groups.push_back(annot);
99 const string& annot_name_base,
110 if(iter->first.size() == 1) {
112 TTaxIdtax_id = *iter->first.begin();
115 if( !tax_id_tag.empty() ) {
119org_ref->GetLabel(&tax_id_tag);
121tax_id_tag +=
"unknown";
128 stringname(annot_name_base);
129 if( !name.empty() ) {
134annot->
SetData().SetAlign().swap(iter->second);
135align_groups.push_back(annot);
137 if( !mixed_annot ) {
139 stringname(annot_name_base);
140 if( !name.empty() ) {
143name +=
"Mixed Taxa";
146mixed_annot->
SetData().SetAlign()
147.insert(mixed_annot->
SetData().SetAlign().end(),
148iter->second.begin(), iter->second.end());
153align_groups.push_back(mixed_annot);
160 const string& annot_name_base,
161objects::CScope& scope,
171TSequenceAlignMap seq_aligns;
177 for( ; id_iter; ++id_iter) {
189seq_aligns[ids].push_back(align);
197 ITERATE(TSequenceAlignMap, iter, seq_aligns) {
198 if( !iter->second.size() ) {
204 ITERATE(TSeqIds, it, iter->first) {
205 if( !
tag.empty() ) {
208it->GetSeqId()->GetLabel(&
tag,
215.insert(annot->
SetData().SetAlign().begin(),
216iter->second.begin(), iter->second.end());
218 stringname(annot_name_base);
219 if( !name.empty() ) {
224align_groups.push_back(annot);
231 const string& annot_name_base,
232objects::CScope& scope)
241TSequenceAlignMap seq_aligns;
250seq_aligns[strands].push_back(align);
258 ITERATE(TSequenceAlignMap, iter, seq_aligns) {
259 if( !iter->second.size() ) {
265 ITERATE(TStrands, it, iter->first) {
266 if( !
tag.empty() ) {
281.insert(annot->
SetData().SetAlign().begin(),
282iter->second.begin(), iter->second.end());
284 stringname(annot_name_base);
285 if( !name.empty() ) {
290align_groups.push_back(annot);
297 const string& annot_name_base,
298objects::CScope& scope,
308TSequenceAlignMap seq_aligns;
312TSequenceTypes
types;
314 for( ; id_iter; ++id_iter) {
343this_flags |=
fHTGS;
389 types.insert(this_flags);
393seq_aligns[
types].push_back(align);
401 ITERATE(TSequenceAlignMap, iter, seq_aligns) {
402 if( !iter->second.size() ) {
408 ITERATE(TSequenceTypes, it, iter->first) {
409 if( !
tag.empty() ) {
429 tag+=
"Predicted RefSeq";
432 tag+=
"GenBank-EMBL-DDBJ";
443.insert(annot->
SetData().SetAlign().begin(),
444iter->second.begin(), iter->second.end());
446 stringname(annot_name_base);
447 if( !name.empty() ) {
452align_groups.push_back(annot);
466 for( ; id_iter; ++id_iter) {
472tax_aligns[ids].push_back(align);
513org_ref =
m_Taxon1->GetOrgRef(tax_id, is_species,
514is_uncultured, blast_name);
521org_ref = tax_iter->second;
User-defined methods of the data storage class.
User-defined methods of the data storage class.
void GroupBySequenceType(const TAlignList &aligns, TAnnotList &align_groups, const string &annot_base_name, objects::CScope &scope, TSequenceFlags flags=fSequenceDefaults)
Group alignments into sequence-related categories.
void GroupByLikeTaxIds(const TAlignList &aligns, TAnnotList &align_groups, const string &annot_base_name, objects::CScope &scope)
Separate a set of alignments into groups that describe how the alignments relate taxonomically.
TTaxId x_GetTaxId(const objects::CSeq_id_Handle &id, objects::CScope &scope)
void GroupByTaxIds(const TAlignList &aligns, TAnnotList &align_groups, const string &annot_base_name, objects::CScope &scope)
Separate a set of alignments into groups that describe how the alignments relate taxonomically.
CConstRef< objects::COrg_ref > x_GetOrgRef(TTaxId tax_id)
unique_ptr< objects::CTaxon1 > m_Taxon1
void GroupBySeqIds(const TAlignList &aligns, TAnnotList &align_groups, const string &annot_base_name, objects::CScope &scope, TSeqIdFlags flags=0)
Group alignments into bins for each set of seq-ids.
void x_SeparateByTaxId(const TAlignList &alignments, TTaxAlignMap &tax_aligns, objects::CScope &scope)
void GroupByStrand(const TAlignList &aligns, TAnnotList &align_groups, const string &annot_base_name, objects::CScope &scope)
Group alignments into bins for each set of strands.
list< CRef< objects::CSeq_align > > TAlignList
list< CRef< objects::CSeq_annot > > TAnnotList
TDim CheckNumRows(void) const
Validatiors.
ENa_strand GetSeqStrand(TDim row) const
Get strand (the first one if segments have different strands).
Template class for iteration on objects of class C (non-medifiable version)
container_type::iterator iterator
const_iterator end() const
iterator_bool insert(const value_type &val)
container_type::value_type value_type
const_iterator find(const key_type &key) const
iterator_bool insert(const value_type &val)
static const struct type types[]
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
#define NON_CONST_ITERATE(Type, Var, Cont)
Non constant version of ITERATE macro.
SStrictId_Tax::TId TTaxId
Taxon id type.
static EAccessionInfo IdentifyAccession(const CTempString &accession, TParseFlags flags=fParse_AnyRaw)
Deduces information from a bare accession a la WHICH_db_accession; may report false negatives on prop...
void GetLabel(string *label, ELabelType type=eDefault, TLabelFlags flags=fLabel_Default) const
Append a label for this Seq-id to the supplied string.
CConstRef< CSeq_id > GetSeqId(void) const
EAccessionInfo
For IdentifyAccession (below)
static CSeq_id_Handle GetHandle(const CSeq_id &id)
Normal way of getting a handle, works for any seq-id.
@ fLabel_Version
Show the version.
@ fLabel_GeneralDbIsContent
For type general, use the database name as the tag and the (text or numeric) key as the content.
@ eContent
Untagged human-readable accession or the like.
const CSeq_id & GetId(const CSeq_loc &loc, CScope *scope)
If all CSeq_ids embedded in CSeq_loc refer to the same CBioseq, returns the first CSeq_id found,...
TTaxId GetTaxId(const CBioseq_Handle &handle)
return the tax-id associated with a given sequence.
@ eGetId_Best
return the "best" gi (uses FindBestScore(), with CSeq_id::CalculateScore() as the score function
@ eGetId_ForceGi
return only a gi-based seq-id
CBioseq_Handle GetBioseqHandle(const CSeq_id &id)
Get bioseq handle by seq-id.
void Reset(void)
Reset reference object.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
static enable_if< is_arithmetic< TNumeric >::value||is_convertible< TNumeric, Int8 >::value, string >::type NumericToString(TNumeric value, TNumToStringFlags flags=0, int base=10)
Convert numeric value to string.
@ e_Other
for historical reasons, 'other' = 'refseq'
void SetData(TData &value)
Assign a value to Data data member.
void SetName(const TName &value)
Assign a value to Name data member.
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