• Ibrahim Hassan Hayatu Institute for Agricultural Research, Ahmadu Bello University, Zaria, Nigeria
  • Abdullahi Mohammed Department of Computer Science, Ahmadu Bello University, Zaria
  • Barroon Ahmad Isma’eel Department of Computer Science, Ahmadu Bello University, Zaria, Nigeria
  • Sahabi Yusuf Ali Department of Computer Science, Ahmadu Bello University, Zaria, Nigeria
Keywords: Clustering, kmeans, soil, fertility, clustering tendency


Soil fertility determines a plant's development process that guarantees food sufficiency and the security of lives and properties through bumper harvests. The fertility of soil varies according to regions, thereby determining the type of crops to be planted. However, there is no repository or any source of information about the fertility of the soil in any region in Nigeria especially the Northwest of the country. The only available information is soil samples with their attributes which gives little or no information to the average farmer. This has affected crop yield in all the regions, more particularly the Northwest region, thus resulting in lower food production.  Therefore, this study is aimed at classifying soil data based on their fertility in the Northwest region of Nigeria using R programming. Data were obtained from the department of soil science from Ahmadu Bello University, Zaria. The data contain 400 soil samples containing 13 attributes. The relationship between soil attributes was observed based on the data. K-means clustering algorithm was employed in analyzing soil fertility clusters. Four clusters were identified with cluster 1 having the highest fertility, followed by 2 and the fertility decreases with an increasing number of clusters. The identification of the most fertile clusters will guide farmers on where best to concentrate on when planting their crops in order to improve productivity and crop yield.


Andreas, A., Margareta , A., & Naomi , C. B. (2018). To Cluster, or Not to Cluster: An Analysis of Clusterability Methods. arXiv, 1-30.

Bhagavi, P., & Jyothi, S. (2011). Soil Classification Using Data Mining Techniques: A Comparative Study. International Journal of Engineering Trends and Technology, 55-59.

Charrad, M., Nadia , G., Véronique , B., & Azam , N. (2014). NbClust: An R Package for Determining the Relevant Number of Clusters in a Data Set. Journal of Statistical Software, 1–36.

Chunhui, Y., & Haitao, Y. (2019). Research on K-Value Selection Method of K-Means Clustering Algorithm. Multi Disciplinary Scientific Journals, 1-10.

Fathima, R. M., & Sharmila , K. (2019). Classification of Soil Based on Fuzzy Logics. International Journal ofadvanced Research in Computer and Communication Engineering, 131-136.

Firdaus, S., & Uddin, M. A. (2015). A survey on clustering algorithm and complexity analysis. Intj. Comput. Sci. issues, 62-85.

Gruhn, P., Goletti, F., & Yudelman, M. (2000). Integrated nutrient management, soil fertility, and sustainable agriculture: current issues and future challenges. Intl Food Policy Res Inst.

Han, J., Micheline, K., & Jian , P. (2012). Data Mining: Concepts and Techniques. Boston: Morgan Kaufmann.

Hooman , F., Leila , M., & Narsis , Z. (2015). The Application of Data Mining Techniques in Agricultural Science. Cientia e natura, 108-116.

Jay, G. (2012). Performance Turning of J48 Algorithm for Prediction of Soil Fertility. Asian Journal of Computer Science and Information Technology (AJCSIT), 251-252.

Jeyalaksshmi, S., Rama, V., & Suseendran, G. (2019). Data Mining in Soil and Plant Nutrient Management, Recent Advances and Future Challanges in Organic Crops. International Journal of Recent Technology and Engineering (IJRTE), 213-216.

Kassambara, A., & Mundt, F. (2016). Extract and Visualize the Results of Multivariate Data Analyses. Version 1.0.3.

Kaufman, L., & Peter , R. (1990). Finding Groups in Data: An Introduction to Cluster Analysis.

M A Syakur, B K Khotimah, E M S Rochman, & B D Satoto. (2018). integration K-Means Clustering method and Elbow Method For Identification of The Best Cluster Profile. IOP Conference Series: Materials Science and Engineering (pp. 1-6). IOP


Maathuis, F. (2009). Physiological functions of mineral macronutrients. Current opinion in plant biology, 250–258.

Madhuri , K., Someswari , P., & Divya , B. Y. (2018). A Survey of using Data Mining Techniques for Soil Fertility. International Journal of Engineering & Technology, 917-918.

Maechler, M., Rousseuw, P., Struyf, A., Hubert, M., & Honik, K. (2019). Cluster: Cluster Analysis basis and Extensions. R package, Version 2.1.0.

Makowski, D., Ben-Shacha, M. S., M., S. P., & Lüdecke, D. (2019). Methods and Algorithms for Correlation Analysis in R. Journal of Open Source Software, 51.

Manjula, E., & Djodiltachoumy, S. (2017). Data Mining Technique to analyse soil nutrients based on Hybrid Classification . International Journal of Advance Research in Computer Science, 505-509.

Marzieh, M., Mahdi , N.-G., & Abdol Rassoul , Z. (2017). Using Self-Organizing Maps for Determination of Soil Fertility. Soil and Water Ress., 11-17.

Muneshwara, M. S., Abigail, A. G., Neha, C. G., Preethi, & Akarsh, S. (2020). Soil Fertility Analysis and Crop Prediction Using Machine Learning. International Journal of Innovative Technology & Exploring Engineering (IJITEF).

Nikhita, A., & Abhay, B. (2017). Application of Data Mining Classification Techniques on Soil Data Using R. International Journal of Advances in Electronics and Computer Science, 33-37.

Noor, A. (2017). A Study of Data Mining Tools and Techniques to Agriculture with Application. International Journal of Trend in Research and Development (IJTRD)), 1-4.

Oteros, J., García-Mozo, H., Hervás, M., & C., G. C. (2013). Year clustering analysis for modelling olive flowering phenology. Int J Biometeorol, 545-547.

Rajeswari, V., & Arunesh, K. (2016). Analysing Soil Data Using Data Mining Classification Techniques. Indian Journal of Science and Technology, 1-4.

Rani, Y., & Rohil, H. (2013). A study of hierarchical clustering algorithm . Intl. J. Inf. Comput. Technol, 1115-1122.

Rounak, J. (2018). Applying Naive Bayes Classification Technique for Classification of Improved Agricultural Land Soil. International Journal for Research in Applied Sciences and Engineering Technology (IJRASET), 189-193.

Samundeerswari, K., & Srinivasan, K. (2020). Soil Data Analysis & Crop Yield Prediction in Data Mining Using R-programming. International Journal of Innovative Technology and Exploring Engineering (IJITEE), 1857-1860.

Saranya, N., & Mythili, A. (2020). Classification of Soil and Crop Suggestion Using Machine Learning Techniques. IJERT, 671-673.

Taiyun, W., & Viliam, S. (2017). R package "corrplot: Visualization of correlation matrix (Version 0.84). Retrieved from https:github.com/taiyun/corrplot

Team, R. C. (2013). R: A language and environment for statistical computing.

YiLan, L., & RuTong, Z. (2015). Clustertend: check the clustering tendency. R package version 1.4.

How to Cite
Hassan HayatuI., MohammedA., Ahmad Isma’eelB., & Yusuf AliS. (2020). K-MEANS CLUSTERING ALGORITHM BASED CLASSIFICATION OF SOIL FERTILITY IN NORTH WEST NIGERIA. FUDMA JOURNAL OF SCIENCES, 4(2), 780 - 787. https://doi.org/10.33003/fjs-2020-0402-363