Aidan Coyle, afcoyle@uw.edu
Originally written 2021/03/10 Roberts Lab, UW-SAFS
Written for analysis of Hematodinium differential gene expression
This is used to obtain gene ontology (GO) terms from accession IDs.
To run this script, you must have the following:
A recently-downloaded, uncompressed copy of the Swiss-Prot database, with all GO terms included - available at https://www.uniprot.org/uniprot/
A newline-separated file of accession IDs
library(tidyverse)
source("hematodinium_analysis_functions.R")
This script utilizes a function I created - uniprot_to_GO() - available in hematodinium_analysis_functions.R
Inputs:
accession_path: A newline-separated file of accession IDs
swissprot_path: path to a downloaded uncompressed copy of the SwissProt database with all GO terms included, available at https://www.uniprot.org/uniprot/
output_path: path to output .txt file
# Elevated Day 0 vs. Elevated Day 2. Individual libraries
uniprot_to_GO(accession_path = "../output/accession_n_GOids/hemat_transcriptomev1.6/allgenes_IDs/elev0_vs_elev2_indiv_All_GeneIDs.txt",
swissprot_path = "../data/all_uniprot_info_inc_GOterms.tab",
output_path = "../output/accession_n_GOids/hemat_transcriptomev1.6/allgenes_IDs/elev0_vs_elev2_indiv_All_GOIDs.txt")
# Ambient Day 2 vs. Elevated Day 2. Individual libraries
uniprot_to_GO(accession_path = "../output/accession_n_GOids/hemat_transcriptomev1.6/allgenes_IDs/amb2_vs_elev2_indiv_All_GeneIDs.txt",
swissprot_path = "../data/all_uniprot_info_inc_GOterms.tab",
output_path = "../output/accession_n_GOids/hemat_transcriptomev1.6/allgenes_IDs/amb2_vs_elev2_indiv_All_GOIDs.txt")