---
title: "74 PI enrichment"
author: Steven Roberts
date: "`r format(Sys.time(), '%d %B, %Y')`" 
output: 
  html_document:
    theme: readable
    highlight: zenburn
    toc: true
    toc_float: true
    number_sections: true
    code_folding: show
    code_download: true
  # github_document:
  #   toc: true
  #   toc_depth: 3
  #   number_sections: true
  #   html_preview: true
---

```{r setup, include=FALSE}
#library(kableExtra)
# library(DESeq2)
# library(pheatmap)
# library(RColorBrewer)
# library(data.table)
#library(DT)
# library(Biostrings)
#library(methylKit)
library(tidyverse)

knitr::opts_chunk$set(
  echo = TRUE,         # Display code chunks
  eval = TRUE,         # Evaluate code chunks
  warning = TRUE,     # Hide warnings
  message = TRUE,     # Hide messages
  fig.width = 6,       # Set plot width in inches
  fig.height = 4,      # Set plot height in inches
  fig.align = "center" # Align plots to the center
)
```

Lets take do annoation or predominant isoform shift

# female

```{r}
fmiso <- read_delim("../output/42-predominant-isoform/predom_iso-diff-controls_vs_exposed-female.tab", col_names = FALSE)
```

```{r}
fmiso %>% filter(X3 > 0) %>%
  select(X1) %>%
  write.csv("../output/74-PI-enrichment/fmiso.txt", row.names = FALSE, col.names = FALSE, quote = FALSE)
```


# male

```{r}
miso <- read_delim("../output/42-predominant-isoform/predom_iso-diff-controls_vs_exposed-male.tab", col_names = FALSE)
```


```{r}
miso %>% filter(X3 > 0) %>%
  select(X1) %>%
  write.csv("../output/74-PI-enrichment/miso.txt", row.names = FALSE, col.names = FALSE, quote = FALSE)
```