Filtered circular fingerprints improve either prediction or runtime performance while retaining interpretability
BackgroundEven though circular fingerprints have been first introduced more than 50 years ago, they are still widely used for building highly predictive, state-of-the-art (Q)SAR models. Historically, these structural fragments were designed to search large molecular databases. Hence, to derive a compact representation, circular fingerprint fragments are often folded to comparatively short bit-strings. However, folding fingerprints introduces bit collisions, and therefore adds noise to the encoded structural information and removes its interpretability. Both representations, folded as well as unprocessed fingerprints, are often used for (Q)SAR modeling.ResultsWe show that it can be preferable to build (Q)SAR models with circular fingerprint fragments that have been filtered by supervised feature selection, instead of applying folded or all fragments. Compared to folded fingerprints, filtered fingerprints significantly increase predictive performance and remain unambiguous and interpretable. Compared to unprocessed fingerprints, filtered fingerprints reduce the computational effort and are a more compact and less redundant feature representation. Depending on the selected learning algorithm filtering yields about equally predictive (Q)SAR models. We demonstrate the suitability of filtered fingerprints for (Q)SAR modeling by presenting our freely available web service Collision-free Filtered Circular Fingerprints that provides rationales for predictions by highlighting important structural features in the query compound (see http://coffer.informatik.uni-mainz.de).ConclusionsCircular fingerprints are potent structural features that yield highly predictive models and encode interpretable structural information. However, to not lose interpretability, circular fingerprints should not be folded when building prediction models. Our experiments show that filtering is a suitable option to reduce the high computational effort when working with all fingerprint fragments. Additionally, our experiments suggest that the area under precision recall curve is a more sensible statistic for validating (Q)SAR models for virtual screening than the area under ROC or other measures for early recognition. Graphical Abstract Electronic supplementary materialThe online version of this article (doi:10.1186/s13321-016-0173-z) contains supplementary material, which is available to authorized users.
Background<!>AUPRC (area under precision recall curve) as early recognition measure<!><!>Results and discussion<!><!>Initial results with default parameters<!><!>CoFFer—a prediction web service with interpretable predictions<!><!>CoFFer—a prediction web service with interpretable predictions<!><!>Algorithms and validation<!><!>Conclusions<!>Filtering fingerprints with supervised feature selection<!><!>Ranking of structural fragments that are used as (Q)SAR prediction features<!>Coloring of compound fragments<!>
<p>(Q)SAR [(Quantitative) structure-activity relationship] models are effective tools to predict the biological or chemical activity of chemical compounds. The broad range of applications includes toxicity testing, where (Q)SAR modeling is an important alternative approach to lower the demand of in vivo animal testing. In drug design, lead compounds can be detected by applying (Q)SAR models for virtual screening, replacing extensive in vitro experiments [1]. The major advantage of the computer-driven approach is that these in silico models are faster and save money compared to conservative testing methods [2]. One of the drawbacks is that it is hard to understand the reasoning behind (Q)SAR model predictions: commonly (Q)SARs are built by training machine learning algorithms and therefore often resemble black boxes. However, interpretability of model predictions to discover a possible mode of action of the query compound is often demanded, e.g., by the OECD guidelines for valid (Q)SAR models [3]. A precondition for interpretable predictions is to train and apply the model with explicable and meaningful features. It is hard to extract any knowledge in case the feature space is encoded in a complex way and the chemical or biological information that the feature values are based on is opaque. One type of such encoded features are folded fingerprints.</p><p>A fingerprint is a bit-wise string, that includes only zeros and ones, encoding absences and presences of structural fragments. Often, fingerprints are folded to a fixed length to yield a compact representation of a potentially large list of structural fragments [4]. Folding introduces bit collisions, as the bit vector size is commonly much smaller than the number of features: multiple different fragments are assigned to the same position in a bit vector. The folding procedure is a one way transformation, i.e., it is not possible to distinguish between several structural features that have been mapped to a particular bit when having only the bit vector available. Bit collisions do not only remove interpretability, they also introduce ambiguity that could possibly deteriorate the prediction model. As an example, an important structural alert could be absent in a query compound. However, the query compound could possibly contain a completely different fragment that is assigned to the same bit position. Nevertheless, due to the sparsity of structural fragments (i.e., each fragment is usually missing in most of the compounds), folded fingerprints have been shown to work well in practice for building predictive (Q)SAR models (see below).</p><p>One category of structural fingerprints are the so-called circular fingerprints, which have already been introduced by Morgan in 1965 [5]. Despite their name, circular fingerprints yield single, separate structural fragments (that could possibly be employed without a bit-wise fingerprint). The fragments have a circular shape: starting with an initial atom, each fragment is extended by taking neighboring atoms into account. An important parameter for the fragments is the diameter that relates to the number of bonds. Fragments with diameter zero describe only the centering atom, fragments with diameter two contain all immediate neighbors of the center, diameter four includes a second layer of neighbors, and so on. A possible representation of circular fingerprint fragments assigns a numeric ID to each fragment, that is created by adding up the IDs of the atoms included in the fragment. The exact information about atoms encoded in the IDs depends on the fingerprint type. A common type is extended-connectivity fingerprints (ECFPs) [4], where the numeric IDs includes a range of atomic properties (like, e.g., atomic number, charge, valence, number of heavy atom neighbors, whether the atom is included in a ring, and so on). The chance that different fragments have the same numeric ID (without applying folding) has been shown to be slim.1 The fragments are mined separately for each molecule and can directly be mapped to the fingerprint bit vector by employing the numeric ID as hash-key. If folding is enabled, the numeric ID is reduced by multiples of the fixed bit vector length until it fits on the fingerprint (using the modulo operation). By default, fragments are enumerated without a support threshold (i.e., with a minimum frequency of 1).</p><p>Currently, there are two freely available cheminformatics libraries to mine ECFPs.2 Even though folded fingerprints are regularly applied for model building [6, 7], many researchers agree that bit-collisions might have a negative effect on modeling. Accordingly, researchers often use unprocessed fingerprints (i.e., without folding) to build (Q)SAR models [8–10]. A comparison, which was restricted to a single dataset, showed that unprocessed fragments can improve modeling results using Logistic Regression [11]. However, the same work stated the contrary for naive Bayes, unprocessed fingerprints for model building decreased the model performance. Additionally, in this study it was technically not feasible to build a random forest model due to the large amount of features. Rogers et al. [12] show that an adjusted version of naive Bayes can work well with unfolded fingerprints. Hence, naive Bayes is modified to employ only fragments that are present in the query compound for prediction and a correction term is introduced for infrequent features [13]. Also limited to a single dataset is the work of Liu et al. [14], who show that different folding sizes of 512, 1024, and 2048 produce only marginal model predictivity differences.</p><p>Circular fingerprints have initially been introduced for similarity searching. For this application, it has been shown that using unprocessed instead of folded fingerprints provides only a small performance gain [15, 16]. Hu et al. [17] present an approach that improves search results by employing only fragments that are present in active compounds.</p><p>We present, to the best of our knowledge, the first comprehensive and systematic comparison of unprocessed and folded fingerprints for (Q)SAR modeling and virtual screening. Moreover, we show that reducing the amount of features with endpoint-specific (i.e., supervised) feature selection is superior to folding. Filtering reduces the computational effort for modeling (similar to folding), while improving the model predictivity by avoiding bit collisions. Additionally, feature selection has the positive effect of retaining the interpretability of features. We demonstrate this by presenting the freely available modeling web service CoFFer (Collision-free Filtered Circular Fingerprints) that provides rationales for predictions.</p><p>This work is structured as follows. In the remainder of the "Background" section, we still elaborate on the type of validation conducted in the paper. In particular, we argue that AUPRC (the area under precision recall curve) is a suitable validation measure for virtual screening. The results section compares the performance of (Q)SAR models built with unprocessed, folded and filtered circular fingerprints and introduces our prediction web service. Details of the experimental setup and implementation are provided in the "Experimental" section. Subsequently, we provide a conclusion before presenting the methods used in this work.</p><!><p>A property of virtual screening datasets is the skewed class distribution: commonly, the number of active compounds is much lower than the number of inactives (in our context, also often referred to as decoys). Hence, accuracy is not a good option as predicting all or most compounds as inactive already yields a very high score.</p><p>The well known AUROC (the area under the receiver operating characteristic (ROC) curve) measure is based on ranking compounds according to their predicted probability of being active. y-axis and x-axis of the ROC curve are true positive rate (also named sensitivity or recall) and false positive rate [18]. The area under the ROC curve usually ranges between 0.5 (random) and 1.0 (perfect), and has the nice property that it can be interpreted as the probability that a randomly drawn positive instance is ranked higher than a randomly drawn negative instance. However, AUROC has the drawback that all compounds within the ranking have equal weight, whereas in virtual screening, researchers are usually more interested in the compounds that are most likely active, and less interested in the compounds that are less likely active. Hence, early recognition measures like EF (enrichment factor) and BEDROC (Boltzmann-Enhanced Discrimination of ROC) have been developed [19, 20].</p><p>Enrichment factor (EF) compares the ratio of active compounds in the entire dataset to the ratio of active compounds within the top \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$\chi $$\end{document}χ ranked compounds [20]. The researcher has to manually decide on a threshold \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$\chi $$\end{document}χ (often one or five percent is selected). EF is insensitive to changes that do not "cross" this threshold (e.g., the enrichment factor does not increase when the ranking improves within the top \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$\chi $$\end{document}χ percent). Moreover, the score is based on the original ratio of active compounds in the entire dataset and can hardly be used to compare predictions on datasets with different class distributions.</p><p>BEDROC is based on robust initial enhancement (RIE), which uses continuously decreasing exponential weight when ranking compounds according to estimated probability [19]. It is bounded between 0 and 1. BEDROC has the drawback to depend on a parameter alpha that defines the exponential weight (and therefore its sensibility towards early recognition).</p><p>We here propose to use the area under the precision recall curve (AUPRC) as validation statistic. To the best of our knowledge it has not been used in virtual screening so far, even though it has been described as a more sensible measure on datasets with skewed class distributions [21–23] than the area under the ROC curve (AUROC). Moreover Davis et al. [21] show that, when comparing validation results, AUROC dominates if and only if AUPRC dominates and that algorithms that optimize AUROC not necessarily optimize AUPRC. Similarly to the ROC curve, the precision recall curve has the true positive rate (recall) as y-axis, however on the x-axis precision is employed (also referred to as selectivity or positive predictive values). For high probability values the curve is calculated with only few compounds as all true negative predictions are ignored by precision and recall. To this end, predictions with high probability have a higher influence on AUPRC than predictions with lower probability, which is desirable when analyzing virtual screening results.</p><p>As a drawback, the baseline of the area under the precision recall curve is equal to the ratio of active compounds in the dataset. In other words, the AUPRC score ranges between the ratio of active compounds (random prediction) and 1 (perfect prediction). This dependency of AUPRC hinders comparisons of margins of improvement between datasets with different class distributions and reduces the interpretability of AUPRC scores. Accordingly, the precision under the precision recall curve is neither "independent to extensive variables" [24] nor is its interpretation as intuitive as, e.g., AUROC scores. However, it full-fills other favorable characteristics of validation measures listed by Nicholls [24] as it has no free parameters, and can be estimated in a robust way providing confidence intervals [25]. Overall, we consider AUPRC to be an appropriate measure for validating virtual screening experiments especially due to its suitability for skewed class distributions.</p><!><p>Comparing AUPRC to other virtual screening measures when improving a reference ranking (a) at different positions (b–e)</p><p>Each bit resembles an active (1) or inactive compound (0). Each bit-string (a–e) corresponds to the result of a classifier that ranks all test-set compounds according to their predicted probability of being active. A perfect prediction would list all "1s" before "0s". The reference prediction (a) has an AUROC (the area under the ROC curve) score of 0.864 (Hence, the probability that a randomly drawn active compound is ranked higher than an inactive compound is 86.4%). We improve the reference prediction (a) by modifying the predicted probability of a single compound at different positions in the ranking: in (b–d), a single active compound is predicted with higher probability and shifted 4 positions upwards in the ranking. In (e), a single inactive compound is predicted with lower probability and is moved 4 positions downwards in the ranking. When performing virtual screening, the last change (e) is probably most important to us, as we are interested in the compounds that are most likely active. However, the change in AUROC is constant for (b–e). EF (enrichment factor) and BEDROC (Boltzmann-Enhanced Discrimination of ROC) have the disadvantage of relying on a user defined parameter. Moreover, EF-5% changes only if the number (not the ordering) of active compounds within the top \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$\chi $$\end{document}χ bits (here: 3) differs. On the contrary, AUPRC (the area under precision recall curve) has the desired property that it increases more when the affected ranking position is higher without relying on a parameter (Please find ROC and precision recall curves for (a–e) in the Additional file 1)</p><!><p>This section is divided into two parts. The first part compares model building results for folded, unprocessed, or filtered circular fingerprint fragments. The second part presents a freely available (Q)SAR prediction service that provides a rationale for each prediction based on un-folded, interpretable circular fingerprints.</p><!><p>Overview of results</p><p>Unprocessed fragments yield random forest (RF) models and support vector machine (SVM) models with good performance and retain interpretability, but require a high computational cost. Folded fragments allow fast processing, but generate inferior models and are non-interpretable due to bit collisions. Filtered fragments yield the best naive Bayes (NB) models and can be employed to build RF models that are equally good as those built with unprocessed fragments. Filtered fragments also retain interpretability and allow fast processing</p><p>In summary, unprocessed (all) fragments are a good option if there are enough computational resources to optimize SVMs and the vast amount of (often redundant) features does not hinder interpreting predictions. Otherwise, filtered fragments should be preferred</p><p>In general, RF models yield good results without parameter tuning, however, SVM models are usually better when their parameters have been optimized (see section on parameter optimization)</p><!><p>In this work, we have selected three well known machine learning algorithms: random forests, support vector machines, and naive Bayes. The algorithms are applied to a range of 76 datasets (see "Experimental" section). Initially, we have selected ECFPs (extended-connectivity fingerprints) with diameter four. The size of the folded fingerprint is 1024, which is the probably most commonly used bit-vector length. To ensure a fair comparison, we have applied our supervised filtering method to select 1024 features as well.</p><!><p>Validation results for ECFP4 for unprocessed, folded and filtered fingerprints (folded/filtered bit-vector size is 1024). For the random forest (RF) algorithm, 5 measures are provided for each of the 76 datasets. The difference between folded fingerprint features and filtered/unprocessed features is less distinct considering the area under the ROC curve (AUROC), and enrichment factor (EF), and more distinct considering the area under precision recall curve (AUPRC). Run-time measure the seconds to mine fragments and build a model and is highest for unprocessed features. The remaining charts for support vector machines (SVM) and naive Bayes (NB) are provided in Additional file 2</p><p>Mean changes in AUROC and AUPRC when comparing filtered, folded and unprocessed fingerprints (ECFP4 with bit-vector size 2048). The applied machine learning algorithms are random forests (RF), support vector machines (SVM) and naive Bayes (NB). Note that the scale for the area under the ROC curve (AUROC) is half the scale of the area under prediction recall curve (AUPRC): both measures have a maximum value of 1, however, the baseline of AUROC scores is 0.5 whereas the baseline of AUPRC is close to 0 on some datasets (on the MUV datasets, the ratio of active compounds is 0.002). Run-time corresponds to the speedup for mining the features and building a model of filtering/folding compared to unprocessed fragments. The run-time of filtering is only slightly slower than folding, as both methods yield an equal number of features and the actual filtering routine is fast (on average 5.1 s) compared to the entire model building process (38.4 s for RF)</p><p>Average number of fragments and bit-collisions when folding circular fingerprints on our datasets</p><p>Rate is the ratio of bit positions that are mapped by more than one fragment (e.g., 99% of bit-positions correspond to multiple fragments for ECFP4 and bit-vector size 1024). Bit-load is the mean number of fragments that are mapped to a single bit</p><p>Win loss statistics to compare AUPRC scores of different feature selection techniques with increasing bit-vector lengths (using ECFP4). Each bar corresponds to a pairwise comparison of two methods on 76 datasets. Wins of the first/second method are colored in blue/red colors and drawn above/below zero respectively. Intense colors indicate significant wins/losses and are additionally stated in numbers above each bar. When comparing filtering/folding to unprocessed fragments, increasing bit-vectors for filtering/folding are compared to the entire unprocessed feature set. Filtering is in general better than folding. The longer the bit-vector, the more similar are the folded or filtered feature sets to the unprocessed feature set. Filtered features yield equally predictive models as unprocessed fragments for RF, less predictive models for SVM and largely improved models for NB. Folding deteriorates predictivity compared to unprocessed fragments unless NB is used</p><p>Win-loss statistics to compare AUPRC scores of ECFP diameter 4 to diameters 0, 2, and 6 (for unprocessed fingerprints and 1024 filtered fingerprint fragments). Each bar corresponds to a pairwise comparison of two methods on 76 datasets. Wins of the first/second method are colored in blue/red colors and drawn above/below zero respectively. Intense colors indicate significant wins/losses and are additionally stated in numbers above each bar. Diameter 4 yields in general the most predictive models. Exceptions are naive Bayes and diameter 0 and 2, which is due to the low number of features with low diameter. However, when applying filtering ECFP4 works best for naive Bayes. Moreover, slightly more predictive support vector machines can be build using ECFP6</p><p>Number of selected configurations for optimized web service models (for each of the 76 datasets)</p><p>To limit the number of parameters we skip FCFPs and set the ECFP diameter to 4. For support vector machines different parameters have been optimized (as described in "Experimental" section). A complete list of selected parameters and nested cross-validation results can be found in Additional file 2</p><!><p>We created a prediction web service to demonstrate the feasibility and utility of the previously described filtering approach. The web service is called CoFFer (Collision-free Filtered Circular Fingerprints). It is open-source. A freely available prototype is running at http://coffer.informatik.uni-mainz.de. It offers 76 (Q)SAR models that can be applied to untested query compounds. The service ranks and highlights the circular fingerprint features that have been used by the (Q)SAR model to help interpreting the prediction result.</p><!><p>Win-loss statistics comparing ECFPs vs FCFPs at different diameters for unprocessed and filtered (1024) fragments. Each bar corresponds to a pairwise comparison of two methods on 76 datasets. Wins of the first/second method are colored in blue/red colors and drawn above/below zero respectively. Intense colors indicate significant wins/losses and are additionally stated in numbers above each bar. ECFPs are mostly better when using unprocessed features, except naive Bayes for diameters 4 and 6. The explanation is the lower number of features produced by FCFPs. When applying filtering, ECFPs always lead to more predictive models than FCFPs</p><p>Workflow of the freely available CoFFer prediction web service. The service is available at http://coffer.informatik.uni-mainz.de. Please refer to the results section for a description</p><!><p>Finally, the CoFFer web service provides information about the occurrence of the employed fingerprint features in the training dataset (E). Here, the phenolic ring pattern matches 92 compounds, 87 of these compounds are estrogen receptor ligands.</p><!><p>The 76 datasets used for our model building experiments</p><p>Multiple occurrences of the same compound are inserted only once. E.g., some of the originally 15,000 decoys for each MUV dataset are removed. In case, multiple occurrences have differing endpoint values, the compound is omitted. Only 5 of 7 endpoints from the CPDBAS dataset could be used for this study as two endpoints (Hamster and Dog/Primates) are to small and yield less than 1024 ECFP4 fragments. A more detailed list of datasets is provided in Additional file 2</p><!><p>We have used the machine learning library WEKA [34] (v3.7.13) for modeling and selected three well known classifiers: random forests [35], naive Bayes [36] and support vector machines [37]. A 3-times repeated tenfold cross-validation has been applied to compare folded, filtered and unprocessed features sets (employing default algorithm parameters without optimization). Filtering of fragments has been carried out within the training data fold of each cross-validation to avoid information leakage. Significance tests have been performed with a corrected paired t test with a p value threshold of 0.05 [38].</p><p>To build the most predictive model for each dataset, we optimized support vector machine parameters and selected the best number of features (see Fig. 4). In order to avoid estimating an over-optimistic validation score, we applied a nested \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$3 	imes 3 	imes 10$$\end{document}3×3×10-fold cross-validation. Model selection is performed on the inner cross-validation loop, and the predictivity estimate of the selected model is evaluated with the outer cross-validation loop. To limit the huge computational effort of nested cross-validation, we fixed fingerprint type and diameter to ECFP4. Within the inner loop of the nested cross-validation we selected the number of fingerprint fragments (1024–8192) and the best parameters for support vector machines. We tested c-values 1, 10, and 100 with a linear kernel and a radial basis function (RBF) kernel. Additionally, gamma values 0.001, 0.01 and 0.1 are tested for the RBF kernel. Random forests and naive Bayes have been applied with default parameters (which is 100 trees for the random forest algorithm). See Additional file 2 for detailed results. The HPC cluster of Johannes Gutenberg Universität Mainz, Mogon, made this computationally extensive evaluation feasible.</p><!><p>provides mining and filtering of circular fingerprints. It is based on the implementation of circular fingerprints in the chemistry development kit (CDK) [39]. Our library adds different bit-vector lengths as well as our filtering approach. Moreover, we provide a depiction functionality to draw a circular fingerprint fragment within a compound.</p><p>extends the machine learning framework WEKA with a nested cross-validation and basic ranking functionalities to sort features according to their influence on a prediction.</p><p>is based on the previous libraries and allows to build and validate (Q)SAR models with circular fingerprint fragments.</p><p>provides the Apache CXF implementation of the CoFFer web service (currently running here: http://coffer.informatik.uni-mainz.de). Additionally to the graphical user interface, it has a REST interface that simplifies the integration of our service into other frameworks and is compliant with the OpenTox API [40]. Moreover, our web service accesses PubChem and ChEMBL to provide additional information for the predicted compounds, and maintains links to sources of modeled endpoints and datasets.</p><!><p>Circular fingerprints can be applied to yield highly predictive (Q)SAR models. Commonly, either unprocessed fingerprints or folded fingerprint fragments are employed, even though the latter introduces bit collisions. This work provides a comprehensive comparison between folded and unprocessed fingerprints. We show that folding improves the model building run-time but yields slightly (yet often significant) less predictive models. Unprocessed fingerprints have also the advantage of retaining interpretability of structural fragments. We introduce a supervised filtering approach, that combines the advantages of both methods: it produces a smaller, less redundant set of interpretable structural features, reduces the computational effort for model building, and yields predictive models. For the presented validation study, we selected the area under precision recall curve (AUPRC) as validation measure. This statistical measure is preferable to the commonly used area under ROC, as it has the advantage of being more sensible to predictions of compounds that are predicted as active with high probability. Moreover, we present a prediction web service that showcases our approach and provides rationales for predictions. To this end, we developed a technique to rank the structural fragments according to their influence on the prediction. The model service is open-source, freely available and can be accessed directly with the browser or with a REST interface.</p><p>In the future, we plan to integrate the prediction models into the OpenTox service ToxPredict [40]. Additionally, filtered circular fingerprints could be incorporated into our 3D-space mapping and visualization tool CheS-Mapper [41].</p><!><p>We apply supervised feature selection to limit the amount of circular fingerprint fragments as an alternative to folding. The main advantage of this method is that bit-collisions are avoided. Hence, well-defined structural fragments that are either present or absent in a query compound are employed as features for the (Q)SAR model. The input for our method is a list of fragments (x-values) and the endpoint (y-values) of the training set compounds. The output is a reduced number of x-values, i.e., the number of columns in the training dataset decreases.</p><p>The high-level pseudo-code for our method is given in Table 6. After stripping compounds that match only a single compound, we remove non-closed fragments. In the context of graph mining, a fragment is not closed if there exists a sub-fragment that matches the exact same set of compounds. Closed fragment mining has been shown to be an effective way to greatly reduce the number of features and decrease redundancy [42]. Subsequently, if the number of fragments is still to large, supervised feature selection is applied using a \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$\chi ^2$$\end{document}χ2 filter. Hence, features that have no measurable correlation to the target endpoint are removed. This supervised feature selection method for molecular fragments has been successfully applied (and is nicely explained) by Maunz et al. [43]. The implementation of our filter method for circular fingerprints is freely available as described in the "Experimental" section above.</p><!><p>Pseudo-code for filtering circular fingerprints with supervised feature selection</p><p>\documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$^{(1)}$$\end{document}(1)Redundant := non-closed; i.e., a fragment is redundant if there exists a sub-fragment that matches the same compounds.</p><p>\documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$^{(2)}$$\end{document}(2)Fragments with the lowest p value of a \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$\chi ^2$$\end{document}χ2 test are removed; the test measures the correlation between the endpoint value distribution of all compounds, and the compounds that match the fragment</p><!><p>Our method ranks features according to their contribution to a particular (Q)SAR model prediction. Subsequently, the most important present and absent substructures in the query compound can be presented to the user and aid in understanding the (Q)SAR model and in deriving a mechanistic interpretation. The input for our method is a classifier for binary class values (e.g. active and inactive), a query compound, and the structural features to be ranked. The result of our method is a ranking of features. Additionally, the features are divided into two lists of fragments that are either present or absent in the query compound. Moreover, it is determined whether a feature has an activating or deactivating effect on the prediction. An example is given in the result section [see (D1) and (D2) in Fig. 6].</p><p>The importance of a feature is computed by swapping the feature value of the fragment and re-classifying the compound. The features are ranked according to the absolute value of the difference in predicted probability. The prefix of the change is used to tag the feature as activating or deactivating: a feature is marked as activating if it is originally present in the compound and a re-classification with swapped feature value leads to a lower probability of being active. Also, a feature is marked as activating if it was originally absent in the query compound and the predicted probability with swapped feature value leads to a higher probability to be active. Otherwise, we consider the feature to be deactivating.</p><p>When swapping feature values for a fragment, the method takes the compound structure into account. If the evaluated fragment is originally present in a compound, its super-fragments (that extend this fragment) will be switched off as well when evaluating the importance of the fragment. Additionally, sub-fragments that are included in this fragment and do not match the compound at a different location are disabled. Accordingly, if the evaluated fragment is originally absent in the compound and is switched on for evaluation, then all sub-fragments (that are contained within this fragment) are switched on simultaneously.</p><p>A drawback of this method is that it might be computationally extensive for large feature sets and slow prediction algorithms (like, e.g., instance based or local models). The main advantage of our method is that it is model independent, i.e., it can be applied with any classifier that provides a probability estimate for a prediction. Moreover, even though we only use it for binary class values, the method can easily be extended to multi-class problems or quantitative prediction (i.e., regression).</p><p>A similar approach that computes the most important structural fragment for a single prediction of a query compound has been presented by Ahlberg et al. [44]. Like our approach, this method evaluates the importance of each feature by re-predicting the query compound with a modified feature vector. Our method has binary feature values (a sub-structure does either match or not match a compound), whereas the method by Ahlberg et al. is based on numeric feature values, counting the number of occurrences of a sub-structure. Accordingly, our approach toggles the feature value for estimating the importance of a particular feature, whereas the other method increases the count. Moreover, the method by Ahlberg et al. does not take dependencies between structural features into account (e.g., the count of \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$N-C$$\end{document}N-C is increased but not the count for N), and absent fragments are not tested.</p><!><p>We depict a circular fingerprint fragment by highlighting the atoms that match this fragment within a compound. Activating fragments are colored in red, deactivating fragments are colored in blue [see (D1) and (D2) in Fig. 6].</p><p>Additionally, we highlight activating and deactivating parts within the query compound. Hence, the weight of each present fragment (i.e., the difference in predicted probability when the feature was swapped) is summed up for all atoms and bonds that match the fragment. The weight is positive for activating and negative for deactivating fragments. Subsequently, the summed-up weights are used as input for a color gradient that ranges from blue (deactivating) to white (neutral) to red (activating).</p><p>The implementation of the depiction is based on the CDK and freely available (see "Experimental" section).</p><!><p>Additional file 1.  AUPRC and AUROC curves for Table 1.</p><p>Additional file 2 . Additional validation plots and tables.</p><p>Collision-free Filtered Circular Fingerprints</p><p>(quantitative) structure-activity relationship</p><p>extended-connectivity fingerprint</p><p>functional class fingerprint</p><p>receiver operating characteristic</p><p>area under ROC curve</p><p>Boltzmann-Enhanced Discrimination of ROC</p><p>enrichment factor</p><p>area under precision recall curve</p><p>chemistry development kit</p><p>representational state transfer</p><p>radial basis function</p><p>high-performance computing</p><p>The collision rate of unfiltered fingerprints is 0.025% for 1 million features [4].</p><p>Currently, only RDKit (http://www.rdkit.org) and CDK [39] provide the computation of ECFP fingerprints (among other types of fingerprints). Open Babel [45] allows calculating MOLPRINT 2D circular fingerprints [46]. The fingerprinting functionalities of the Indigo Toolkit (http://lifescience.opensource.epam.com/indigo) are tree based.</p><p>In [16], a 50-times repeated holdout validation is performed, using 20% of the compounds for training and 80% as test set. Thus, the models are build on a relatively small amount of the data, which explains the reduced predictivity compared to our approach. Although, the disadvantage of small training datasets was compensated to a degree by increasing the relative amount of active compounds in the training dataset compared to the test dataset.</p><p>Our applicability domain evaluation is based on the distance measure D(c), which is defined as the mean Tanimoto distance to the three nearest neighbors in the training dataset (computed with the same structural fragments that are employed by the respective (Q)SAR model). The distance D(c) is computed for each training compound and the thus created distribution is fitted to a normal distribution. To evaluate a query compound, we compute the cumulative probability \documentclass[12pt]{minimal}
				sepackage{amsmath}
				sepackage{wasysym} 
				sepackage{amsfonts} 
				sepackage{amssymb} 
				sepackage{amsbsy}
				sepackage{mathrsfs}
				sepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				egin{document}$$P(X \le x)$$\end{document}P(X≤x) of its distance D(c), which resembles the probability that a randomly selected training distance is less than or equal to the query compound distance. The query compound is accepted if P is less than or equal to 0.95.</p>