data4.Rmd 17.5 KB
Newer Older
mariefbourdon's avatar
mariefbourdon committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
---
title: "data4.Rmd"
author: "Marie Bourdon"
date: '2022-06-08'
output: html_document
---

```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
library(stuart)
library(magrittr)
library(readr)
library(stringr)
library(qtl)
source("../files/QTL_plot.R")
```

## Load
```{r}
mariefbourdon's avatar
data3-4    
mariefbourdon committed
20
genos <- read_csv("genos_data4.csv",show_col_types = FALSE) #genotypes of F2s
mariefbourdon's avatar
mariefbourdon committed
21
annot_mini <- read.csv(url("https://raw.githubusercontent.com/kbroman/MUGAarrays/master/UWisc/mini_uwisc_v2.csv")) #annotation file for miniMUGA
mariefbourdon's avatar
data3-4    
mariefbourdon committed
22
23
phenos <- read_csv("phenos_data4.csv",show_col_types = FALSE) #phenotypes of F2s
parents <- read_csv("parents_data4.csv",show_col_types = FALSE) #genotypes of parental strains (genotyped with F2s)
mariefbourdon's avatar
mariefbourdon committed
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
strns_ref <- read_csv("ref_geno_data4.csv",show_col_types = FALSE) #reference genotypes of parental strains
```

```{r}
tab <- tab_mark(genos,annot_mini,"cM_cox")
```

## Before: creation of Rqtl csv file 

```{r cross_before}
# filter at minima: remove non polymorphic and NA>0.5 
tab_before <- mark_na(tab)
tab_before <- mark_poly(tab_before)

#join with annotation file from miniMUGA
strns_ref <- strns_ref %>% select(name,StrainA,StrainB) %>% right_join(annot_mini,.,by=c("marker"="name")) %>% select(c(marker,chr,cM_cox,StrainA,StrainB))

# create rqtl csv file
write_rqtl(geno=genos,pheno=phenos,tab=tab_before,ref=strns_ref,par1="StrainA",par2="StrainB",prefix=" ",pos="cM_cox",path="cluster/cross_before.csv")

# import cross
cross_before <- read.cross(format="csv",file="cluster/cross_before.csv",
                              genotypes=c("0","1","2"),na.strings=c("NA"), convertXdata=TRUE)

mariefbourdon's avatar
data3-4    
mariefbourdon committed
48
49
50

load("cluster/newmap_before.rda")
plotMap(cross_before,newmap_before,shift=TRUE)
mariefbourdon's avatar
mariefbourdon committed
51
52
53
54
55
```

### Before: plot genome scan

```{r before_scan}
mariefbourdon's avatar
data3-4    
mariefbourdon committed
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# load rda with perm
load("cluster/before_1000p.rda")
# load("files/before_1000p.rda")


# calculate thresholds
threshold_before <- summary(before_1000p,alpha=c(0.05,0.1,0.63)) #donne lod score pour risque 0.05, 0.1, 0.63

# scanone
cross_before <- calc.genoprob(cross_before, step=2.0, off.end=0.0,
                                 error.prob=1.0E-4, map.function="haldane", stepwidth="fixed")


pheno_before <- scanone(cross=cross_before, chr=c("1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "X", "Y"), pheno.col="Pheno", model="normal", method="em")
summary(pheno_before)

# Plot
pheno_before_plot <- qtl_plot(pheno_before,lod=data.frame(group = c("alpha=0.05", "alpha=0.1","alpha=0.63"),
                 lod = threshold_before[1:3]),
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6,
         strip.pos="bottom") +
    theme(legend.position = "none") +
    ggtitle("")
pheno_before_plot
mariefbourdon's avatar
mariefbourdon committed
83
84
```

mariefbourdon's avatar
mariefbourdon committed
85

mariefbourdon's avatar
mariefbourdon committed
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
```{r}
#our genotypes

#create tibble with individivual names
parental_strains <- tibble::tibble(StrainA = "StrainA",
                                   StrainB = c("StrainB_1","StrainB_2"))


#create data frame with geno_strains
strains <- geno_strains(annot=annot_mini,geno=parents,
                        strn=parental_strains,cols=c("chr","cM_cox"))
rm(parental_strains)

#summary
summary(strains)
```

## Use of stuart's functions

```{r}
tab2 <- mark_match(tab,ref=strains)
tab2 <- mark_poly(tab2)
tab2 <- mark_na(tab2)
tab2 <- mark_prop(tab2,cross="F2",homo=0.1,hetero=0.1,homo1X=c(0.1,1),homo2X=c(0.1,1),heteroX=c(0.1,1))
tab2 <- mark_allele(tab2,ref=strains,cross="F2",par1="StrainA",par2="StrainB")
```

### estmap

```{r}
# create rqtl csv file
write_rqtl(geno=genos,pheno=phenos,tab=tab2,ref=strains,par1="StrainA",par2="StrainB",prefix=" ",pos="cM_cox",path="cluster/cross_after.csv")

mariefbourdon's avatar
data3-4    
mariefbourdon committed
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
# import cross
cross_after <- read.cross(format="csv",file="cluster/cross_after.csv",
                              genotypes=c("0","1","2"),na.strings=c("NA"), convertXdata=TRUE)


load("cluster/newmap_after.rda")
plotMap(cross_after,newmap_after,shift=TRUE)

tab2 <- mark_estmap(tab=tab2,map=newmap_after,annot=annot_mini)

# create new rqtl csv file
write_rqtl(geno=genos,pheno=phenos,tab=tab2,ref=strains,par1="StrainA",par2="StrainB",prefix="F2-",pos="cM_cox",path="cluster2/cross_after2.csv")
```


### After: plot estimated map 2

```{r after_map2}
# import cross
cross_after2 <- read.cross(format="csv",file="cluster2/cross_after2.csv",
                              genotypes=c("0","1","2"),na.strings=c("NA"), convertXdata=TRUE)

# load rda with newmap
load("cluster2/newmap_after2.rda")

# plot
plotMap(cross_after2,newmap_after2,shift=TRUE)
plotmap_after <- ~plotMap(cross_after2,newmap_after2,shift=TRUE,main="After stuart")
```

```{r after_scan}
# load rda with perm
load("cluster2/after_1000p2.rda")

# calculate thresholds
threshold_after <- summary(after_1000p2,alpha=c(0.05,0.1,0.63)) #donne lod score pour risque 0.05, 0.1, 0.63

# scanone
cross_after <- calc.genoprob(cross_after2, step=2.0, off.end=0.0, 
                                 error.prob=1.0E-4, map.function="haldane", stepwidth="fixed")


pheno_after <- scanone(cross=cross_after2, chr=c("1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "X", "Y"), pheno.col="Pheno", model="normal", method="em")
summary(pheno_after)

# Plot
pheno_after_plot <- qtl_plot(pheno_after,lod=data.frame(group = c("alpha=0.05", "alpha=0.1","alpha=0.63"),
                 lod = threshold_after[1:3]),
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6) +
    theme(legend.position = "none") +
    ggtitle("")
pheno_after_plot
```


## Number of markers kept after each function

```{r barplot}
none <- tab2 %>% nrow()
match <- tab2 %>% filter(exclude_match==0) %>% nrow()
allele <- tab2 %>% filter(exclude_match==0&exclude_allele==0) %>% nrow()
naf <- tab2 %>% filter(exclude_match==0&exclude_allele==0&exclude_na==0) %>% nrow()
poly <- tab2 %>% filter(exclude_match==0&exclude_allele==0&exclude_na==0&exclude_poly==0) %>% nrow()
prop <- tab2 %>% filter(exclude_match==0&exclude_allele==0&exclude_na==0&exclude_poly==0&exclude_prop==0) %>% nrow()
estmap <- tab2 %>% filter(exclude_match==0&exclude_allele==0&exclude_na==0&exclude_poly==0&exclude_prop==0&exclude_estmap==0) %>% nrow()

functions_df <- tibble(fct=c("none","match","allele","na","poly","prop","estmap"),
                       markers=c(none,match,allele,naf,poly,prop,estmap))

functions_plot <- functions_df %>% ggplot(aes(x=markers,y=fct)) +
  geom_bar(stat="identity",width=0.6) +
  geom_text(aes(label=markers), hjust=1.3, color="white", size=3.5) +
  scale_y_discrete(limits=c("estmap","prop","poly", "na", "allele","match","none")) +
  theme(aspect.ratio=0.7) +
  labs(title="Number of markers kept after each step",
       x="Number of markers",
       y="Function used") +
  theme_classic() +
  theme(plot.title = element_text(hjust = 0.4,face="bold",size=14))

functions_plot
rm(none,allele,match,poly,prop)
mariefbourdon's avatar
mariefbourdon committed
204
205
206
207
208
```


## Narrow peaks

mariefbourdon's avatar
mariefbourdon committed
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
```{r before_ann}
chrs <- c("1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "X")
ann_dat_text<-data.frame(
    chr=factor(chrs,
               levels=chrs),
    lod=c(9,NA,NA,NA,11,NA,NA,NA,NA,13,NA,NA,8.5,NA,NA,NA,NA,7,NA,NA),
    label=c(8,NA,NA,NA,9,NA,NA,NA,NA,10,NA,NA,11,NA,NA,NA,NA,12,NA,NA),
    x=c(45,NA,NA,NA,20,NA,NA,NA,NA,27,NA,NA,30,NA,NA,NA,NA,35,NA,NA)
)

pheno_before_annot_data4 <- pheno_before_plot +  geom_text(
    # the new dataframe for annotating text
    data = ann_dat_text,
    mapping = aes(x = x,
                  y = lod,
                  label = label,
                  color="blue")
)
pheno_before_annot_data4
```

mariefbourdon's avatar
mariefbourdon committed
230
231
232
233
Investigation of high lod score peaks 

### Peak 8

mariefbourdon's avatar
mariefbourdon committed
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
```{r peak8_zoom}
peak8 <- qtl_plot(pheno_before,lod=data.frame(group = c("alpha=0.05", "alpha=0.1","alpha=0.63"),
                 lod = threshold_before[1:3]),
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6,
         strip.pos="bottom",
         chr="1",
         rug=TRUE) +
    theme(legend.position = "none",
          strip.background = element_blank(),
          strip.text.x = element_blank()) +
    xlab("Position (cM)") +
    ggtitle("")
peak8
```

1 peak on chromosome 1 on 1 pseudomarker : c1.loc42, postionned between gUNC1177319 and S6J013976867.
mariefbourdon's avatar
mariefbourdon committed
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292

Here are the infos on genotype counts for these markers:

```{r summary_geno_peak8}
tab_before %>% filter(marker %in% c("gUNC1177319", "S6J013976867")) %>% select(marker:n_NA)
```


For gUNC1177319, all individuals heterozygous so this marker should be removed. The proportions for S6J013976867 seem correct.

Graph:

```{r geno_plot_peak8}
phenotypes <- cross_before[["pheno"]]
map <- cross_before[["geno"]][["1"]][["map"]] 
map <- tibble(marker=names(map),pos=map)
genotypes <- cross_before[["geno"]][["1"]][["data"]]
genotypes <- as_tibble(genotypes)
phenogeno <- cbind(phenotypes,genotypes)
phenogeno %<>% pivot_longer(SAH010136363:gUNC2460751,names_to="marker",values_to="genotype")
pgmap <- full_join(phenogeno,map,by="marker")

geno_plot8 <- pgmap %>% filter(pos > 42 & pos < 52) %>%
  filter(id %in% sample(phenotypes$id,10)) %>%
  ggplot(aes(x=pos,y=as.factor(id))) +
  geom_point(aes(color=as.factor(genotype))) +
  coord_cartesian(ylim = c(1, 10), expand = TRUE, clip = "off") +
  annotate(geom="text",y=-1,size=3,
           x = map %>% filter(pos > 42 & pos < 52) %>% pull(pos),
           label = map %>% filter(pos > 42 & pos < 52) %>% pull(marker),
           angle=90) +
  labs(x="Position (cM)",y="Individual",color="Genotype") +
  theme_bw() +
  theme(plot.margin = unit(c(1, 1, 1, 1), "lines"),
        axis.title.x = element_text(margin = margin(t = 50)))
geno_plot8
```

### Peak 9

mariefbourdon's avatar
mariefbourdon committed
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
```{r peak9_zoom}
peak9 <- qtl_plot(pheno_before,lod=data.frame(group = c("alpha=0.05", "alpha=0.1","alpha=0.63"),
                 lod = threshold_before[1:3]),
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6,
         strip.pos="bottom",
         chr="5",
         rug=TRUE) +
    theme(legend.position = "none",
          strip.background = element_blank(),
          strip.text.x = element_blank()) +
    xlab("Position (cM)") +
    ggtitle("")
peak9
```

1 peak on chromosome 5 on 3 pseudomarkers : c5.loc16, c5.loc18, c5.loc20 in a region with very few markers, postionned between S6J050685107 and mUNC050096588.
mariefbourdon's avatar
mariefbourdon committed
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351

Here are the infos on genotype counts for these markers:

```{r summary_geno_peak9}
tab_before %>% filter(marker %in% c("S6J050685107","mUNC050096588")) %>% select(marker:n_NA)
```


For mUNC050096588, all individuals heterozygous so this marker should be removed. The proportions for S6J050685107 seem correct.

Graph:

```{r geno_plot_peak9}
phenotypes <- cross_before[["pheno"]]
map <- cross_before[["geno"]][["5"]][["map"]] 
map <- tibble(marker=names(map),pos=map)
genotypes <- cross_before[["geno"]][["5"]][["data"]]
genotypes <- as_tibble(genotypes)
phenogeno <- cbind(phenotypes,genotypes)
phenogeno %<>% pivot_longer(mUNC050013072:gUNC10448854,names_to="marker",values_to="genotype")
pgmap <- full_join(phenogeno,map,by="marker")

geno_plot9 <- pgmap %>% filter(pos > 1 & pos < 30) %>%
  filter(id %in% sample(phenotypes$id,10)) %>%
  ggplot(aes(x=pos,y=as.factor(id))) +
  geom_point(aes(color=as.factor(genotype))) +
  coord_cartesian(ylim = c(1, 10), expand = TRUE, clip = "off") +
  annotate(geom="text",y=-1,size=3,
           x = map %>% filter(pos > 1 & pos < 30) %>% pull(pos),
           label = map %>% filter(pos > 1 & pos < 30) %>% pull(marker),
           angle=90) +
  labs(x="Position (cM)",y="Individual",color="Genotype") +
  theme_bw() +
  theme(plot.margin = unit(c(1, 1, 1, 1), "lines"),
        axis.title.x = element_text(margin = margin(t = 50)))
geno_plot9
```

### Peak 10

mariefbourdon's avatar
mariefbourdon committed
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
```{r peak10_zoom}
peak10 <- qtl_plot(pheno_before,lod=data.frame(group = c("alpha=0.05", "alpha=0.1","alpha=0.63"),
                 lod = threshold_before[1:3]),
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6,
         strip.pos="bottom",
         chr="10",
         rug=TRUE) +
    theme(legend.position = "none",
          strip.background = element_blank(),
          strip.text.x = element_blank()) +
    xlab("Position (cM)") +
    ggtitle("")
peak10
```

mariefbourdon's avatar
mariefbourdon committed
370
1 peak on 1 marker and one pseudomarker : S2C102505843 and c10.loc30  postionned between SAH102097335 and S2C102505843.
mariefbourdon's avatar
mariefbourdon committed
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411

Here are the infos on genotype counts for these markers:

```{r summary_geno_peak10}
tab_before %>% filter(marker %in% c("SAH102097335","S2C102505843")) %>% select(marker:n_NA)
```


For S2C102505843, all individuals except 1 are homozygous so this marker should be removed. The proportions for SAH102097335 seem correct.

Graph:

```{r geno_plot_peak10}
phenotypes <- cross_before[["pheno"]]
map <- cross_before[["geno"]][["10"]][["map"]] 
map <- tibble(marker=names(map),pos=map)
genotypes <- cross_before[["geno"]][["10"]][["data"]]
genotypes <- as_tibble(genotypes)
phenogeno <- cbind(phenotypes,genotypes)
phenogeno %<>% pivot_longer(gICR258:S6J105101847,names_to="marker",values_to="genotype")
pgmap <- full_join(phenogeno,map,by="marker")

geno_plot10 <- pgmap %>% filter(pos > 25 & pos < 35) %>%
  filter(id %in% sample(phenotypes$id,10)) %>%
  ggplot(aes(x=pos,y=as.factor(id))) +
  geom_point(aes(color=as.factor(genotype))) +
  coord_cartesian(ylim = c(1, 10), expand = TRUE, clip = "off") +
  annotate(geom="text",y=-1,size=3,
           x = map %>% filter(pos > 25 & pos < 35) %>% pull(pos),
           label = map %>% filter(pos > 25 & pos < 35) %>% pull(marker),
           angle=90) +
  labs(x="Position (cM)",y="Individual",color="Genotype") +
  theme_bw() +
  theme(plot.margin = unit(c(1, 1, 1, 1), "lines"),
        axis.title.x = element_text(margin = margin(t = 50)))
geno_plot10
```


### Peak 11

mariefbourdon's avatar
mariefbourdon committed
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
```{r peak11_zoom}
peak11 <- qtl_plot(pheno_before,
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6,
         strip.pos="bottom",
         chr="13",
         rug=TRUE) +
    theme(legend.position = "none",
          strip.background = element_blank(),
          strip.text.x = element_blank()) +
    xlab("Position (cM)") +
    ggtitle("Peak 11")
peak11
```

1 peak on 1 marker and 1 pseudomarker : SAC132487883 and c13.loc28, postionned between S6J132182752 and SAC132487883.
mariefbourdon's avatar
mariefbourdon committed
430
431
432
433

Here are the infos on genotype counts for these markers:

```{r summary_geno_peak11}
mariefbourdon's avatar
mariefbourdon committed
434
435
peak11_tab <- tab_before %>% filter(marker %in% c("S6J132182752","SAC132487883")) %>% select(marker:n_NA)
peak11_tab
mariefbourdon's avatar
mariefbourdon committed
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
```


For SAC132487883, all individuals are heterozygous so this marker should be removed. The proportions for S6J132182752 seem correct.

Graph:

```{r geno_plot_peak11}
phenotypes <- cross_before[["pheno"]]
map <- cross_before[["geno"]][["13"]][["map"]] 
map <- tibble(marker=names(map),pos=map)
genotypes <- cross_before[["geno"]][["13"]][["data"]]
genotypes <- as_tibble(genotypes)
phenogeno <- cbind(phenotypes,genotypes)
phenogeno %<>% pivot_longer(gB6_rs13481676:SFH134765844,names_to="marker",values_to="genotype")
pgmap <- full_join(phenogeno,map,by="marker")

geno_plot11 <- pgmap %>% filter(pos > 20 & pos < 35) %>%
  filter(id %in% sample(phenotypes$id,10)) %>%
  ggplot(aes(x=pos,y=as.factor(id))) +
  geom_point(aes(color=as.factor(genotype))) +
  coord_cartesian(ylim = c(1, 10), expand = TRUE, clip = "off") +
  annotate(geom="text",y=-1,size=3,
           x = map %>% filter(pos > 20 & pos < 35) %>% pull(pos),
           label = map %>% filter(pos > 20 & pos < 35) %>% pull(marker),
           angle=90) +
  labs(x="Position (cM)",y="Individual",color="Genotype") +
  theme_bw() +
  theme(plot.margin = unit(c(1, 1, 1, 1), "lines"),
        axis.title.x = element_text(margin = margin(t = 50)))
geno_plot11
```

### Peak 12

mariefbourdon's avatar
mariefbourdon committed
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
```{r peak12_zoom}
peak12 <- qtl_plot(pheno_before,lod=data.frame(group = c("alpha=0.05", "alpha=0.1","alpha=0.63"),
                 lod = threshold_before[1:3]),
         ylab="LOD score",
         title="QTL mapping",
         x.label = element_blank(),
         size=0.6,
         strip.pos="bottom",
         chr="18",
         rug=TRUE) +
    theme(legend.position = "none",
          strip.background = element_blank(),
          strip.text.x = element_blank()) +
    xlab("Position (cM)") +
    ggtitle("")
peak12
```

mariefbourdon's avatar
mariefbourdon committed
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
1 peak on 1 marker : S3C182557441

Here are the infos on genotype counts for these markers:

```{r summary_geno_peak12}
tab_before %>% filter(marker %in% c("S3C182557441")) %>% select(marker:n_NA)
```


For this marker, all individuals except one are homozygous so this marker should be removed.

Graph:

```{r geno_plot_peak12}
phenotypes <- cross_before[["pheno"]]
map <- cross_before[["geno"]][["18"]][["map"]] 
map <- tibble(marker=names(map),pos=map)
genotypes <- cross_before[["geno"]][["18"]][["data"]]
genotypes <- as_tibble(genotypes)
phenogeno <- cbind(phenotypes,genotypes)
phenogeno %<>% pivot_longer(mJAX00450679:gUNC29817480,names_to="marker",values_to="genotype")
pgmap <- full_join(phenogeno,map,by="marker")

geno_plot12 <- pgmap %>% filter(pos > 32 & pos < 42) %>%
  filter(id %in% sample(phenotypes$id,10)) %>%
  ggplot(aes(x=pos,y=as.factor(id))) +
  geom_point(aes(color=as.factor(genotype))) +
  coord_cartesian(ylim = c(1, 10), expand = TRUE, clip = "off") +
  annotate(geom="text",y=-1,size=3,
           x = map %>% filter(pos > 32 & pos < 42) %>% pull(pos),
           label = map %>% filter(pos > 32 & pos < 42) %>% pull(marker),
           angle=90) +
  labs(x="Position (cM)",y="Individual",color="Genotype") +
  theme_bw() +
  theme(plot.margin = unit(c(1, 1, 1, 1), "lines"),
        axis.title.x = element_text(margin = margin(t = 50)))
geno_plot12
```
mariefbourdon's avatar
mariefbourdon committed
527
528
529
530
531
532


```{r}
save(pheno_before_annot_data4,peak11,peak11_tab,file="data4_peaks.rda")
```