Introduction

Understanding the emergence and progression of complex diseases incessantly pose challenges to researchers due to its intricate and multifactorial nature. These diseases are caused by interplays between genetics and environmental factors leading to a plethora of combinations that need to be considered in modeling. From the genetics’ aspect, understanding the etiology of complex diseases necessitates an extensive localization of significant genomic variations due to its polygenic nature1,2,3. Identifying these biomarkers, albeit elucidating only a portion of the entire underpinnings of complex diseases, could nevertheless aid in increasing patients’ chances of survival by allowing a more personalized and advanced disease risk assessment4.

A genome-wide association study (GWAS) is the traditional approach employed to discover genetic biomarkers, i.e. single nucleotide polymorphisms (SNPs), associated with various traits and diseases5. GWAS has been successful in identifying several risk loci for a wide array of illnesses including cancer6, Type 2 diabetes mellitus7, Crohn’s disease8, and coronary artery disease9, among others. However, despite these achievements, GWAS faces limitations due to its individual-SNP analysis approach exacerbated by the high dimensionality of genomic datasets. As multitudinous individual association tests are performed, stringent thresholds must be adopted to account for error rates leading to underpowered detection10. This increases the probability of not detecting SNPs with small effects that are truly associated with a trait and could significantly contribute to phenotypic variability11. The traditional GWAS approach also fails to capture SNP-SNP interactions as it only tests for the marginal effects of SNPs and disregards the variants’ joint contributions to phenotypic expression. These interactions require explicit analysis since they are vital in addressing the “missing heritability” problem12 which states that single genetic variations are insufficient in explaining the entire heritability of a trait.

Under the “polygenic paradigm”, refining statistical models, such as increasing sample sizes13 and reducing the number of tests employed14, is crucial in increasing the chances of discovering true associations. Empirical evidence15,16 has shown that as sample size increases, GWAS continues to yield more novel trait-associated loci. However, this approach is not always feasible14 especially for studies involving small populations and diseases with low prevalence. For this reason, it is more viable to reduce the number of tests employed to relax the stringent conditions used to consider genomic variants as significant. Existing approaches to this latter strategy include haplotype-based association analysis and SNP-set analysis, both of which also address the inability of GWAS to capture SNP-SNP interactions17,18. Haplotype-based analysis19 accounts for linkage disequilibrium between SNPs; while SNP-set analysis, e.g. gene-based20 and pathway-based analyses21, considers the joint effects of variants on phenotypic expression. Aside from addressing the aforementioned GWAS’ limitations, SNP-set analysis further permits hypothesis testing on associations possibly existing between wider loci and traits18. However, when this type of analysis groups SNPs based on prior biological knowledge, a study’s success may be hampered when information on genetic variations and competitive pathways related to the trait are insufficient. To allow a less restricted analysis, it is necessary to explore other methods of forming SNP-sets using information independent of a priori biological knowledge.

Machine learning (ML) is an innovative and powerful approach used in solving complex problems in various fields and disciplines due to its capability to handle and analyze high-dimensional datasets22,23,24. Several studies have already demonstrated the usability of ML in genomic datasets25,26,27; however, to our knowledge, there is only a handful of existing literature discussing its application to SNP-set formation28,29,30,31. These studies employed cluster analysis to form SNP-sets in a data-driven manner. This approach could subsequently lead to the identification of novel risk loci associated with a trait31, albeit there may be problems related to computational complexity and cost. As genomic datasets are usually of high dimension, it is susceptible to the “curse of dimensionality”32,33, a problem that could be addressed by solely clustering the SNPs found in certain genomic regions that are known to play a role in trait development29,30. However, this approach defeats the purpose of performing an inclusive analysis as the search for significant biomarkers is restricted by relatively narrow regions. For a more varied selection of SNPs to analyze, dimensionality reduction techniques based on random forest (RF) could be used to reduce dataset dimensions before conducting cluster analysis. RF has been widely incorporated in SNP research25,34,35,36 due to its significant properties: (1) a nonparametric nature that allows the establishment of predictive models without the need for preliminary statistical assumptions, and (2) the capability to provide an importance score, i.e. variable importance measure (VIM) for each SNP, which increases the probability of detecting highly relevant biomarkers.

Cluster analysis and random forest have already been proven applicable and effective in genomic data analysis, specifically in identifying predictive and presumably disease-associated SNPs31,37. However, based on the literature review, the integration of these approaches has not been explored on SNP data. This study aims to incorporate these two techniques to augment previous GWAS findings and allow the discovery of novel trait-associated susceptibility loci. The study implements the proposed integrated framework using the following three-step algorithm:

  1. 1.

    Dimensionality reduction through RF;

  2. 2.

    SNP-set formation through cluster analysis involving top-ranking SNPs from Step 1 and SNPs considered by GWAS to be significantly associated with the trait of interest (termed in this study as ‘GWAS-identified SNPs’); and

  3. 3.

    Association testing on the resulting SNP-sets from Step 2.

In Step 1, dimension reduction is implemented using random forest feature selection to circumvent the “curse of dimensionality” problem associated with analyzing high-dimensional SNP datasets35. In Step 2, top-ranking SNPs determined from the results of Step 1 and GWAS-identified SNPs are subjected to cluster analysis to evaluate shared similarities among the variants and form SNP-sets. Finally, Step 3 involves testing the SNP-sets derived from Step 2 for trait-association. The proposed methodology was applied to the GWAS data by38 wherein the phenotype of interest is hepatitis B virus surface antigen (HBsAg) seroclearance, a marker for clearance of chronic hepatitis B virus (HBV) infection.

Methodology

This study aims to discover novel trait-associated susceptibility loci through a machine learning-based SNP-set analysis approach built on the integration of RF, cluster analysis, and previous GWAS findings. The entire analysis is divided into three main parts: dimension reduction, SNP-set formation, and association testing. Figure 1 shows the architecture of the proposed integrated framework.

Figure 1
figure 1

The architecture of the proposed integrated framework. In Stage 2, SNPs in concentric circles in darker shades of gray represent higher-ranking SNPs based on RF. (Image generated using Canva40).

Data description and preprocessing

The data used in this study was adopted from the GWAS conducted by38 which aimed to identify susceptibility loci associated with HBsAg seroclearance among patients with chronic hepatitis B. The dataset is composed of 1,365,088 SNPs collected from 200 subjects of Korean ethnicity. The subjects were further divided into two groups: the cases (n = 100), which consist of patients who had experienced HBsAg seroclearance before the age of 60, and the controls (n = 100) comprising of patients who exhibited high levels (> 1000 IU/mL) of HBsAg at \(\ge\) 60 years of age. An additive genetic model was utilized to transform the SNP dataset. A SNP marker is encoded as 0, 1, or 2 depending on the number of minor alleles it carries.

Dimension reduction

Dimension reduction is commonly a prerequisite in analyzing SNP datasets as large amounts of features impedes the capability of analytical approaches in performing fast and effective analyses. In this study, features are only selected for cluster analysis if they were considered by a previous GWAS to be statistically significant or if they are one of the top-ranking SNPs as per RF. RF ranks SNPs based on their feature importance scores which is a measure of the usefulness of a marker in predicting a target variable, in this case, trait occurrence. RF has been widely utilized in analyzing SNP data primarily due to its capacity to build a predictive model without making any assumptions about the underlying relationship between genotype and phenotype39. In RF, the predictive abilities of multiple decision trees, which are trained on bootstrap samples of the data, are consolidated to generate the final output prediction. In addition, randomization is not only induced by bootstrapping but also introduced at the node level when growing a tree. It selects a random subset of SNPs at each node of the tree as candidates to find the best split for the node. In estimating the importance of SNPs, RF calculates the Gini importance which quantifies the difference between a node’s impurity and the weighted sum of the impurities of the two descendent nodes.

Mathematically, the importance of \(SNP_{j}\) is determined by summing the decrease in impurity (\(\Delta I\)) for all the nodes \(t\), where \(SNP_{j}\) is split. The decreases in impurity are weighted by fractions of samples in the nodes \(p\left( t \right)\) and averaged over all trees in the forest. The Gini variable importance is then given by,

$$VI_{gini}^{\left( k \right)} \left( {SNP_{j} } \right) = \mathop \sum \limits_{{t \in T_{k} :v\left( {s_{t} } \right)}} p\left( t \right) \Delta I \left( {s_{t} , t} \right)$$

where \(T_{k}\) is the number of nodes in the \(k{\rm{th}}\) tree, \(p\left( t \right) = \frac{{n_{t} }}{n}\) is the fraction of the samples reaching node \(t\); and \(v\left( {s_{t} } \right)\) is the variable used in the split \(s_{t}\).

Since one round of calculations is not enough to ensure robustness of scores, the Leave-One-Out cross-validation (LOOCV) strategy was adopted. For each fold in the LOOCV, RF is trained on the (N-1) dataset, where N is the number of observations, and a corresponding score (the Gini variable importance) for each SNP is calculated. The scores obtained by a SNP for all folds are then averaged and the result would be the final feature importance score of that variant. In symbols,

$$SNP_{i} = \frac{{\mathop \sum \nolimits_{j = 0}^{N} VI_{gini}^{k} \left( {SNP_{j} } \right)}}{N}$$

where \(VI_{gini}^{k} \left( {SNP_{j} } \right)\) is the SNP importance for the jth fold, N is the number of subjects, and SNPi is the final SNP score of the ith SNP. The final scores are then used to rank the SNPs. The number of top biomarkers included in the clustering process is determined by the researchers as it is already outside the scope of RF. A detailed description on how SNPs are ranked is provided in the ‘Appendix’ section.

SNP-set formation

This study exploited the similarities shared among SNPs to identify novel susceptibility loci associated with HBsAg seroclearance. The analysis utilized the unsupervised machine learning method known as cluster analysis which aims to separate data points into distinct groups such that more similarities are shared among objects within the same group than objects belonging to different groups. Similarities between SNPs can be quantified in terms of agreement, i.e. based on the occurrence of sequence alterations computed via matching coefficients and measures of correlation, or dependence, i.e. based on the presence or absence of dependence quantified via measures based on the χ2-statistic41. This study adopts an agreement-based similarity measure by employing the method proposed in30. This method modified an agglomerative hierarchical clustering algorithm with average linkage for continuous data to develop a Hamming distance-based algorithm for determining SNP-sets. Hamming distance is a similarity measure used to calculate the number of dissimilar components between two categorical data points of the same size42. Applied to SNP data, the Hamming Distance dHAD between SNPs i and j would be,

$$d^{HAD} \left( {i,j} \right) = \mathop \sum \limits_{k = 0}^{n - 1} \left[ {y_{i.k} \ne y_{j.k} } \right]$$

where n is the total number of subjects and yk is the genotype of the kth subject. The similarity measure was adapted on SNP datasets based on the premise that the more individuals carrying the same genotype concerning two given SNPs or two SNP-sets (signified by a relatively small Hamming distance), the more similar the variants are and more likely to cluster30.

Multiple cluster analyses were performed exclusively on GWAS-identified and top-ranking SNPs obtained by random forest. As shown in Table 1 Column 2, the number of SNPs analyzed was gradually increased to achieve a higher likelihood of discovering novel susceptibility loci. The set of SNPs included in each cluster analysis is the union of the 52 significant SNPs from Kim et. al.’s GWAS38 and the top biomarkers identified by random forest (starting from top 1000 to top 5000 SNPs in increments of 1000). Each implementation resulted in candidate SNP-sets identified using the following parameters: percentile cut which specifies the height wherein a dendrogram will be cut and minimum cluster size which dictates the minimum number of SNPs for all clusters.

Table 1 Number of SNPs subjected to cluster analysis.

Association test

Hamming distance-based association tests (HDAT)30 were employed to identify the candidate SNP-sets significantly associated with HBsAg seroclearance. The presence of association depends on the amount of difference in the biomarkers found in cases and controls. Minor alleles were incorporated in the equations as it reveals more similarities in the genomes of two individuals than common alleles43. A comprehensive discussion of the equations used in HDAT can be found in30. Permutation test, a non-parametric test used to evaluate the statistical significance of a model through randomization, is used to compute the p-value of each SNP-set. The test calculates the p-value by permuting the dataset and constructing a test-statistic distribution and evaluating the probability that a test-statistic would be equal to or more extreme than the initial computed value.

Ethics approval and consent to participate

This study used the data provided in38 which was a project approved by the ethics committees at Korea University Anam Hospital (ED13220) and conducted in agreement with the ethical principles of the Declaration of Helsinki. According to the project’s ethical declaration, all patients provided written informed consent for participation and use of their data for research purposes.

Results

Top-ranking SNPs from dimension reduction

This study used random forest feature selection to reduce dataset dimensions prior to conducting cluster analysis. Specifically, random forest was employed to rank SNPs based on their feature importance score, a measure which determines a variant’s relevance in making accurate phenotype predictions. SNPs are assigned a feature importance score based on the average scores for every fold in LOOCV to eliminate bias and ensure robustness. Investigation into the functional significance of three of the top five biomarkers ranked by RF led to possible connections between the variants and HBsAg seroclearance. SNPs rs28588178 (top-ranking SNP), rs1994209 (3rd-ranking SNP), and rs7958186 (5th-ranking SNP) are linked with Cadherin 4 (CDH4), PIG11, and PCED1B, respectively—genes reported to be associated with hepatocellular carcinoma (HCC)44,45,46, a disease that can develop due to the presence of the hepatitis B virus.

Generated SNP-sets

Upon performing multiple cluster analyses, a total of 108 candidate SNP-sets were identified at a percentile cut of 0.9 and a minimum cluster size of 3. SNP-sets with the maximum number of SNPs were chosen in cases where there were overlaps to maximize the information obtained from the analyses.

SNP-sets containing SNPs which were considered significant in a previous GWAS were investigated as the variants sharing high degrees of similarity with GWAS-identified SNPs may also provide insights into trait etiology. As shown in Table 2, SNPs rs2399971, rs2119977, rs6826277, rs35689347, rs1505687, and rs741229 were grouped with at least one of the variants reported to be significantly associated with HBsAg seroclearance (Note: SNPs in boldface are those that obtained a p-value less than 10–4 in Kim et. al.’s GWAS38). Genes were retrieved from dbSNP47 and38.) No information regarding possible association existing between the latter five SNPs and the phenotype of interest was found; meanwhile, the opposite was true for rs2399971. Notably, albeit rs2399971 had not reached the cut-off value used in the GWAS performed by Kim et al.38 on the whole study population, it was nevertheless found to be significantly associated with HBsAg seroclearance in the subjects who had received antiviral treatment38. Figure 2 shows the dendrogram of the GWAS-identified SNPs together with the aforementioned six variants and as presented, the SNPs belonging to the SNP-set which contains rs2399971 shows the least height differences, indicating that the SNPs in the set are more similar to each other than the variants found in other clusters.

Table 2 Cluster memberships of the SNPs that obtained a p-value less than 10–4 in Kim et al.’s GWAS38.
Figure 2
figure 2

Dendrogram of the SNPs listed in Table 2.

Significant SNP-sets

Hamming distance-based association test (HDAT) was performed on the candidate SNP-sets to further identify SNPs possibly associated with HBsAg seroclearance. After performing a Bonferroni correction for multiple tests, 11 SNP-sets significantly associated with HBsAg seroclearance (p-value < 0.0005) were identified, the majority of which (7 out of 11) were found to harbor at least one of the GWAS-identified SNPs. Among the SNP-sets obtaining the lowest p-values, the set which obtained the highest test statistic is the one composed of rs1809862, rs10769023, rs10838245, rs2017434, rs2047456, rs7945342, and rs872751—all GWAS-identified SNPs38. All these variants reside in 11p15.4, a region that shows a possible correlation with HBsAg seroclearance. In a study by48, it was observed that among hepatocellular carcinoma cases, more than 20 percent loss of heterozygosity (LOH) was shown for locus 11p, wherein region 11p15 was commonly affected. Moreover, a significant correlation was found to exist between LOH on 11p and HBsAg positivity. Specifically, results showed that there is a significantly higher frequency of LOH on 11p among hepatitis B virus carriers48.

Table 3 shows the five significant SNP-sets which do not hold any of the GWAS-identified SNPs (p-values were obtained from 10000 permutations). No supporting evidence was found regarding possible associations between the individual variants belonging to the five SNP-sets and HBsAg seroclearance. Nonetheless, interesting findings were discovered when SNPs were analyzed collectively. Results showed that three out of the five SNP-sets in Table 3 harbor SNPs residing in similar genes, i.e. there is a corresponding gene for each distinct set. These are the following: (1) LOC105373438 for SNP-set 3, (2) LINC00578 for SNP-set 4, and (3) STOX2 for SNP-set 5. In49, LINC00578 was reported to be a prognostic marker for pancreatic cancer (PC), a disease for which hepatitis B has been suggested to be a risk factor50,51,52, increasing the likelihood of PC by 24%53.

Table 3 SNP-sets obtaining the lowest p-values (excluding those that harbor variants reported by Kim et al.38 to be significantly associated with HBsAg seroclearance).

Discussion

This study aims to discover novel trait-associated susceptibility loci by augmenting previous GWAS findings using a machine learning-based SNP-set analysis approach built on the integration of RF and cluster analysis. By analyzing SNP-sets instead of individual variants, we increase the chances of discovering other existing true associations in two ways. First, by exploiting the similarities shared among the variants, SNPs that are truly associated with the trait of interest but which did not pass the threshold of significance can still be detected when grouped with statistically significant SNPs. Second, by reducing the unit of analysis into groups, a substantial decrease in the number of tests ensues which eliminates the necessity to adopt stringent thresholds used in considering a SNP significant. Investigation into the functional relevance of variants found in the same SNP-set containing GWAS-identified SNPs and SNP-sets obtaining significant p-values led to the discovery of loci that may also contribute to phenotypic expression yet overlooked by GWAS as a consequence of its individual SNP analysis approach. The novelty in our proposed method lies in the GWAS-based and data-driven approach in feature selection prior to cluster analyses. This study did not restrict the discovery of susceptibility loci to a certain genomic region alone as the criteria for selecting SNPs depend on statistical significance and predictive powers. As a result, the resulting SNP-sets implicated a varied selection of genes and cytobands.

The proposed method was applied on an HBsAg seroclearance GWAS data38 and was able to enhance the GWAS findings in two ways. First is through the discovery of SNPs highly similar with GWAS-identified variants. As shown in Table 2, statistically significant SNPs tend to cluster together. This acts as justification for further investigation of all variants belonging to the sets which contain GWAS-identified SNPs. It is possible that they may be false negatives or linked with the phenotype in some way. For example, rs2399971, a variant detected in the cluster analyses stage, was not considered significant in the GWAS conducted on the whole study population as it did not reach the threshold that was used (obtaining a p-value of 1.05 × 10–4 wherein the cut-off p-value used was 1.00 × 10–4). Nevertheless, it was found to be significantly associated with HBsAg seroclearance in patients who had received antiviral treatment38. The other way in which the proposed approach has successfully enhanced the previous GWAS findings is through the identification of SNP-sets significantly associated with the trait of interest. Variants in Table 3 were not considered as statistically significant by the previous GWAS. However, since the SNP-sets where they belong showed association with the phenotype upon testing, we could say that some, if not all of them, could still be susceptible SNPs. This assumption is based on how HDAT results are interpreted as defined by30. Identifying these significant SNP-sets also allows hypothesis generation not only on SNPs but also on other larger biological units such as genes or cytobands18,29. For instance, gene LINC00578 and locus 11p15, regions implicated by two of the SNP-sets with the lowest p-values, have shown potential in understanding HBsAg seroclearance as both are linked with diseases associated with the presence of hepatitis B virus infection. By mapping out these implicated regions and identifying shared susceptibility loci with a well-researched phenotype, a better understanding of the intricate underpinnings of the trait of interest could be achieved. For instance, some of the SNPs associated with height may be considered in understanding the etiology of HBsAg seroclearance as 11p15 has been reported to harbor genes responsible for growth and development54. Furthermore, elevations in alanine transaminase (ALT) level, a consideration in declaring HBsAg seroclearance, was found to be an important factor for growth impairment in children55.

Despite the advantages of the proposed method, several issues remain to be resolved. First, the total number of SNPs to consider in the clustering process should be optimized in future implementations of the approach so that variants possibly associated with the trait but obtaining low feature importance scores could still have higher chances of being discovered. Secondly, parameter values would still have to be tuned by utilizing specific measures such as gap statistics56,57 to ensure an optimal number and a more cohesive composition of SNP-sets. Thirdly, the type of clustering procedure and association test employed on the SNP-sets should be modified depending on the goals of a study. HDAT, the association test used herein, only evaluates whether a SNP-set could distinguish different disease phenotypes. It does not determine if there is a presence of interaction in the set and even more so if that interaction is significant. Accounting for complex SNP interactions and nonlinear effects would require employing a different type of test on the SNP-sets such as the logistic kernel-machine-based test by18.

Aside from optimizing the settings directly involved in the actual data analysis, another fundamental issue that needs to be addressed in this study is the possible presence of population structure in the dataset which could negatively affect the clustering results and could lead to spurious associations. Some approaches that could be used to correct for this include principal component analysis (PCA) and clustering techniques which utilize similarity measures such as the allele-sharing distance (ASD)58. However, the results of these techniques could be distorted when there is a large number of correlated markers due to linkage disequilibrium (LD)58. To address this problem, one could employ a clustering-based strategy on the SNPs initially in order to minimize the number of markers to only the most informative ones59. Following these premises, a proposed approach that could be utilized to avoid unreliable results is to perform clustering on the SNPs first to select representative markers, then on the patients to identify subpopulations, and lastly on the variants once again to identify the final list of SNP-sets that would then be subjected to the association tests. Although correcting for population structure is a prerequisite for any genetic data analysis, it should be proceeded with caution when the dataset being analyzed contains only a few observations (small sample size). In these settings, handling population stratification could be more complicated than usual especially if statistical power is at stake30. Mentioned that even though it is intuitive to address population stratification first before conducting association tests on the case and control groups of the same population, if the stratified populations are only of smaller sizes, then it could just lead to unstable findings.

Conclusion

This study aims to identify disease-associated susceptibility loci by augmenting previous GWAS findings using the integration of RF and cluster analysis. The proposed approach was applied to a hepatitis B virus surface antigen (HBsAg) seroclearance GWAS data38. Thereafter, the researchers were able to detect rs2399971, a variant that was not considered to be significantly associated with the phenotype in the main GWAS, but which obtained a significantly low p-value in a subgroup analysis38. Results of the association tests conducted on the generated SNP-sets led to the implication of gene LINC00578 and locus 11p15. The former was linked with pancreatic cancer49 and the latter with hepatocellular carcinoma48, diseases associated with hepatitis B virus infection. There are three ways in which readers could reinforce their findings using the proposed approach. The first one could be done during the dimension reduction phase wherein random forest is employed to identify SNPs which are highly predictive of the trait of interest. If a researcher found that the variant they discovered to be associated with a phenotype is also one of the top-ranking SNPs as per RF, then this could provide strong evidence for follow-up investigations on the said variant. Predictive importance and association do not always coincide and so if they do, it could show important promise for clinical translation. The second way that readers could reinforce their findings is by looking at the SNP-sets which are significantly associated with the trait of interest. By identifying the genomic regions implicated by these sets, further evidence is provided to studies reporting on the significance of the said regions on a given phenotype. And lastly, one could check if the variant discovered to be associated with a phenotype belongs to a set which contains GWAS-identified SNPs. For instance, SNP rs2399971 was discovered in this study as it shared a high degree of similarity with variants significantly associated with HBsAg seroclearance. This somehow supports38’s finding on the association existing between rs2399971 and HBsAg seroclearance on patients who had received antiviral treatment38. Researchers who aim to extend this study could experiment on different supervised learning techniques for feature selection and utilize other similarity measures for clustering SNPs. With further investigation and validation, insights gleaned using the proposed framework could also be integrated into prediction models to aid in quantifying patients’ risks for trait or disease development.

Data availability

The dataset used in this study can be accessed through this link: https://figshare.com/articles/dataset/gtReport_txt/6614975. The Python code used for implementing random forest can be found in https://github.com/jdgaudillo/SNP-ML.git while the R codes for clustering and association tests are available at http://homepage.ntu.edu.tw/~ckhsiao/HammingDistance/HD.htm.