51±¾É«

ImplicitR - Inferring Implicit Assumptions in Data Science Code

On the Project

Higher-level languages such as R and Python are widely used to analyze and visualize research data. In spite of their extensive ecosystems and a plethora of powerful features, data science artifacts face a severe execution and reproducibility crisis, with around 65–74% of R scripts and notebooks being non-executable some time after their publication. These features also make scripts harder to comprehend and maintain, and hinder code reuse, which happens frequently with real-world artifacts.

Many of these problems are due to implicit assumptions: hidden expectations a script has on its environment without stating them anywhere. Such implicit assumptions include expectations on the structure of external data files, on interdependencies between multiple scripts, and on the specific versions of libraries. As long as the original environment is intact, such assumptions go unnoticed. However, once the script is run elsewhere or reused in a new study, they become a serious challenge.

In this project, we build on , our static dataflow analysis framework for R, to infer these assumptions, verify them, and make them explicit in the source code. To do so, we combine 's static analysis with the (partial) execution of scripts with intelligently generated inputs. As a result, researchers learn why their scripts (would) fail to reproduce, reviewers get actionable information for assessing submitted artifacts, and anyone reusing existing analyses with new data or studies can do so without compromising their validity.

German Research Foundation (DFG) - Project number 592763516