Extract FASTA
Generate FASTA file from indexed Genome FASTA file and BED file. Script will generate FAI index if not present in Genome FASTA folder.
File inputs (Genomic FASTA & BED)
BED files capture coordinate regions without the sequence information. This tool allows the user to search the FASTA file the BED file is based on and extract the sequence within the genomic region to a new FASTA-formatted file. The input FASTA is often a genome FASTA but as long as chrname column matches FASTA identifiers, it could be any FASTA.
When using the GUI, make sure your input is properly formatted and uses the appropriate BED (.bed or .bed.gz) and FASTA (.fa / .fa.gz / .fasta / ...) extensions.
Force Strandedness
This ensures that the DNA strand orientation from the BED file is used (otherwise sequence interval extracted from reference '+' strand).
FASTA Header ID Options
BED file specifications allow the user to specify an identifier for each coordinate in the file (fourth column) and this option allows the user to proceed with labeling each FASTA sequence with the value in the BED id column ("BED Name") or to create a new header based on the genomic sequence coordinate information ("Genome Coordinate").
Output format (FASTA)
For each input BED file, a new FASTA file is created with the coordinates using the input filename except with the file extension swapped for .fa.
Output GZip
Toggling this allows the user to write output to a compressed file format using a general compression (gzip) which has the added advantage of speeding up the execution time by shrinking the I/O load (esp for large output). The .gz extension will be appended as appropriate.
Command Line Interface
Usage:
java -jar ScriptManager.jar sequence-analysis fasta-extract [-cfhV] [-o=<output>]
<genomeFile> <bedFile>
Positional Input
The first positional input
| Option | Description |
|---|---|
<fastaFile> | reference genome FASTA file |
<bedFile> | the BED file of sequences to extract |
Output Options
| Option | Description |
|---|---|
-o, --output=<output> | Specify output file |
-z, --gzip | gzip output (default=false) |
Extract Options
| Option | Description |
|---|---|
-c, --coord-header | use genome coordinate for output FASTA header (default is to use bed file headers) |
-f, --force | force-strandedness (default) |