bb_create_blast_db - ampinzonv/BB3 GitHub Wiki
bb_create_blast_db
Function: Create a BLAST database from a FASTA file using makeblastdb
.
๐ Description
This function generates a BLAST database from a given FASTA file. It automatically detects whether the sequences are nucleotide or protein and uses that to configure makeblastdb
.
๐ฅ Input
- A FASTA file with nucleotide or protein sequences.
๐ค Output
- A set of files forming a BLAST database (e.g.,
.nsq
,.nin
,.nhr
or.psq
,.pin
,.phr
).
๐งช Examples
Create a nucleotide database:
bb_create_blast_db --input genome.fasta
Create a protein database in a custom directory:
bb_create_blast_db --input proteins.fasta --outdir blastdb/ --db_name mydb
Dry run (show command only):
bb_create_blast_db --input sequences.fasta --dry_run
โ๏ธ Usage
bb_create_blast_db --input FILE [--outdir DIR] [--db_name NAME] [--title TITLE] [--dry_run] [--quiet] [--force]
๐งต Options
Option | Description |
---|---|
--input FILE |
Input FASTA file (required) |
--outdir DIR |
Output directory (default: current directory) |
--db_name NAME |
Name of the BLAST database (default: derived from input file name) |
--title TITLE |
Human-readable title (default: derived from input) |
--dry_run |
Print the command instead of executing it |
--quiet |
Suppress informational messages |
--force |
Overwrite existing database files |
๐ Notes
- The function uses
bb_guess_sequence_type
to auto-detect if the database is nucleotide or protein. - Compatible with downstream functions like
bb_run_blast
.