Blastn error, database creation problem, BLAST
2
1
Entering edit mode
6.6 years ago
biomagician ▴ 410

Hi,

I am trying to blast contigs to the C. elegans reference genome sequence with the following 2 commands:

makeblastdb -in celegans.fa -input_type fasta -dbtype nucl -title celRef -out celegans.db -taxid 6239

blastn -subject celegans.db -query celegans.contigs.fasta -out bristol.txt -outfmt 6 -html -num_threads 8

More details here:

 makeblastdb -in output/genome/celegans/ref/seq/celegans.fa -input_type fasta -dbtype nucl -title celRef -out output/genome/celegans/ref/database/celegans.db -taxid 6239

    Building a new DB, current time: 08/30/2017 16:35:01
    New DB name:   /Users/cr517/Documents/phd/project/output/genome/celegans/ref/database/celegans.db
    New DB title:  celRef
    Sequence type: Nucleotide
    Deleted existing Nucleotide BLAST database named /Users/cr517/Documents/phd/project/output/genome/celegans/ref/database/celegans.db
    Keep MBits: T
    Maximum file size: 1000000000B
    Adding sequences from FASTA; added 7 sequences in 1.03467 seconds.

  blastn -subject output/genome/celegans/ref/database/celegans.db -query output/assembly/celegans/canu/bristol/celegans.contigs.fasta -out output/alignment/celegans/ref/pacbio/contigs/canu/blastn/bristol.txt -outfmt 6 -html -num_threads 8
    Command line argument error: Argument "subject". File is not accessible:  `output/genome/celegans/ref/database/celegans.db'

But when I check with ls, I do have database files in my directory:

ls output/genome/celegans/ref/database 
        celegans.db.nhr celegans.db.nin celegans.db.nsq

I do not understand why the database is not accessible. Your help would be appreciated.

Thanks.

Best, C.

blast blastn database makeblastdb • 3.1k views
ADD COMMENT
2
Entering edit mode
6.6 years ago
h.mon 35k

You want to use -db /path/to/celegans.db. -subject is used for blasting two sequences against each other - I think both in fasta format.

ADD COMMENT
2
Entering edit mode
6.6 years ago
st.ph.n ★ 2.7k

Try providing the full path here:

output/genome/celegans/ref/database/celegans.db

What version of blast are you running? Change -subject to -db:

blastn -db celegans.db -query celegans.contigs.fasta -out bristol.txt -outfmt 6 -html -num_threads 8
ADD COMMENT
0
Entering edit mode

Hi,

I've changed it to -db and it is running now.

Thanks.

C.

ADD REPLY

Login before adding your answer.

Traffic: 2539 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6