Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
standalone_blast [2012/05/17 19:49]
anniearchambault created
standalone_blast [2014/11/21 19:43] (current)
sebastien.renaut
Line 1: Line 1:
 +===== Install BLAST+ locally. =====
 +Find and install the latest version that corresponds to your operating system (MAC, Windows, Linux): ftp://​ftp.ncbi.nlm.nih.gov/​blast/​executables/​LATEST/​
  
 +### DOWNLOAD A PREFORMATED DATABASE FROM NCBI###
 +  *download the protein nr database
 +<​code>​
 +$ update_blastdb.pl nr
 +</​code>​
 +  *The database is in *tar.gz format which needs to be unzipped like this: 
 +<​code>​
 +$ tar -xvzf *tar.gz
 +</​code>​
  
-===Sequence searches using standalone BLAST===+### MAKE A REFERENCE DATABASE ### 
 +  *this is to generate your own reference database from your own fasta file (either nucleotide or protein) 
 +<​code>​ 
 +$ makeblastdb -dbtype nucl -in genes1_fas_pathway.txt 
 +</​code>​ 
 +OR 
 +<​code>​ 
 +$ makeblastdb -dbtype prot -in Plantcyc_Enzymes_Without_Tags_BLASTset.fasta 
 +</​code>​ 
 + 
 +### BLASTn ### 
 +  *BLASTn (nucleotide against nucleotide) with discontiguous megablast, usually for distant interspecific relationships. 
 +  *Mininum e-value to report result set as 1e-10 
 +  *report a maximum of 100 target sequences 
 +  *output format is in XML format (5), (tabular ouput: 6, 0: “web-like” output, default) 
 +  *blast is run on 12 CPUs simultaneously 
 +<​code>​ 
 +$ blastn -task dc-megablast -evalue 1e-10 -max_target_seqs 100 -query mygenes.fasta -db nr -num_threads 12 -outfmt 5 -out mygenes.blast.out 
 +</​code>​ 
 +### BLASTn ### 
 +  *with tabular output (outfmt 6) 
 +<​code>​ 
 +$ blastn -task dc-megablast -evalue 1e-10 -max_target_seqs 5 -query mygenes.fasta -db database/​ara_pathway/​genes1_fas_pathway.txt -num_threads 4 -outfmt 6 -out mygenes.blast.out 
 +</​code>​ 
 + 
 +### BLASTn – short sequences ### 
 +  *short sequences option 
 +  *run it with a nohup command (i.e run it in the background and continue performing other tasks without the risk of session interrupting) 
 +<​code>​ 
 +$ nohup blastn -task blastn-short -evalue 1e-5 -max_target_seqs 20 -query mygenes.fasta -db ../​../​blast/​database/​all_mito_sequences_e50 -num_threads 8 -outfmt 6 -out mygenes.blast.out > log & 
 +</​code>​ 
 + 
 +### BLASTx with nohup### 
 +  *Blastx translate your sequence in all 6 possible framework and searches a protein databases. 
 +<​code>​ 
 +$ nohup blastx -evalue 1e-10 -max_target_seqs 5 -query mygenes.fasta -db database/​ara_pathway/​Plantcyc_Enzymes_Without_Tags_BLASTset.fasta -num_threads 6 -outfmt 6 -out mygenes.blast.out > log & 
 +</​code>​ 
 + 
 +### BLASTp with gi restriction###​ 
 +  *protein against protein 
 +  *gi_viridiplantae contains a list of all GI for all viriplantae. This speeds things up a lot since it restrict the search to plants only. 
 +<​code>​ 
 +$ blastp -query mygenes.fasta -db ~/​blast/​database/​ncbi_nr/​nr -gilist gi_viridiplantae -outfmt 4 -out mygenes.blast.out 
 +</​code>​ 
 +  *To get a GI list, go to http://​www.ncbi.nlm.nih.gov/​ 
 +  *Search for "​viridiplantae"​ in "​protein"​ database. 
 +  *Download all GI (top right, >send to, >choose destination file, >format gilist, >create file) 
 + 
 +===== More examples ===== 
 +###Sequence searches using standalone BLAST
 In January 2011, Annie Archambault (research professional at the [[http://​qcbs.ca/​|QCBS]]) and [[http://​www.bio.umontreal.ca/​personnel/​CAMERON_Christopher/​index.html|Christopher Cameron]] (professor at Université de Montréal) set up a sequence similarity between 451 spicule matrix proteins from the sea urchin (Strongylocentrotus purpuratus, an echinoderm) that are involved in biomineralization ((Mann K, Wilt FH, Poustka AJ (2010) Proteomic analysis of sea urchin (Strongylocentrotus purpuratus) spicule matrix. Proteome Science 8 DOI 33 10.1186/​1477-5956-8-33)) and the genome of //​Saccoglossus kowlevskii//​ (a hemichordate that forms biominerals) and //Ciona// (a hemichordate that do not form biominerals).  ​ In January 2011, Annie Archambault (research professional at the [[http://​qcbs.ca/​|QCBS]]) and [[http://​www.bio.umontreal.ca/​personnel/​CAMERON_Christopher/​index.html|Christopher Cameron]] (professor at Université de Montréal) set up a sequence similarity between 451 spicule matrix proteins from the sea urchin (Strongylocentrotus purpuratus, an echinoderm) that are involved in biomineralization ((Mann K, Wilt FH, Poustka AJ (2010) Proteomic analysis of sea urchin (Strongylocentrotus purpuratus) spicule matrix. Proteome Science 8 DOI 33 10.1186/​1477-5956-8-33)) and the genome of //​Saccoglossus kowlevskii//​ (a hemichordate that forms biominerals) and //Ciona// (a hemichordate that do not form biominerals).  ​
  
Line 7: Line 67:
  
  
-==Parsing the Blast output file==+===Parsing the Blast output file===
 The output file from the 451 sequences was too large to be easily understood. We developed a small script in R to parse the blast output file, and kept only the best match: the one hit that has the minimum e-value, for each query sequence. The {{:​unique_lowest_evalue.r|Blast parser in R}} for tab delimited blast result files is available here, and was inspired by a [[http://​seqanswers.com/​forums/​showthread.php?​t=9052|forum post]].  ​ The output file from the 451 sequences was too large to be easily understood. We developed a small script in R to parse the blast output file, and kept only the best match: the one hit that has the minimum e-value, for each query sequence. The {{:​unique_lowest_evalue.r|Blast parser in R}} for tab delimited blast result files is available here, and was inspired by a [[http://​seqanswers.com/​forums/​showthread.php?​t=9052|forum post]].  ​
  
Line 26: Line 86:
   -Make sure the number and the order of arguments are correct because an existing file will be overwritten if given the same name as your new output file.    -Make sure the number and the order of arguments are correct because an existing file will be overwritten if given the same name as your new output file. 
   -That script currently does not keep the headings of the columns, any improvement is welcome. ​   -That script currently does not keep the headings of the columns, any improvement is welcome. ​
- 
- 
- 
- 
  
 ===References=== ===References===
- 
- 
-