Discovering Epistatic Genetic Patterns Associated with Penicillin Allergy
This repository documents a research note focused on epistasis and gene–gene interactions as explanatory units in pharmacogenomics. It explores the use of association rule mining to identify non-linear combinations of SNPs associated with penicillin allergy, using publicly available genomic and personal health record data.
While genome-wide association studies (GWAS) are the standard first-line approach to detect single-variant effects, they are structurally limited to additive models and marginal effects. When adverse drug reactions are driven by specific combinations of genetic variants, univariate GWAS analyses are insufficient by design.
This work directly targets non-linear, interaction-driven genetic patterns, treating combined genotypes as primary variables rather than secondary effects.
Summary
- Problem: Explaining genetic susceptibility to penicillin allergy
- Approach: Association Rule Mining (interpretable, non-linear modeling)
- Conceptual focus: Epistasis and gene–gene interactions
- Data: Public genomes and Personal Health Records from the Harvard Personal Genome Project (PGP)
- Outcome: Detection of specific SNP combinations potentially associated with penicillin allergy
Although penicillin allergy is a relatively common condition (≈5–7% prevalence), the space of possible multi-locus genetic combinations is extremely large, making the identification of explanatory interaction patterns a non-trivial task.
Data Sources
The analysis was based on publicly available data from the Personal Genome Project (Harvard Medical School):
- Project homepage:
https://pgp.med.harvard.edu - Public genetic data (current):
https://my.pgp-hms.org/public_genetic_data - Example Personal Health Record (penicillin allergy mentioned):
https://my.pgp-hms.org/profile/huE58004
At the time of the study, genomes were predominantly provided in 23andMe format.
Methodology
- Collection of all publicly available Personal Health Records
- Identification of records mentioning penicillin allergy
- Extraction and consolidation of individual genome files into a single analytical dataset
- Large-scale data merging using the MergeGUI R package
(historical CRAN archive; required careful memory management) - String normalization and cleanup using
stringr - Detection of epistatic SNP combinations using Association Rule Mining
via the R packagearules
All analyses were performed in R.
GWAS and Epistasis
GWAS are well suited to identify single-SNP associations and should be considered a necessary first step when exploring genetic datasets. However, GWAS models are inherently additive and do not test whether a phenotype emerges only when multiple variants are present simultaneously.
Epistasis addresses this limitation by explicitly modeling gene–gene interactions. In this work, penicillin allergy is analyzed through logical combinations of SNP genotypes, using association rules and contingency tables rather than additive linear models.
This approach does not replace GWAS; it complements it by exploring interaction-driven signals that remain invisible to univariate analyses.
Why Association Rules?
Association Rules are particularly well suited for epistatic analysis because:
- the phenotype may be relatively common
- explanatory genetic patterns are combinatorially sparse
- interactions are non-linear and multi-locus
- combined genotypes can be treated as explicit variables
- interpretability and auditability are essential
As the dimensionality of the genetic space increases, the problem increasingly resembles finding a needle in a haystack — not because the condition is rare, but because meaningful genetic interactions are.
Paper / Research Note
The full research note is available here:
- OSF (official preprint)
https://osf.io/8ks2d/ - PDF mirror
https://www.amsafis.com/pdf/SNPs-to-predict-penicillin-allergy.pdf
The document is intentionally concise (≈3 pages of content) and focuses on methodology and results, rather than formal publication structure.
Scope and Reusability
This repository is documentation-focused.
- No trained model is included
- No executable pipeline is provided
- The goal is methodological clarity and knowledge sharing, not benchmarking
The approach is applicable to:
- epistatic genotype–phenotype associations
- pharmacogenomics
- adverse drug reactions
- high-dimensional biomedical data
- interpretable and decision-oriented AI
- both common and rare conditions, when interactions are explanatory
Author
This repository is maintained by AMSAFIS
https://www.amsafis.com
Specialized in:
- Epistasis and gene–gene interaction analysis
- Machine Learning
- Expert Systems (including a decision-support sandbox for rare diseases: http://64.225.98.129:9070/ )
- Interpretable, mechanism-oriented AI for healthcare
Licensed under CC BY 4.0.