Translating IT Research into Code: Applying a C5.0 Decision Tree to Spine Classification
Tags: Machine Learning, Data Processing, R, Academic Research, C5.0
The Context: Assisting in IT Research
Back in 2019, during my college years, I had the opportunity to step outside the standard academic curriculum and assist my IT lecturer, Ulfi Saidata Aesyi, with her research. Her work explored the application and efficacy of machine learning algorithms on complex, sensitive datasets.
To benchmark and test these algorithms, her research utilized a publicly available orthopedic dataset. The primary objective was to classify the biomechanical features of the vertebral column to identify abnormalities—such as disk hernia or spondylolisthesis—versus a normal, healthy spine. While she designed the overarching IT research methodology and selected the algorithms to be evaluated, my role was strictly technical: I was tasked with building the programmatic script that would process this public data and execute the machine learning model she was studying.
The Requirement: Why the C5.0 Algorithm?
In academic IT research, you cannot simply feed data into a library and blindly accept the output; the mechanics of the algorithm itself must be heavily scrutinized. For this specific phase of her research, she chose a Decision Tree architecture—the C5.0 algorithm.
The goal was to utilize an explainable model. A decision tree works by splitting data based on a series of clear, logical questions, ultimately generating a literal flowchart of decisions. This transparency allowed the research to trace exactly how the algorithm handled specific biomechanical features (like pelvic tilt or sacral slope) and at what mathematical thresholds it decided to flag an abnormality. My job was to ensure the code accurately captured and outputted these decision pathways so they could be properly documented and analyzed in her research paper.
The Technical Implementation with R
I was not inventing a new algorithm from scratch. Instead, my responsibility was to build a robust pipeline to execute the C5.0 model exactly to the research specifications. To do this, I utilized R—a programming language heavily favored in academic and statistical research for its powerful data processing and modeling libraries.
The development process required a highly structured approach to data handling. Even though we were using a public dataset, orthopedic data contains sensitive numeric attributes that require careful treatment. The initial phases of my R script were heavily focused on exploratory data analysis (EDA) and data formatting. I had to ensure that the data frames feeding into the algorithm were processed correctly without losing their structural integrity.
Once the data was clean, I implemented the decision tree model using R's specific C5.0 packages. One of the strongest features of the C5.0 algorithm is its native "winnowing" capability—automatically identifying and discarding attributes that do not significantly contribute to the final classification. My script ultimately outputted both the accuracy metrics of the classification and a visual representation (plot) of the decision tree. This gave the lead researcher exactly what she needed: a transparent, human-readable path of logical deductions to analyze and include in her findings.
The Takeaway: Engineering for Academic Methodologies
Looking back at this 2019 project, it served as a foundational lesson in technical implementation. It taught me that my job as a developer is not always to write the most complex code possible, but to choose the right tools—like leveraging R for statistical transparency—to faithfully execute a specific methodology.
By focusing on clean data processing and utilizing the right libraries for an explainable model, I was able to provide my lecturer with a reliable programmatic tool that advanced her academic work. It reinforced a principle I carry into my enterprise consulting projects today: code must be specifically tailored to serve the exact analytical needs of the stakeholder.
You can view the R script and the pipeline for this project on my GitHub: spine-c50-decision-tree