8.12 Genotype-phenotype boxplots

First, let’s plot the relationship between genotype and phenotype to see if it looks interesting.


Create boxplots of the phenotype, stratified by genotype of the test SNP.
ggplot(data = gwas_data) +
  geom_boxplot(aes(x = gt_GT_alleles,
                   y = GS451_IC50))
## Warning: Removed 1 rows containing non-finite values (stat_boxplot).

It’s unclear whether there’s a relationship here, because the phenotype distributions for these two genotypes are mostly overlapping. To be certain, we’ll now test this with linear regression.