AI & Computingarticle2026-12-01

Application of Principal Component Analysis to the Karnataka Agricultural Dataset Using R and Python

Open access0 citations

Abstract

Researchers increasingly use statistical methods to find patterns in agricultural data. This study applies Principal Component Analysis (PCA) to an open agricultural dataset from Karnataka, India. The dataset has 3,158 records and six numeric variables: area, rainfall, temperature, yield, humidity and price. Most analyses were conducted in R and three-dimensional PCA plots were created in Python. The variables were checked and their units were clarified. Area, yield and price were highly skewed, so we applied a log transformation to make them more symmetric. Prior to PCA, the Kaiser-Meyer-Olkin (KMO) measure and Bartlett's test were used to evaluate sampling adequacy. The KMO value was borderline (0.50) and, although Bartlett's test was significant (χ² = 35, df = 15, p = 0.0023), the variables showed very weak correlations (|r| ≤ 0.07). As a result, PCA did not provide effective dimensionality reduction: the first five components each explained only about 16-18% of the variance and five components were needed to reach 84.6%. These converging diagnostics indicated that the variables shared little common linear variance, so linear data reduction with PCA was of limited practical value for this dataset. Reporting this negative methodological result was useful for assessing dataset suitability before PCA was used as a preliminary step for subsequent predictive modelling.

// Source

View paper (DOI)Open access versionOpenAlexUniversal Journal of Agricultural ResearchPublished 2026-12-01

Authors: Firdevs Bahşi, Orhan Atakan Gürbüz, M. Cüneyt Bağdatlı

Institutions: Niğde Ömer Halisdemir Üniversitesi