---
title: "06-GO-BLAST"
format: html
editor: visual
---
## Download NCBI Blast Software
```{r, engine='bash'}
# navigate to outside of git repo directory using relative paths
cd ../../
# make application directory (will throw an error if already made once
# comment out `mkdir applications` if this is the case)
# mkdir applications
# switch into applications directory
cd applications
# curl (download from the internet) the NCBI software
curl -O https://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/LATEST/ncbi-blast-2.13.0+-x64-linux.tar.gz
# tar unzip software with `tar -xf`
tar -xf ncbi-blast-2.13.0+-x64-linux.tar.gz
```
```{r, engine='bash'}
~/applications/ncbi-blast-2.13.0+/bin/blastx -h
```
```{r, engine='bash'}
# change into assignments/data directory
cd ../data
# download fasta.gz files from uniprot
curl -O https://ftp.uniprot.org/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz
# use the 'move' `mv` command to rename uniprot_sprot to include info on year & assignment number
mv uniprot_sprot.fasta.gz uniprot_sprot_r2023_01.fasta.gz
# unzip file (zipped by `gz`.. so unzip with `gunzip`..something something)
gunzip -k uniprot_sprot_r2023_01.fasta.gz
# list the files in the data directory to check that they are there with the right names
ls ../data
```