Beginner's Guide to Computation in Statistical Research

From Stat DS Computing Wiki

While the foundations of statistical methods are grounded in mathematical theory, we often need to demonstrate that these methods are useful in practice. This can done via toy examples, simulation studies, and applications to real-world datasets. We do not recommend spending hundreds of hours running calculations on datasets by hand. Thus, we will introduce the reader to core concepts of statistical computing and relevant resources in the CMU Department of Statistics and Data Science.

Implementation

The main aim for statistical computing is to implement proposed algorithms in code such that they can be applied to a variety of inputs very quickly. These implementations can be as simple as computing the OLS coefficients to optimizing a billion-parameter neural network.

These implementations are usually achieved through computer programming. As a student in the Statistics department, you will be exposed to a variety of programming languages and tools. Below is a reading list of first steps to get you started on your computation journey

Title Description Reading Time?
Choosing and Installing a Programming Language Helping you decide between R, Python, etc 5 minutes
Installing and Configuring an Integrated Development Environment Your coding program is just as important as your programming language
Other Helpful Resources for Implementation Things like AI, CMU Courses, and informational seminars

Scale and Efficiency

Once you have gotten the hang of implementing statistical algorithms in code, the next major hurdle will be making your workflows scalable and efficient. For code running on your own machine, you want to make sure you are using every CPU core and every bit of RAM as efficiently as possible. Even then, your personal computer alone can only get you so far. Thankfully, the department also provides several options for remote high-performance computing for even the largest of research workflows.

Title Description Reading Time?
Parallelization: Making the most of your Machine How to run many experiments at once
Building Workflows on Remote Servers Using the department servers and other computing clusters
Big Data Management How to handle datasets that are measured in terabytes

Reproducibility and Collaboration

While it is important that you are able to obtain results efficiently, it is also equally important for other member of the academic community to arrive at your same results independently. Specifically, others should be able to run your workflow and obtain the exact same output as you did with minimal tinkering and friction.

Title Description Reading Time?
Version Control Keeping track of code/experiment history
Dependency Management Making sure anyone else in the world can run your workflow

Software Development

Topics like