Skip to content

Commit 484b3f9

Browse files
authored
push script
1 parent 3556594 commit 484b3f9

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

getOrthologs.R

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# script to get all genes orthologous to human in mouse
2+
3+
library(tidyverse)
4+
library(homologene)
5+
6+
# Retrieve all orthologs between human and mouse
7+
all_human_mouse_orthologs <- homologeneData2 |>
8+
filter(Taxonomy %in% c(9606, 10090))
9+
10+
# Split human and mouse data
11+
human_genes <- all_human_mouse_orthologs |> filter(Taxonomy == 9606)
12+
mouse_genes <- all_human_mouse_orthologs |> filter(Taxonomy == 10090)
13+
14+
15+
# Merge human and mouse data by HID to get ortholog pairs
16+
human_mouse_pairs <- merge(human_genes, mouse_genes, by = "HID", suffixes = c("_human", "_mouse"))

0 commit comments

Comments
 (0)