Talk to the Veterans Crisis Line now
U.S. flag
An official website of the United States government

VA Health Systems Research

Go to the VA ORD website
Go to the QUERI website

VA Informatics and Computing Infrastructure

Profiling and Optimizing R Code

by Andrew Redd, PhD
Seminar date: 3/10/2022

Description: Profiling is a method of analyzing how a program runs. This gives details such as memory usage, computation time, etcetera. When asking the VINCI helpdesk for assistance optimizing a program to deal with memory or computation time issues, you will likely be asked to provide a profile file. This presentation will show how to create code profiles for R code, as well as the tools that are available to perform analysis on the resulting data, including examples before and after optimizations.

Intended Audience: The presentation is directed at intermediate R programmers, but the principles apply in other languages such as SAS and Python.

View archived session video:

DOWNLOAD: PDF handout | Audio only (mp3) | transcript

Questions about the HSR website? Email the Web Team

Any health information on this website is strictly for informational purposes and is not intended as medical advice. It should not be used to diagnose or treat any condition.