BLAST (Basic Local Alignment Search Tool)#

Runners#

class pyncbitk.algo.blast.Blast#

A base command object for running a BLAST search.

classmethod __new__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

__repr__()#

Return repr(self).

coverage_hsp#

Query coverage percentage per HSP.

Type:

float

culling_limit#

The culling limit for hits.

If the query range of a hit is enveloped by that of at least this many higher-scoring hits, delete the hit.

Type:

int

database_size#

The effective length of the database.

Type:

int

evalue#

Expectation value (E) threshold for saving hits.

Type:

float

gapped#

False if alignments are performed in ungapped mode only.

Type:

bool

max_target_sequences#

The maximum number of aligned sequences to retain.

Type:

int

off_diagonal_range#

The number of off-diagonals to search for the second hit.

Type:

int

percent_identity#

Percentage identity threshold for saving hits.

Type:

float

program#

The name of the BLAST program.

Type:

str

run#

Run a BLAST query with the given sequences.

Parameters:
  • queries (BioSeq, BioSeqSet, SearchQuery, SearchQueryVector) – The queries to use on the subject sequences.

  • (BioSeq (subjects) – DatabaseReader): The subjects sequences to search. A BLAST database can be given by passing a DatabaseReader object directly.

  • BioSeqSetDatabaseReader): The subjects sequences to search. A BLAST database can be given by passing a DatabaseReader object directly.

  • SearchQueryDatabaseReader): The subjects sequences to search. A BLAST database can be given by passing a DatabaseReader object directly.

  • SearchQueryVectorDatabaseReader): The subjects sequences to search. A BLAST database can be given by passing a DatabaseReader object directly.

:paramDatabaseReader): The subjects sequences to search. A BLAST

database can be given by passing a DatabaseReader object directly.

Parameters:

pairwise (bool) – Set to True to run the database search in pairwise mode, forcing BLAST to produce one SearchResults per query, even when no hits were found. Ignored when subjects is a DatabaseReader.

Returns:

SearchResultsSet – The list of search results, with one SearchResults item per query.

search_space#

The effective length of the search space.

Type:

int

window_size#

The window size for multiple hits.

Type:

int

xdrop_gap#

X-dropoff value (in bits) for preliminary gapped extensions.

Type:

float

xdrop_gap_final#

X-dropoff value (in bits) for final gapped alignment.

Type:

float

class pyncbitk.algo.blast.NucleotideBlast(Blast)#

A base command object for running a nucleotide BLAST search.

classmethod __new__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

class pyncbitk.algo.blast.ProteinBlast(Blast)#

A base command object for running a protein BLAST search.

classmethod __new__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

class pyncbitk.algo.blast.MappingBlast(Blast)#

A base command object for running a mapping BLAST search.

classmethod __new__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

class pyncbitk.algo.blast.BlastN(NucleotideBlast)#

A command object for running blastn searches.

classmethod __new__(*args, **kwargs)#
__init__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

dust_filtering#

Whether DUST filtering is enabled or not.

Type:

bool

penalty#

The (negative) score penalty for a nucleotide mismatch.

Type:

int

reward#

The (positive) score reward for a nucleotide match.

Type:

int

class pyncbitk.algo.blast.BlastP(ProteinBlast)#

A command object for running blastn searches.

classmethod __new__(*args, **kwargs)#
__init__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

word_size#

The word size for the wordfinder algorithm.

Type:

int

word_threshold#

The minimum score to record a word in the BLAST lookup table.

Type:

float

class pyncbitk.algo.blast.BlastX(NucleotideBlast)#

A command object for running blastx searches.

classmethod __new__(*args, **kwargs)#
__init__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

max_intron_length#

Largest allowed intron in a translated nucleotide sequence.

Type:

int

query_genetic_code#

Genetic code to use for translating the query sequences.

Type:

int

class pyncbitk.algo.blast.TBlastN(ProteinBlast)#

A command object for running tblastn searches.

classmethod __new__(*args, **kwargs)#
__init__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

database_genetic_code#

Genetic code to use for translating the database sequences.

Type:

int

max_intron_length#

Largest allowed intron in a translated nucleotide sequence.

Type:

int

Queries#

class pyncbitk.algo.blast.SearchQuery#
classmethod __new__(*args, **kwargs)#
__init__(*args, **kwargs)#
__reduce__()#

Helper for pickle.

class pyncbitk.algo.blast.SearchQueryVector#
classmethod __new__(*args, **kwargs)#
__init__(*args, **kwargs)#
__len__()#

Return len(self).

__reduce__()#

Helper for pickle.

Results#

class pyncbitk.algo.blast.SearchResultsSet#
classmethod __new__(*args, **kwargs)#
__getitem__(key, /)#

Return self[key].

__len__()#

Return len(self).

__reduce__()#

Helper for pickle.

class pyncbitk.algo.blast.SearchResults#
classmethod __new__(*args, **kwargs)#
__reduce__()#

Helper for pickle.