NCBI C++ ToolKit
blast_format.hpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: blast_format.hpp 94643 2021-08-25 17:36:40Z jianye $
2 * ===========================================================================
3 *
4 * PUBLIC DOMAIN NOTICE
5 * National Center for Biotechnology Information
6 *
7 * This software/database is a "United States Government Work" under the
8 * terms of the United States Copyright Act. It was written as part of
9 * the author's offical duties as a United States Government employee and
10 * thus cannot be copyrighted. This software/database is freely available
11 * to the public for use. The National Library of Medicine and the U.S.
12 * Government have not placed any restriction on its use or reproduction.
13 *
14 * Although all reasonable efforts have been taken to ensure the accuracy
15 * and reliability of the software and data, the NLM and the U.S.
16 * Government do not and cannot warrant the performance or results that
17 * may be obtained by using this software or data. The NLM and the U.S.
18 * Government disclaim all warranties, express or implied, including
19 * warranties of performance, merchantability or fitness for any particular
20 * purpose.
21 *
22 * Please cite the author in any work or product based on this material.
23 *
24 * ===========================================================================*/
25 
26 /*****************************************************************************
27 
28 Author: Jason Papadopoulos
29 
30 ******************************************************************************/
31 
32 /** @file blast_format.hpp
33  * Produce formatted blast output for command line applications
34 */
35 
36 #ifndef ALGO_BLAST_FORMAT___BLAST_FORMAT__HPP
37 #define ALGO_BLAST_FORMAT___BLAST_FORMAT__HPP
38 
39 #include <corelib/ncbi_limits.hpp>
59 
60 
62 USING_SCOPE(align_format);
64 
65 /// This class formats the BLAST results for command line applications
67 {
68 public:
69 
70  ///igblast clone info
71  struct SClone {
72  string na;
73  string chain_type;
74  string aa;
75  string v_gene;
76  string d_gene;
77  string j_gene;
78  string c_gene;
79  string seqid;
80  double identity;
81  string productive;
82  };
83 
84  enum {
85  /// The line length of pairwise blast output
86  kFormatLineLength = 68,
87  kMinTaxFormatLineLength = 100
88  };
89 
90  ///Display options for blast_report
95  eDescriptionsWithTemplates // this option is not implemented in blast_report
96  };
97  /// Constructor
98  /// @param opts BLAST options used in the search [in]
99  /// @param db_adapter Adapter object representing a BLAST database or
100  /// subject sequences [in]
101  /// @param format_type enumeration that specifies the requested type of output [in]
102  /// @param believe_query set to true if sequence IDs of query sequences
103  /// are to be parsed. If multiple queries are provieded,
104  /// their sequence ID's must be distinct. If you don't know
105  /// what this means, set to false [in]
106  /// @param outfile Stream that will receive formatted output
107  /// @param num_summary The number of 1-line summaries at the top of
108  /// the blast report (for output types that have
109  /// 1-line summaries). Default value for the BLAST
110  /// programs is align_format::kDfltArgNumDescriptions [in]
111  /// @param num_alignments The number of alignments to display in the BLAST
112  /// report. Default value for the BLAST programs is
113  /// align_format::kDfltArgNumAlignments [in]
114  /// @param scope The scope to use for retrieving sequence data
115  /// (must contain query and database sequences) [in]
116  /// @param matrix_name Name of protein score matrix (BLOSUM62 if
117  /// empty, ignored for nucleotide formatting) [in]
118  /// @param show_gi When printing database sequence identifiers,
119  /// include the GI number if set to true; otherwise
120  /// database sequences only have an accession [in]
121  /// @param is_html true if the output is to be in HTML format [in]
122  /// @param qgencode Genetic code used to translate query sequences
123  /// (if applicable) [in]
124  /// @param dbgencode Genetic code used to translate database sequences
125  /// (if applicable) [in]
126  /// @param use_sum_statistics Were sum statistics used in this search? [in]
127  /// @param is_remote_search is this formatting the results of a remote
128  /// search [in]
129  /// @param dbfilt_algorithm BLAST database filtering algorithm ID (if
130  /// applicable), value of -1 means not available [in]
131  /// @param is_megablast true if megablast [in]
132  /// @param is_indexed true if indexed search [in]
133  /// @param custom_output_format custom output format specification for
134  /// tabular/comma-separated value output format. An empty string implies to
135  /// use the default value when applicable. [in]
136  /// @param domain_db_adapter Domain database for Delta-blast [in]
137  /// @param cmdline Actual command-line for SAM [in]
138  /// @param subjectTag Identifier for set of subjects [in]
139  CBlastFormat(const blast::CBlastOptions& opts,
140  blast::CLocalDbAdapter& db_adapter,
142  bool believe_query, CNcbiOstream& outfile,
143  int num_summary,
144  int num_alignments,
145  CScope & scope,
146  const char *matrix_name = BLAST_DEFAULT_MATRIX,
147  bool show_gi = false,
148  bool is_html = false,
149  int qgencode = BLAST_GENETIC_CODE,
150  int dbgencode = BLAST_GENETIC_CODE,
151  bool use_sum_statistics = false,
152  bool is_remote_search = false,
153  int dbfilt_algorithm = -1,
154  const string& custom_output_format = kEmptyStr,
155  bool is_megablast = false,
156  bool is_indexed = false,
157  const blast::CIgBlastOptions * ig_opts = NULL,
158  const blast::CLocalDbAdapter* domain_db_adapter = NULL,
159  const string & cmdline = kEmptyStr,
160  const string& subjectTag = kEmptyStr);
161 
162  /// Constructor
163  /// @param opts BLAST options used in the search [in]
164  /// @param dbinfo_list Database info list, provided directly [in]
165  /// @param format_type Integer indication the type of output [in]
166  /// @param believe_query set to true if sequence IDs of query sequences
167  /// are to be parsed. If multiple queries are provieded,
168  /// their sequence ID's must be distinct. If you don't know
169  /// what this means, set to false [in]
170  /// @param outfile Stream that will receive formatted output
171  /// @param num_summary The number of 1-line summaries at the top of
172  /// the blast report (for output types that have
173  /// 1-line summaries). Default value for the BLAST
174  /// programs is align_format::kDfltArgNumDescriptions [in]
175  /// @param num_alignments The number of alignments to display in the BLAST
176  /// report. Default value for the BLAST programs is
177  /// align_format::kDfltArgNumAlignments [in]
178  /// @param scope The scope to use for retrieving sequence data
179  /// (must contain query and database sequences) [in]
180  /// @param show_gi When printing database sequence identifiers,
181  /// include the GI number if set to true; otherwise
182  /// database sequences only have an accession [in]
183  /// @param is_html true if the output is to be in HTML format [in]
184  /// @param is_remote_search is this formatting the results of a remote
185  /// search [in]
186  /// @param custom_output_format custom output format specification for
187  /// tabular/comma-separated value output format. An empty string implies to
188  /// use the default value when applicable. [in]
189  CBlastFormat(const blast::CBlastOptions& opts,
190  const vector< CBlastFormatUtil::SDbInfo >& dbinfo_list,
192  bool believe_query, CNcbiOstream& outfile,
193  int num_summary,
194  int num_alignments,
195  CScope & scope,
196  bool show_gi = false,
197  bool is_html = false,
198  bool is_remote_search = false,
199  const string& custom_output_format = kEmptyStr,
200  bool is_vdb = false,
201  const string & cmdline = kEmptyStr);
202 
203  /// Class destructor
204  ~CBlastFormat();
205 
206  /// Print the header of the blast report
207  void PrintProlog();
208 
209  /// Get total length of the database
210  Int8 GetDbTotalLength();
211 
212  /// Print all alignment information for a single query sequence along with
213  /// any errors or warnings (errors are deemed fatal)
214  /// @param results Object containing alignments, mask regions, and
215  /// ancillary data to be output [in]
216  /// @param queries Query sequences (cached for XML formatting) [in]
217  /// @param itr_num iteration number, if applicable, otherwise it should be
218  /// numeric_limits<unsigned int>::max() [in]
219  /// @param prev_seqids list of previously found Seq-ids, if applicable,
220  /// otherwise it should be an empty list [in]
221  /// @param is_deltablast_domain_result True if Delta-blast CDD search
222  /// results are being formatted [in]
223  void PrintOneResultSet(const blast::CSearchResults& results,
225  unsigned int itr_num =
227  blast::CPsiBlastIterationState::TSeqIds prev_seqids =
228  blast::CPsiBlastIterationState::TSeqIds(),
229  bool is_deltablast_domain_result = false);
230 
231  /// Print all Ig alignment information for a single query sequence along with
232  /// any errors or warnings (errors are deemed fatal)
233  /// @param results Object containing alignments, mask regions, and
234  /// ancillary data to be output [in]
235  /// @param queries Query sequences (cached for XML formatting) [in]
236  /// @param result position index if index >= 0 [in]
237  void PrintOneResultSet(blast::CIgBlastResults& results,
239  SClone& clone_info,
240  bool fill_clone_info,
241  bool print_airr_format_header,
242  int index = -1);
243 
244  /// Print all alignment information for aa PHI-BLAST run.
245  /// any errors or warnings (errors are deemed fatal)
246  /// @param result_set Object containing alignments, mask regions, and
247  /// ancillary data to be output [in]
248  /// @param queries Query sequences (cached for XML formatting) [in]
249  /// @param itr_num iteration number, if applicable, otherwise it should be
250  /// numeric_limits<unsigned int>::max() [in]
251  /// @param prev_seqids list of previously found Seq-ids, if applicable,
252  /// otherwise it should be an empty list [in]
253  void PrintPhiResult(const blast::CSearchResultSet& result_set,
255  unsigned int itr_num =
257  blast::CPsiBlastIterationState::TSeqIds prev_seqids =
258  blast::CPsiBlastIterationState::TSeqIds());
259 
260  ///Print Metadata in json format or descriptions in html format or alignments in html format
261  ///app.ini file with template info must be present
262  /// @param results Object containing alignments, mask regions, and
263  /// ancillary data to be output [in]
264  /// @param displayOption indicates what info to display
265  void PrintReport(const blast::CSearchResults& results,
266  CBlastFormat::DisplayOption displayOption);
267 
268 
269  /// Writes out the query and results as an "archive" format
270  /// @param queries Query factory to provide queries
271  /// @param options_handle BLAST options
272  /// @param results the search results
273  /// @param num_iters number of iterations for psiblast
274  void WriteArchive(blast::IQueryFactory& queries,
275  blast::CBlastOptionsHandle& options_handle,
276  const blast::CSearchResultSet& results,
277  unsigned int num_iters = 0,
278  const list<CRef<objects::CBlast4_error> >& msg = list<CRef<objects::CBlast4_error> > () );
279 
280  /// Writes out the pssm and results as an "archive" format
281  /// @param pssm psiblast pssm
282  /// @param options_handle BLAST options
283  /// @param results the search results
284  /// @param num_iter number of iterations for psiblast
285  void WriteArchive(objects::CPssmWithParameters & pssm,
286  blast::CBlastOptionsHandle& options_handle,
287  const blast::CSearchResultSet& results,
288  unsigned int num_iters = 0,
289  const list<CRef<objects::CBlast4_error> > & msg = list<CRef<objects::CBlast4_error> >());
290 
291  /// Print the footer of the blast report
292  /// @param options Options used for performing the blast search [in]
293  ///
294  void PrintEpilog(const blast::CBlastOptions& options);
295 
296  /// Resets the scope history for some output formats.
297  ///
298  /// This method tries to release memory no longer needed after
299  /// each query sequence is processed. For XML formatting, all
300  /// data must be kept until the Epilog stage, so for XML this
301  /// method has no effect. Searches with multiple queries will
302  /// therefore require more memory to produce XML format output
303  /// than when using other output formats.
304  void ResetScopeHistory();
305 
306  /// Set query range
307  /// @param query_range query range [in]
308 
309  void SetQueryRange(const TSeqRange & query_range) { m_QueryRange = query_range; }
310 
311  /// Get query range
312  TSeqRange GetQueryRange(void) { return m_QueryRange; }
313 
314  /// For use by XML2 only
315  void SetBaseFile(string base) {m_BaseFile = base;}
316 
317  /// Set Alignment Length
318  void SetLineLength(size_t len) {m_LineLength = len;}
319  void SetAlignSeqList(string alignSeqList) {m_AlignSeqList = alignSeqList;}
320  void SetHitsSortOption(int hitsSortOption) {m_HitsSortOption = hitsSortOption;}
321  void SetHspsSortOption(int hspsSortOption) {m_HspsSortOption = hspsSortOption;}
322  void SetCustomDelimiter(string customDelim) {m_CustomDelim = customDelim;}
323 
324 
325 
326  static void PrintArchive(CRef<objects::CBlast4_archive> archive,
327  CNcbiOstream& out);
328 
329  // Extract search info in CBlastFormat and add to blast report usage
330  void LogBlastSearchInfo(blast::CBlastUsageReport & report);
331 
332 private:
333  /// Format type
335  bool m_IsHTML; ///< true if HTML output desired
336  bool m_DbIsAA; ///< true if database has protein sequences
337  bool m_BelieveQuery; ///< true if query sequence IDs are parsed
338  CNcbiOstream& m_Outfile; ///< stream to receive output
339  int m_NumSummary; ///< number of 1-line summaries
340  int m_NumAlignments; ///< number of database sequences to present alignments for.
341  int m_HitlistSize; ///< number of database sequences to save results for
342  string m_Program; ///< blast program
343  string m_DbName; ///< name of blast database
344  int m_QueryGenCode; ///< query genetic code
345  int m_DbGenCode; ///< database genetic code
346  bool m_ShowGi; ///< add GI number of database sequence IDs
347  /// If the output format supports 1-line summaries, the search is ungapped
348  /// and the alignments have had HSP linking performed, append the number of
349  /// hits in the linked set of the best alignment to each database sequence
351  bool m_IsUngappedSearch; ///< true if the search was ungapped
352  const char* m_MatrixName; ///< name of scoring matrix
353  /** Scoring matrix instantiated from m_MatrixName */
355  /** Scope containing query and subject sequences */
357  /** True if we are formatting for BLAST2Sequences */
358  bool m_IsBl2Seq;
359  /// True if it is m_IsBl2Seq in dbscan mode
361  /// Tag for subject sequences (e.g., name of input file)
362  string m_SubjectTag;
363  /// True if this object is formatting the results of a remote search
365  /// Used to count number of searches formatted.
367 
368  bool m_Megablast; ///< true if megablast was used.
369  bool m_IndexedMegablast; ///< true if indexed megablast was used.
370  /// Used to retrieve subject sequence information
372 
373  /// internal representation of database information
374  vector<CBlastFormatUtil::SDbInfo> m_DbInfo;
375 
377 
378  /// Queries are required for XML format only
380  /// Accumulated results to display in XML format
381  blast::CSearchResultSet m_AccumulatedResults;
382  /// Modify format to accomodate results that do not
383  /// contain KA stats such as bitscores and evalues. -RMH-
385  /// The custom output format specification
387 
388  /// Structure for incremental XML BLAST output.
390 
391  /// Used by Igblast formatting.
393 
394  /// Information about DELTA-BLAST domain database
395  vector<CBlastFormatUtil::SDbInfo> m_DomainDbInfo;
396 
397  /// BLAST options
399 
400  /// Flag indicate vdb search
401  bool m_IsVdb;
402 
404 
406 
407  string m_BaseFile;
409 
410  size_t m_LineLength;
411 
412  IOS_BASE::iostate m_OrigExceptionMask;
413 
414  /// Pointer to the SAM formatting object
415  unique_ptr<CBlast_SAM_Formatter> m_SamFormatter;
416 
417  string m_Cmdline;
418 
419  /// If true, print long sequence ids (database|accession)
421 
422 
426 
430 
431  /// Output the ancillary data for one query that was searched
432  /// @param summary The ancillary data to report [in]
433  void x_PrintOneQueryFooter(const blast::CBlastAncillaryData& summary);
434 
435  /// Display the BLAST deflines in the traditional BLAST report
436  /// @param aln_set alignments to display [in]
437  /// @param itr_num iteration number, if applicable, otherwise it should be
438  /// numeric_limits<unsigned int>::max() [in]
439  /// @param prev_seqids list of previously found Seq-ids, if applicable,
440  /// otherwise it should be an empty list [in]
441  /// @param additional show additional aligment summary [in]
442  /// @param index add result postition index to quick url link on score if index >=0 [in]
443  void x_DisplayDeflines(CConstRef<CSeq_align_set> aln_set,
444  unsigned int itr_num,
445  blast::CPsiBlastIterationState::TSeqIds& prev_seqids,
446  int additional = 0,
447  int index = -1,
448  int defline_length = -1);
449 
450  /// Split the full alignment into two sets of alignments: one for those
451  /// seen in the previous iteration and used to build the PSSM and the other
452  /// for newly found sequences. Only applicable to PSI-BLAST.
453  /// @param full_alignment results of the PSI-BLAST search [in]
454  /// @param repeated_seqs object where the repeated alignments will be
455  /// copied to [in|out]
456  /// @param new_seqs object where the newly found sequence alignments will
457  /// be copied to [in|out]
458  /// @param prev_seqids list of previosly found seqids [in]
459  void x_SplitSeqAlign(CConstRef<CSeq_align_set> full_alignment,
460  CSeq_align_set& repeated_seqs,
461  CSeq_align_set& new_seqs,
462  blast::CPsiBlastIterationState::TSeqIds& prev_seqids);
463 
464  /// Configure the CShowBlastDefline instance passed to it
465  /// @param showdef CShowBlastDefline object to configure [in|out]
466  /// @param skip_from skipping display from [in]
467  /// @param skip_to skipping display to [in]
468  /// @param index to add index (if >=0)to quick url link to score [in]
469  /// @param int num_descriptions_to_show the number of descriptions to show,
470  /// this controls whether the header in the descriptions section is shown
471  /// or not: if its value is non-zero it's shown, otherwise it isn't [in]
472  void x_ConfigCShowBlastDefline(align_format::CShowBlastDefline& showdef,
473  int skip_from = -1,
474  int skip_to = -1,
475  int index = -1,
476  int num_descriptions_to_show = -1);
477 
478  /// Prints XML and both species of ASN.1
479  /// @param results Results for one query or Phi-blast iteration [in]
480  /// @param queries Bioseqs to be formatted (for XML) [in]
481  void x_PrintStructuredReport(const blast::CSearchResults& results,
483 
484  /// Prints Tabular report for one query
485  /// @param results Results for one query or Phi-blast iteration [in]
486  /// @param itr_num Iteration number for PSI-BLAST [in]
487  void x_PrintTabularReport(const blast::CSearchResults& results,
488  unsigned int itr_num);
489 
490  /// Prints IgTabular report for one query
491  /// @param results Results for one query or Phi-blast iteration [in]
492  void x_PrintIgTabularReport(const blast::CIgBlastResults& results,
493  SClone& clone_info,
494  bool fill_clone_info);
495 
496  /// Prints AirrRearrangement format
497  /// @param results Results for one query or Phi-blast iteration [in]
498  void x_PrintAirrRearrangement(const blast::CIgBlastResults& results,
499  SClone& clone_info,
500  bool fill_clone_info,
501  bool print_airr_format_header);
502 
503 
504  /// Replace the query with its reversed-compliement
505  /// @param results Ig Blast results [in, out]
506  void x_ReverseQuery(blast::CIgBlastResults& results);
507 
508  /// Creates a bioseq to be able to print the acknowledgement for the
509  /// subject bioseq when formatting bl2seq results
510  /// @note this method contains a static variable that assumes the order of
511  /// the calls to it to retrieve the proper subject sequence
512  CConstRef<objects::CBioseq> x_CreateSubjectBioseq();
513 
514  /// Wrap the Seq-align-set to be printed in a Seq-annot (as the C toolkit
515  /// binaries)
516  /// @param alnset Alignment to wrap in a Seq-annot, must be non-NULL [in]
518  x_WrapAlignmentInSeqAnnot(CConstRef<objects::CSeq_align_set> alnset,
519  const string& db_title) const;
520 
521  // Return true if the search is againist vdb databases
522  bool x_IsVdbSearch()const;
523 
524  void x_PrintXML2Report(const blast::CSearchResults& results,
526 
527  void x_GenerateXML2MasterFile(void);
528  void x_GenerateJSONMasterFile(void);
529  void x_WriteXML2(CCmdLineBlastXML2ReportData & report_data);
530 
531  void x_InitSAMFormatter();
532  void x_PrintTaxReport(const blast::CSearchResults& results);
533  void x_InitDeflineTemplates(void);
534  void x_InitAlignTemplates(void);
535  void x_DisplayDeflinesWithTemplates(CConstRef<CSeq_align_set> aln_set);
536  void x_SetAlignParameters(CDisplaySeqalign& cds);
537  void x_DisplayAlignsWithTemplates(CConstRef<CSeq_align_set> aln_set,const blast::CSearchResults& results);
538  //Creates json object array of info for each defline to display
539  void x_CreateDeflinesJson(CConstRef<CSeq_align_set> aln_set);
540 };
541 
543 
544 #endif /* ALGO_BLAST_FORMAT___BLAST_FORMAT__HPP */
545 
USING_SCOPE(align_format)
BLAST formatter utilities.
Sequence alignment display tool.
Declares class to display one-line descriptions at the top of the BLAST report.
Formatting of pairwise sequence alignments in tabular form.
Interface for converting blast-related command line arguments into blast options.
Interface for converting sources of sequence data into blast sequence input.
#define BLAST_DEFAULT_MATRIX
Default matrix name: BLOSUM62.
Definition: blast_options.h:77
#define BLAST_GENETIC_CODE
Default genetic code for query and/or database.
Definition of classes which constitute the results of running a BLAST search.
Defines interface for retrieving sequence identifiers.
Declaration of ADT to retrieve sequences for the BLAST engine.
BLAST usage report api.
This class formats the BLAST results for command line applications.
size_t m_LineLength
TSeqRange m_QueryRange
blast::CFormattingArgs::EOutputFormat m_FormatType
Format type.
string m_SubjectTag
Tag for subject sequences (e.g., name of input file)
bool m_IsVdb
Flag indicate vdb search.
CConstRef< blast::CIgBlastOptions > m_IgOptions
Used by Igblast formatting.
string m_CustomOutputFormatSpec
The custom output format specification.
vector< CBlastFormatUtil::SDbInfo > m_DomainDbInfo
Information about DELTA-BLAST domain database.
void SetHitsSortOption(int hitsSortOption)
void SetHspsSortOption(int hspsSortOption)
bool m_IsUngappedSearch
true if the search was ungapped
CRef< SBlastXMLIncremental > m_BlastXMLIncremental
Structure for incremental XML BLAST output.
CRef< blast::IBlastSeqInfoSrc > m_SeqInfoSrc
Used to retrieve subject sequence information.
CRef< blast::CSearchDatabase > m_SearchDb
CRef< CScope > m_Scope
Scope containing query and subject sequences.
bool m_IsBl2Seq
True if we are formatting for BLAST2Sequences.
void SetCustomDelimiter(string customDelim)
void WriteArchive(objects::CPssmWithParameters &pssm, blast::CBlastOptionsHandle &options_handle, const blast::CSearchResultSet &results, unsigned int num_iters=0, const list< CRef< objects::CBlast4_error > > &msg=list< CRef< objects::CBlast4_error > >())
Writes out the pssm and results as an "archive" format.
const char * m_MatrixName
name of scoring matrix
bool m_IsRemoteSearch
True if this object is formatting the results of a remote search.
void SetBaseFile(string base)
For use by XML2 only.
int m_DbGenCode
database genetic code
int m_NumAlignments
number of database sequences to present alignments for.
void SetLineLength(size_t len)
Set Alignment Length.
void SetAlignSeqList(string alignSeqList)
bool m_DbIsAA
true if database has protein sequences
bool m_ShowGi
add GI number of database sequence IDs
TSeqRange GetQueryRange(void)
Get query range.
CShowBlastDefline::SDeflineTemplates * m_DeflineTemplates
CConstRef< blast::CBlastOptions > m_Options
BLAST options.
DisplayOption
Display options for blast_report.
int m_HitlistSize
number of database sequences to save results for
string m_Program
blast program
int m_QueryGenCode
query genetic code
int m_QueriesFormatted
Used to count number of searches formatted.
CNcbiOstream & m_Outfile
stream to receive output
vector< CBlastFormatUtil::SDbInfo > m_DbInfo
internal representation of database information
void WriteArchive(blast::IQueryFactory &queries, blast::CBlastOptionsHandle &options_handle, const blast::CSearchResultSet &results, unsigned int num_iters=0, const list< CRef< objects::CBlast4_error > > &msg=list< CRef< objects::CBlast4_error > >())
Writes out the query and results as an "archive" format.
int m_NumSummary
number of 1-line summaries
bool m_IsHTML
true if HTML output desired
bool m_DisableKAStats
Modify format to accomodate results that do not contain KA stats such as bitscores and evalues.
bool m_Megablast
true if megablast was used.
CNcbiMatrix< int > m_ScoringMatrix
Scoring matrix instantiated from m_MatrixName.
CDisplaySeqalign::SAlignTemplates * m_AlignTemplates
string m_DbName
name of blast database
bool m_IndexedMegablast
true if indexed megablast was used.
bool m_LongSeqId
If true, print long sequence ids (database|accession)
string m_AlignSeqList
CRef< blast::CBlastQueryVector > m_AccumulatedQueries
Queries are required for XML format only.
bool m_ShowLinkedSetSize
If the output format supports 1-line summaries, the search is ungapped and the alignments have had HS...
string m_CustomDelim
IOS_BASE::iostate m_OrigExceptionMask
bool m_BelieveQuery
true if query sequence IDs are parsed
unique_ptr< CBlast_SAM_Formatter > m_SamFormatter
Pointer to the SAM formatting object.
bool m_IsDbScan
True if it is m_IsBl2Seq in dbscan mode.
blast::CSearchResultSet m_AccumulatedResults
Accumulated results to display in XML format.
void SetQueryRange(const TSeqRange &query_range)
Set query range.
Strategy class to gather the data for generating BLAST XML output.
CConstRef –.
Definition: ncbiobj.hpp:1266
CObject –.
Definition: ncbiobj.hpp:180
CRef –.
Definition: ncbiobj.hpp:618
CScope –.
Definition: scope.hpp:92
std::ofstream out("events_result.xml")
main entry point for tests
EOutputFormat
Definition: grid_cli.hpp:276
#define NULL
Definition: ncbistd.hpp:225
int64_t Int8
8-byte (64-bit) signed integer
Definition: ncbitype.h:104
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
IO_PREFIX::ostream CNcbiOstream
Portable alias for ostream.
Definition: ncbistre.hpp:149
#define kEmptyStr
Definition: ncbistr.hpp:123
#define NCBI_XBLASTFORMAT_EXPORT
Definition: ncbi_export.h:1073
Declares CIgBlast, the C++ API for the IG-BLAST engine.
int len
Declares class which provides internal BLAST database representations to the internal BLAST APIs.
T max(T x_, T y_)
static FILE * outfile
Definition: pcretest.c:1033
Defines class which represents the iteration state in PSI-BLAST.
Formatting of pairwise sequence alignments in SAM form.
NOTE: This file contains work in progress and the APIs are likely to change, please do not rely on th...
Definition of SSeqLoc structure.
igblast clone info
Sequence alignment taxonomy display tool.
Uniform BLAST Search Interface.
Modified on Thu Jul 18 16:06:49 2024 by modify_doxy.py rev. 669887