InitData(&emptyAlignmentList, blankDisplay);
150AlignmentList::const_iterator
a, ae = newAlignments.end();
151 for(
a=newAlignments.begin();
a!=ae; ++
a) {
152 if((*a)->NRows() != 2) {
153 ERRORMSG(
"UpdateViewer::AddAlignments() - got alignment with "<< (*a)->NRows() <<
" rows");
158alignments.push_back(*
a);
164 for(
unsigned int row=0;
row<2; ++
row)
168 if(alignments.size() > 0)
169display->
SetStartingColumn(alignments.front()->GetFirstAlignedBlockPosition() - 5);
190keepAlignments.push_back((*a)->Clone());
207 if((*a)->NRows() != 2) {
208 ERRORMSG(
"CreateSeqAlignFromUpdate() - can only save pairwise updates");
212(*a)->GetUngappedAlignedBlocks(&
blocks);
214 if(!newSeqAlign)
continue;
217 CUpdate_align*updateAlign = (*a)->updateOrigin.GetPointer();
224 ERRORMSG(
"UpdateViewer::SaveAlignments() - confused by Update-align format");
234updateAlign->
SetType((*a)->GetSequenceOfRow(1)->molecule ?
239comment->
SetComment(
"Created by demotion or import in Cn3D");
245seqAnnotRef->
SetData().SetAlign();
250 if(!updateAlign || !(seqAlignList = &(updateAlign->
SetSeqannot().SetData().SetAlign()))) {
251 ERRORMSG(
"UpdateViewer::SaveAlignments() - can't find Update-align and/or Seq-align list");
257 if(usedUpdateAligns.
find(updateAlign) == usedUpdateAligns.
end()) {
258seqAlignList->clear();
259updates.resize(updates.size() + 1);
260updates.back().Reset(updateAlign);
261usedUpdateAligns[updateAlign] =
true;
265seqAlignList->resize(seqAlignList->size() + 1);
266seqAlignList->back().Reset(newSeqAlign);
288vector < const Sequence * > chains;
290 if(chains.size() == 1) {
293wxString *titles =
newwxString[chains.size()];
295 for(choice=0; choice<(
int)chains.size(); ++choice)
296titles[choice] = chains[choice]->identifier->ToString().c_str();
297choice = wxGetSingleChoiceIndex(
"Align to which protein chain?",
298 "Select Chain", chains.size(), titles);
300master = chains[choice];
307 ERRORMSG(
"UpdateViewer::GetMasterSequence() - no master sequence defined");
314wxGetTextFromUser(
"Enter a list of protein GIs or Accessions:",
316 if(ids.size() == 0)
return;
318wxStringTokenizer tkz(ids,
" ,;\t\r\n", wxTOKEN_STRTOK);
319 while(tkz.HasMoreTokens()) {
320wxString
id= tkz.GetNextToken();
322 if(bioseq.
Empty())
327newSequences->push_back(sequence);
329 ERRORMSG(
"The sequence must be a protein");
336newSequences->clear();
338wxString fastaFile = wxFileSelector(
"Choose a FASTA file from which to import",
339 "",
"",
"",
"*.*", wxFD_OPEN | wxFD_FILE_MUST_EXIST, *
viewerWindow);
340 if(fastaFile.size() > 0) {
345 ERRORMSG(
"Unable to open file "<< fastaFile.c_str());
358newSequences->push_back(sequence);
362 if(!(*b)->IsSeq()) {
363 WARNINGMSG(
"CFastaReader returned nested Bioseq-set");
367newSequences->push_back(sequence);
371 WARNINGMSG(
"CFastaReader returned unknown format or no Bioseqs");
380(*seqs)[1] = dependent;
384 ERRORMSG(
"MakeEmptyAlignment() - error finalizing alignment");
394newAlignments->clear();
395SequenceList::const_iterator s, se = newSequences.end();
396 for(s=newSequences.begin(); s!=se; ++s) {
398 if(newAlignment) newAlignments->push_back(newAlignment);
405 static constwxString choiceStrings[] = {
"Network via GI/Accession",
"From a FASTA File"};
406 enumchoiceValues { FROM_GI=0, FROM_FASTA, N_CHOICES };
407 intimportFrom = wxGetSingleChoiceIndex(
"From what source would you like to import sequences?",
408 "Select Import Source", N_CHOICES, choiceStrings, *
viewerWindow);
409 if(importFrom < 0)
return;
412 if(importFrom == FROM_GI)
416 else if(importFrom == FROM_FASTA)
424 if(!master)
return;
429 if(newSequences.size() == 0) {
430 WARNINGMSG(
"UpdateViewer::ImportSequence() - no sequences were imported");
439 if(newAlignments.size() > 0)
442 ERRORMSG(
"UpdateViewer::ImportSequence() - no new alignments were created");
448 unsigned intmasterFrom,
unsigned intmasterTo)
const 451 WARNINGMSG(
"UpdateViewer::GetVASTAlignments() - " 456SequenceList::const_iterator s, se = newSequences.end();
457 for(s=newSequences.begin(); s!=se; ++s) {
458 if((*s)->identifier->pdbID.size() == 0) {
459 WARNINGMSG(
"UpdateViewer::GetVASTAlignments() - " 460 "can't be called with non-MMDB dependent "<< (*s)->identifier->ToString());
462 if(newAlignment) newAlignments->push_back(newAlignment);
468host =
"www.ncbi.nlm.nih.gov",
469path =
"/Structure/VA/vastalign.cgi", err;
472<<
"&neighbor="<< (*s)->identifier->ToString();
473 if(masterFrom <= masterTo && masterFrom < master->Length() && masterTo < master->Length())
474argstr <<
"&from="<< (masterFrom+1) <<
"&to="<< (masterTo+1);
479 INFOMSG(
"trying to load VAST alignment data from "<< host << path <<
'?'<< args);
482 ERRORMSG(
"Error calling vastalign.cgi: "<< err);
484 if(newAlignment) newAlignments->push_back(newAlignment);
487 INFOMSG(
"successfully loaded data from vastalign.cgi");
489 WriteASNToFile(
"vastalign.dat.txt", structureAlignment,
false, &err);
500 if(structureAlignment.
IsSetId() && structureAlignment.
GetId().front()->IsMmdb_id() &&
501structureAlignment.
GetId().front()->GetMmdb_id().Get() == 0)
503 WARNINGMSG(
"VAST found no alignment for these chains");
508 if(!structureAlignment.
IsSetId() || !structureAlignment.
GetId().front()->IsMmdb_id() ||
510structureAlignment.
GetFeatures().front()->GetFeatures().size() != 1 ||
511!structureAlignment.
GetFeatures().front()->GetFeatures().front()->IsSetLocation() ||
512!structureAlignment.
GetFeatures().front()->GetFeatures().front()->GetLocation().IsAlignment())
514 throw "VAST data does not contain exactly one alignment of recognized format - " 515 "possibly a problem with vastalign.cgi";
519 throw "Master structure MMDB ID mismatch - check to see if this structure been updated";
523structureAlignment.
GetFeatures().front()->GetFeatures().front()->GetLocation().GetAlignment();
529alignment.
GetBiostruc_ids().back()->GetMmdb_id().Get() != (*s)->identifier->mmdbID ||
531!alignment.
GetAlignment().front()->GetResidues().IsInterval() ||
533!alignment.
GetAlignment().back()->GetResidues().IsInterval() ||
534alignment.
GetAlignment().front()->GetResidues().GetInterval().size() !=
535alignment.
GetAlignment().back()->GetResidues().GetInterval().size())
537 throw "Unrecognized VAST data format";
541CResidue_pntrs::TInterval::const_iterator
i, j,
542ie = alignment.
GetAlignment().front()->GetResidues().GetInterval().end();
543 for(
i=alignment.
GetAlignment().front()->GetResidues().GetInterval().begin(),
544j=alignment.
GetAlignment().back()->GetResidues().GetInterval().begin();
i!=ie; ++
i, ++j)
547(*j)->GetMolecule_id().Get() != (*s)->identifier->moleculeID)
549 throw "Mismatch in molecule ids in alignment interval block";
552newBlock->
SetRangeOfRow(0, (*i)->GetFrom().Get() - 1, (*i)->GetTo().Get() - 1);
553newBlock->
SetRangeOfRow(1, (*j)->GetFrom().Get() - 1, (*j)->GetTo().Get() - 1);
554newBlock->
width= (*i)->GetTo().Get() - (*i)->GetFrom().Get() + 1;
561structureAlignments->resize(structureAlignments->size() + 1);
562structureAlignments->back().structureAlignment =
563structureAlignment.
SetFeatures().front()->SetFeatures().front();
564structureAlignments->back().masterDomainID =
565structureAlignment.
GetFeatures().front()->GetId().Get();
566structureAlignments->back().dependentDomainID =
567structureAlignment.
GetFeatures().front()->GetFeatures().front()->GetId().Get();
569 throw "No structure alignment in VAST data blob";
571}
catch(
const char*err) {
572 ERRORMSG(
"Failed to import VAST alignment: "<< err);
577 ERRORMSG(
"MakeEmptyAlignment() - error finalizing alignment");
581newAlignments->push_back(newAlignment);
589 if(!master)
return;
591 ERRORMSG(
"Can't import another structure when current structure has multiple models");
596 static constwxString choiceStrings[] = {
"Via Network",
"From a File"};
597 enumchoiceValues { FROM_NETWORK=0, FROM_FILE, N_CHOICES };
598 intimportFrom = wxGetSingleChoiceIndex(
599 "From what source would you like to import the structure?",
"Select Import Source",
601 if(importFrom < 0)
return;
606 if(importFrom == FROM_NETWORK) {
607wxString
id= wxGetTextFromUser(
"Enter a PDB or MMDB ID:",
"Input Identifier",
"", *
viewerWindow);
612biostruc, &bioseqs)) {
613 ERRORMSG(
"Failed to load structure "<<
id.c_str());
618 else if(importFrom == FROM_FILE) {
619 stringfilename =
WX_TO_STD(wxFileSelector(
"Choose a single-structure file:",
621 if(filename.size() == 0)
return;
622 boolreadOK =
false;
624 TRACEMSG(
"trying to read file '"<< filename <<
"' as binary mime");
631 TRACEMSG(
"trying to read file '"<< filename <<
"' as ascii mime");
639 ERRORMSG(
"Couldn't read structure from "<< filename);
647 if(biostruc->
GetId().size() == 0 || !biostruc->
GetId().front()->IsMmdb_id()) {
648 ERRORMSG(
"Can't get MMDB ID from loaded structure");
651mmdbID = biostruc->
GetId().front()->GetMmdb_id().Get();
655 if(biostruc->
GetModel().size() != 1 ||
660 ERRORMSG(
"Biostruc does not match current data - should be " 661<< (master->
parentSet->
isAlphaOnly?
"alpha-only":
"one-coordinate-per-atom") <<
" model");
667vector < pair < const CSeq_id * , string > > chains;
669CBiostruc_graph::TDescr::const_iterator d, de;
670CBiostruc_graph::TMolecule_graphs::const_iterator
673 boolisProtein =
false;
676 stringfull_name =
"";
679de = (*m)->GetDescr().end();
680 for(d=(*m)->GetDescr().begin(); d!=de; ++d) {
681 if((*d)->IsName()) {
682full_name = (*d)->GetName();
683name = (*d)->GetName()[0];
685 else if((*d)->IsMolecule_type() &&
688 if(isProtein && (full_name !=
""))
break;
692 if((*m)->IsSetSeq_id())
693sid = &((*m)->GetSeq_id());
696 if(isProtein && (full_name !=
"") && sid !=
NULL) {
697moleculeIDs[sid] = (*m)->GetId().Get();
698chains.push_back(make_pair(sid, full_name));
701 if(chains.size() == 0) {
702 ERRORMSG(
"No protein chains found in this structure!");
708CBiostruc::TDescr::const_iterator
n,
ne= biostruc->
GetDescr().end();
710 if((*n)->IsName()) {
711pdbID = (*n)->GetName();
717vector < const CSeq_id * > sids;
718vector < string > sids_chain_ids;
719 if(chains.size() == 1) {
720sids.push_back(chains[0].
first);
721sids_chain_ids.push_back(chains[0].second);
723wxString *choices =
newwxString[chains.size()];
725 for(choice=0; choice<(
int)chains.size(); ++choice)
726choices[choice].Printf(
"%s_%s %s",
727pdbID.c_str(), chains[choice].second, chains[choice].first->GetSeqIdString().c_str());
728wxArrayInt selections;
730 intnsel = wxGetSelectedChoices(selections,
"Which chain(s) do you want to align?",
731 "Select Chain", chains.size(), choices, *
viewerWindow);
732 if(nsel == 0)
return;
733 for(choice = 0; choice < nsel; ++choice) {
734sids.push_back(chains[selections[choice]].
first);
735sids_chain_ids.push_back(chains[selections[choice]].second);
742 for(
unsigned intj=0; j<sids.size(); ++j) {
746 if((*s)->identifier->MatchesSeqId(*(sids[j]))) {
748newSequences.push_back(*s);
749seq2id[*s] = sids[j];
756BioseqRefList::iterator
b, be = bioseqs.end();
757 for(
b=bioseqs.begin();
b!=be; ++
b) {
758CBioseq::TId::const_iterator
i, ie = (*b)->GetId().end();
759 for(
i=(*b)->GetId().begin();
i!=ie; ++
i) {
760 if((*i)->Match(*(sids[j])))
811newSequences.push_back(sequence);
812seq2id[sequence] = sids[j];
824SequenceList::const_iterator w, we = newSequences.end();
825 for(w=newSequences.begin(); w!=we; ++w) {
828(*w)->AddMMDBAnnotTag(mmdbID);
834 if((*w)->identifier->mmdbID != mmdbID)
835 ERRORMSG(
"MMDB ID mismatch in sequence "<< (*w)->identifier->ToString()
836<<
"; "<< (*w)->identifier->mmdbID <<
" vs "<< mmdbID);
838 if(moleculeIDs.
find(seq2id[*w]) != moleculeIDs.
end()) {
841moleculeIDs[seq2id[*w]];
843 if((*w)->identifier->moleculeID != moleculeIDs[seq2id[*w]])
844 ERRORMSG(
"Molecule ID mismatch in sequence "<< (*w)->identifier->ToString());
847 ERRORMSG(
"No matching id for MMDB sequence "<< (*w)->identifier->ToString());
853 intmasterFrom = -1, masterTo = -1;
858 if(aBlocks.size() > 0) {
859masterFrom = aBlocks.front()->GetRangeOfRow(0)->from;
860masterTo = aBlocks.back()->GetRangeOfRow(0)->to;
866SequenceList::const_iterator s, se = newSequences.end();
867 for(s=newSequences.begin(); s!=se; ++s) {
876 ERRORMSG(
"ImportStructure() - error finalizing alignment");
880newAlignments.push_back(newAlignment);
885 if(newAlignments.size() == newSequences.size())
888 ERRORMSG(
"UpdateViewer::ImportStructure() - no new alignments were created");
896wxMessageBox(
"The structure has been successfully imported! However, it will not appear until you\n" 897 "save this data to a file and then re-load it in a new session. And depending on the type\n" 898 "of data, it still might not appear unless the corresponding new pairwise alignment has\n" 899 "been merged into the multiple alignment.",
900 "Structure Added", wxOK | wxICON_INFORMATION, *
viewerWindow);
903wxMessageBox(
"The selected sequence from this structure has been imported! However, the structure\n" 904 "itself can not appear in the structure window until the sequence has been merged into the\n" 905 "multiple alignment and the alignment has been remastered to a structured sequence.",
906 "Sequence Added", wxOK | wxICON_INFORMATION, *
viewerWindow);
912 TRACEMSG(
"saving pending imported structures and structure alignments");
920 ERRORMSG(
"UpdateViewer::SavePendingStructures() - error saving Biostruc");
936 if(usePSSMFromMultiple && !multipleForPSSM) {
937 ERRORMSG(
"Can't do BLAST/PSSM when no multiple alignment is present");
944 if(*
a!= alignment)
continue;
948toRealign.push_back(alignment);
951multipleForPSSM, toRealign, &newAlignments, usePSSMFromMultiple);
952 if(newAlignments.size() != 1) {
953 ERRORMSG(
"UpdateViewer::BlastUpdate() - CreateNewPairwiseAlignmentsByBlast() failed");
956 if(newAlignments.front()->NAlignedBlocks() == 0) {
958 deletenewAlignments.front();
963 TRACEMSG(
"BLAST succeeded - replacing alignment");
965*
a= newAlignments.front();
978 intdependentRow, vector < int > *dependent2master)
980dependent2master->clear();
984BlockMultipleAlignment::UngappedAlignedBlockList::const_iterator
b, be = uaBlocks.end();
985 for(
b=uaBlocks.begin();
b!=be; ++
b) {
987*masterRange = (*b)->GetRangeOfRow(0),
988*dependentRange = (*b)->GetRangeOfRow(dependentRow);
989 for(
unsigned int i=0;
i<(*b)->width; ++
i)
990(*dependent2master)[dependentRange->from +
i] = masterRange->
from+
i;
998 if(rowAlignments.size() != multiple->
NRows()) {
999 ERRORMSG(
"GetAlignmentByBestNeighbor: wrong # alignments");
1005 unsigned int b, bestRow = 0;
1006BLASTer::AlignmentList::const_iterator p, pe = rowAlignments.end();
1007 for(
b=0, p=rowAlignments.begin(); p!=pe; ++
b, ++p) {
1009bestMatchFromMultiple = *p;
1013 if(!bestMatchFromMultiple || bestMatchFromMultiple->
GetRowDouble(0) > 0.000001) {
1014 WARNINGMSG(
"GetAlignmentByBestNeighbor: no significant hit found");
1017 INFOMSG(
"Closest neighbor from multiple: sequence " 1019<<
", E-value: "<< bestMatchFromMultiple->
GetRowDouble(0));
1025 if(bestRow == 0)
returnbestMatchFromMultiple->
Clone();
1028vector < int > import2dependent, dependent2master;
1035(*seqs)[1] = importSeq;
1040 intmasterStart=-1, importStart, importLoc, dependentLoc, masterLoc,
len=0;
1041 for(importStart=-1, importLoc=0; importLoc<=(
int)importSeq->
Length(); ++importLoc) {
1044dependentLoc = (importLoc < (
int)importSeq->
Length()) ? import2dependent[importLoc] : -1;
1045masterLoc = (dependentLoc >= 0) ? dependent2master[dependentLoc] : -1;
1048 if(importStart >= 0) {
1051 if(masterLoc >= 0 && masterLoc-masterStart == importLoc-importStart) {
1067 if(importStart < 0) {
1068 if(masterLoc >= 0) {
1069masterStart = masterLoc;
1070importStart = importLoc;
1078 ERRORMSG(
"error finalizing alignment");
1079 deletenewAlignment;
1083 returnnewAlignment;
1090 ERRORMSG(
"Can't do BLAST Neighbor when no multiple alignment is present");
1095 if(uaBlocks.size() == 0) {
1096 ERRORMSG(
"Can't do BLAST Neighbor with null multiple alignment");
1104 if(*
a== update)
break;
1113(*seqs)[1] = updateSeq;
1120 WARNINGMSG(
"Can't get footprint excess residues from registry");
1121newAlignment->
alignMasterFrom= uaBlocks.front()->GetRangeOfRow(
row)->from - excess;
1124newAlignment->
alignMasterTo= uaBlocks.back()->GetRangeOfRow(
row)->to + excess;
1125 if(newAlignment->
alignMasterTo>= ((
int)((*seqs)[0]->Length())))
1129toRealign.push_back(newAlignment);
1131 ERRORMSG(
"error finalizing alignment");
1132 deletenewAlignment;
1139 if(
result.size() != 1) {
1140 ERRORMSG(
"UpdateViewer::BlastUpdate() - CreateNewPairwiseAlignmentsByBlast() failed");
1143newAlignments.push_back(
result.front());
1149 if(!alignmentByNeighbor) {
1153 TRACEMSG(
"BLAST Neighbor succeeded - replacing alignment");
1155*
a= alignmentByNeighbor;
1171 a->GetSequenceOfRow(1)->identifier,
1172 b->GetSequenceOfRow(1)->identifier);
1178 return(
a->GetRowDouble(0) >
b->GetRowDouble(0));
1185 TRACEMSG(
"sorting updates by identifier");
1192 TRACEMSG(
"sorting updates by PSSM");
1196 ERRORMSG(
"Can't do sort by PSSM when no multiple alignment is present");
1204 const Sequence*updateSeq = (*a)->GetSequenceOfRow(1);
1206(*a)->GetUngappedAlignedBlocks(&uaBlocks);
1207BlockMultipleAlignment::UngappedAlignedBlockList::const_iterator
b, be = uaBlocks.end();
1211 for(
b=uaBlocks.begin();
b!=be; ++
b) {
1212 const Block::Range*m = (*b)->GetRangeOfRow(0), *u = (*b)->GetRangeOfRow(1);
1213 for(
unsigned int i=0;
i<(*b)->width; ++
i)
1214score += multiple->
GetPSSM().GetPSSMScore(
1220(*a)->SetRowStatusLine(0,
string(
"Score vs. PSSM: ") +
NStr::IntToString(score));
1221(*a)->SetRowStatusLine(1, (*a)->GetRowStatusLine(0));
1222(*a)->SetRowDouble(0, score);
1223(*a)->SetRowDouble(1, score);
1233 ERRORMSG(
"UpdateViewer::SortUpdates() - must first set comparison function");
1254 for(
i=0;
i<sortedVector.size(); ++
i) sortedList.push_back(sortedVector[
i]);
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.
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.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
bool GetAsnDataViaHTTPS(const std::string &host, const std::string &path, const std::string &args, ASNClass *asnObject, std::string *err, bool binaryData=true)
bool GetStructureProteins(std::vector< const Sequence * > *chains) const
const BlockMultipleAlignment * GetCurrentMultipleAlignment(void) const
void ReplaceUpdatesInASN(ncbi::objects::CCdd::TPending &newUpdates) const
std::list< BlockMultipleAlignment * > AlignmentList
void CreateNewPairwiseAlignmentsByBlast(const BlockMultipleAlignment *multiple, const AlignmentList &toRealign, AlignmentList *newAlignments, bool usePSSM)
BlockMultipleAlignment * Clone(void) const
std::vector< const Sequence * > SequenceList
const BLAST_Matrix * GetPSSM(void) const
const Sequence * GetMaster(void) const
std::vector< const UngappedAlignedBlock * > UngappedAlignedBlockList
const Sequence * GetSequenceOfRow(unsigned int row) const
void GetUngappedAlignedBlocks(UngappedAlignedBlockList *blocks) const
unsigned int NRows(void) const
double GetRowDouble(unsigned int row) const
bool UpdateBlockMapAndColors(bool clearRowInfo=true)
bool AddUnalignedBlocks(void)
bool AddAlignedBlockAtEnd(UngappedAlignedBlock *newBlock)
void SetRangeOfRow(unsigned int row, int from, int to)
CChem_graph_alignment â.
Base class for reading FASTA sequences.
CNcbiOstrstreamToString class helps convert CNcbiOstrstream to a string Sample usage:
Simple implementation of ILineReader for i(o)streams.
void PostRedrawSequenceViewer(ViewerBase *viewer)
bool RemoveAllHighlights(bool postRedraws)
void UnPostRedrawSequenceViewer(ViewerBase *viewer)
void AddHighlights(const Sequence *sequence, unsigned int seqIndexFrom, unsigned int seqIndexTo)
static bool CompareIdentifiers(const MoleculeIdentifier *a, const MoleculeIdentifier *b)
static const int VALUE_NOT_SET
std::string ToString(void) const
void AddRowFromAlignment(unsigned int row, BlockMultipleAlignment *fromAlignment)
unsigned int NRows(void) const
void AddRowFromString(const std::string &anyString)
unsigned int GetStartingColumn(void) const
void AddBlockBoundaryRow(BlockMultipleAlignment *forAlignment)
void SetStartingColumn(unsigned int column)
const Molecule * molecule
const MoleculeIdentifier * identifier
unsigned int Length(void) const
bool AddBiostrucToASN(ncbi::objects::CBiostruc *biostruc)
const Sequence * FindOrCreateSequence(ncbi::objects::CBioseq &bioseq)
const SequenceSet * sequenceSet
void AddStructureAlignment(ncbi::objects::CBiostruc_feature *feature, int masterDomainID, int dependentDomainID)
AlignmentManager * alignmentManager
bool SaveDialog(bool prompt, bool canCancel)
void BlastUpdate(BlockMultipleAlignment *alignment, bool usePSSMFromMultiple)
void FetchSequencesViaHTTP(SequenceList *newSequences, StructureSet *sSet) const
void GetVASTAlignments(const SequenceList &newSequences, const Sequence *master, AlignmentList *newAlignments, PendingStructureAlignments *structureAlignments, unsigned int masterFrom=kMax_UInt, unsigned int masterTo=kMax_UInt) const
void SavePendingStructures(void)
void FetchSequences(StructureSet *sSet, SequenceList *newSequences) const
void ReplaceAlignments(const AlignmentList &alignmentList)
void AddAlignments(const AlignmentList &alignmentList)
void ImportStructure(void)
const Sequence * GetMasterSequence(void) const
void SaveDialog(bool prompt)
void SaveAlignments(void)
std::list< BlockMultipleAlignment * > AlignmentList
UpdateViewerWindow * updateWindow
void DeleteAlignment(BlockMultipleAlignment *toDelete)
void ReadSequencesFromFile(SequenceList *newSequences, StructureSet *sSet) const
PendingStructureAlignments pendingStructureAlignments
std::list< StructureAlignmentInfo > PendingStructureAlignments
void CreateUpdateWindow(void)
void MakeEmptyAlignments(const SequenceList &newSequences, const Sequence *master, AlignmentList *newAlignments) const
void ImportSequences(void)
friend class UpdateViewerWindow
void BlastNeighbor(BlockMultipleAlignment *update)
BiostrucList pendingStructures
std::list< const Sequence * > SequenceList
void SetInitialState(void)
void SortByIdentifier(void)
AlignmentList currentAlignments
AlignmentManager * alignmentManager
SequenceDisplay * GetCurrentDisplay(void)
ViewerWindowBase **const viewerWindow
const AlignmentList & GetCurrentAlignments(void) const
void NewDisplay(SequenceDisplay *display, bool enableSelectByColumn)
void ScrollToColumn(int column)
void UpdateDisplay(SequenceDisplay *display)
bool GeometryViolationsShown(void) const
const_iterator end() const
const_iterator find(const key_type &key) const
bool ExtractBiostrucAndBioseqs(CNcbi_mime_asn1 &mime, CRef< CBiostruc > &biostruc, BioseqRefList *sequences)
CNcbi_mime_asn1 * LoadStructureViaCache(const std::string &uid, ncbi::objects::EModel_type modelType, int assemblyId)
std::list< ncbi::CRef< ncbi::objects::CBioseq > > BioseqRefList
string GetSeqIdString(const CSeq_id &id)
Include a standard set of the NCBI C++ Toolkit most basic headers.
static bool ReadASNFromFile(const char *filename, ASNClass *ASNobject, bool isBinary, std::string *err)
static bool WriteASNToFile(const char *filename, const ASNClass &ASNobject, bool isBinary, std::string *err, ncbi::EFixNonPrint fixNonPrint=ncbi::eFNP_Default)
Operators to edit gaps in sequences.
static DLIST_TYPE *DLIST_NAME() first(DLIST_LIST_TYPE *list)
EDiagSev SetDiagPostLevel(EDiagSev post_sev=eDiag_Error)
Set the threshold severity for posting the messages.
@ eDiag_Info
Informational message.
@ eDiag_Error
Error message.
@ eDiag_Fatal
Fatal error â guarantees exit(or abort)
CRef< CSeq_entry > ReadSet(int max_seqs=kMax_Int, ILineErrorListener *pMessageListener=nullptr)
Read multiple sequences (by default, as many as are available.)
@ fAssumeProt
Assume prots unless accns indicate otherwise.
TObjectType * GetPointer(void) THROWS_NONE
Get pointer,.
void Reset(void)
Reset reference object.
bool Empty(void) const THROWS_NONE
Check if CRef is empty â not pointing to any object, which means having a null value.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_SCOPE(ns)
Define a new scope.
IO_PREFIX::ifstream CNcbiIfstream
Portable alias for ifstream.
static string IntToString(int value, TNumToStringFlags flags=0, int base=10)
Convert int to string.
const TMolecule_graphs & GetMolecule_graphs(void) const
Get the Molecule_graphs member data.
TDimension GetDimension(void) const
Get the Dimension member data.
const TTransform & GetTransform(void) const
Get the Transform member data.
const TBiostruc_ids & GetBiostruc_ids(void) const
Get the Biostruc_ids member data.
const TAlignment & GetAlignment(void) const
Get the Alignment member data.
@ eModel_type_ncbi_all_atom
@ eModel_type_ncbi_backbone
TFeatures & SetFeatures(void)
Assign a value to Features data member.
const TFeatures & GetFeatures(void) const
Get the Features member data.
const TId & GetId(void) const
Get the Id member data.
const TModel & GetModel(void) const
Get the Model member data.
bool IsSetId(void) const
Check if a value has been assigned to Id data member.
const TId & GetId(void) const
Get the Id member data.
const TChemical_graph & GetChemical_graph(void) const
Get the Chemical_graph member data.
const TDescr & GetDescr(void) const
Get the Descr member data.
const TDescription & GetDescription(void) const
Get the Description member data.
list< CRef< CUpdate_align > > TPending
TComment & SetComment(void)
Select the variant.
bool IsSetSeqannot(void) const
contains the SeqAlign Check if a value has been assigned to Seqannot data member.
const TSeqannot & GetSeqannot(void) const
Get the Seqannot member data.
void SetType(TType value)
Assign a value to Type data member.
void SetSeqannot(TSeqannot &value)
Assign a value to Seqannot data member.
TDescription & SetDescription(void)
Assign a value to Description data member.
TSet & SetSet(void)
Select the variant.
const TSet & GetSet(void) const
Get the variant data.
bool IsSeq(void) const
Check if variant Seq is selected.
bool IsSet(void) const
Check if variant Set is selected.
const TSeq_set & GetSeq_set(void) const
Get the Seq_set member data.
TSeq & SetSeq(void)
Select the variant.
TSeq_set & SetSeq_set(void)
Assign a value to Seq_set data member.
bool IsAlign(void) const
Check if variant Align is selected.
void SetData(TData &value)
Assign a value to Data data member.
list< CRef< CSeq_align > > TAlign
const TData & GetData(void) const
Get the Data member data.
unsigned int
A callback function used to compare two keys in a database.
Lightweight interface for getting lines of data with minimal memory copying.
Messenger * GlobalMessenger(void)
const struct ncbi::grid::netcache::search::fields::SIZE size
The NCBI C++/STL use hints.
bool ne(T x_, T y_, T round_)
std::istream & in(std::istream &in_, double &x_)
void copy(Njn::Matrix< S > *matrix_, const Njn::Matrix< T > &matrix0_)
#define row(bind, expected)
static DP_BlockInfo * blocks
ncbi::objects::CSeq_align * CreatePairwiseSeqAlignFromMultipleRow(const BlockMultipleAlignment *multiple, const BlockMultipleAlignment::UngappedAlignedBlockList &blocks, unsigned int slaveRow)
#define DELETE_ALL_AND_CLEAR(container, ContainerType)
unsigned char LookupNCBIStdaaNumberFromCharacter(char r)
static bool CompareUpdatesByIdentifier(BlockMultipleAlignment *a, BlockMultipleAlignment *b)
static BlockMultipleAlignment * MakeEmptyAlignment(const Sequence *master, const Sequence *dependent)
static CompareUpdates updateComparisonFunction
static bool CompareUpdatesByScore(BlockMultipleAlignment *a, BlockMultipleAlignment *b)
bool(* CompareUpdates)(BlockMultipleAlignment *a, BlockMultipleAlignment *b)
static BlockMultipleAlignment * GetAlignmentByBestNeighbor(const BlockMultipleAlignment *multiple, const BLASTer::AlignmentList rowAlignments)
static void MapDependentToMaster(const BlockMultipleAlignment *alignment, int dependentRow, vector< int > *dependent2master)
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