blast::CSearchResultSet&
results,
49 constblast::CBlastOptions& opts,
50 const string&
dbname,
booldb_is_aa,
51 intqgencode,
intdbgencode,
53 intdbfilt_algorithm
)
54: m_Queries(queries), m_Options(opts),
56m_QueryGeneticCode(qgencode),
57m_DbGeneticCode(dbgencode),
58m_NoHitsFound(
false),
64vector<CBlastFormatUtil::SDbInfo> dbinformation;
66CBlastFormatUtil::GetBlastDbInfo(dbinformation,
m_DbName, db_is_aa,
67dbfilt_algorithm, is_remote);
70 x_Init(queries,
results, opts, dbinformation, qgencode, dbgencode, is_remote, dbfilt_algorithm);
76 constblast::CSearchResultSet&
results,
77 constblast::CBlastOptions& opts,
78 constvector<CAlignFormatUtil::SDbInfo> & dbInfo,
83: m_Queries(queries), m_Options(opts),
85m_QueryGeneticCode(qgencode),
86m_DbGeneticCode(dbgencode),
87m_NoHitsFound(
false),
94 ITERATE(vector<CBlastFormatUtil::SDbInfo>,
i, dbInfo) {
95 if(
i!= dbInfo.begin())
99 x_Init(queries,
results, opts, dbInfo, qgencode, dbgencode, is_remote, dbfilt_algorithm);
105 constblast::CSearchResultSet&
results,
106 constblast::CBlastOptions& opts,
107 constvector<CAlignFormatUtil::SDbInfo> & dbInfo,
111 intdbfilt_algorithm)
116 if(!dbInfo.empty()) {
117 ITERATE(vector<CBlastFormatUtil::SDbInfo>,
i, dbInfo) {
137CBlastFormatUtil::kNoHitsFound);
144 for(
size_t i= 0;
i<
results.size() - 1;
i++) {
158 stringerrors =
results[
i].GetErrorStrings();
160 if( !errors.empty() ) {
163errors +=
results[
i].GetWarningStrings();
165 if( !
results[
i].HasAlignments() ) {
166errors += (errors.empty() ?
kEmptyStr:
" ");
167errors += CBlastFormatUtil::kNoHitsFound;
190 if(matrix_name ==
NULL)
195 if(
strcmp(matrix_name,
"BLOSUM45") == 0)
197 else if(
strcmp(matrix_name,
"BLOSUM50") == 0)
199 else if(
strcmp(matrix_name,
"BLOSUM62") == 0)
201 else if(
strcmp(matrix_name,
"BLOSUM80") == 0)
203 else if(
strcmp(matrix_name,
"BLOSUM90") == 0)
205 else if(
strcmp(matrix_name,
"PAM30") == 0)
207 else if(
strcmp(matrix_name,
"PAM70") == 0)
209 else if(
strcmp(matrix_name,
"PAM250") == 0)
211 else if(
strcmp(matrix_name,
"IDENTITY") == 0)
216 if(prog_name !=
"blastn"&& prog_name !=
"megablast") {
217 NCBI_THROW(blast::CBlastException, eInvalidArgument,
218 "unsupported score matrix");
256x256 matrix used for calculating positives etc.
CRef< blast::CBlastQueryVector > m_Queries
Query sequences.
vector< CRef< blast::CBlastAncillaryData > > m_AncillaryData
ancillary results data
int m_NumSequences
Number of sequences in all BLAST databases involved in this search.
bool m_NoHitsFound
True if results did not find any hits.
int * m_Matrix[kMatrixCols]
Score matrix used to determine neighboring protein residues.
TSeqLocInfoVector m_Masks
masks for the queries
unsigned int GetNumQueries(void) const
@inheritDoc
const blast::CBlastOptions & m_Options
BLAST algorithm options.
Int8 m_NumBases
Number of bases in all BLAST databases involved in this search.
void x_FillScoreMatrix(const char *matrix_name=BLAST_DEFAULT_MATRIX)
Initialize the score matrix to be used for formatting (if applicable)
string m_DbName
name of blast database
int GetLengthAdjustment(int) const
@inheritDoc
CCmdLineBlastXMLReportData(CRef< blast::CBlastQueryVector > queries, const blast::CSearchResultSet &results, const blast::CBlastOptions &opts, const string &dbname, bool db_is_aa, int qgencode=BLAST_GENETIC_CODE, int dbgencode=BLAST_GENETIC_CODE, bool is_remote=false, int dbfilt_algorithm=-1)
Constructor.
double GetEntropy(int query_index) const
@inheritDoc
vector< string > m_Errors
Error messages (one element per query)
void x_Init(CRef< blast::CBlastQueryVector > queries, const blast::CSearchResultSet &results, const blast::CBlastOptions &opts, const vector< align_format::CAlignFormatUtil::SDbInfo > &dbInfo, int qgencode, int dbgencode, bool is_remote, int dbfilt_algorith)
vector< CConstRef< CSeq_align_set > > m_Alignments
the alignments
double GetLambda(int query_index) const
@inheritDoc
~CCmdLineBlastXMLReportData()
Destructor.
double GetKappa(int query_index) const
@inheritDoc
static const unsigned int kMatrixCols
Number of columns used in score matrices.
CBlastFormattingMatrix * GetMatrix(void) const
@inheritDoc
Implementation of interface class to produce data required for generating BLAST XML output.
string Blast_ProgramNameFromType(EBlastProgramType program)
Returns a string program name, given a blast::EBlastProgramType enumeration.
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
bool Empty(void) const THROWS_NONE
Check if CRef is empty â not pointing to any object, which means having a null value.
char * dbname(DBPROCESS *dbproc)
Get name of current database.
int strcmp(const char *str1, const char *str2)
const SNCBIPackedScoreMatrix NCBISM_Pam30
const SNCBIPackedScoreMatrix NCBISM_Blosum62
const SNCBIPackedScoreMatrix NCBISM_Pam250
const SNCBIPackedScoreMatrix NCBISM_Blosum50
const SNCBIPackedScoreMatrix NCBISM_Blosum80
void NCBISM_Unpack(const SNCBIPackedScoreMatrix *psm, SNCBIFullScoreMatrix *fsm)
Expand a packed score matrix into an unpacked one, which callers can proceed to index directly by sta...
const SNCBIPackedScoreMatrix NCBISM_Pam70
const SNCBIPackedScoreMatrix NCBISM_Blosum45
The standard matrices.
const SNCBIPackedScoreMatrix NCBISM_Identity
const SNCBIPackedScoreMatrix NCBISM_Blosum90
Structure to hold the Karlin-Altschul parameters.
double K
K value used in statistics.
double Lambda
Lambda value used in statistics.
double H
H value used in statistics.
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