Reference & Exercise

Session 5

Exercise 1: Compute/load the DESeq result and build your gene list for ORA. How many Up and Down genes do you see?

Click for Hint
# ----------------------------------------------------------------------------
# TASK 1 (0:03-0:10)  Build your gene lists
# ----------------------------------------------------------------------------
# HINT: filter to padj <= 0.05, then split by sign of log2FoldChange.
# You need three objects:
#   de_genes_up  - character vector of upregulated gene names
#   de_genes_dn  - character vector of downregulated gene names
#   uni_genes    - character vector of background genes

Exercise 2: Run ORA on both directions and show the results in table.

Click for Hint
# ----------------------------------------------------------------------------
# TASK 2 (0:10-0:18)  Run ORA on both directions
# ----------------------------------------------------------------------------
# HINT: enrichGO(gene = ..., universe = uni_genes, OrgDb = org.Mm.eg.db,
#                keyType = ..., ont = "BP",
#                pAdjustMethod = "BH", pvalueCutoff = 0.05)

# ego_result_up <- ...
# ego_result_dn <- ...

# Look at the top terms in BOTH directions: with DT::datatable()

Exercise 3: Visualize your results combining both Up and Down plot together.

Click for Hint
- Use `Dotplot` 
    - what does the DOT SIZE encode?  
    - what does the COLOR encode?     
- Use `emapplot`
- Use `cnetplot`

Exercise 4: Summarize redundant terms and visualize for Up regulated genes

Click for Hint
# ----------------------------------------------------------------------------
# TASK 4 (0:05-0:15)  
# ----------------------------------------------------------------------------
# HINT: use `rrvgo` 
# You need three objects:
#   calculate similarity  - calculateSimMatrix()
#   create score for each go term with qvalue
#   reducedTerms
#   treemapPlot