Motivation: Precision medicine is a promising field that proposes, in contrast to a one-size-fits-all approach, the tailoring of medical decisions, treatments or products. In this context, it is crucial to introduce innovative methods to stratify a population of patients on the basis of an accurate system-level knowledge of the disease. This is particularly important in very challenging conditions, where the use of standard statistical methods can be prevented by poor data availability or by the need of oversimplifying the processes regulating a complex disease. Results: We define an innovative method for phenotype classification that combines experimental data and a mathematical description of the disease biology. The methodology exploits the mathematical model for inferring additional subject features relevant for the classification. Finally, the algorithm identifies the optimal number of clusters and classifies the samples on the basis of a subset of the features estimated during the model fit. We tested the algorithm in two test cases: an in silico case in the context of dyslipidemia, a complex disease for which a large population of patients has been generated, and a clinical test case, in the context of a lysosomal rare disorder, for which the amount of available data was limited. In both the scenarios, our methodology proved to be accurate and robust, and allowed the inference of an additional phenotype division that the experimental data did not show. Availability and implementation: The code to reproduce the in silico results has been implemented in MATLAB v.2017b and it is available in the Supplementary Material.