Skip to Content
RStudio for R Statistical Computing Cookbook
book

RStudio for R Statistical Computing Cookbook

by Andrea Cirillo
April 2016
Beginner to intermediate content levelBeginner to intermediate
246 pages
5h 20m
English
Packt Publishing
Content preview from RStudio for R Statistical Computing Cookbook

Evaluating your code performance using the profvis package

The profvis package is a powerful tool for line profiling in R.

This package is provided by the RStudio team, and its most appreciated feature is the interactive report that is automatically produced, representing a really effective way of visualizing and investigating time resources requested by each part of your code.

Getting ready

Since the lineprof package is not hosted on CRAN, but on GitHub, we first need it to install the devtools package in order to leverage the install_github function provided by this package.

Moreover, we will use the ggmap package to build the example to be profiled:

install.packages(c("devtools","ggmap")) library(devtools) install_github("rstudio/profvis") library(profvis) ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Practical Data Analysis Using Jupyter Notebook

Practical Data Analysis Using Jupyter Notebook

Marc Wintjen

Publisher Resources

ISBN: 9781784391034Supplemental Content