Skip to content

Instantly share code, notes, and snippets.

@Miserlou
Created February 19, 2019 19:35
Show Gist options
  • Save Miserlou/1482ac9f7d5a9fcae3985dcaa1c3671b to your computer and use it in GitHub Desktop.
Save Miserlou/1482ac9f7d5a9fcae3985dcaa1c3671b to your computer and use it in GitHub Desktop.
Get gene info for zebrafish genes
# C.Savonen
# ALSF for CCDL
# 2019
# Purpose: Get gene info for Zebrafish/Human genes
# Replace 'Hs' with 'Dr' etc
columns(org.Hs.eg.db::org.Hs.eg.db)
# Get ensembl genes
genes <- AnnotationDbi::keys(org.Hs.eg.db::org.Hs.eg.db, "ENSEMBL")
# Retrieve transcripts for those
gene_info <- AnnotationDbi::select(org.Hs.eg.db::org.Hs.eg.db, keys = genes,
columns = c("ONTOLOGY", "GO"),
keytype = "ENSEMBL")
# Write to tsv file
readr::write_tsv(gene_info, "human_genes_info.tsv", col_names = FALSE)
@KingGame0
Copy link

<style type="text/css"></style> KingGame -- Gold99 PGasia

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment