Opportunities and limitations of the <scp>ChatGPT</scp> Advanced Data Analysis plugin for hydrological analyses
Dylan J. Irvine, Landon J. S. Halloran, Philip Brunner
Abstract
Abstract Artificial intelligence (AI) tools, such as ChatGPT, have already changed the way that many industries operate. Much of the recent discussion surrounding AI tools has focused on their ability to generate text and the associated ethical concerns. Recent developments with the ChatGPT Code Interpreter, now called the Advanced Data Analysis plugin, demonstrate that AI's growing abilities in the generation, translation and adaptation of computer scripts also offer significant potential to change the way that data analyses are conducted. We demonstrate the new capabilities of ChatGPT, providing four worked examples of prompt‐based generation of Python scripts to analyse hydrological datasets. Our examples include (1) converting R functions to Python to perform baseflow separation, (2) converting MATLAB functions to Python to ‘web scrape’ temperature data, (3) creating a correlation matrix of major ion groundwater data, and (4) presenting boxplots of river flow data. We discuss the significant opportunities, current limitations and concerns relating to the use of ChatGPT in hydrological data analyses.