Predicting Insect Emergence
by Bridget Baron
Introduction
From the grass you walk on to the food you eat, and even the clothes you wear, your daily life relies upon insects. Urban life often feels disconnected from nature, but that could not be further from the truth as urban life relies upon the global ecosystem. Because the global ecosystem is propped up by insects, it is not an exaggeration to say that human beings are reliant on insects for our survival. As such, scientists spend significant time tracking insect populations.
This report discusses the reasons why tracking insect populations is important, as well as summarizes my exploration of using one example of software scientists predicting insect emergence, the Degree-Days, Risk, and Phenological event mapping (DDRP) program created by Brittany S Barker, Leonard Coop, Tyson Wepprich, Fritzi Grevstad, and Gericke Cook.
Insects and Agriculture
75% of all crop plants depend on insects for pollination (National Geographic). This includes food crops as well as plants like cotton that are used to produce textiles. Insects maintain healthy soils, as well. Dung beetles, among others, are insects that specialize in the decomposition of decaying organic matter. They return nutrients to the soils, which allow more plants to grow and keep the circle of life turning. There have even been some cases where introducing termites into arid fields made them fertile again within less than a year (National Geographic). Termites and other ground-burrowing insects (like ants!) aerate soils with their tunnels. This allows water, oxygen, and nutrients to reach deeper down and protects soil quality (National Geographic).
However, not all insects are beneficial to agriculture. Pests are insects that consume or destroy beneficial or domesticated plants. In the United States, several of the most harmful pests are invasive species, such as the Emerald Ash Borer Beetle and the Asian Longhorned Beetle (USDA). Invasive species come from other ecosystems and are often generalists. Generalists are not reliant upon a single source of food and adapt well to competition and new environments (i.e. raccoons). Conversely, many native species are specialists. These are species that have evolved to rely on a small number of food sources to avoid competition (i.e. pandas). These species often play vital roles in their native ecosystems but are very vulnerable to competition when an aggressive invasive species arrives to eat their food and use their habitats.
(Photo by the Author: New York Carpenter Ant Camponotus novaeboracensis)
My Project
After becoming interested in insect tracking, I stumbled across an open-source program called DDRP (Degree-Days, Risk, and Phenological event mapping). It uses weather data to calculate degree-days (measures of heating-cooling within a single day) and temperature stress to insects. DDRP then uses that information to predict the emergence, number of generations, and present life stages of various invasive insects.
I decided to learn how the program worked and try running it for myself by following these detailed instructions. While attempting to run the program on my home PC, I encountered various challenges:
I knew very little about programming and had no knowledge of R, the language used to create DDRP. To learn, I followed beginner tutorials such as Codecademy’s R lesson series and utilized ChatGPT to interpret sections of code I was unfamiliar with over the course of six weeks.
I also faced various issues with my setup. One issue was that the program could not create a template file of the specified region. The reason for this was that some of the optional sets of instructions of code (called packages), like Rgdal, that DDRP relies on are no longer supported in R. I had to uninstall R and RStudio and download an older version that ran all of the packages I needed.
I then had some difficulties regarding the permissions for my file system. Something was preventing my files and folders from being taken off of “read-only” status. I spent several hours troubleshooting this via Google, ChatGPT, and Perplexity.ai, but was not able to completely resolve the issue without risking damage to my computer by changing its operational code.
There was one other major issue I was unable to resolve completely. For some reason, after changing to an older instance of R, the inputs were being nullified. This prevented the program from actually running the calculations that it needed to in order to operate. In order to diagnose the issue, I edited the code to have the computer print the values of the “year” variable as well as the “keep_leap” variable. These were the two values that were being nullified. Their purposes are to specify the start year for the calculations, and to specify whether the 366th day in leap years should be factored into the calculations.
A screenshot of the program crashing while attempting to create the template.
A screenshot of the variable nullification issue.
Conclusion
Ultimately, I wasn't able to get the program successfully and completely running on my device, but I learned a lot. I strongly encourage others with an interest in data science – especially as it relates to environmental science – to conduct research and leverage programs like DDRP. It might or might not end up working as expected, but it’s the process of trying things and learning from mistakes that creates the toolset to advocate for change. It’s our world. We all have a part to play in taking care of it.
About Me
Hello! My name is Bridget Baron and I’m an upcoming first year at Barnard College in New York City. As a Senior at Alexandria City High School in Alexandria, VA, I worked as an intern at the Virginia Tech Thinkabit Lab. My major scientific interests are climate change and insects, and working with the VT Thinkabit Lab gave me the opportunity to explore one of the cross-sections between those two: insect phenology. My research into the phenological cycles of insects, and how they’re impacted by climate change, is what led me to this particular research project.