Liver Disease Prediction using Machine Learning Algorithms
Objectives: Liver disease includes several disorders, such as fatty liver, hepatitis, cirrhosis, and liver failure, that interfere with normal liver function. These conditions often progress silently, and early symptoms such as fatigue, nausea, loss of appetite, jaundice, abdominal pain or swelling, dark urine, pale stools, and unexplained weight loss are frequently ignored. Early prediction of liver disease is essential for timely diagnosis and treatment. This study aims to develop an effective machine-learning model for predicting liver disease and to compare the performance of three classification algorithms.
Methods: A liver disease dataset containing clinical and biochemical features such as age, gender, total and direct bilirubin, alkaline phosphatase, SGPT, SGOT, total protein, albumin, and albumin-globulin ratio was used. Data preprocessing involved handling missing values, normalization, and splitting into training and testing sets. Three classification algorithms-Logistic Regression, Decision Tree, and Random Forest were implemented in Python. Model performance was evaluated using accuracy, precision, recall, F1-score, and ROC AUC metrics.
Findings: The results revealed that the Random Forest classifier achieved the highest prediction accuracy compared to the Logistic Regression and Decision Tree models. The Random Forest model demonstrated strong generalisation and effectively distinguished between healthy and diseased liver conditions. The study concludes that machine-learning approaches can provide reliable support for early detection of liver disease, thereby assisting clinicians in decision-making and improving patient outcomes.