Entering edit mode
6.9 years ago
maximilian.mayerhofer
▴
30
Hello,
I have a Folder containing multiple genomes as .fasta files.
strainA.fasta
strainB.fasta
strainC.fasta
....
I have set up a local blast db called "dbGOI.fasta"
I want to blast all the genomes against my local db.
for file in dir
do
blastn -in *.fasta -db dbGOI.fasta -out blast[strainname].txt
done
But as you might guess, it does not work as intended.
It should be something like:
For explanation: the variable yyou use to loop is called file. You call this variable in with $file . to get the name of the fasta without the file-ending you call basename with the variable and the ending you want to remove. with $() you use the output of basename as a string.
I just don't know if it is -in or -query in the blastn function