-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathFunctionalAnalysis.Rmd
41 lines (36 loc) · 1.88 KB
/
FunctionalAnalysis.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
---
title: "ATAC-Seq Data Analysis with Human Data - Functionally Interpret Peak Regions"
author: "Anni Liu"
date: '`r format(Sys.Date(), "%B %d, %Y")`'
output:
html_document:
code_folding: show
---
```{r, shorcut, include=FALSE}
## RStudio keyboard shortcut
# Cursor at the beginning of a command line: Ctrl+A
# Cursor at the end of a command line: Ctrl+E
# Clear all the code from your console: Ctrl+L
# Create a pipe operator %>%: Ctrl+Shift+M (Windows) or Cmd+Shift+M (Mac)
# Create an assignment operator <-: Alt+- (Windows) or Option+-(Mac)
# Knit a document (knitr): Ctrl+Shift+K (Windows) or Cmd+Shift+K (Mac)
# Comment or uncomment current selection: Ctrl+Shift+C (Windows) or Cmd+Shift+C (Mac)
```
```{r}
if (!require("rGREAT", quietly = TRUE)) {
BiocManager::install("rGREAT"); library(rGREAT)
} else {
library(rGREAT)
}
# Perform online GREAT analysis: http://great.stanford.edu/public/html/ | http://bejerano.stanford.edu/papers/GREAT.pdf
# "GREAT assigns biological meaning to a set of non-coding genomic regions by analyzing the annotations of the nearby genes. Thus, it is particularly useful in studying cis functions of sets of non-coding genomic regions. Cis-regulatory regions can be identified via both experimental methods (e.g. ChIP-seq) and by computational methods (e.g. comparative genomics)."
# "Whereas previous methods took into account only binding proximal to genes, GREAT is able to properly incorporate distal binding sites and control for false positives using a binomial test over the input genomic regions."
job <- submitGreatJob(peak_final, species = "hg38")
availableCategories(job)
# [1] "GO" "Phenotype" "Genes"
(enrich_table <- getEnrichmentTables(job))
names(enrich_table)
# [1] "GO Molecular Function" "GO Biological Process" "GO Cellular Component"
enrich_table[["GO Molecular Function"]] |> View()
enrich_table[["GO Biological Process"]] |> View()
```