-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest.Rmd
46 lines (37 loc) · 946 Bytes
/
test.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
42
43
44
45
46
---
output: pdf_document
geometry: margin=1in
mainfont: Times New Roman
---
```{r,fig.width=7.5, fig.height=7.5,warning=F, message=F, echo=F,comment="K",results='asis'}
library(cegwas)
library(cegwas)
library(genetics)
library(pander)
library(dplyr)
library(ggplot2)
library(data.table)
library(grid)
library(stringr)
library(gridExtra)
library(knitr)
library(tidyr)
library(scales)
library(gtable)
library(cowplot)
setwd("/Users/kristen/Documents/transposon_figure_data/data")
#load("Processed_Transposon_Mappings_2.Rda")
#load("Processed_Transposon_Mappings_SUBSET.Rda")
load("Processed_Transposon_Mappings_SUBSET2.Rda")
for (i in unique(processed_mapping_df$trait)){
test<-filter(processed_mapping_df,trait==i)
sns <- dplyr::filter(test, aboveBF == 1, !is.na(peak_id) )
#ans<-
if (nrow(sns)>1){
crs <- plot_peak_ld(sns)
#ld<-ggplotGrob(crs)
plot(crs)
} else {
crs<-NULL #single peak, no need to check for LD
}
}