Sunday, October 18, 2026
Science
No Result
View All Result
  • Login
  • HOME
  • SCIENCE NEWS
  • CONTACT US
  • HOME
  • SCIENCE NEWS
  • CONTACT US
No Result
View All Result
Scienmag
No Result
View All Result
Home Science News

New R tool uses machine learning to identify Mexican native maize complexes

October 18, 2026
in Science News
Alan Morgan
By Alan Morgan Scienmag Editorial Profile - Precision Agriculture
Reading Time: 6 mins read
0
New R tool uses machine learning to identify Mexican native maize complexes

New R tool uses machine learning to identify Mexican native maize complexes

65
SHARES
587
VIEWS
Share on FacebookShare on Twitter
ADVERTISEMENT

Deep in the fields of Mexico, where farmers have cultivated maize for thousands of years, an extraordinary diversity of native landraces persists—each one a living archive of genetic adaptation, cultural identity and food security. Yet identifying these varieties has long depended on the slow, subjective judgement of a handful of experts. Now, a team of researchers has unveiled imanr, an open-source R package that harnesses machine learning to classify Mexican native maize racial complexes automatically, achieving balanced accuracy of up to 90 percent and a Cohen’s Kappa coefficient of 0.84. The study, published in the journal One Ecosystem, represents a significant leap forward in the conservation of one of the world’s most important biocultural resources.

Maize (Zea mays L.) is far more than a crop in Mexico. It is a cultural keystone species, deeply intertwined with national identity, indigenous heritage and food sovereignty. The modern maize consumed today descends from its wild ancestor, teosinte (Zea mays ssp. parviglumis), which Mesoamerican peoples began domesticating between 9,000 and 5,000 BCE. Over millennia of co-evolution between domestication and migration, farmers across Mexico’s diverse regions developed unique landraces adapted to specific local conditions, fulfilling nutritional, flavour and resilience demands across a remarkable range of climates and soils.

The classification of Mexican maize has a history spanning more than a century. Early systematic attempts emerged at the turn of the twentieth century, notably the work of E. Lewis Sturtevant, who categorised known varieties into six types based on kernel morphology. The concept of the maize race was not introduced until Anderson and Cutler (1942) incorporated morphological, ecological and cultural attributes into a more comprehensive framework. The foundational taxonomy came with Wellhausen and colleagues in 1951, who identified 25 races and three subraces. During the second half of the twentieth century, research on isozymatic diversity enabled the grouping of Mexican maize races into seven racial complexes based on shared morphological traits, ecological adaptation and genetic similarity. In 2011, the National Commission for Knowledge and Use of Biodiversity (CONABIO) published the results of the Global Maize Project (PGMN), identifying 64 maize landraces in the country, of which 59 were classified as native.

Accurate identification of native maize landraces is essential for conserving adaptive genetic diversity. Each landrace represents a unique set of traits shaped by long-term selection under specific environmental and cultural conditions. The loss of any variety implies the irreversible disappearance of locally adapted genotypes and agronomic strategies that may become vital in future contexts of climate change and food insecurity. Native maize also forms the structural foundation of the traditional milpa system, the intercropped agroecosystem whose functioning and resilience vary significantly across regions depending on which maize varieties interact with companion crops, soil conditions and climate.

Despite this importance, identification of maize landraces still relies on time-consuming, expert-driven procedures. Classical approaches use dichotomous keys and reference collections based on morphological descriptors first systematised in the 1950s, which are often inaccessible or difficult to use for non-specialists. Molecular identification methods exist, yet their adoption is limited by cost and infrastructure barriers. Local communities maintain their own ethnobotanical classification systems, but these are not integrated into formal conservation frameworks. The imanr package was developed to ease access to landrace identification through a computational approach grounded in machine learning, providing automated, accurate and reproducible classification of racial complexes based on simple inputs such as geographical coordinates and accessible morphological traits.

The development of imanr was based on data collected by the Global Maize Project, managed by the National Institute for Forestry, Agriculture and Livestock Research (INIFAP). Two main datasets were used: a 2010 database including 22,932 records with geographic information, producer data, agricultural practices and detailed morphological measurements of ears and plants; and a 2017 database comprising 25,861 records containing only georeferenced information and race classifications. Given the larger diversity of variables available, the 2010 database was selected as the primary training source. A panel of three experts independently evaluated the available variables, establishing criteria for the proportion of complete records, direct relevance and format consistency. Variables with at least 35 percent complete records were considered for inclusion, resulting in a final set of geographic, qualitative and quantitative data.

To ensure compatibility with classification algorithms, qualitative variables were numerically encoded while quantitative variables were normalised to prevent biases arising from differences in scale. Missing values were handled through mean imputation for quantitative variables and mode imputation for qualitative ones. The researchers then explored a range of supervised learning techniques, from simple probabilistic classifiers to advanced ensemble models. The algorithms tested included Naive Bayes, K-Nearest Neighbours, Support Vector Machines, Random Forests, Boosted Ensembles, Neural Networks and Bagged Trees. All models were trained using the tidymodels framework with consistent preprocessing and hyperparameter tuning via cross-validation. The dataset was randomly split into 75 percent for training and 25 percent for testing, with five-fold cross-validation applied within the training phase to optimise hyperparameters.

Evaluation employed four complementary metrics suited to the multi-class and imbalanced nature of the dataset: Balanced Accuracy, which measures average recall across all classes; the F1-score, the harmonic mean of precision and recall; Cohen’s Kappa, which evaluates agreement between predicted and true labels adjusted for chance; and the Area Under the Precision-Recall Curve (AUPRC), which is particularly informative for imbalanced datasets. After training and testing, the Boosted Ensemble model emerged as the best performer, achieving the highest Balanced Accuracy (0.903), F1-score (0.843) and Cohen’s Kappa (0.835), with a high AUPRC of 0.912. In contrast, Naive Bayes performed poorly across all metrics. Random Forests and Bagged Trees showed high performance closely behind, with RF achieving a Balanced Accuracy of 0.893, suggesting that models based on multiple decision trees are particularly adequate for this classification problem.

Hyperparameter tuning revealed the optimal configuration for the final model: a learning rate of approximately 0.057, a sample size of 0.516 and a tree depth of 10. Performance improved as tree depth increased from 1 to 5, then plateaued, suggesting that deeper trees provide diminishing returns due to potential overfitting. The final model was implemented using the xgboost library, with the tidymodels framework employed for preprocessing, metrics evaluation, training and tuning. External validation was conducted using individual maize samples collected in a project documenting the native maize of the Otomi-Tepehua Region. The imanr package is publicly available on CRAN, accompanied by detailed documentation and reproducible examples, while the developing version is open source on GitHub.

To enhance accessibility for users without programming expertise, the team developed an interactive graphical interface using ShinyApps. This web application allows users to upload morphological and geographical data, perform classifications and intuitively visualise results, eliminating the need for any knowledge of R. In the R environment, users can classify individual or batch samples by passing a dataframe with morphological and geographical information; a ready-to-use template is available in the project’s GitHub repository. The function returns the predicted racial complex as a factor vector, while the web app guides users through the input process with numeric values entered directly and qualitative variables selected from predefined dropdown menus, displaying the predicted complex along with a representative image and a summary of its typical characteristics.

The researchers acknowledge several limitations in the current version. The model is restricted to identifying racial complexes, leaving open the possibility of expanding its capabilities to classify primary races, an enhancement that would significantly impact census and genetic diversity monitoring programmes. The training data reflect the state of landrace diversity at the time of collection in 2010, so landraces developed or identified after that date may not be represented. The model also assumes discrete boundaries between racial complexes, whereas maize landraces exist along continuous phenotypic and genetic gradients, especially in transitional regions, a phenomenon of racial mixture that may result in classification ambiguities. While cross-validation with careful hyperparameter tuning mitigated overfitting risk, true external validation across independent and temporally updated datasets remains limited. Retraining the model with updated or region-specific datasets, while technically feasible, involves considerable computational cost.

Nevertheless, the findings demonstrate that imanr not only surpasses conventional methods in terms of efficiency but also offers an accessible tool for conserving and monitoring native maize diversity, aligning with the recommendations of the Global Maize Project. The Boosted Ensemble model proved computationally efficient, delivering reliable classifications in short time frames even with large datasets—a significant advantage over traditional identification methods that depend on expert judgement, prolonged evaluation times and elevated costs. By offering a scalable and accessible solution, imanr constitutes a substantial advancement in the modernisation of native maize racial complex classification, supporting broader efforts to modernise agrobiodiversity monitoring and reinforcing the importance of integrating computational tools into conservation strategies for this essential genetic resource.

Subject of Research: imanr: An R tool for the identification of Mexican native maize complexes

Article Title: imanr : An R tool for the identification of Mexican native maize complexes

Article References: Sanchez-Porras, A., Romero-Natale, A., Acevedo-Sandoval, O., & Guerra-Castro, E. (2025). imanr: An R tool for the identification of Mexican native maize complexes. One Ecosystem, 10, Article e149055. https://doi.org/10.3897/oneeco.10.e149055

Image Credits: AI Generated

DOI: 10.3897/oneeco.10.e149055

Keywords: imanr, tool, identification, Mexican, native, maize, complexes, scientific research

Cite Scienmag News

Alan Morgan. (October 18, 2026). New R tool uses machine learning to identify Mexican native maize complexes. Scienmag. https://scienmag.com/new-r-tool-uses-machine-learning-to-identify-mexican-native-maize-complexes/

Alan Morgan. "New R tool uses machine learning to identify Mexican native maize complexes." Scienmag, 18 October 2026, https://scienmag.com/new-r-tool-uses-machine-learning-to-identify-mexican-native-maize-complexes/. Accessed 18 October 2026.

Alan Morgan. "New R tool uses machine learning to identify Mexican native maize complexes." Scienmag. October 18, 2026. https://scienmag.com/new-r-tool-uses-machine-learning-to-identify-mexican-native-maize-complexes/

Tags: agricultural biodiversity conservationAI-based crop identificationbiocultural conservation of maizecomplexescrop landrace preservationfood security and maize biodiversityidentificationimanrindigenous maize varietiesmachine learning in crop identificationmaizemaize genetic adaptationMaize landrace classificationMexicanMexican maize cultural heritagenativenative Mexican maize genetic diversityopen-source R tools for plant classificationScientific Researchtool
Share26Tweet16
Previous Post

Hidden Fungal Species Behind Leaf Spots on China’s Oak Forests Revealed by DNA Sleuthing

Next Post

Two New Cave Bristletail Species Elevate Balkans to European Subterranean Hotspot

Related Posts

Landmark Study Maps 406 Rare Diseases and COVID-19 Infection Across 62.5 Million People in England
Technology and Engineering

Landmark Study Maps 406 Rare Diseases and COVID-19 Infection Across 62.5 Million People in England

October 18, 2026
New funnel-web spider species from Brazil’s Cerrado pushes a once-Amazonian genus far south
Biology

New funnel-web spider species from Brazil’s Cerrado pushes a once-Amazonian genus far south

October 18, 2026
Two New Cave Bristletail Species Elevate Balkans to European Subterranean Hotspot
Biology

Two New Cave Bristletail Species Elevate Balkans to European Subterranean Hotspot

October 18, 2026
Hidden Fungal Species Behind Leaf Spots on China’s Oak Forests Revealed by DNA Sleuthing
Biology

Hidden Fungal Species Behind Leaf Spots on China’s Oak Forests Revealed by DNA Sleuthing

October 18, 2026
Invasive brine shrimp rapidly reshapes hypersaline ecosystems and disrupts bird parasites
Science News

Invasive brine shrimp rapidly reshapes hypersaline ecosystems and disrupts bird parasites

October 18, 2026
ChatGPT is quietly reshaping medical school, but most students are using it wrong
Science Education

ChatGPT is quietly reshaping medical school, but most students are using it wrong

October 18, 2026
Next Post
Two New Cave Bristletail Species Elevate Balkans to European Subterranean Hotspot

Two New Cave Bristletail Species Elevate Balkans to European Subterranean Hotspot

  • Mothers who receive childcare support from maternal grandparents show more optimized

    Mothers who receive childcare support from maternal grandparents show more parental warmth, finds NTU Singapore study

    27656 shares
    Share 11059 Tweet 6912
  • University of Seville Breaks 120-Year-Old Mystery, Revises a Key Einstein Concept

    1061 shares
    Share 424 Tweet 265
  • Bee body mass, pathogens and local climate influence heat tolerance

    682 shares
    Share 273 Tweet 171
  • Researchers record first-ever images and data of a shark experiencing a boat strike

    546 shares
    Share 218 Tweet 137
  • Groundbreaking Clinical Trial Reveals Lubiprostone Enhances Kidney Function

    531 shares
    Share 212 Tweet 133
Science

Embark on a thrilling journey of discovery with Scienmag.com—your ultimate source for cutting-edge breakthroughs. Immerse yourself in a world where curiosity knows no limits and tomorrow’s possibilities become today’s reality!

RECENT NEWS

  • Landmark Study Maps 406 Rare Diseases and COVID-19 Infection Across 62.5 Million People in England
  • New funnel-web spider species from Brazil’s Cerrado pushes a once-Amazonian genus far south
  • Two New Cave Bristletail Species Elevate Balkans to European Subterranean Hotspot
  • New R tool uses machine learning to identify Mexican native maize complexes

Categories

  • Agriculture
  • Anthropology
  • Archaeology
  • Athmospheric
  • Biology
  • Biotechnology
  • Blog
  • Bussines
  • Cancer
  • Chemistry
  • Climate
  • Earth Science
  • Editorial Policy
  • Marine
  • Mathematics
  • Medicine
  • Pediatry
  • Policy
  • Psychology & Psychiatry
  • Science Education
  • Science News
  • Social Science
  • Space
  • Technology and Engineering

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 5,149 other subscribers

© 2025 Scienmag - Science Magazine

Welcome Back!

Login to your account below

Forgotten Password?

Retrieve your password

Please enter your username or email address to reset your password.

Log In
No Result
View All Result
  • HOME
  • SCIENCE NEWS
  • CONTACT US

© 2025 Scienmag - Science Magazine

Discover more from Science

Subscribe now to keep reading and get access to the full archive.

Continue reading