-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path02-missingness.R
More file actions
27 lines (25 loc) · 861 Bytes
/
02-missingness.R
File metadata and controls
27 lines (25 loc) · 861 Bytes
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
#vcftools --gzvcf Gm20.SNPs.id.biallic.vcf.gz --missing-site --out Gm20.SNPs.id.biallic.vcf
#reformat into two column file, c1 = position, c2 = missing proportion
library(tidyverse)
library(viridis)
missplot <- miss %>% ggplot(aes(x = POS, y = F_MISS, colour = F_MISS)) +
geom_point() +
ylab("Missing Frequency") +
xlab("Position") +
scale_color_viridis_c('Missing Freq',
option = 3,
limits = c(0, 0.25),
oob = scales::squish,
begin = 0,
end = 0.8) +
geom_vline(xintercept = c(31604127 ,31777346),
color = "red",
linetype = "dashed") +
theme_minimal()
ggsave('missplot.pdf',
missplot,
device = 'pdf',
dpi = 1800,
height = 90,
width = 160,
units = "mm")